-
Notifications
You must be signed in to change notification settings - Fork 38
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(ToggleGroup): ✨ New ToggleGroup
component
#813
Conversation
ToggleGroup
component
Co-authored-by: Michael Marszalek <[email protected]>
9d45959
to
b14b3c6
Compare
Storybook preview deployment is available at https://storybook-2ke3oh28q-designsystemet.vercel.app |
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.
packages/react/src/components/ToggleGroup/ToggleGroupItem/useToggleGroupitem.ts
Outdated
Show resolved
Hide resolved
packages/react/src/components/ToggleGroup/ToggleGroup.stories.tsx
Outdated
Show resolved
Hide resolved
packages/react/src/components/ToggleGroup/ToggleGroup.stories.tsx
Outdated
Show resolved
Hide resolved
packages/react/src/components/ToggleGroup/ToggleGroup.stories.tsx
Outdated
Show resolved
Hide resolved
Co-authored-by: Michael Marszalek <[email protected]>
Co-authored-by: Michael Marszalek <[email protected]>
Co-authored-by: Michael Marszalek <[email protected]>
Suggest also updating the Overview.mdx to point to this new "felles" component :) |
Co-authored-by: Michael Marszalek <[email protected]>
Co-authored-by: Michael Marszalek <[email protected]>
Co-authored-by: Michael Marszalek <[email protected]>
…oggleGroupitem.ts Co-authored-by: Michael Marszalek <[email protected]>
Co-authored-by: Michael Marszalek <[email protected]>
Storybook preview deployment is available at https://storybook-b69hri3mk-designsystemet.vercel.app |
Storybook preview deployment is available at https://storybook-1ko0pw5a3-designsystemet.vercel.app |
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.
Some more suggestions on docs else looking good! 👍
packages/react/src/components/ToggleGroup/ToggleGroup.stories.tsx
Outdated
Show resolved
Hide resolved
packages/react/src/components/ToggleGroup/ToggleGroup.stories.tsx
Outdated
Show resolved
Hide resolved
Co-authored-by: Michael Marszalek <[email protected]>
Co-authored-by: Michael Marszalek <[email protected]>
Co-authored-by: Michael Marszalek <[email protected]> Co-authored-by: Michael Marszalek <[email protected]>
ToggleGroup
ToggleGroup
component which can be populated byToggleGroup.Item
s and allow for one of the items to be active by handling the value of theToggleGroup
.ToggleGroup
s value can be both controlled using state and uncontrolled.defaultValue
.ToggleGroup
is usingRovingTabindexRoot
as adiv
, and theToggleGroup.Item
is usingRovingTabindexItem
as a designsysstemButton
.Roving Tabindex:
ToggleGroup
is handled by the newRovingTabindex
utility component.RovingTabindexItem
in the extensible componentRovingTabindexRoot
. You can then tab in and out of theRovingTabindexRoot
and only one of the items will be focused.Example usage:
Resolves: #805