|
6 | 6 | > [!NOTE]
|
7 | 7 | > This is a work in progress. For some components the necessary libraries are coming soon (e.g. [Radix NG](https://www.radix-ng.com/primitives/overview/introduction)).
|
8 | 8 |
|
9 |
| -- Built with Angular and TailwindCSS |
| 9 | +- Built with Angular and TailwindCSS v4 |
10 | 10 | - RadixNG and Angular CDK
|
11 | 11 | - Zoneless enable!
|
12 | 12 |
|
|
16 | 16 |
|
17 | 17 | ### Prerequisites
|
18 | 18 |
|
19 |
| -- [TailwindCSS v3](https://v3.tailwindcss.com/) |
| 19 | +- [TailwindCSS v4](https://tailwindcss.com/) |
20 | 20 | - [Radix Angular](https://radix-ng.com)
|
21 | 21 | - [Angular CDK](https://material.angular.io/cdk/categories)
|
22 | 22 | - [Lucide Angular](https://lucide.dev/guide/packages/lucide-angular)
|
|
31 | 31 | npm install @origin-ui/components
|
32 | 32 | ```
|
33 | 33 |
|
34 |
| -### CSS Variables |
| 34 | +### Tailwind v4 CSS Variables |
35 | 35 | Import the CSS in your `style.css` file (the following is based on tailwindcss):
|
36 | 36 |
|
37 | 37 | ```css
|
38 |
| -@layer base { |
39 |
| - :root { |
40 |
| - --background: 0 0% 100%; |
41 |
| - --foreground: 240 10% 3.9%; |
42 |
| - --card: 0 0% 100%; |
43 |
| - --card-foreground: 240 10% 3.9%; |
44 |
| - --popover: 0 0% 100%; |
45 |
| - --popover-foreground: 240 10% 3.9%; |
46 |
| - --primary: 240 5.9% 10%; |
47 |
| - --primary-foreground: 0 0% 98%; |
48 |
| - --secondary: 240 4.8% 95.9%; |
49 |
| - --secondary-foreground: 240 5.9% 10%; |
50 |
| - --muted: 240 4.8% 95.9%; |
51 |
| - --muted-foreground: 240 3.8% 46.1%; |
52 |
| - --accent: 240 4.8% 95.9%; |
53 |
| - --accent-foreground: 240 5.9% 10%; |
54 |
| - --destructive: 0 84.2% 60.2%; |
55 |
| - --destructive-foreground: 0 0% 100%; |
56 |
| - --border: 240 5.9% 90%; |
57 |
| - --input: 240 4.9% 83.9%; |
58 |
| - --ring: 240 5% 64.9%; |
59 |
| - --radius: 0.5rem; |
60 |
| - } |
61 |
| - .dark { |
62 |
| - --background: 240 10% 3.9%; |
63 |
| - --foreground: 0 0% 98%; |
64 |
| - --card: 240 10% 3.9%; |
65 |
| - --card-foreground: 0 0% 98%; |
66 |
| - --popover: 240 10% 3.9%; |
67 |
| - --popover-foreground: 0 0% 98%; |
68 |
| - --primary: 0 0% 98%; |
69 |
| - --primary-foreground: 240 5.9% 10%; |
70 |
| - --secondary: 240 3.7% 15.9%; |
71 |
| - --secondary-foreground: 0 0% 98%; |
72 |
| - --muted: 240 5.9% 10%; |
73 |
| - --muted-foreground: 240 4.4% 58%; |
74 |
| - --accent: 240 5.9% 10%; |
75 |
| - --accent-foreground: 0 0% 98%; |
76 |
| - --destructive: 0 84.2% 60.2%; |
77 |
| - --destructive-foreground: 0 0% 100%; |
78 |
| - --border: 240 3.7% 15.9%; |
79 |
| - --input: 240 3.7% 15.9%; |
80 |
| - --ring: 240 3.8% 46.1%; |
81 |
| - } |
| 38 | +:root { |
| 39 | + --background: oklch(1 0 0); |
| 40 | + --foreground: oklch(0.141 0.005 285.823); |
| 41 | + --card: oklch(1 0 0); |
| 42 | + --card-foreground: oklch(0.141 0.005 285.823); |
| 43 | + --popover: oklch(1 0 0); |
| 44 | + --popover-foreground: oklch(0.141 0.005 285.823); |
| 45 | + --primary: oklch(0.21 0.006 285.885); |
| 46 | + --primary-foreground: oklch(0.985 0 0); |
| 47 | + --secondary: oklch(0.967 0.001 286.375); |
| 48 | + --secondary-foreground: oklch(0.21 0.006 285.885); |
| 49 | + --muted: oklch(0.967 0.001 286.375); |
| 50 | + --muted-foreground: oklch(0.55 0.01 286); |
| 51 | + --accent: oklch(0.967 0.001 286.375); |
| 52 | + --accent-foreground: oklch(0.21 0.006 285.885); |
| 53 | + --destructive: oklch(0.637 0.237 25.331); |
| 54 | + --destructive-foreground: oklch(0.637 0.237 25.331); |
| 55 | + --border: oklch(0.92 0 286); |
| 56 | + --input: oklch(0.871 0.006 286.286); |
| 57 | + --ring: oklch(0.871 0.006 286.286); |
| 58 | + --chart-1: oklch(0.646 0.222 41.116); |
| 59 | + --chart-2: oklch(0.6 0.118 184.704); |
| 60 | + --chart-3: oklch(0.398 0.07 227.392); |
| 61 | + --chart-4: oklch(0.828 0.189 84.429); |
| 62 | + --chart-5: oklch(0.769 0.188 70.08); |
| 63 | + --radius: 0.625rem; |
| 64 | + --sidebar: oklch(0.985 0 0); |
| 65 | + --sidebar-foreground: oklch(0.141 0.005 285.823); |
| 66 | + --sidebar-primary: oklch(0.21 0.006 285.885); |
| 67 | + --sidebar-primary-foreground: oklch(0.985 0 0); |
| 68 | + --sidebar-accent: oklch(0.967 0.001 286.375); |
| 69 | + --sidebar-accent-foreground: oklch(0.21 0.006 285.885); |
| 70 | + --sidebar-border: oklch(0.92 0.004 286.32); |
| 71 | + --sidebar-ring: oklch(0.871 0.006 286.286); |
| 72 | +} |
| 73 | + |
| 74 | +.dark { |
| 75 | + --background: oklch(0.141 0.005 285.823); |
| 76 | + --foreground: oklch(0.985 0 0); |
| 77 | + --card: oklch(0.141 0.005 285.823); |
| 78 | + --card-foreground: oklch(0.985 0 0); |
| 79 | + --popover: oklch(0.141 0.005 285.823); |
| 80 | + --popover-foreground: oklch(0.985 0 0); |
| 81 | + --primary: oklch(0.985 0 0); |
| 82 | + --primary-foreground: oklch(0.21 0.006 285.885); |
| 83 | + --secondary: oklch(0.274 0.006 286.033); |
| 84 | + --secondary-foreground: oklch(0.985 0 0); |
| 85 | + --muted: oklch(0.21 0.006 285.885); |
| 86 | + --muted-foreground: oklch(0.65 0.01 286); |
| 87 | + --accent: oklch(0.21 0.006 285.885); |
| 88 | + --accent-foreground: oklch(0.985 0 0); |
| 89 | + --destructive: oklch(0.396 0.141 25.723); |
| 90 | + --destructive-foreground: oklch(0.637 0.237 25.331); |
| 91 | + --border: oklch(0.274 0.006 286.033); |
| 92 | + --input: oklch(0.274 0.006 286.033); |
| 93 | + --ring: oklch(0.442 0.017 285.786); |
| 94 | + --chart-1: oklch(0.488 0.243 264.376); |
| 95 | + --chart-2: oklch(0.696 0.17 162.48); |
| 96 | + --chart-3: oklch(0.769 0.188 70.08); |
| 97 | + --chart-4: oklch(0.627 0.265 303.9); |
| 98 | + --chart-5: oklch(0.645 0.246 16.439); |
| 99 | + --sidebar: oklch(0.205 0 0); |
| 100 | + --sidebar-foreground: oklch(0.985 0 0); |
| 101 | + --sidebar-primary: oklch(0.488 0.243 264.376); |
| 102 | + --sidebar-primary-foreground: oklch(0.985 0 0); |
| 103 | + --sidebar-accent: oklch(0.269 0 0); |
| 104 | + --sidebar-accent-foreground: oklch(0.985 0 0); |
| 105 | + --sidebar-border: oklch(0.274 0.006 286.033); |
| 106 | + --sidebar-ring: oklch(0.442 0.017 285.786); |
82 | 107 | }
|
83 | 108 | ```
|
84 | 109 |
|
|
0 commit comments