@codenhub/styles 0.7.0 → 0.8.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/README.es.md +8 -7
- package/README.md +7 -6
- package/README.pt-BR.md +8 -7
- package/dist/aesthetics/chunky-tile.css +1 -1
- package/dist/aesthetics/cyber.css +1 -1
- package/dist/aesthetics/glass.css +1 -1
- package/dist/aesthetics/index.css +2 -2
- package/dist/aesthetics/neobrutalism.css +1 -1
- package/dist/aesthetics/sketch.css +1 -1
- package/dist/cli.js +189 -0
- package/dist/components.css +2 -2
- package/dist/index.css +2 -2
- package/dist/index.d.ts +1 -0
- package/dist/native.css +2 -2
- package/dist/palette.css +1 -1
- package/dist/theme.css +2 -2
- package/docs/accessibility.md +46 -27
- package/docs/changelog/0.8.0.md +70 -0
- package/docs/changelog/index.md +1 -0
- package/docs/es/accessibility.md +47 -28
- package/docs/es/index.md +3 -2
- package/docs/es/integrating/index.md +38 -10
- package/docs/es/integrating/tailwind.md +78 -8
- package/docs/es/integrating/without-a-bundler.md +128 -5
- package/docs/es/setup.md +42 -34
- package/docs/es/usage/aesthetics.md +19 -13
- package/docs/es/usage/buttons.md +6 -2
- package/docs/es/usage/composing.md +6 -2
- package/docs/es/usage/content-and-layout.md +8 -4
- package/docs/es/usage/customizing.md +19 -13
- package/docs/es/usage/feedback.md +5 -1
- package/docs/es/usage/forms.md +29 -4
- package/docs/es/usage/index.md +6 -2
- package/docs/es/usage/presets.md +92 -0
- package/docs/es/usage/solo.md +4 -2
- package/docs/es/usage/theming.md +28 -15
- package/docs/index.md +2 -1
- package/docs/integrating/index.md +38 -10
- package/docs/integrating/tailwind.md +77 -7
- package/docs/integrating/without-a-bundler.md +127 -4
- package/docs/pt-BR/accessibility.md +47 -28
- package/docs/pt-BR/index.md +3 -2
- package/docs/pt-BR/integrating/index.md +38 -10
- package/docs/pt-BR/integrating/tailwind.md +78 -8
- package/docs/pt-BR/integrating/without-a-bundler.md +128 -5
- package/docs/pt-BR/setup.md +42 -34
- package/docs/pt-BR/usage/aesthetics.md +19 -13
- package/docs/pt-BR/usage/buttons.md +6 -2
- package/docs/pt-BR/usage/composing.md +6 -2
- package/docs/pt-BR/usage/content-and-layout.md +8 -4
- package/docs/pt-BR/usage/customizing.md +19 -13
- package/docs/pt-BR/usage/feedback.md +5 -1
- package/docs/pt-BR/usage/forms.md +29 -4
- package/docs/pt-BR/usage/index.md +6 -2
- package/docs/pt-BR/usage/presets.md +92 -0
- package/docs/pt-BR/usage/solo.md +4 -2
- package/docs/pt-BR/usage/theming.md +21 -8
- package/docs/setup.md +30 -22
- package/docs/usage/aesthetics.md +18 -12
- package/docs/usage/buttons.md +5 -1
- package/docs/usage/composing.md +5 -1
- package/docs/usage/content-and-layout.md +7 -3
- package/docs/usage/customizing.md +18 -12
- package/docs/usage/feedback.md +4 -0
- package/docs/usage/forms.md +28 -3
- package/docs/usage/index.md +5 -1
- package/docs/usage/presets.md +91 -0
- package/docs/usage/solo.md +3 -1
- package/docs/usage/theming.md +20 -7
- package/llms-full.txt +592 -115
- package/package.json +113 -63
- package/{dist/tw → tw}/aesthetics/chunky-tile.css +39 -19
- package/{dist/tw → tw}/aesthetics/cyber.css +15 -24
- package/{dist/tw → tw}/aesthetics/glass.css +105 -36
- package/{dist/tw → tw}/aesthetics/neobrutalism.css +37 -20
- package/{dist/tw → tw}/aesthetics/sketch.css +152 -133
- package/{dist/tw → tw}/box.css +89 -12
- package/tw/components/button.css +11 -0
- package/tw/components/button.rules.css +187 -0
- package/tw/components/feedback.css +11 -0
- package/{dist/tw/components/feedback.css → tw/components/feedback.rules.css} +134 -30
- package/tw/components/form.css +11 -0
- package/{dist/tw/components/form.css → tw/components/form.rules.css} +524 -111
- package/tw/components/index.css +16 -0
- package/tw/components/rules.css +41 -0
- package/tw/components/surface.css +11 -0
- package/tw/components/surface.rules.css +222 -0
- package/tw/components/tooltip.css +11 -0
- package/{dist/tw/components/tooltip.css → tw/components/tooltip.rules.css} +43 -27
- package/{dist/tw → tw}/corner.css +18 -12
- package/{dist/tw → tw}/elevation.css +23 -17
- package/{dist/tw → tw}/index.css +11 -9
- package/tw/index.d.ts +1 -0
- package/tw/intent.css +312 -0
- package/tw/modifiers.css +127 -0
- package/tw/native.css +320 -0
- package/tw/presentation.css +139 -0
- package/tw/reset.css +10 -0
- package/{dist/tw/reset.css → tw/reset.rules.css} +7 -8
- package/tw/size.css +34 -0
- package/tw/surface.css +9 -0
- package/tw/surface.rules.css +212 -0
- package/{dist/tw → tw}/theme.css +92 -28
- package/tw/typography.css +8 -0
- package/{dist/tw/typography.css → tw/typography.rules.css} +0 -3
- package/{dist/tw → tw}/utilities/content.css +183 -63
- package/tw/utilities/index.css +11 -0
- package/tw/utilities/layout.css +208 -0
- package/tw/utilities/rules.css +8 -0
- package/dist/tw/components/button.css +0 -139
- package/dist/tw/components/index.css +0 -35
- package/dist/tw/components/surface.css +0 -184
- package/dist/tw/intent.css +0 -229
- package/dist/tw/native.css +0 -203
- package/dist/tw/palette.css +0 -460
- package/dist/tw/presentation.css +0 -68
- package/dist/tw/surface.css +0 -61
- package/dist/tw/utilities/index.css +0 -6
- package/dist/tw/utilities/layout.css +0 -144
- /package/{dist/tw → tw}/aesthetics/index.css +0 -0
- /package/{dist/tw → tw}/aesthetics/pixel.css +0 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codenhub/styles",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.8.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Build a consistent, themeable interface by writing class names on plain HTML, with one stylesheet of tokens, a reset, layout and type helpers, and component classes, and no JavaScript.",
|
|
6
6
|
"homepage": "https://github.com/codenhub/codenhub/tree/main/packages/styles",
|
|
@@ -10,8 +10,12 @@
|
|
|
10
10
|
"url": "git+https://github.com/codenhub/codenhub.git",
|
|
11
11
|
"directory": "packages/styles"
|
|
12
12
|
},
|
|
13
|
+
"bin": {
|
|
14
|
+
"codenhub-styles": "./dist/cli.js"
|
|
15
|
+
},
|
|
13
16
|
"files": [
|
|
14
17
|
"dist",
|
|
18
|
+
"tw",
|
|
15
19
|
"NOTICE",
|
|
16
20
|
"README.md",
|
|
17
21
|
"docs",
|
|
@@ -22,158 +26,190 @@
|
|
|
22
26
|
"sideEffects": [
|
|
23
27
|
"**/*.css"
|
|
24
28
|
],
|
|
29
|
+
"types": "./dist/index.d.ts",
|
|
25
30
|
"exports": {
|
|
26
31
|
".": {
|
|
32
|
+
"types": "./dist/index.d.ts",
|
|
27
33
|
"style": "./dist/index.css",
|
|
28
34
|
"import": "./dist/index.css",
|
|
29
35
|
"default": "./dist/index.css"
|
|
30
36
|
},
|
|
31
37
|
"./theme": {
|
|
38
|
+
"types": "./dist/index.d.ts",
|
|
32
39
|
"style": "./dist/theme.css",
|
|
33
40
|
"import": "./dist/theme.css",
|
|
34
41
|
"default": "./dist/theme.css"
|
|
35
42
|
},
|
|
36
43
|
"./palette": {
|
|
44
|
+
"types": "./dist/index.d.ts",
|
|
37
45
|
"style": "./dist/palette.css",
|
|
38
46
|
"import": "./dist/palette.css",
|
|
39
47
|
"default": "./dist/palette.css"
|
|
40
48
|
},
|
|
41
49
|
"./components": {
|
|
50
|
+
"types": "./dist/index.d.ts",
|
|
42
51
|
"style": "./dist/components.css",
|
|
43
52
|
"import": "./dist/components.css",
|
|
44
53
|
"default": "./dist/components.css"
|
|
45
54
|
},
|
|
46
55
|
"./aesthetics": {
|
|
56
|
+
"types": "./dist/index.d.ts",
|
|
47
57
|
"style": "./dist/aesthetics/index.css",
|
|
48
58
|
"import": "./dist/aesthetics/index.css",
|
|
49
59
|
"default": "./dist/aesthetics/index.css"
|
|
50
60
|
},
|
|
51
61
|
"./aesthetics/neobrutalism": {
|
|
62
|
+
"types": "./dist/index.d.ts",
|
|
52
63
|
"style": "./dist/aesthetics/neobrutalism.css",
|
|
53
64
|
"import": "./dist/aesthetics/neobrutalism.css",
|
|
54
65
|
"default": "./dist/aesthetics/neobrutalism.css"
|
|
55
66
|
},
|
|
56
67
|
"./aesthetics/glass": {
|
|
68
|
+
"types": "./dist/index.d.ts",
|
|
57
69
|
"style": "./dist/aesthetics/glass.css",
|
|
58
70
|
"import": "./dist/aesthetics/glass.css",
|
|
59
71
|
"default": "./dist/aesthetics/glass.css"
|
|
60
72
|
},
|
|
61
73
|
"./aesthetics/pixel": {
|
|
74
|
+
"types": "./dist/index.d.ts",
|
|
62
75
|
"style": "./dist/aesthetics/pixel.css",
|
|
63
76
|
"import": "./dist/aesthetics/pixel.css",
|
|
64
77
|
"default": "./dist/aesthetics/pixel.css"
|
|
65
78
|
},
|
|
66
79
|
"./aesthetics/chunky-tile": {
|
|
80
|
+
"types": "./dist/index.d.ts",
|
|
67
81
|
"style": "./dist/aesthetics/chunky-tile.css",
|
|
68
82
|
"import": "./dist/aesthetics/chunky-tile.css",
|
|
69
83
|
"default": "./dist/aesthetics/chunky-tile.css"
|
|
70
84
|
},
|
|
71
85
|
"./aesthetics/cyber": {
|
|
86
|
+
"types": "./dist/index.d.ts",
|
|
72
87
|
"style": "./dist/aesthetics/cyber.css",
|
|
73
88
|
"import": "./dist/aesthetics/cyber.css",
|
|
74
89
|
"default": "./dist/aesthetics/cyber.css"
|
|
75
90
|
},
|
|
76
91
|
"./aesthetics/sketch": {
|
|
92
|
+
"types": "./dist/index.d.ts",
|
|
77
93
|
"style": "./dist/aesthetics/sketch.css",
|
|
78
94
|
"import": "./dist/aesthetics/sketch.css",
|
|
79
95
|
"default": "./dist/aesthetics/sketch.css"
|
|
80
96
|
},
|
|
81
97
|
"./tw": {
|
|
82
|
-
"
|
|
83
|
-
"
|
|
84
|
-
"
|
|
98
|
+
"types": "./tw/index.d.ts",
|
|
99
|
+
"style": "./tw/index.css",
|
|
100
|
+
"import": "./tw/index.css",
|
|
101
|
+
"default": "./tw/index.css"
|
|
85
102
|
},
|
|
86
103
|
"./tw/theme": {
|
|
87
|
-
"
|
|
88
|
-
"
|
|
89
|
-
"
|
|
104
|
+
"types": "./tw/index.d.ts",
|
|
105
|
+
"style": "./tw/theme.css",
|
|
106
|
+
"import": "./tw/theme.css",
|
|
107
|
+
"default": "./tw/theme.css"
|
|
90
108
|
},
|
|
91
109
|
"./tw/components": {
|
|
92
|
-
"
|
|
93
|
-
"
|
|
94
|
-
"
|
|
110
|
+
"types": "./tw/index.d.ts",
|
|
111
|
+
"style": "./tw/components/index.css",
|
|
112
|
+
"import": "./tw/components/index.css",
|
|
113
|
+
"default": "./tw/components/index.css"
|
|
95
114
|
},
|
|
96
115
|
"./tw/surface": {
|
|
97
|
-
"
|
|
98
|
-
"
|
|
99
|
-
"
|
|
116
|
+
"types": "./tw/index.d.ts",
|
|
117
|
+
"style": "./tw/components/surface.css",
|
|
118
|
+
"import": "./tw/components/surface.css",
|
|
119
|
+
"default": "./tw/components/surface.css"
|
|
100
120
|
},
|
|
101
121
|
"./tw/button": {
|
|
102
|
-
"
|
|
103
|
-
"
|
|
104
|
-
"
|
|
122
|
+
"types": "./tw/index.d.ts",
|
|
123
|
+
"style": "./tw/components/button.css",
|
|
124
|
+
"import": "./tw/components/button.css",
|
|
125
|
+
"default": "./tw/components/button.css"
|
|
105
126
|
},
|
|
106
127
|
"./tw/form": {
|
|
107
|
-
"
|
|
108
|
-
"
|
|
109
|
-
"
|
|
128
|
+
"types": "./tw/index.d.ts",
|
|
129
|
+
"style": "./tw/components/form.css",
|
|
130
|
+
"import": "./tw/components/form.css",
|
|
131
|
+
"default": "./tw/components/form.css"
|
|
110
132
|
},
|
|
111
133
|
"./tw/feedback": {
|
|
112
|
-
"
|
|
113
|
-
"
|
|
114
|
-
"
|
|
134
|
+
"types": "./tw/index.d.ts",
|
|
135
|
+
"style": "./tw/components/feedback.css",
|
|
136
|
+
"import": "./tw/components/feedback.css",
|
|
137
|
+
"default": "./tw/components/feedback.css"
|
|
115
138
|
},
|
|
116
139
|
"./tw/tooltip": {
|
|
117
|
-
"
|
|
118
|
-
"
|
|
119
|
-
"
|
|
140
|
+
"types": "./tw/index.d.ts",
|
|
141
|
+
"style": "./tw/components/tooltip.css",
|
|
142
|
+
"import": "./tw/components/tooltip.css",
|
|
143
|
+
"default": "./tw/components/tooltip.css"
|
|
120
144
|
},
|
|
121
145
|
"./tw/reset": {
|
|
122
|
-
"
|
|
123
|
-
"
|
|
124
|
-
"
|
|
146
|
+
"types": "./tw/index.d.ts",
|
|
147
|
+
"style": "./tw/reset.css",
|
|
148
|
+
"import": "./tw/reset.css",
|
|
149
|
+
"default": "./tw/reset.css"
|
|
125
150
|
},
|
|
126
151
|
"./tw/native": {
|
|
127
|
-
"
|
|
128
|
-
"
|
|
129
|
-
"
|
|
152
|
+
"types": "./tw/index.d.ts",
|
|
153
|
+
"style": "./tw/native.css",
|
|
154
|
+
"import": "./tw/native.css",
|
|
155
|
+
"default": "./tw/native.css"
|
|
130
156
|
},
|
|
131
157
|
"./tw/typography": {
|
|
132
|
-
"
|
|
133
|
-
"
|
|
134
|
-
"
|
|
158
|
+
"types": "./tw/index.d.ts",
|
|
159
|
+
"style": "./tw/typography.css",
|
|
160
|
+
"import": "./tw/typography.css",
|
|
161
|
+
"default": "./tw/typography.css"
|
|
135
162
|
},
|
|
136
163
|
"./tw/utilities": {
|
|
137
|
-
"
|
|
138
|
-
"
|
|
139
|
-
"
|
|
164
|
+
"types": "./tw/index.d.ts",
|
|
165
|
+
"style": "./tw/utilities/index.css",
|
|
166
|
+
"import": "./tw/utilities/index.css",
|
|
167
|
+
"default": "./tw/utilities/index.css"
|
|
140
168
|
},
|
|
141
169
|
"./tw/aesthetics": {
|
|
142
|
-
"
|
|
143
|
-
"
|
|
144
|
-
"
|
|
170
|
+
"types": "./tw/index.d.ts",
|
|
171
|
+
"style": "./tw/aesthetics/index.css",
|
|
172
|
+
"import": "./tw/aesthetics/index.css",
|
|
173
|
+
"default": "./tw/aesthetics/index.css"
|
|
145
174
|
},
|
|
146
175
|
"./tw/aesthetics/neobrutalism": {
|
|
147
|
-
"
|
|
148
|
-
"
|
|
149
|
-
"
|
|
176
|
+
"types": "./tw/index.d.ts",
|
|
177
|
+
"style": "./tw/aesthetics/neobrutalism.css",
|
|
178
|
+
"import": "./tw/aesthetics/neobrutalism.css",
|
|
179
|
+
"default": "./tw/aesthetics/neobrutalism.css"
|
|
150
180
|
},
|
|
151
181
|
"./tw/aesthetics/glass": {
|
|
152
|
-
"
|
|
153
|
-
"
|
|
154
|
-
"
|
|
182
|
+
"types": "./tw/index.d.ts",
|
|
183
|
+
"style": "./tw/aesthetics/glass.css",
|
|
184
|
+
"import": "./tw/aesthetics/glass.css",
|
|
185
|
+
"default": "./tw/aesthetics/glass.css"
|
|
155
186
|
},
|
|
156
187
|
"./tw/aesthetics/pixel": {
|
|
157
|
-
"
|
|
158
|
-
"
|
|
159
|
-
"
|
|
188
|
+
"types": "./tw/index.d.ts",
|
|
189
|
+
"style": "./tw/aesthetics/pixel.css",
|
|
190
|
+
"import": "./tw/aesthetics/pixel.css",
|
|
191
|
+
"default": "./tw/aesthetics/pixel.css"
|
|
160
192
|
},
|
|
161
193
|
"./tw/aesthetics/chunky-tile": {
|
|
162
|
-
"
|
|
163
|
-
"
|
|
164
|
-
"
|
|
194
|
+
"types": "./tw/index.d.ts",
|
|
195
|
+
"style": "./tw/aesthetics/chunky-tile.css",
|
|
196
|
+
"import": "./tw/aesthetics/chunky-tile.css",
|
|
197
|
+
"default": "./tw/aesthetics/chunky-tile.css"
|
|
165
198
|
},
|
|
166
199
|
"./tw/aesthetics/cyber": {
|
|
167
|
-
"
|
|
168
|
-
"
|
|
169
|
-
"
|
|
200
|
+
"types": "./tw/index.d.ts",
|
|
201
|
+
"style": "./tw/aesthetics/cyber.css",
|
|
202
|
+
"import": "./tw/aesthetics/cyber.css",
|
|
203
|
+
"default": "./tw/aesthetics/cyber.css"
|
|
170
204
|
},
|
|
171
205
|
"./tw/aesthetics/sketch": {
|
|
172
|
-
"
|
|
173
|
-
"
|
|
174
|
-
"
|
|
206
|
+
"types": "./tw/index.d.ts",
|
|
207
|
+
"style": "./tw/aesthetics/sketch.css",
|
|
208
|
+
"import": "./tw/aesthetics/sketch.css",
|
|
209
|
+
"default": "./tw/aesthetics/sketch.css"
|
|
175
210
|
},
|
|
176
211
|
"./native": {
|
|
212
|
+
"types": "./dist/index.d.ts",
|
|
177
213
|
"style": "./dist/native.css",
|
|
178
214
|
"import": "./dist/native.css",
|
|
179
215
|
"default": "./dist/native.css"
|
|
@@ -186,35 +222,49 @@
|
|
|
186
222
|
"devDependencies": {
|
|
187
223
|
"@codenhub/tools": "0.1.0",
|
|
188
224
|
"@playwright/test": "~1.63.0",
|
|
189
|
-
"@tailwindcss/cli": "^4.3.
|
|
225
|
+
"@tailwindcss/cli": "^4.3.4",
|
|
226
|
+
"@tailwindcss/node": "^4.3.4",
|
|
227
|
+
"@tailwindcss/oxide": "^4.3.4",
|
|
190
228
|
"@types/node": "^26.6.6",
|
|
191
|
-
"tailwindcss": "^4.3.
|
|
229
|
+
"tailwindcss": "^4.3.4",
|
|
230
|
+
"tsdown": "^0.23.5",
|
|
192
231
|
"typescript": "^6.0.3",
|
|
193
232
|
"vitest": "^4.1.10"
|
|
194
233
|
},
|
|
195
234
|
"peerDependencies": {
|
|
235
|
+
"@tailwindcss/cli": ">=4.3.2 <5",
|
|
196
236
|
"tailwindcss": ">=4.3.2 <5"
|
|
197
237
|
},
|
|
198
238
|
"peerDependenciesMeta": {
|
|
239
|
+
"@tailwindcss/cli": {
|
|
240
|
+
"optional": true
|
|
241
|
+
},
|
|
199
242
|
"tailwindcss": {
|
|
200
243
|
"optional": true
|
|
201
244
|
}
|
|
202
245
|
},
|
|
246
|
+
"engines": {
|
|
247
|
+
"node": ">=24"
|
|
248
|
+
},
|
|
203
249
|
"codenhub": {
|
|
204
250
|
"label": "StyleKit",
|
|
205
251
|
"status": "active",
|
|
206
|
-
"docs": {}
|
|
252
|
+
"docs": {},
|
|
253
|
+
"tools": {
|
|
254
|
+
"timeout": 1800
|
|
255
|
+
}
|
|
207
256
|
},
|
|
208
257
|
"scripts": {
|
|
209
|
-
"clean": "node -e \"
|
|
258
|
+
"clean": "node -e \"for (const d of ['dist', 'tw']) fs.rmSync(d, { recursive: true, force: true })\"",
|
|
210
259
|
"dev": "pnpm --filter=@codenhub/styles-dev dev",
|
|
211
260
|
"debug": "pnpm build && pnpm --filter=@codenhub/styles-debug dev",
|
|
212
261
|
"demo": "pnpm build && pnpm --filter=@codenhub/styles-demo dev",
|
|
213
262
|
"generate": "node scripts/generate-palette.mjs",
|
|
214
|
-
"build": "pnpm clean && node scripts/build-styles.mjs && pnpm build:tw",
|
|
263
|
+
"build": "pnpm clean && node scripts/build-styles.mjs && pnpm build:tw && pnpm build:cli",
|
|
215
264
|
"build:styles": "node scripts/build-styles.mjs --styles",
|
|
216
265
|
"build:aesthetics": "node scripts/build-styles.mjs --aesthetics",
|
|
217
266
|
"build:tw": "node scripts/build-tw.mjs",
|
|
267
|
+
"build:cli": "tsdown src/cli/cli.ts --format esm --no-clean --no-fixed-extension --no-dts",
|
|
218
268
|
"status:npm": "npm view @codenhub/styles version dist-tags time --json && npm dist-tag ls @codenhub/styles && npm access get status @codenhub/styles",
|
|
219
269
|
"status:pack": "npm pack --dry-run --ignore-scripts",
|
|
220
270
|
"test": "vitest run",
|
|
@@ -144,6 +144,17 @@
|
|
|
144
144
|
--ui-label-case: initial;
|
|
145
145
|
--ui-label-shadow: initial;
|
|
146
146
|
}
|
|
147
|
+
|
|
148
|
+
/* More contrast asked for: the tile takes the controls' grey, since its own
|
|
149
|
+
is about 2.5:1 against the page in both themes. The bar under a tile is
|
|
150
|
+
this ink too, and darkens with it. A rule of its own rather than nested
|
|
151
|
+
above: `registry.test.ts` reads that block's declarations flat. See
|
|
152
|
+
docs/accessibility.md. */
|
|
153
|
+
@media (prefers-contrast: more) {
|
|
154
|
+
.chunky-tile {
|
|
155
|
+
--ui-ink: light-dark(var(--color-neutral-600), var(--color-neutral-400));
|
|
156
|
+
}
|
|
157
|
+
}
|
|
147
158
|
}
|
|
148
159
|
|
|
149
160
|
/* Solo: the same look painted onto the one element carrying the class, for an
|
|
@@ -189,9 +200,17 @@
|
|
|
189
200
|
0 var(--_solo-depth) 0 0 var(--_tile-bar),
|
|
190
201
|
inset 0 0 0 100vmax var(--_solo-fill);
|
|
191
202
|
font-family: var(--font-rounded, var(--font-default, ui-sans-serif, system-ui, sans-serif));
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
/* More contrast asked for: the controls' grey, as on `.chunky-tile`, for the
|
|
206
|
+
same 2.5:1. An element's intent still colours the line. */
|
|
207
|
+
@media (prefers-contrast: more) {
|
|
208
|
+
.chunky-tile-solo {
|
|
209
|
+
--_solo-ink: var(
|
|
210
|
+
--_solo-intent-border,
|
|
211
|
+
light-dark(var(--color-neutral-600, oklch(43.9% 0 0)), var(--color-neutral-400, oklch(70.8% 0 0)))
|
|
212
|
+
);
|
|
213
|
+
}
|
|
195
214
|
}
|
|
196
215
|
|
|
197
216
|
/* An intent class on the element colours it, as on a component. Named rather
|
|
@@ -223,7 +242,12 @@
|
|
|
223
242
|
color: var(--_solo-fg);
|
|
224
243
|
}
|
|
225
244
|
|
|
226
|
-
/* The heavier, tracked label is an action's, as under the aesthetic class.
|
|
245
|
+
/* The heavier, tracked label is an action's, as under the aesthetic class.
|
|
246
|
+
|
|
247
|
+
So is the press's transition: `transition` is one list, so writing it on
|
|
248
|
+
every solo element replaced a container's own -- a toast's fade and height
|
|
249
|
+
stopped animating. The travel is the independent `translate`, so the
|
|
250
|
+
element's own `transform` stays its own. */
|
|
227
251
|
.chunky-tile-solo:is(
|
|
228
252
|
button,
|
|
229
253
|
a[href],
|
|
@@ -235,6 +259,16 @@
|
|
|
235
259
|
) {
|
|
236
260
|
font-weight: 800;
|
|
237
261
|
letter-spacing: 0.04em;
|
|
262
|
+
transition:
|
|
263
|
+
box-shadow var(--motion-duration-normal, 200ms) var(--motion-ease, cubic-bezier(0.2, 0, 0, 1)),
|
|
264
|
+
translate var(--motion-duration-normal, 200ms) var(--motion-ease, cubic-bezier(0.2, 0, 0, 1));
|
|
265
|
+
|
|
266
|
+
/* Reduced motion keeps the press and drops its motion: the tile lands on
|
|
267
|
+
its bar at once. The near-zero duration `box` uses, so a `transitionend`
|
|
268
|
+
still fires. */
|
|
269
|
+
@media (prefers-reduced-motion: reduce) {
|
|
270
|
+
transition-duration: 0.01ms;
|
|
271
|
+
}
|
|
238
272
|
}
|
|
239
273
|
|
|
240
274
|
/* The press, only on something pressed: an action, not disabled. A solo
|
|
@@ -252,19 +286,5 @@
|
|
|
252
286
|
box-shadow:
|
|
253
287
|
0 0 0 0 var(--_tile-bar),
|
|
254
288
|
inset 0 0 0 100vmax var(--_solo-fill);
|
|
255
|
-
|
|
256
|
-
}
|
|
257
|
-
|
|
258
|
-
@media (prefers-reduced-motion: reduce) {
|
|
259
|
-
.chunky-tile-solo:is(
|
|
260
|
-
button,
|
|
261
|
-
a[href],
|
|
262
|
-
[role="button"],
|
|
263
|
-
summary,
|
|
264
|
-
input[type="button"],
|
|
265
|
-
input[type="submit"],
|
|
266
|
-
input[type="reset"]
|
|
267
|
-
):active:not(:disabled, [aria-disabled="true"]) {
|
|
268
|
-
transform: none;
|
|
269
|
-
}
|
|
289
|
+
translate: 0 var(--_solo-depth);
|
|
270
290
|
}
|
|
@@ -88,7 +88,7 @@
|
|
|
88
88
|
|
|
89
89
|
/* The glow holds still under the pointer and under a press; the press is the
|
|
90
90
|
base scale, restated because a region nested inside another aesthetic must
|
|
91
|
-
not inherit that one's travel.
|
|
91
|
+
not inherit that one's travel. */
|
|
92
92
|
--ui-hover-transform: none;
|
|
93
93
|
--ui-active-shadow-x: 0px;
|
|
94
94
|
--ui-active-shadow-y: 0px;
|
|
@@ -145,12 +145,6 @@
|
|
|
145
145
|
--ui-radius-surface: 0;
|
|
146
146
|
}
|
|
147
147
|
}
|
|
148
|
-
|
|
149
|
-
@media (prefers-reduced-motion: reduce) {
|
|
150
|
-
.cyber {
|
|
151
|
-
--ui-active-transform: none;
|
|
152
|
-
}
|
|
153
|
-
}
|
|
154
148
|
}
|
|
155
149
|
|
|
156
150
|
/* Solo: the same look painted onto the one element carrying the class, for an
|
|
@@ -199,7 +193,6 @@
|
|
|
199
193
|
0 0 var(--cyber-glow, 8px) 1px color-mix(in oklab, var(--_solo-ink) 60%, transparent),
|
|
200
194
|
inset 0 0 0 100vmax var(--_solo-fill);
|
|
201
195
|
font-family: var(--font-cyber, ui-monospace, SFMono-Regular, Menlo, Consolas, monospace);
|
|
202
|
-
transition: transform var(--motion-duration-normal, 200ms) var(--motion-ease, cubic-bezier(0.2, 0, 0, 1));
|
|
203
196
|
}
|
|
204
197
|
|
|
205
198
|
/* An intent class on the element colours it, as on a component. Named rather
|
|
@@ -231,7 +224,12 @@
|
|
|
231
224
|
color: var(--_solo-fg);
|
|
232
225
|
}
|
|
233
226
|
|
|
234
|
-
/* An action takes the control shape, on the opposite diagonal to a pane's.
|
|
227
|
+
/* An action takes the control shape, on the opposite diagonal to a pane's.
|
|
228
|
+
|
|
229
|
+
And the press's transition, on an action only: `transition` is one list, so
|
|
230
|
+
writing it on every solo element replaced a container's own -- a toast's
|
|
231
|
+
fade and height stopped animating. The press is the independent `scale`, so
|
|
232
|
+
the element's own `transform` stays its own. */
|
|
235
233
|
.cyber-solo:is(
|
|
236
234
|
button,
|
|
237
235
|
a[href],
|
|
@@ -242,6 +240,13 @@
|
|
|
242
240
|
input[type="reset"]
|
|
243
241
|
) {
|
|
244
242
|
border-radius: var(--cyber-shape, min(var(--cyber-cut, 0.625rem), 25%) 0 / min(var(--cyber-cut, 0.625rem), 25%) 0);
|
|
243
|
+
transition: scale var(--motion-duration-normal, 200ms) var(--motion-ease, cubic-bezier(0.2, 0, 0, 1));
|
|
244
|
+
|
|
245
|
+
/* Reduced motion keeps the press and drops its motion: the element gives at
|
|
246
|
+
once. The near-zero duration `box` uses, so a `transitionend` still fires. */
|
|
247
|
+
@media (prefers-reduced-motion: reduce) {
|
|
248
|
+
transition-duration: 0.01ms;
|
|
249
|
+
}
|
|
245
250
|
}
|
|
246
251
|
|
|
247
252
|
@supports not (corner-shape: bevel) {
|
|
@@ -271,19 +276,5 @@
|
|
|
271
276
|
input[type="submit"],
|
|
272
277
|
input[type="reset"]
|
|
273
278
|
):active:not(:disabled, [aria-disabled="true"]) {
|
|
274
|
-
|
|
275
|
-
}
|
|
276
|
-
|
|
277
|
-
@media (prefers-reduced-motion: reduce) {
|
|
278
|
-
.cyber-solo:is(
|
|
279
|
-
button,
|
|
280
|
-
a[href],
|
|
281
|
-
[role="button"],
|
|
282
|
-
summary,
|
|
283
|
-
input[type="button"],
|
|
284
|
-
input[type="submit"],
|
|
285
|
-
input[type="reset"]
|
|
286
|
-
):active:not(:disabled, [aria-disabled="true"]) {
|
|
287
|
-
transform: none;
|
|
288
|
-
}
|
|
279
|
+
scale: 0.97;
|
|
289
280
|
}
|