fiddle
fiddle copied to clipboard
Better UX for expired PAT for Gist publishing
When a GitHub PAT expires, we pop up a dialog that says that the auth was invalid. To remedy this, the user needs to manually sign out in the settings afterwards and generate a new token.
As a UX improvement, we should redirect to the settings prompt as an option in the dialog, or at least clear the invalid token.
The current warning popup is based on the showWarningDialogue.
- The problem with the dialogue popup is the messageOptions props button field are defined as
String[]. - As a result, we can't toggle the settings panel or can't perform any other operation to the user actions.
- We can show a toast when the user's Github access token is expired. The toast will be more user-friendly when compared to the current
showWarningDialogue. - Here is a possible solution that will help users to quickly navigate to the settings menu with the help of Toast, in order to redirect to settings & remove their expired github token.
Let me know your suggestions / alternatives. I am happy to contribute & will send a pull request to solve this issue.