css-is-awesome 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +343 -0
- package/CHANGELOG.md +1036 -0
- package/CLAUDE.md +9 -0
- package/CONTRACT.md +580 -0
- package/GEMINI.md +9 -0
- package/LICENSE +21 -0
- package/LICENSE-third-party +88 -0
- package/MIGRATION.md +312 -0
- package/README.md +380 -0
- package/ROADMAP.md +714 -0
- package/THEMING.md +290 -0
- package/THREE-TIERS.md +158 -0
- package/VERSIONING.md +200 -0
- package/_index.scss +34 -0
- package/api.scss +16 -0
- package/bin/README.md +57 -0
- package/bin/cia.cjs +114 -0
- package/bin/migrate-bootstrap.cjs +427 -0
- package/bin/migrate-tailwind.cjs +832 -0
- package/css-is-awesome.instructions.md +533 -0
- package/dist/css-is-awesome.core.css +598 -0
- package/dist/css-is-awesome.core.min.css +1 -0
- package/dist/css-is-awesome.css +3733 -0
- package/dist/css-is-awesome.min.css +1 -0
- package/dist/css-is-awesome.utilities.css +2445 -0
- package/dist/css-is-awesome.utilities.min.css +1 -0
- package/dist/tokens.css +508 -0
- package/dist/tokens.d.ts +266 -0
- package/dist/tokens.min.css +1 -0
- package/figma-tokens/README.md +57 -0
- package/figma-tokens/primitives-brand.scss +121 -0
- package/figma-tokens/semantic-dark.scss +61 -0
- package/figma-tokens/semantic-light.scss +61 -0
- package/figma-tokens/tokens.json +144 -0
- package/llm.txt +183 -0
- package/mcp/server.cjs +1495 -0
- package/package.json +199 -0
- package/public/icons/README.md +278 -0
- package/public/icons/arrow-right.svg +4 -0
- package/public/icons/check.svg +4 -0
- package/public/icons/chevron-down.svg +4 -0
- package/public/icons/close.svg +4 -0
- package/public/icons/core/arrow-down.svg +13 -0
- package/public/icons/core/arrow-left.svg +13 -0
- package/public/icons/core/arrow-right.svg +13 -0
- package/public/icons/core/arrow-up.svg +13 -0
- package/public/icons/core/bell.svg +13 -0
- package/public/icons/core/calendar.svg +15 -0
- package/public/icons/core/check.svg +12 -0
- package/public/icons/core/chevron-down.svg +12 -0
- package/public/icons/core/chevron-left.svg +12 -0
- package/public/icons/core/chevron-right.svg +12 -0
- package/public/icons/core/chevron-up.svg +12 -0
- package/public/icons/core/clock.svg +13 -0
- package/public/icons/core/close.svg +13 -0
- package/public/icons/core/copy.svg +13 -0
- package/public/icons/core/download.svg +14 -0
- package/public/icons/core/edit.svg +13 -0
- package/public/icons/core/error.svg +14 -0
- package/public/icons/core/external-link.svg +14 -0
- package/public/icons/core/eye-off.svg +15 -0
- package/public/icons/core/eye.svg +13 -0
- package/public/icons/core/filter.svg +12 -0
- package/public/icons/core/heart.svg +12 -0
- package/public/icons/core/help.svg +14 -0
- package/public/icons/core/home.svg +13 -0
- package/public/icons/core/info.svg +14 -0
- package/public/icons/core/loading.svg +12 -0
- package/public/icons/core/lock.svg +13 -0
- package/public/icons/core/mail.svg +13 -0
- package/public/icons/core/menu.svg +14 -0
- package/public/icons/core/message.svg +12 -0
- package/public/icons/core/minus.svg +12 -0
- package/public/icons/core/more-horizontal.svg +14 -0
- package/public/icons/core/pause.svg +13 -0
- package/public/icons/core/play.svg +12 -0
- package/public/icons/core/plus.svg +13 -0
- package/public/icons/core/refresh.svg +15 -0
- package/public/icons/core/save.svg +14 -0
- package/public/icons/core/search.svg +13 -0
- package/public/icons/core/settings.svg +13 -0
- package/public/icons/core/share.svg +14 -0
- package/public/icons/core/sort.svg +15 -0
- package/public/icons/core/star.svg +12 -0
- package/public/icons/core/success.svg +13 -0
- package/public/icons/core/trash.svg +16 -0
- package/public/icons/core/unlock.svg +13 -0
- package/public/icons/core/upload.svg +14 -0
- package/public/icons/core/user.svg +13 -0
- package/public/icons/core/users.svg +15 -0
- package/public/icons/core/warning.svg +14 -0
- package/public/icons/download.svg +4 -0
- package/public/icons/edit.svg +4 -0
- package/public/icons/menu.svg +4 -0
- package/public/icons/search.svg +4 -0
- package/public/theme.css +4179 -0
- package/public/themes/README.md +102 -0
- package/public/themes/boilerplate/theme.css +154 -0
- package/public/themes/boilerplate-dark/theme.css +171 -0
- package/public/themes/boilerplate-light/theme.css +171 -0
- package/public/themes/cupertino/theme.css +165 -0
- package/public/themes/cupertino-dark/theme.css +200 -0
- package/public/themes/cupertino-light/theme.css +227 -0
- package/public/themes/glass/theme.css +190 -0
- package/public/themes/glass-dark/theme.css +201 -0
- package/public/themes/glass-light/theme.css +229 -0
- package/public/themes/graphite/theme.css +155 -0
- package/public/themes/graphite-dark/theme.css +223 -0
- package/public/themes/graphite-light/theme.css +191 -0
- package/public/themes/press/theme.css +189 -0
- package/public/themes/press-dark/theme.css +199 -0
- package/public/themes/press-light/theme.css +235 -0
- package/public/themes/prism/theme.css +159 -0
- package/public/themes/prism-dark/theme.css +185 -0
- package/public/themes/prism-light/theme.css +188 -0
- package/public/themes/sketchbook/theme.css +152 -0
- package/public/themes/sketchbook-dark/theme.css +194 -0
- package/public/themes/sketchbook-light/theme.css +188 -0
- package/public/themes/terminal/theme.css +159 -0
- package/public/themes/terminal-dark/theme.css +229 -0
- package/public/themes/terminal-light/theme.css +152 -0
- package/scripts/README.md +70 -0
- package/scripts/icon-contract.json +67 -0
- package/scripts/icon-validator.js +205 -0
- package/scripts/prepare-dist.mjs +65 -0
- package/scripts/theme-a11y.js +415 -0
- package/scripts/theme-contract.json +171 -0
- package/scripts/theme-validator.js +674 -0
- package/scss/README.md +55 -0
- package/scss/_animations-utilities.scss +107 -0
- package/scss/_animations.scss +248 -0
- package/scss/_app-styles.scss +15 -0
- package/scss/_generator.scss +174 -0
- package/scss/_icons.scss +475 -0
- package/scss/_index.scss +17 -0
- package/scss/_layout.scss +597 -0
- package/scss/_mixins.scss +1036 -0
- package/scss/_system.scss +291 -0
- package/scss/_utilities.scss +377 -0
- package/scss/api.scss +61 -0
- package/scss/components/_accordion.scss +72 -0
- package/scss/components/_buttons.scss +171 -0
- package/scss/components/_copy-button.scss +69 -0
- package/scss/components/_data.scss +190 -0
- package/scss/components/_feedback.scss +197 -0
- package/scss/components/_forms.scss +272 -0
- package/scss/components/_index.scss +17 -0
- package/scss/components/_navigation.scss +186 -0
- package/scss/components/_overlay.scss +259 -0
- package/scss/components/_stepper.scss +159 -0
- package/scss/components/_tabs.scss +72 -0
- package/scss/core.scss +54 -0
- package/scss/examples/_theming.scss +107 -0
- package/scss/examples/_usage.scss +317 -0
- package/scss/main.scss +64 -0
- package/scss/recipes/README.md +110 -0
- package/scss/recipes/_bare-tags.scss +232 -0
- package/scss/recipes/_recipe-template.md +119 -0
- package/scss/recipes/combobox.md +509 -0
- package/scss/recipes/dialog.md +265 -0
- package/scss/recipes/print-to-pdf.md +263 -0
- package/scss/theme/README.md +67 -0
- package/scss/theme/_brand.scss +18 -0
- package/scss/theme/_colors-dark.scss +68 -0
- package/scss/theme/_colors-light.scss +70 -0
- package/scss/theme/_components.scss +94 -0
- package/scss/theme/_icons.scss +104 -0
- package/scss/theme/_index.scss +62 -0
- package/scss/theme/_shadows.scss +65 -0
- package/scss/theme/_shape.scss +13 -0
- package/scss/theme/_typography.scss +9 -0
- package/scss/theme/registry.json +447 -0
- package/scss/themes/boilerplate-dark.scss +212 -0
- package/scss/themes/boilerplate-light.scss +209 -0
- package/scss/themes/boilerplate.scss +181 -0
- package/scss/themes/cupertino-dark.scss +238 -0
- package/scss/themes/cupertino-light.scss +266 -0
- package/scss/themes/cupertino.scss +194 -0
- package/scss/themes/glass-dark.scss +238 -0
- package/scss/themes/glass-light.scss +266 -0
- package/scss/themes/glass.scss +220 -0
- package/scss/themes/graphite-dark.scss +260 -0
- package/scss/themes/graphite-light.scss +228 -0
- package/scss/themes/graphite.scss +182 -0
- package/scss/themes/press-dark.scss +237 -0
- package/scss/themes/press-light.scss +273 -0
- package/scss/themes/press.scss +241 -0
- package/scss/themes/prism-dark.scss +217 -0
- package/scss/themes/prism-light.scss +220 -0
- package/scss/themes/prism.scss +190 -0
- package/scss/themes/sketchbook-dark.scss +231 -0
- package/scss/themes/sketchbook-light.scss +231 -0
- package/scss/themes/sketchbook.scss +178 -0
- package/scss/themes/terminal-dark.scss +267 -0
- package/scss/themes/terminal-light.scss +175 -0
- package/scss/themes/terminal.scss +185 -0
- package/scss/tokens.scss +23 -0
- package/scss/utilities-only.scss +4 -0
|
@@ -0,0 +1,291 @@
|
|
|
1
|
+
// ============================================================================
|
|
2
|
+
// SYSTEM - Universal Constants (Same across ALL projects)
|
|
3
|
+
// ============================================================================
|
|
4
|
+
// Compile-time values. NOT themed. NOT imported from Figma.
|
|
5
|
+
// Breakpoints, z-index, spacing scale, font sizes, weights, line heights.
|
|
6
|
+
// These feed into the generator and mixin API.
|
|
7
|
+
// ============================================================================
|
|
8
|
+
@use 'sass:map';
|
|
9
|
+
|
|
10
|
+
// ----------------------------------------------------------------------------
|
|
11
|
+
// SPACING - 4px base unit system
|
|
12
|
+
// Numbered scale 1..9 is the source of truth (matches Radix, Open Props, IBM
|
|
13
|
+
// Carbon). T-shirt aliases layer on top for readability.
|
|
14
|
+
//
|
|
15
|
+
// Mapping:
|
|
16
|
+
// xs -> 1 (0.5rem / 8px)
|
|
17
|
+
// sm -> 2 (0.75rem / 12px)
|
|
18
|
+
// -- -> 3 (0.875rem / 14px, gap — no t-shirt alias)
|
|
19
|
+
// md -> 4 (1rem / 16px)
|
|
20
|
+
// lg -> 5 (1.5rem / 24px)
|
|
21
|
+
// xl -> 6 (2rem / 32px)
|
|
22
|
+
// 2xl -> 7 (3rem / 48px)
|
|
23
|
+
// 3xl -> 8 (4rem / 64px)
|
|
24
|
+
// 4xl -> 9 (6rem / 96px)
|
|
25
|
+
//
|
|
26
|
+
// Extras (outside the numbered scale but retained as aliases): 0, none, 2xs.
|
|
27
|
+
// All values in rem for accessibility (scales with user preferences).
|
|
28
|
+
// ----------------------------------------------------------------------------
|
|
29
|
+
|
|
30
|
+
// Numbered scale — source of truth
|
|
31
|
+
$spacing-scale: (
|
|
32
|
+
1: 0.5rem, // 8px
|
|
33
|
+
2: 0.75rem, // 12px
|
|
34
|
+
3: 0.875rem, // 14px (gap — intentional, no t-shirt alias)
|
|
35
|
+
4: 1rem, // 16px
|
|
36
|
+
5: 1.5rem, // 24px
|
|
37
|
+
6: 2rem, // 32px
|
|
38
|
+
7: 3rem, // 48px
|
|
39
|
+
8: 4rem, // 64px
|
|
40
|
+
9: 6rem, // 96px
|
|
41
|
+
) !default;
|
|
42
|
+
|
|
43
|
+
// T-shirt aliases — numeric key each t-shirt resolves to
|
|
44
|
+
$spacing-aliases: (
|
|
45
|
+
xs: 1,
|
|
46
|
+
sm: 2,
|
|
47
|
+
md: 4,
|
|
48
|
+
lg: 5,
|
|
49
|
+
xl: 6,
|
|
50
|
+
2xl: 7,
|
|
51
|
+
3xl: 8,
|
|
52
|
+
4xl: 9,
|
|
53
|
+
) !default;
|
|
54
|
+
|
|
55
|
+
// Combined lookup: numbered scale + t-shirt aliases + legacy extras.
|
|
56
|
+
// Both `space(4)` and `space(md)` resolve to 1rem.
|
|
57
|
+
$spacing: map.merge(
|
|
58
|
+
$spacing-scale,
|
|
59
|
+
(
|
|
60
|
+
// Legacy / extra aliases (not on the numbered scale)
|
|
61
|
+
0: 0,
|
|
62
|
+
none: 0,
|
|
63
|
+
2xs: 0.25rem,
|
|
64
|
+
|
|
65
|
+
// T-shirt aliases resolve to the same value as the numeric key
|
|
66
|
+
xs: map.get($spacing-scale, map.get($spacing-aliases, xs)),
|
|
67
|
+
sm: map.get($spacing-scale, map.get($spacing-aliases, sm)),
|
|
68
|
+
md: map.get($spacing-scale, map.get($spacing-aliases, md)),
|
|
69
|
+
lg: map.get($spacing-scale, map.get($spacing-aliases, lg)),
|
|
70
|
+
xl: map.get($spacing-scale, map.get($spacing-aliases, xl)),
|
|
71
|
+
2xl: map.get($spacing-scale, map.get($spacing-aliases, 2xl)),
|
|
72
|
+
3xl: map.get($spacing-scale, map.get($spacing-aliases, 3xl)),
|
|
73
|
+
4xl: map.get($spacing-scale, map.get($spacing-aliases, 4xl)),
|
|
74
|
+
)
|
|
75
|
+
) !default;
|
|
76
|
+
|
|
77
|
+
// ----------------------------------------------------------------------------
|
|
78
|
+
// FONT SIZES - Type scale
|
|
79
|
+
// Numbered scale 1..10 is the source of truth; t-shirt aliases layer on top.
|
|
80
|
+
//
|
|
81
|
+
// Mapping:
|
|
82
|
+
// xs -> 1 (0.75rem)
|
|
83
|
+
// sm -> 2 (0.875rem)
|
|
84
|
+
// base -> 3 (1rem)
|
|
85
|
+
// lg -> 4 (1.125rem)
|
|
86
|
+
// xl -> 5 (1.25rem)
|
|
87
|
+
// 2xl -> 6 (1.5rem)
|
|
88
|
+
// 3xl -> 7 (1.875rem)
|
|
89
|
+
// 4xl -> 8 (2.25rem)
|
|
90
|
+
// 5xl -> 9 (3rem)
|
|
91
|
+
// 6xl -> 10 (3.75rem)
|
|
92
|
+
// ----------------------------------------------------------------------------
|
|
93
|
+
|
|
94
|
+
$font-sizes-scale: (
|
|
95
|
+
1: 0.75rem, // 12px
|
|
96
|
+
2: 0.875rem, // 14px
|
|
97
|
+
3: 1rem, // 16px
|
|
98
|
+
4: 1.125rem, // 18px
|
|
99
|
+
5: 1.25rem, // 20px
|
|
100
|
+
6: 1.5rem, // 24px
|
|
101
|
+
7: 1.875rem, // 30px
|
|
102
|
+
8: 2.25rem, // 36px
|
|
103
|
+
9: 3rem, // 48px
|
|
104
|
+
10: 3.75rem, // 60px
|
|
105
|
+
) !default;
|
|
106
|
+
|
|
107
|
+
$font-sizes-aliases: (
|
|
108
|
+
xs: 1,
|
|
109
|
+
sm: 2,
|
|
110
|
+
base: 3,
|
|
111
|
+
lg: 4,
|
|
112
|
+
xl: 5,
|
|
113
|
+
2xl: 6,
|
|
114
|
+
3xl: 7,
|
|
115
|
+
4xl: 8,
|
|
116
|
+
5xl: 9,
|
|
117
|
+
6xl: 10,
|
|
118
|
+
) !default;
|
|
119
|
+
|
|
120
|
+
$font-sizes: map.merge(
|
|
121
|
+
$font-sizes-scale,
|
|
122
|
+
(
|
|
123
|
+
xs: map.get($font-sizes-scale, map.get($font-sizes-aliases, xs)),
|
|
124
|
+
sm: map.get($font-sizes-scale, map.get($font-sizes-aliases, sm)),
|
|
125
|
+
base: map.get($font-sizes-scale, map.get($font-sizes-aliases, base)),
|
|
126
|
+
lg: map.get($font-sizes-scale, map.get($font-sizes-aliases, lg)),
|
|
127
|
+
xl: map.get($font-sizes-scale, map.get($font-sizes-aliases, xl)),
|
|
128
|
+
2xl: map.get($font-sizes-scale, map.get($font-sizes-aliases, 2xl)),
|
|
129
|
+
3xl: map.get($font-sizes-scale, map.get($font-sizes-aliases, 3xl)),
|
|
130
|
+
4xl: map.get($font-sizes-scale, map.get($font-sizes-aliases, 4xl)),
|
|
131
|
+
5xl: map.get($font-sizes-scale, map.get($font-sizes-aliases, 5xl)),
|
|
132
|
+
6xl: map.get($font-sizes-scale, map.get($font-sizes-aliases, 6xl)),
|
|
133
|
+
)
|
|
134
|
+
) !default;
|
|
135
|
+
|
|
136
|
+
// ----------------------------------------------------------------------------
|
|
137
|
+
// FONT WEIGHTS
|
|
138
|
+
// ----------------------------------------------------------------------------
|
|
139
|
+
$font-weights: (
|
|
140
|
+
light: 300,
|
|
141
|
+
normal: 400,
|
|
142
|
+
medium: 500,
|
|
143
|
+
semibold: 600,
|
|
144
|
+
bold: 700,
|
|
145
|
+
"black": 900,
|
|
146
|
+
) !default;
|
|
147
|
+
|
|
148
|
+
// ----------------------------------------------------------------------------
|
|
149
|
+
// LINE HEIGHTS
|
|
150
|
+
// Numbered scale 1..6 is the source of truth; named aliases layer on top.
|
|
151
|
+
//
|
|
152
|
+
// Mapping:
|
|
153
|
+
// none -> 1 (1.0)
|
|
154
|
+
// tight -> 2 (1.25)
|
|
155
|
+
// snug -> 3 (1.375)
|
|
156
|
+
// normal -> 4 (1.5)
|
|
157
|
+
// relaxed -> 5 (1.625)
|
|
158
|
+
// loose -> 6 (2.0)
|
|
159
|
+
// ----------------------------------------------------------------------------
|
|
160
|
+
|
|
161
|
+
$line-heights-scale: (
|
|
162
|
+
1: 1,
|
|
163
|
+
2: 1.25,
|
|
164
|
+
3: 1.375,
|
|
165
|
+
4: 1.5,
|
|
166
|
+
5: 1.625,
|
|
167
|
+
6: 2,
|
|
168
|
+
) !default;
|
|
169
|
+
|
|
170
|
+
$line-heights-aliases: (
|
|
171
|
+
none: 1,
|
|
172
|
+
tight: 2,
|
|
173
|
+
snug: 3,
|
|
174
|
+
normal: 4,
|
|
175
|
+
relaxed: 5,
|
|
176
|
+
loose: 6,
|
|
177
|
+
) !default;
|
|
178
|
+
|
|
179
|
+
$line-heights: map.merge(
|
|
180
|
+
$line-heights-scale,
|
|
181
|
+
(
|
|
182
|
+
none: map.get($line-heights-scale, map.get($line-heights-aliases, none)),
|
|
183
|
+
tight: map.get($line-heights-scale, map.get($line-heights-aliases, tight)),
|
|
184
|
+
snug: map.get($line-heights-scale, map.get($line-heights-aliases, snug)),
|
|
185
|
+
normal: map.get($line-heights-scale, map.get($line-heights-aliases, normal)),
|
|
186
|
+
relaxed: map.get($line-heights-scale, map.get($line-heights-aliases, relaxed)),
|
|
187
|
+
loose: map.get($line-heights-scale, map.get($line-heights-aliases, loose)),
|
|
188
|
+
)
|
|
189
|
+
) !default;
|
|
190
|
+
|
|
191
|
+
// ----------------------------------------------------------------------------
|
|
192
|
+
// LETTER SPACING
|
|
193
|
+
// ----------------------------------------------------------------------------
|
|
194
|
+
$letter-spacings: (
|
|
195
|
+
tighter: -0.05em,
|
|
196
|
+
tight: -0.025em,
|
|
197
|
+
normal: 0em,
|
|
198
|
+
wide: 0.025em,
|
|
199
|
+
wider: 0.05em,
|
|
200
|
+
widest: 0.1em,
|
|
201
|
+
) !default;
|
|
202
|
+
|
|
203
|
+
// ----------------------------------------------------------------------------
|
|
204
|
+
// BREAKPOINTS — direction-agnostic (rem for accessibility)
|
|
205
|
+
// Pair with m.media / m.media-down / m.media-between per design intent;
|
|
206
|
+
// cia is responsive, not mobile-first.
|
|
207
|
+
// IMPORTANT: These MUST stay as SCSS values (not CSS vars).
|
|
208
|
+
// @media queries cannot use CSS custom properties.
|
|
209
|
+
// ----------------------------------------------------------------------------
|
|
210
|
+
$breakpoints: (
|
|
211
|
+
sm: 40rem, // 640px
|
|
212
|
+
md: 48rem, // 768px
|
|
213
|
+
lg: 64rem, // 1024px
|
|
214
|
+
xl: 80rem, // 1280px
|
|
215
|
+
2xl: 96rem, // 1536px
|
|
216
|
+
) !default;
|
|
217
|
+
|
|
218
|
+
// Convenience aliases
|
|
219
|
+
$bp-tablet: map.get($breakpoints, md) !default;
|
|
220
|
+
$bp-desktop: map.get($breakpoints, lg) !default;
|
|
221
|
+
|
|
222
|
+
// ----------------------------------------------------------------------------
|
|
223
|
+
// Z-INDEX - Layer system
|
|
224
|
+
// ----------------------------------------------------------------------------
|
|
225
|
+
$z-layers: (
|
|
226
|
+
hide: -1,
|
|
227
|
+
base: 0,
|
|
228
|
+
dropdown: 1000,
|
|
229
|
+
sticky: 1100,
|
|
230
|
+
fixed: 1200,
|
|
231
|
+
backdrop: 1300,
|
|
232
|
+
modal: 1400,
|
|
233
|
+
popover: 1500,
|
|
234
|
+
tooltip: 1600,
|
|
235
|
+
toast: 1700,
|
|
236
|
+
) !default;
|
|
237
|
+
|
|
238
|
+
// ----------------------------------------------------------------------------
|
|
239
|
+
// BORDER WIDTHS
|
|
240
|
+
// ----------------------------------------------------------------------------
|
|
241
|
+
$border-widths: (
|
|
242
|
+
0: 0,
|
|
243
|
+
1: 1px,
|
|
244
|
+
2: 2px,
|
|
245
|
+
4: 4px,
|
|
246
|
+
) !default;
|
|
247
|
+
|
|
248
|
+
// ----------------------------------------------------------------------------
|
|
249
|
+
// DURATIONS - Animation timing
|
|
250
|
+
// ----------------------------------------------------------------------------
|
|
251
|
+
$durations: (
|
|
252
|
+
instant: 0ms,
|
|
253
|
+
fast: 150ms,
|
|
254
|
+
normal: 250ms,
|
|
255
|
+
slow: 400ms,
|
|
256
|
+
slower: 600ms,
|
|
257
|
+
) !default;
|
|
258
|
+
|
|
259
|
+
// ----------------------------------------------------------------------------
|
|
260
|
+
// EASINGS
|
|
261
|
+
// ----------------------------------------------------------------------------
|
|
262
|
+
$easings: (
|
|
263
|
+
linear: linear,
|
|
264
|
+
ease: ease,
|
|
265
|
+
ease-in: ease-in,
|
|
266
|
+
ease-out: ease-out,
|
|
267
|
+
ease-in-out: ease-in-out,
|
|
268
|
+
bounce: cubic-bezier(0.68, -0.55, 0.265, 1.55),
|
|
269
|
+
smooth: cubic-bezier(0.4, 0, 0.2, 1),
|
|
270
|
+
) !default;
|
|
271
|
+
|
|
272
|
+
// ----------------------------------------------------------------------------
|
|
273
|
+
// OPACITY
|
|
274
|
+
// ----------------------------------------------------------------------------
|
|
275
|
+
$opacities: (
|
|
276
|
+
0: 0,
|
|
277
|
+
5: 0.05,
|
|
278
|
+
10: 0.1,
|
|
279
|
+
20: 0.2,
|
|
280
|
+
25: 0.25,
|
|
281
|
+
30: 0.3,
|
|
282
|
+
40: 0.4,
|
|
283
|
+
50: 0.5,
|
|
284
|
+
60: 0.6,
|
|
285
|
+
70: 0.7,
|
|
286
|
+
75: 0.75,
|
|
287
|
+
80: 0.8,
|
|
288
|
+
90: 0.9,
|
|
289
|
+
95: 0.95,
|
|
290
|
+
100: 1,
|
|
291
|
+
) !default;
|
|
@@ -0,0 +1,377 @@
|
|
|
1
|
+
// ============================================================================
|
|
2
|
+
// UTILITIES - Drop-in utility classes (cia- prefix)
|
|
3
|
+
// ============================================================================
|
|
4
|
+
// Generated from existing design tokens. No SCSS knowledge required to use.
|
|
5
|
+
// Usage: <div class="cia-flex cia-p-md cia-bg-surface-subtle cia-rounded-lg">
|
|
6
|
+
// ============================================================================
|
|
7
|
+
@use 'sass:map';
|
|
8
|
+
@use 'sass:list';
|
|
9
|
+
@use 'sass:meta';
|
|
10
|
+
@use './system' as s;
|
|
11
|
+
@use './theme' as t;
|
|
12
|
+
@use './mixins' as m;
|
|
13
|
+
|
|
14
|
+
// ============================================================================
|
|
15
|
+
// SPACING: margin & padding
|
|
16
|
+
// ============================================================================
|
|
17
|
+
// .cia-m-md, .cia-mt-lg, .cia-mx-xl, .cia-p-sm, .cia-py-2xl, etc.
|
|
18
|
+
// ============================================================================
|
|
19
|
+
|
|
20
|
+
$_space-props: (
|
|
21
|
+
m: margin,
|
|
22
|
+
mt: margin-top,
|
|
23
|
+
mr: margin-right,
|
|
24
|
+
mb: margin-bottom,
|
|
25
|
+
ml: margin-left,
|
|
26
|
+
p: padding,
|
|
27
|
+
pt: padding-top,
|
|
28
|
+
pr: padding-right,
|
|
29
|
+
pb: padding-bottom,
|
|
30
|
+
pl: padding-left,
|
|
31
|
+
);
|
|
32
|
+
|
|
33
|
+
$_space-axis: (
|
|
34
|
+
mx: (margin-left, margin-right),
|
|
35
|
+
my: (margin-top, margin-bottom),
|
|
36
|
+
px: (padding-left, padding-right),
|
|
37
|
+
py: (padding-top, padding-bottom),
|
|
38
|
+
);
|
|
39
|
+
|
|
40
|
+
@each $key, $value in s.$spacing {
|
|
41
|
+
@each $prefix, $prop in $_space-props {
|
|
42
|
+
.cia-#{$prefix}-#{$key} { #{$prop}: $value; }
|
|
43
|
+
}
|
|
44
|
+
@each $prefix, $props in $_space-axis {
|
|
45
|
+
.cia-#{$prefix}-#{$key} {
|
|
46
|
+
@each $prop in $props { #{$prop}: $value; }
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
// ============================================================================
|
|
52
|
+
// ACCESSIBILITY UTILITIES
|
|
53
|
+
// ============================================================================
|
|
54
|
+
.cia-sr-only { @include m.sr-only; }
|
|
55
|
+
|
|
56
|
+
// Auto margin utilities
|
|
57
|
+
.cia-m-auto { margin: auto; }
|
|
58
|
+
.cia-mx-auto { margin-left: auto; margin-right: auto; }
|
|
59
|
+
.cia-my-auto { margin-top: auto; margin-bottom: auto; }
|
|
60
|
+
.cia-ml-auto { margin-left: auto; }
|
|
61
|
+
.cia-mr-auto { margin-right: auto; }
|
|
62
|
+
.cia-mt-auto { margin-top: auto; }
|
|
63
|
+
.cia-mb-auto { margin-bottom: auto; }
|
|
64
|
+
|
|
65
|
+
// Gap utilities
|
|
66
|
+
@each $key, $value in s.$spacing {
|
|
67
|
+
.cia-gap-#{$key} { gap: $value; }
|
|
68
|
+
.cia-gap-x-#{$key} { column-gap: $value; }
|
|
69
|
+
.cia-gap-y-#{$key} { row-gap: $value; }
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
// ============================================================================
|
|
73
|
+
// TYPOGRAPHY
|
|
74
|
+
// ============================================================================
|
|
75
|
+
|
|
76
|
+
@each $key, $value in s.$font-sizes {
|
|
77
|
+
.cia-text-#{$key} { font-size: var(--font-size-#{$key}, #{$value}); }
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
@each $key, $value in s.$font-weights {
|
|
81
|
+
.cia-font-#{$key} { font-weight: var(--font-weight-#{$key}, #{$value}); }
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
@each $key, $value in s.$line-heights {
|
|
85
|
+
.cia-leading-#{$key} { line-height: $value; }
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
@each $key, $value in s.$letter-spacings {
|
|
89
|
+
.cia-tracking-#{$key} { letter-spacing: $value; }
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.cia-text-left { text-align: left; }
|
|
93
|
+
.cia-text-center { text-align: center; }
|
|
94
|
+
.cia-text-right { text-align: right; }
|
|
95
|
+
.cia-text-justify { text-align: justify; }
|
|
96
|
+
|
|
97
|
+
.cia-uppercase { text-transform: uppercase; }
|
|
98
|
+
.cia-lowercase { text-transform: lowercase; }
|
|
99
|
+
.cia-capitalize { text-transform: capitalize; }
|
|
100
|
+
.cia-normal-case { text-transform: none; }
|
|
101
|
+
|
|
102
|
+
.cia-underline { text-decoration: underline; }
|
|
103
|
+
.cia-line-through { text-decoration: line-through; }
|
|
104
|
+
.cia-no-underline { text-decoration: none; }
|
|
105
|
+
|
|
106
|
+
.cia-truncate {
|
|
107
|
+
overflow: hidden;
|
|
108
|
+
text-overflow: ellipsis;
|
|
109
|
+
white-space: nowrap;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
.cia-whitespace-nowrap { white-space: nowrap; }
|
|
113
|
+
.cia-whitespace-normal { white-space: normal; }
|
|
114
|
+
.cia-break-words { overflow-wrap: break-word; }
|
|
115
|
+
|
|
116
|
+
// ============================================================================
|
|
117
|
+
// COLORS (semantic tokens via CSS custom properties)
|
|
118
|
+
// ============================================================================
|
|
119
|
+
|
|
120
|
+
$_color-tokens: (
|
|
121
|
+
// Text
|
|
122
|
+
text-primary, text-secondary, text-muted, text-inverse, text-link,
|
|
123
|
+
// Status text
|
|
124
|
+
success-text, warning-text, error-text, info-text,
|
|
125
|
+
);
|
|
126
|
+
|
|
127
|
+
@each $token in $_color-tokens {
|
|
128
|
+
.cia-text-#{$token} { color: var(--#{$token}); }
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
$_bg-tokens: (
|
|
132
|
+
// Backgrounds
|
|
133
|
+
background-default, background-subtle, background-navbar,
|
|
134
|
+
// Surfaces
|
|
135
|
+
surface-default, surface-subtle, surface-muted, surface-emphasis,
|
|
136
|
+
// Status
|
|
137
|
+
success-subtle, warning-subtle, error-subtle, info-subtle,
|
|
138
|
+
// Actions
|
|
139
|
+
action-primary-default, action-secondary-default,
|
|
140
|
+
);
|
|
141
|
+
|
|
142
|
+
@each $token in $_bg-tokens {
|
|
143
|
+
.cia-bg-#{$token} { background-color: var(--#{$token}); }
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
$_border-tokens: (border-default, border-subtle, border-emphasis, border-focus);
|
|
147
|
+
|
|
148
|
+
@each $token in $_border-tokens {
|
|
149
|
+
.cia-border-#{$token} { border-color: var(--#{$token}); }
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
// ============================================================================
|
|
153
|
+
// LAYOUT: display
|
|
154
|
+
// ============================================================================
|
|
155
|
+
|
|
156
|
+
.cia-block { display: block; }
|
|
157
|
+
.cia-inline-block { display: inline-block; }
|
|
158
|
+
.cia-inline { display: inline; }
|
|
159
|
+
.cia-flex { display: flex; }
|
|
160
|
+
.cia-inline-flex { display: inline-flex; }
|
|
161
|
+
.cia-grid { display: grid; }
|
|
162
|
+
.cia-inline-grid { display: inline-grid; }
|
|
163
|
+
.cia-hidden { display: none; }
|
|
164
|
+
.cia-contents { display: contents; }
|
|
165
|
+
|
|
166
|
+
// ============================================================================
|
|
167
|
+
// LAYOUT: flexbox
|
|
168
|
+
// ============================================================================
|
|
169
|
+
|
|
170
|
+
.cia-flex-row { flex-direction: row; }
|
|
171
|
+
.cia-flex-row-reverse { flex-direction: row-reverse; }
|
|
172
|
+
.cia-flex-col { flex-direction: column; }
|
|
173
|
+
.cia-flex-col-reverse { flex-direction: column-reverse; }
|
|
174
|
+
|
|
175
|
+
.cia-flex-wrap { flex-wrap: wrap; }
|
|
176
|
+
.cia-flex-nowrap { flex-wrap: nowrap; }
|
|
177
|
+
.cia-flex-wrap-reverse { flex-wrap: wrap-reverse; }
|
|
178
|
+
|
|
179
|
+
.cia-flex-1 { flex: 1 1 0%; }
|
|
180
|
+
.cia-flex-auto { flex: 1 1 auto; }
|
|
181
|
+
.cia-flex-initial { flex: 0 1 auto; }
|
|
182
|
+
.cia-flex-none { flex: none; }
|
|
183
|
+
.cia-flex-grow { flex-grow: 1; }
|
|
184
|
+
.cia-flex-grow-0 { flex-grow: 0; }
|
|
185
|
+
.cia-flex-shrink { flex-shrink: 1; }
|
|
186
|
+
.cia-flex-shrink-0 { flex-shrink: 0; }
|
|
187
|
+
|
|
188
|
+
// ============================================================================
|
|
189
|
+
// LAYOUT: alignment
|
|
190
|
+
// ============================================================================
|
|
191
|
+
|
|
192
|
+
.cia-items-start { align-items: flex-start; }
|
|
193
|
+
.cia-items-end { align-items: flex-end; }
|
|
194
|
+
.cia-items-center { align-items: center; }
|
|
195
|
+
.cia-items-baseline { align-items: baseline; }
|
|
196
|
+
.cia-items-stretch { align-items: stretch; }
|
|
197
|
+
|
|
198
|
+
.cia-justify-start { justify-content: flex-start; }
|
|
199
|
+
.cia-justify-end { justify-content: flex-end; }
|
|
200
|
+
.cia-justify-center { justify-content: center; }
|
|
201
|
+
.cia-justify-between { justify-content: space-between; }
|
|
202
|
+
.cia-justify-around { justify-content: space-around; }
|
|
203
|
+
.cia-justify-evenly { justify-content: space-evenly; }
|
|
204
|
+
|
|
205
|
+
.cia-self-auto { align-self: auto; }
|
|
206
|
+
.cia-self-start { align-self: flex-start; }
|
|
207
|
+
.cia-self-end { align-self: flex-end; }
|
|
208
|
+
.cia-self-center { align-self: center; }
|
|
209
|
+
.cia-self-stretch { align-self: stretch; }
|
|
210
|
+
|
|
211
|
+
// Composition shortcuts
|
|
212
|
+
.cia-flex-center {
|
|
213
|
+
display: flex;
|
|
214
|
+
align-items: center;
|
|
215
|
+
justify-content: center;
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
.cia-flex-between {
|
|
219
|
+
display: flex;
|
|
220
|
+
align-items: center;
|
|
221
|
+
justify-content: space-between;
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
.cia-stack {
|
|
225
|
+
display: flex;
|
|
226
|
+
flex-direction: column;
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
// ============================================================================
|
|
230
|
+
// LAYOUT: grid
|
|
231
|
+
// ============================================================================
|
|
232
|
+
|
|
233
|
+
.cia-grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
|
|
234
|
+
.cia-grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
|
235
|
+
.cia-grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
|
|
236
|
+
.cia-grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
|
|
237
|
+
.cia-grid-cols-6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
|
|
238
|
+
.cia-grid-cols-12 { grid-template-columns: repeat(12, minmax(0, 1fr)); }
|
|
239
|
+
|
|
240
|
+
.cia-col-span-1 { grid-column: span 1 / span 1; }
|
|
241
|
+
.cia-col-span-2 { grid-column: span 2 / span 2; }
|
|
242
|
+
.cia-col-span-3 { grid-column: span 3 / span 3; }
|
|
243
|
+
.cia-col-span-4 { grid-column: span 4 / span 4; }
|
|
244
|
+
.cia-col-span-6 { grid-column: span 6 / span 6; }
|
|
245
|
+
.cia-col-span-12 { grid-column: span 12 / span 12; }
|
|
246
|
+
.cia-col-span-full { grid-column: 1 / -1; }
|
|
247
|
+
|
|
248
|
+
// ============================================================================
|
|
249
|
+
// POSITION
|
|
250
|
+
// ============================================================================
|
|
251
|
+
|
|
252
|
+
.cia-static { position: static; }
|
|
253
|
+
.cia-relative { position: relative; }
|
|
254
|
+
.cia-absolute { position: absolute; }
|
|
255
|
+
.cia-fixed { position: fixed; }
|
|
256
|
+
.cia-sticky { position: sticky; }
|
|
257
|
+
|
|
258
|
+
.cia-inset-0 { inset: 0; }
|
|
259
|
+
.cia-top-0 { top: 0; }
|
|
260
|
+
.cia-right-0 { right: 0; }
|
|
261
|
+
.cia-bottom-0 { bottom: 0; }
|
|
262
|
+
.cia-left-0 { left: 0; }
|
|
263
|
+
|
|
264
|
+
// ============================================================================
|
|
265
|
+
// SIZING
|
|
266
|
+
// ============================================================================
|
|
267
|
+
|
|
268
|
+
.cia-w-full { width: 100%; }
|
|
269
|
+
.cia-w-screen { width: 100vw; }
|
|
270
|
+
.cia-w-auto { width: auto; }
|
|
271
|
+
.cia-w-fit { width: fit-content; }
|
|
272
|
+
.cia-w-min { width: min-content; }
|
|
273
|
+
.cia-w-max { width: max-content; }
|
|
274
|
+
.cia-min-w-0 { min-width: 0; }
|
|
275
|
+
.cia-min-w-full { min-width: 100%; }
|
|
276
|
+
.cia-max-w-none { max-width: none; }
|
|
277
|
+
.cia-max-w-full { max-width: 100%; }
|
|
278
|
+
|
|
279
|
+
.cia-h-full { height: 100%; }
|
|
280
|
+
.cia-h-screen { height: 100vh; }
|
|
281
|
+
.cia-h-auto { height: auto; }
|
|
282
|
+
.cia-h-fit { height: fit-content; }
|
|
283
|
+
.cia-min-h-0 { min-height: 0; }
|
|
284
|
+
.cia-min-h-screen { min-height: 100vh; }
|
|
285
|
+
.cia-min-h-full { min-height: 100%; }
|
|
286
|
+
|
|
287
|
+
// ============================================================================
|
|
288
|
+
// BORDER & RADIUS
|
|
289
|
+
// ============================================================================
|
|
290
|
+
|
|
291
|
+
.cia-border { border: 1px solid var(--border-default); }
|
|
292
|
+
.cia-border-0 { border: 0; }
|
|
293
|
+
.cia-border-t { border-top: 1px solid var(--border-default); }
|
|
294
|
+
.cia-border-r { border-right: 1px solid var(--border-default); }
|
|
295
|
+
.cia-border-b { border-bottom: 1px solid var(--border-default); }
|
|
296
|
+
.cia-border-l { border-left: 1px solid var(--border-default); }
|
|
297
|
+
|
|
298
|
+
@each $key, $value in t.$theme-radius {
|
|
299
|
+
.cia-rounded-#{$key} { border-radius: var(--radius-#{$key}, #{$value}); }
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
// ============================================================================
|
|
303
|
+
// SHADOWS
|
|
304
|
+
// ============================================================================
|
|
305
|
+
|
|
306
|
+
@each $key, $value in t.$theme-shadows-light {
|
|
307
|
+
.cia-shadow-#{$key} { box-shadow: var(--shadow-#{$key}, #{$value}); }
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
// ============================================================================
|
|
311
|
+
// OPACITY
|
|
312
|
+
// ============================================================================
|
|
313
|
+
|
|
314
|
+
@each $key, $value in s.$opacities {
|
|
315
|
+
.cia-opacity-#{$key} { opacity: $value; }
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
// ============================================================================
|
|
319
|
+
// Z-INDEX
|
|
320
|
+
// ============================================================================
|
|
321
|
+
|
|
322
|
+
@each $key, $value in s.$z-layers {
|
|
323
|
+
.cia-z-#{$key} { z-index: $value; }
|
|
324
|
+
}
|
|
325
|
+
|
|
326
|
+
// ============================================================================
|
|
327
|
+
// OVERFLOW
|
|
328
|
+
// ============================================================================
|
|
329
|
+
|
|
330
|
+
.cia-overflow-auto { overflow: auto; }
|
|
331
|
+
.cia-overflow-hidden { overflow: hidden; }
|
|
332
|
+
.cia-overflow-visible { overflow: visible; }
|
|
333
|
+
.cia-overflow-scroll { overflow: scroll; }
|
|
334
|
+
.cia-overflow-x-auto { overflow-x: auto; }
|
|
335
|
+
.cia-overflow-y-auto { overflow-y: auto; }
|
|
336
|
+
.cia-overflow-x-hidden { overflow-x: hidden; }
|
|
337
|
+
.cia-overflow-y-hidden { overflow-y: hidden; }
|
|
338
|
+
|
|
339
|
+
// ============================================================================
|
|
340
|
+
// CURSOR & INTERACTION
|
|
341
|
+
// ============================================================================
|
|
342
|
+
|
|
343
|
+
.cia-cursor-pointer { cursor: pointer; }
|
|
344
|
+
.cia-cursor-default { cursor: default; }
|
|
345
|
+
.cia-cursor-not-allowed { cursor: not-allowed; }
|
|
346
|
+
.cia-pointer-events-none { pointer-events: none; }
|
|
347
|
+
.cia-pointer-events-auto { pointer-events: auto; }
|
|
348
|
+
.cia-select-none { user-select: none; }
|
|
349
|
+
.cia-select-text { user-select: text; }
|
|
350
|
+
.cia-select-all { user-select: all; }
|
|
351
|
+
|
|
352
|
+
// ============================================================================
|
|
353
|
+
// ACCESSIBILITY
|
|
354
|
+
// ============================================================================
|
|
355
|
+
|
|
356
|
+
.cia-sr-only {
|
|
357
|
+
position: absolute;
|
|
358
|
+
width: 1px;
|
|
359
|
+
height: 1px;
|
|
360
|
+
padding: 0;
|
|
361
|
+
margin: -1px;
|
|
362
|
+
overflow: hidden;
|
|
363
|
+
clip: rect(0, 0, 0, 0);
|
|
364
|
+
border: 0;
|
|
365
|
+
}
|
|
366
|
+
|
|
367
|
+
.cia-not-sr-only {
|
|
368
|
+
position: static;
|
|
369
|
+
width: auto;
|
|
370
|
+
height: auto;
|
|
371
|
+
padding: 0;
|
|
372
|
+
margin: 0;
|
|
373
|
+
overflow: visible;
|
|
374
|
+
clip: auto;
|
|
375
|
+
border: 0;
|
|
376
|
+
}
|
|
377
|
+
|