-
Notifications
You must be signed in to change notification settings - Fork 100
feat(empty-state): new SHINE styles and Svelte Component #2100
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
base: beta
Are you sure you want to change the base?
Conversation
🦋 Changeset detectedLatest commit: 6ca500c The changes in this PR will be included in the next version bump. 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 |
✅ Deploy Preview for stacks-svelte ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
✅ Deploy Preview for stacks ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
This reverts commit c24783d.
dancormier
left a 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.
Thanks for building this out @mukunku. I have a few suggestions to tidy things up and reinforce a bit more consistency across the component/library. Nothing too out there. Let me know if anything could use clarification
packages/stacks-classic/lib/components/empty-state/empty-state.less
Outdated
Show resolved
Hide resolved
packages/stacks-svelte/src/components/EmptyState/EmptyState.stories.svelte
Outdated
Show resolved
Hide resolved
packages/stacks-svelte/src/components/EmptyState/EmptyState.svelte
Outdated
Show resolved
Hide resolved
packages/stacks-classic/lib/components/empty-state/empty-state.less
Outdated
Show resolved
Hide resolved
packages/stacks-svelte/src/components/ExpandingInput/ExpandingInput.svelte
Outdated
Show resolved
Hide resolved
| <div class={["s-empty-state", className]}> | ||
| <Icon src={SpotEmpty} native /> | ||
| {#if title} | ||
| <h4 class="s-empty-state__title">{title}</h4> |
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.
Since heading levels are dependent on context, maybe it would make sense to do one of the following:
- Add a prop to the
EmptyStatecomponent fortitleTagortitleHeadingLevel - Provide a
EmptyStateTitlecomponent that renders using asvelte:elementtag. It could provide a prop ofheadingLevelortag(with a default value)
I'm probably leaning towards the first solution but I could be swayed. If we go with either, we can limit the potential tags by typing the prop "h2" | "h3" | ….
What do you think @mukunku?
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.
That's a good idea 👍🏾 I went with allowing any tag the user wants for the most flexibility: b4fb2ae
dancormier
left a 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.
Great work @mukunku ❤️
Summary
This PR:
EmptyStateSvelte componentExpandingInputto Svelte 5 syntax.How to Test
EmptyStateSvelte component: https://deploy-preview-2100--stacks-svelte.netlify.app/?path=/docs/components-emptystate--docsExpandingInputworks again: https://deploy-preview-2100--stacks-svelte.netlify.app/?path=/docs/components-expandinginput--docs