-
Notifications
You must be signed in to change notification settings - Fork 877
chore: add Select component #16121
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
chore: add Select component #16121
Conversation
<SelectPrimitive.Content | ||
ref={ref} | ||
className={cn( | ||
"relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border border-border border-solid bg-surface-primary text-content-primary shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2", |
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.
For long Tailwind class names, I have been following the pattern of using multi-line strings to make these easier to read. See some of the other existing shadcn components.
)); | ||
SelectSeparator.displayName = SelectPrimitive.Separator.displayName; | ||
|
||
export { |
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.
So far I have been exporting in place instead of the bottom of the file for the shadcn components as this matches the current patterns in the codebase.
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
Related to #15297 and based on this design.