Repository navigation
**NOT A WORKING COMMIT** Demo purpose branch to show possible solutions to TailwindCSS & Radix UI css variables issue - #11
Open
chanmSC wants to merge 1 commit into
Conversation
Not a working solution, using this branch for demo/discussion jumping off point of the theme variables management/use issue between TailwindCSS & Radix UI
Contributor
Author
|
A bunch of decisions have been made in offline meeting between @stmudie @pcsmomo , with the actionable plan being:
|
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Note This branch is not a working solution, this PR is purely for easy diffs demo/discussion jumping off point of the theme variables management/use issue between TailwindCSS & Radix UI.
Things that need to be discussed/decided:
CSS module elements would need to be rewritten with purely tailwindcss (not a discussion point, just something important to note)Not true, we can totally use css modules, and for more complex styling, I would recommend it, as it's a lot more legible/maintainable than super crazy long text stringsstyle.cssto export both the tailwindcss and radix css variables?Some components aren't exporting/builti.e.import { Badge } from '@australiansynchrotron/sci-comp-ui'Can notice the missing exports fromThis has been fixed now, it was because some vanilla shadcn components weren't being re-exported, we now do these direct handball exports clearly inindex.es.js(as in they're not there)src/shadcn.tsWhat happens when we have a custom version of an existing Radix component?If we extend a shadcn component (and there's no existing custom alternative), then we should treat it as a custom component, i.e. create ui component/element file, create doc example file, export it fromsrc/index.tsi.e. Buttons, Form InputsShould we prefer non-radix components, as they're less likely to visual/behaviourally change based on 3rd party (Radix UI) decisionsYes, because shadcn has already been adding non-radix-ui components, and have started adding components imported from other libraries, this won't be great for maintenance going ahead, so it's custom component without heavy external package dependencies should be preferred where possibleShould we agree on sth like Radix can be used for components without an existing custom component, and in situations where it's less of an issue if we need to upgrade Radix and they change those components visually/behaviourally)?Yes, this should be the main use case, and we've made it easier to support ppl using shadcn components without breaking changes when a custom version of the component is made with the@australiansynchrotron/sci-comp-uivs@australiansynchrotron/sci-comp-ui/shadcnseparate import paths (so ppl can migrate to our custom components in their own time)Should we be doubling up on Radix UI component docs?No, we shouldn't double up on shadcn vanilla component docs, we should only create & maintain docs for our custom components/elements, this will also apply for when we add testing laterShould we prefer non-radix components in the docs?We should make a decided distinction between what components go into sci-comp-ui docs, and what we leave for ppl to refer to radix-ui docs?