jolbol1 / jolly-ui

shadcn/ui compatible react aria components that you can copy and paste into your apps. Accessible. Customizable. Open Source.
https://jollyui.dev
MIT License
544 stars 13 forks source link

Some components not 1-to-1 with shadcn/ui #8

Closed brandonmcconnell closed 3 months ago

brandonmcconnell commented 5 months ago

Some components are not 1-to-1 with shadcn/ui.

In the case of the combobox (shadcn | jolly), for example, one is a field you can click and type into while the other acts more like a button.

I think it would be most helpful if both the components and examples led a 1:1 relationship to shadcn/ui, especially if the goal is to be a direct and more accessible alternative until shadcn/ui switches to using React Aria or similar.

jolbol1 commented 5 months ago

I see the point. In the case of the combobox, it was actually the first reason the library started, as the shadcn implementation relies on cmdk and seemed bulky for the simpler stuff.

I'll see if I can modify it to have a variant closer to shadcn and add some examples. If there's any other components let me know.

Another possible option is adding a callout where parity isn't possible.

brandonmcconnell commented 5 months ago

Also, for the existing variant, often when I click into the field the suggestions do not appear unless I specifically click on the arrows. It would be great if—at least by default—it revealed those suggestions when focused and filtered them as you type.

jolbol1 commented 5 months ago

@brandonmcconnell for that you can change the prop menuTrigger to be "input". See Adobe docs

I will considering making this the default behavior and if not at least ensuring there is an example or its well documented.

Thanks for the input!

brandonmcconnell commented 3 months ago

@jolbol1 Thanks! I think it could really help to keep the baseline with consistent parity to shadcn/ui, as even slight differences could complicate a migration to jolly-ui in the future, unless the goal is actually to keep this package standalone and not merge into shadcn/ui at some point.

jolbol1 commented 3 months ago

Hey @brandonmcconnell, I think it comes down to this:

To summarize and clarify the key points:

Does this clear things up? Any more thoughts let me know!

brandonmcconnell commented 3 months ago

That makes a ton of sense! Thanks for clearing that up 🙂