-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Show instructional UI if main.js updating fails #41
Show instructional UI if main.js updating fails #41
Conversation
AP-3485 Display the project token and project id to the user in case of failure - enable user to configure manually.
When a user selects a project from the project picker, we automatically add these to the main.js file. However, in the event that the user has a very custom configuration, there is a possibility that adding it automatically will fail. This is a suggestion that we display the project token and project id that the user selects, before trying to automatically add it to the storybook configuration. In this case, it may also make sense to provide a prompt to the user before trying to automatically modify their configuration. Perhaps a secondary button that skips automatic configuration (and lets the user know how to manually configure it). Otherwise, we would always attempt to configure it and potentially break their configuration. Even in the event of a failure, the projectToken and projectId are stored in localstorage on the client and an environment variable on the server to not require a storybook restart, so the addon allows the user to continue without finishing the configuration step. This may not be an issue, but if we allow user to manually update, then this may lead to some confusion if they skip manually and automatically updating it. |
…he-project-token-and-project-id-to-the-user-in-case
Add a new event to tell manager if we failed + UI as per design here: https://linear.app/chromaui/issue/AP-3485#comment-0767a585
To QA:
options
frommain.js
updateMain.ts
📦 Published PR as canary version:
0.0.41--canary.41.7576b70.0
✨ Test out this PR locally via:
npm install @chromaui/addon-visual-tests@0.0.41--canary.41.7576b70.0 # or yarn add @chromaui/addon-visual-tests@0.0.41--canary.41.7576b70.0