-
Notifications
You must be signed in to change notification settings - Fork 0
[PB-3520]: add HeadlessPopover component with accessibility support #73
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: master
Are you sure you want to change the base?
Conversation
Introduces a new HeadlessPopover component built with @headlessui/react, providing enhanced accessibility features including ARIA support, keyboard navigation, and focus management. The component supports flexible APIs including render props, custom styling, transitions, and static mode.
08ced9b to
592893b
Compare
| "storybook:build": "storybook build" | ||
| }, | ||
| "dependencies": { | ||
| "@headlessui/react": "1.7.5", |
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’m not totally convinced about adding a new library for the headless setup, so I created a separate popover component instead of changing the existing one. Curious what you think
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.
The fewer dependencies on third parties, the better. Why use this library compared to what we already have?
CandelR
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.
Remember to add the storybook of the component and the snapshot tests :)
| * </HeadlessPopover> | ||
| * ``` | ||
| * | ||
| * **Note:** If `children` prop is provided, all other props (trigger, panel, etc.) are ignored. |
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 think that classname it applies
| * @returns {JSX.Element} | ||
| * - The rendered HeadlessPopover component. | ||
| */ | ||
| export default function HeadlessPopover({ |
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.
Is not totally headless because it already has default style :O
| "storybook:build": "storybook build" | ||
| }, | ||
| "dependencies": { | ||
| "@headlessui/react": "1.7.5", |
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.
The fewer dependencies on third parties, the better. Why use this library compared to what we already have?
Introduces a new HeadlessPopover component built with @headlessui/react, providing
enhanced accessibility features including ARIA support, keyboard navigation, and
focus management. The component supports flexible APIs including render props, custom
styling, transitions, and static mode.