mirror of
https://github.com/supabase/supabase.git
synced 2026-06-28 03:19:09 -04:00
0abe792889
This PR migrates the JS config for Tailwind into a CSS config. As such, all variables have been defined as CSS variables and they're using the specialized Tailwind syntax for generating utility classes. Beside the migration, these changes were also added: - Added `tailwind.config.css` to few packages to make the Tailwind Intellisense work. - Migrated away from Radix style color classes to our defined classes, the values will remain the same. - Most of the CSS is generated by scripts, they'll be removed in next PRs. * Removed redundant `border-light` classes from several components since it was undefined. * Removed redundant `text-strong` classes from several components since it was undefined. How to test: - Open all apps, compare the UI (mainly colors) to builds from #45417 and try to find a difference. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Style** * Harmonized color variable usages and updated UI color references (affects palettes, charts, gradients, hero illustrations, and scrollbars). * Tweaked border, tab, and selection visuals across components. * **New Features** * Added a suite of theme animations and refined typography presets used by site prose and docs. * **Refactor** * Overhauled Tailwind/theme configuration and color token generation for more consistent theming. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
31 lines
1.1 KiB
CSS
31 lines
1.1 KiB
CSS
/*
|
|
* Custom Tailwind v4 variants migrated from:
|
|
* - packages/config/ui.config.js addVariant calls
|
|
* - packages/config/tailwind.config.js addVariant + darkMode setting
|
|
*/
|
|
|
|
/*
|
|
* `darkMode: ['class', '[data-theme*="dark"]']` from the v3 config is replaced
|
|
* by this @custom-variant. The :where() wrapper keeps specificity at 0 so
|
|
* the dark utilities don't override unrelated rules.
|
|
*/
|
|
@custom-variant dark (&:where([data-theme*='dark'] *, [data-theme*='dark']));
|
|
|
|
@custom-variant data-open-parent ([data-state='open'] &);
|
|
@custom-variant data-closed-parent ([data-state='closed'] &);
|
|
@custom-variant data-open (&[data-state='open']);
|
|
@custom-variant data-closed (&[data-state='closed']);
|
|
|
|
/* may be unused — verify before pruning */
|
|
@custom-variant data-show (&[data-state='show']);
|
|
/* may be unused — verify before pruning */
|
|
@custom-variant data-hide (&[data-state='hide']);
|
|
|
|
@custom-variant data-checked (&[data-state='checked']);
|
|
/* may be unused — verify before pruning */
|
|
@custom-variant data-unchecked (&[data-state='unchecked']);
|
|
|
|
@custom-variant aria-expanded (&[aria-expanded='true']);
|
|
|
|
@custom-variant not-disabled (&:not(:disabled));
|