-
Notifications
You must be signed in to change notification settings - Fork 6
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
feat: add storybook #115
feat: add storybook #115
Conversation
🦋 Changeset detectedLatest commit: 4638481 The changes in this PR will be included in the next version bump. This PR includes changesets to release 4 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
This pull request is being automatically deployed with Vercel (learn more). 🔍 Inspect: https://vercel.com/blockstack/blockstack-ui/4kQ6Ak44tqy8FuWNtNZ8dCSzU7TN [Deployment for f7522f8 failed] |
Nice one @fbwoolf. My preference would be to put the stories of a given component in with the component itself. Thoughts? |
Yeah, I like that idea. I can do a sample story for one of our components for this PR and remove the generated examples. |
Was going to try and wrap this up, realized maybe this shouldn't be at the root level but just in the |
Makes sense. I think stories should be coupled as close to components themselves as possible. |
fe3bd4f
to
a3413f8
Compare
@aulneau @kyranjamie this can be reviewed again. I dug in a bit to how best handled with a monorepo and was suggested to leave installed at the root, but move stories into the packages where needed. I removed the default stories and created a sample |
a3413f8
to
c9d731d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM @fbwoolf—though what are the jsxRuntime comments for, can that be configured elsewhere than comments?
I was running into this error |
I ended up trying a few other suggestions, but nothing worked. This is where I found the current solution: emotion-js/emotion#2041 (comment) @aulneau any thoughts or ok with what I added? |
c9d731d
to
c1531db
Compare
c1531db
to
36ad56b
Compare
36ad56b
to
fa732e1
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great, I'd just prefer to make any pragma changes to storybook config instead of the components themselves
packages/ui/src/spinner.tsx
Outdated
@@ -1,3 +1,4 @@ | |||
/** @jsxRuntime classic */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would this work instead? https://duncanleung.com/emotion-css-prop-jsx-pragma-storybook/
or maybe this? storybookjs/storybook#12881 (comment) setting it to "classic"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
or perhaps this storybookjs/storybook#12952 (comment)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried a few things, but can't remem if any of these specifically ...let me try.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried these but can't get them to work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This ended up working: storybookjs/storybook#7540 (comment)
fa732e1
to
c498486
Compare
@fbwoolf awesome, feel free to merge |
How do I get past the deploy failure to merge it? |
c498486
to
f7522f8
Compare
@fbwoolf sorry seems like there are conflicts -- can you rebase? I've disconnected vercel so that should no longer fail |
Yep, will do. Thx! |
f7522f8
to
4638481
Compare
Description
This PR adds Storybook to the UI library making the following changes:
For details refer to issue #50
Type of Change
Does this introduce a breaking change?
No.
Are documentation updates required?
TBD.