@hemerson/design-system 0.1.0 → 0.3.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.md +44 -2
- package/dist/appearance/appearance.d.ts +23 -0
- package/dist/appearance/index.d.ts +2 -0
- package/dist/appearance/useAppearance.d.ts +13 -0
- package/dist/appearance-J15aUjQp.js +57 -0
- package/dist/appearance-J15aUjQp.js.map +1 -0
- package/dist/appearance.js +1 -0
- package/dist/components/AppearanceToggles/AppearanceToggles.d.ts +17 -0
- package/dist/components/Dialog/Dialog.d.ts +3 -1
- package/dist/components/Toast/Toast.d.ts +7 -3
- package/dist/components/Toast/ToastProvider.d.ts +29 -0
- package/dist/components/Toast/ToastView.d.ts +14 -0
- package/dist/enableGlassRefraction-CgDeg-2E.js +88 -0
- package/dist/enableGlassRefraction-CgDeg-2E.js.map +1 -0
- package/dist/glass/enableGlassRefraction.d.ts +6 -5
- package/dist/glass/index.d.ts +1 -0
- package/dist/glass/lens.d.ts +15 -0
- package/dist/glass.js +1 -0
- package/dist/index.d.ts +7 -0
- package/dist/index.js +445 -329
- package/dist/index.js.map +1 -1
- package/dist/internal/Icon.d.ts +31 -8
- package/dist/styles.css +94 -34
- package/dist/tokens.css +16 -10
- package/dist/tokens.json +39 -15
- package/package.json +15 -2
package/dist/styles.css
CHANGED
|
@@ -27,12 +27,14 @@
|
|
|
27
27
|
--line: #ffffff26;
|
|
28
28
|
--line-strong: var(--secondary-500);
|
|
29
29
|
--focus-ring: var(--accent);
|
|
30
|
-
--glass-regular-tint: #
|
|
30
|
+
--glass-regular-tint: #1b1b1b4d;
|
|
31
31
|
--glass-thick-tint: #1b1b1bf0;
|
|
32
32
|
--glass-solid: var(--surface-raised);
|
|
33
33
|
--glass-clear-tint: #e4e3de12;
|
|
34
|
-
--glass-sheen: #
|
|
35
|
-
--glass-rim: #
|
|
34
|
+
--glass-sheen: #ffffff2e;
|
|
35
|
+
--glass-rim: #ffffffd9;
|
|
36
|
+
--glass-rim-low: #ffffff80;
|
|
37
|
+
--glass-edge: #ffffff1f;
|
|
36
38
|
--glass-accent-tint: #7ea8a71f;
|
|
37
39
|
--glass-accent-sheen: #b9d8d759;
|
|
38
40
|
--success: #8ab4d8;
|
|
@@ -40,9 +42,10 @@
|
|
|
40
42
|
--danger: #f19b90;
|
|
41
43
|
--on-danger: var(--dark-900);
|
|
42
44
|
--scrim: #0000008c;
|
|
43
|
-
--shadow-glass: inset 0 1px 0 0 rgba(255,255,255,0.
|
|
45
|
+
--shadow-glass: inset 0 1px 1px rgba(255,255,255,0.45), inset 0 -1px 1px rgba(255,255,255,0.12), inset 0 0 20px rgba(255,255,255,0.08), 0 10px 30px -8px rgba(0,0,0,0.45);
|
|
44
46
|
--shadow-glow: 0 0 14px rgba(126,168,167,0.55);
|
|
45
47
|
--shadow-raised: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -4px rgba(0,0,0,0.1);
|
|
48
|
+
--glass-text-shadow: 0 1px 2px rgba(0,0,0,0.35);
|
|
46
49
|
}
|
|
47
50
|
|
|
48
51
|
[data-theme="light"] {
|
|
@@ -67,12 +70,14 @@
|
|
|
67
70
|
--line: #1b1b1b26;
|
|
68
71
|
--line-strong: var(--secondary-500);
|
|
69
72
|
--focus-ring: var(--accent);
|
|
70
|
-
--glass-regular-tint: #
|
|
73
|
+
--glass-regular-tint: #f2f1ec33;
|
|
71
74
|
--glass-thick-tint: #f2f1ecf0;
|
|
72
75
|
--glass-solid: var(--surface-raised);
|
|
73
76
|
--glass-clear-tint: #ffffff8c;
|
|
74
|
-
--glass-sheen: #
|
|
75
|
-
--glass-rim: #
|
|
77
|
+
--glass-sheen: #ffffff66;
|
|
78
|
+
--glass-rim: #ffffff;
|
|
79
|
+
--glass-rim-low: #ffffffb3;
|
|
80
|
+
--glass-edge: #1b1b1b29;
|
|
76
81
|
--glass-accent-tint: #7ea8a71f;
|
|
77
82
|
--glass-accent-sheen: #b9d8d759;
|
|
78
83
|
--success: #2d5b86;
|
|
@@ -80,9 +85,10 @@
|
|
|
80
85
|
--danger: #a1342a;
|
|
81
86
|
--on-danger: #ffffff;
|
|
82
87
|
--scrim: #1b1b1b59;
|
|
83
|
-
--shadow-glass: inset 0 1px 0 0 rgba(255,255,255,0.
|
|
88
|
+
--shadow-glass: inset 0 1px 1px rgba(255,255,255,0.9), inset 0 -1px 1px rgba(255,255,255,0.4), inset 0 0 20px rgba(255,255,255,0.25), 0 10px 30px -8px rgba(27,27,27,0.25);
|
|
84
89
|
--shadow-glow: 0 0 14px rgba(63,107,106,0.35);
|
|
85
90
|
--shadow-raised: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -4px rgba(0,0,0,0.1);
|
|
91
|
+
--glass-text-shadow: 0 1px 1px rgba(255,255,255,0.6);
|
|
86
92
|
}
|
|
87
93
|
|
|
88
94
|
:root {
|
|
@@ -102,9 +108,9 @@
|
|
|
102
108
|
--radius-2xl: 24px;
|
|
103
109
|
--content-max: 1152px;
|
|
104
110
|
--sidebar-width: 64px;
|
|
105
|
-
--glass-blur: blur(
|
|
111
|
+
--glass-blur: blur(6px) saturate(180%);
|
|
106
112
|
--glass-thick-blur: blur(20px) saturate(150%);
|
|
107
|
-
--glass-accent-blur: blur(
|
|
113
|
+
--glass-accent-blur: blur(6px) saturate(200%);
|
|
108
114
|
--font-sans: Raleway, "Segoe UI", system-ui, sans-serif;
|
|
109
115
|
--font-mono: "JetBrains Mono", ui-monospace, Consolas, monospace;
|
|
110
116
|
}
|
|
@@ -209,6 +215,18 @@
|
|
|
209
215
|
outline-offset: 2px;
|
|
210
216
|
}
|
|
211
217
|
|
|
218
|
+
/* The hidden attribute always wins over the display set by these styles */
|
|
219
|
+
[class*="hds-"][hidden] {
|
|
220
|
+
display: none !important;
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
/* Dialogs and toasts render straight into <body>, outside .hds-root */
|
|
224
|
+
.hds-scrim,
|
|
225
|
+
.hds-toast-region {
|
|
226
|
+
font-family: var(--font-sans);
|
|
227
|
+
color: var(--ink);
|
|
228
|
+
}
|
|
229
|
+
|
|
212
230
|
.hds-visually-hidden {
|
|
213
231
|
position: absolute;
|
|
214
232
|
width: 1px;
|
|
@@ -228,76 +246,111 @@
|
|
|
228
246
|
}
|
|
229
247
|
|
|
230
248
|
/* ---------- Glass material ----------
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
249
|
+
Modelled on Apple's Liquid Glass: a light tint so the content behind stays visible,
|
|
250
|
+
a light blur, a lit rim brightest at the top-left, a soft inner glow and, in Chromium,
|
|
251
|
+
a lens that bends the backdrop near the edges.
|
|
252
|
+
|
|
253
|
+
Layer 1: solid, always readable. Layer 2: frosted glass where backdrop-filter works.
|
|
254
|
+
Layer 3: the edge lens, added per element by enableGlassRefraction() (Chromium only).
|
|
255
|
+
|
|
256
|
+
Glass follows the brightness of what is behind it: over dark imagery in the light
|
|
257
|
+
theme, set data-theme="dark" on the glass element itself, and the reverse. */
|
|
234
258
|
|
|
235
259
|
.hds-glass {
|
|
236
260
|
position: relative;
|
|
261
|
+
isolation: isolate;
|
|
237
262
|
color: var(--ink);
|
|
238
263
|
background: var(--glass-solid);
|
|
239
264
|
border: 1px solid var(--line);
|
|
240
|
-
|
|
241
|
-
box-shadow: var(--shadow-glass);
|
|
265
|
+
box-shadow: var(--shadow-raised);
|
|
242
266
|
}
|
|
243
267
|
|
|
244
268
|
@supports ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
|
|
245
269
|
.hds-glass {
|
|
246
|
-
|
|
247
|
-
|
|
270
|
+
border: 0;
|
|
271
|
+
background: linear-gradient(135deg, var(--glass-sheen), transparent 42%), var(--glass-regular-tint);
|
|
272
|
+
box-shadow: 0 0 0 0.5px var(--glass-edge), var(--shadow-glass);
|
|
273
|
+
text-shadow: var(--glass-text-shadow);
|
|
274
|
+
-webkit-backdrop-filter: blur(6px) saturate(180%);
|
|
248
275
|
backdrop-filter: var(--glass-blur);
|
|
249
276
|
}
|
|
250
277
|
|
|
278
|
+
/* The lit rim: brightest at the top-left, softer at the bottom-right */
|
|
279
|
+
.hds-glass::before {
|
|
280
|
+
content: "";
|
|
281
|
+
position: absolute;
|
|
282
|
+
inset: 0;
|
|
283
|
+
z-index: -1;
|
|
284
|
+
padding: 1.5px;
|
|
285
|
+
border-radius: inherit;
|
|
286
|
+
background: linear-gradient(135deg, var(--glass-rim), transparent 38%, transparent 62%, var(--glass-rim-low));
|
|
287
|
+
-webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
|
|
288
|
+
-webkit-mask-composite: xor;
|
|
289
|
+
mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
|
|
290
|
+
pointer-events: none;
|
|
291
|
+
}
|
|
292
|
+
|
|
251
293
|
.hds-glass--clear {
|
|
252
|
-
background: linear-gradient(135deg, var(--glass-sheen), transparent
|
|
294
|
+
background: linear-gradient(135deg, var(--glass-sheen), transparent 42%), var(--glass-clear-tint);
|
|
253
295
|
}
|
|
254
296
|
|
|
255
297
|
.hds-glass--thick {
|
|
256
|
-
background: linear-gradient(135deg, var(--glass-sheen), transparent
|
|
298
|
+
background: linear-gradient(135deg, var(--glass-sheen), transparent 42%), var(--glass-thick-tint);
|
|
257
299
|
-webkit-backdrop-filter: blur(20px) saturate(150%);
|
|
258
300
|
backdrop-filter: var(--glass-thick-blur);
|
|
259
301
|
}
|
|
260
302
|
|
|
261
303
|
.hds-glass--accent {
|
|
262
304
|
background: linear-gradient(135deg, var(--glass-accent-sheen), transparent 60%), var(--glass-accent-tint), var(--glass-regular-tint);
|
|
263
|
-
-
|
|
305
|
+
box-shadow: 0 0 0 1px var(--accent), var(--shadow-glass), var(--shadow-glow);
|
|
306
|
+
-webkit-backdrop-filter: blur(6px) saturate(200%);
|
|
264
307
|
backdrop-filter: var(--glass-accent-blur);
|
|
265
308
|
}
|
|
266
309
|
}
|
|
267
310
|
|
|
268
|
-
|
|
269
|
-
border-color: var(--accent);
|
|
270
|
-
box-shadow: var(--shadow-glass), var(--shadow-glow);
|
|
271
|
-
}
|
|
272
|
-
|
|
311
|
+
/* Edge lens: enableGlassRefraction() sets --hds-glass-lens on each glass element */
|
|
273
312
|
html[data-glass-refraction] .hds-glass:not(.hds-glass--thick) {
|
|
274
|
-
backdrop-filter:
|
|
313
|
+
backdrop-filter: var(--hds-glass-lens, blur(0px)) blur(4px) saturate(180%);
|
|
275
314
|
}
|
|
276
315
|
|
|
277
316
|
html[data-glass-refraction] .hds-glass--accent {
|
|
278
|
-
backdrop-filter:
|
|
317
|
+
backdrop-filter: var(--hds-glass-lens, blur(0px)) blur(4px) saturate(200%);
|
|
279
318
|
}
|
|
280
319
|
|
|
281
320
|
/* Reduced transparency: the system setting, or the app's own setting */
|
|
282
321
|
@media (prefers-reduced-transparency: reduce) {
|
|
283
322
|
html .hds-glass,
|
|
284
323
|
html[data-glass-refraction] .hds-glass:not(.hds-glass--thick) {
|
|
324
|
+
border: 1px solid var(--line);
|
|
285
325
|
background: var(--glass-solid);
|
|
326
|
+
box-shadow: var(--shadow-raised);
|
|
327
|
+
text-shadow: none;
|
|
286
328
|
-webkit-backdrop-filter: none;
|
|
287
329
|
backdrop-filter: none;
|
|
288
330
|
}
|
|
331
|
+
|
|
332
|
+
html .hds-glass::before {
|
|
333
|
+
display: none;
|
|
334
|
+
}
|
|
289
335
|
}
|
|
290
336
|
|
|
291
337
|
html[data-transparency="reduced"] .hds-glass,
|
|
292
338
|
html[data-transparency="reduced"][data-glass-refraction] .hds-glass:not(.hds-glass--thick) {
|
|
339
|
+
border: 1px solid var(--line);
|
|
293
340
|
background: var(--glass-solid);
|
|
341
|
+
box-shadow: var(--shadow-raised);
|
|
342
|
+
text-shadow: none;
|
|
294
343
|
-webkit-backdrop-filter: none;
|
|
295
344
|
backdrop-filter: none;
|
|
296
345
|
}
|
|
297
346
|
|
|
347
|
+
html[data-transparency="reduced"] .hds-glass::before {
|
|
348
|
+
display: none;
|
|
349
|
+
}
|
|
350
|
+
|
|
298
351
|
@media (prefers-contrast: more) {
|
|
299
352
|
.hds-glass {
|
|
300
|
-
|
|
353
|
+
box-shadow: 0 0 0 2px currentColor, var(--shadow-glass);
|
|
301
354
|
}
|
|
302
355
|
}
|
|
303
356
|
|
|
@@ -638,18 +691,21 @@ html[data-transparency="reduced"][data-glass-refraction] .hds-glass:not(.hds-gla
|
|
|
638
691
|
display: inline-block;
|
|
639
692
|
}
|
|
640
693
|
|
|
694
|
+
/* Rendered into <body> and placed from the trigger by the component, so scroll
|
|
695
|
+
containers never clip it; above dialogs, so a menu inside one still shows */
|
|
641
696
|
.hds-menu-panel {
|
|
642
|
-
position:
|
|
643
|
-
top:
|
|
644
|
-
|
|
697
|
+
position: fixed;
|
|
698
|
+
top: 0;
|
|
699
|
+
left: 0;
|
|
700
|
+
z-index: 70;
|
|
645
701
|
min-width: 176px;
|
|
702
|
+
max-height: calc(100vh - var(--space-4));
|
|
703
|
+
overflow: auto;
|
|
646
704
|
padding: var(--space-1);
|
|
647
705
|
border-radius: var(--radius-lg);
|
|
706
|
+
font-family: var(--font-sans);
|
|
648
707
|
}
|
|
649
708
|
|
|
650
|
-
.hds-menu-panel--start { left: 0; }
|
|
651
|
-
.hds-menu-panel--end { right: 0; }
|
|
652
|
-
|
|
653
709
|
.hds-menu-item {
|
|
654
710
|
display: flex;
|
|
655
711
|
align-items: center;
|
|
@@ -712,6 +768,10 @@ html[data-transparency="reduced"][data-glass-refraction] .hds-glass:not(.hds-gla
|
|
|
712
768
|
border-radius: var(--radius-2xl);
|
|
713
769
|
}
|
|
714
770
|
|
|
771
|
+
.hds-dialog--lg {
|
|
772
|
+
max-width: 880px;
|
|
773
|
+
}
|
|
774
|
+
|
|
715
775
|
.hds-dialog-header {
|
|
716
776
|
display: flex;
|
|
717
777
|
align-items: flex-start;
|
package/dist/tokens.css
CHANGED
|
@@ -23,12 +23,14 @@
|
|
|
23
23
|
--line: #ffffff26;
|
|
24
24
|
--line-strong: var(--secondary-500);
|
|
25
25
|
--focus-ring: var(--accent);
|
|
26
|
-
--glass-regular-tint: #
|
|
26
|
+
--glass-regular-tint: #1b1b1b4d;
|
|
27
27
|
--glass-thick-tint: #1b1b1bf0;
|
|
28
28
|
--glass-solid: var(--surface-raised);
|
|
29
29
|
--glass-clear-tint: #e4e3de12;
|
|
30
|
-
--glass-sheen: #
|
|
31
|
-
--glass-rim: #
|
|
30
|
+
--glass-sheen: #ffffff2e;
|
|
31
|
+
--glass-rim: #ffffffd9;
|
|
32
|
+
--glass-rim-low: #ffffff80;
|
|
33
|
+
--glass-edge: #ffffff1f;
|
|
32
34
|
--glass-accent-tint: #7ea8a71f;
|
|
33
35
|
--glass-accent-sheen: #b9d8d759;
|
|
34
36
|
--success: #8ab4d8;
|
|
@@ -36,9 +38,10 @@
|
|
|
36
38
|
--danger: #f19b90;
|
|
37
39
|
--on-danger: var(--dark-900);
|
|
38
40
|
--scrim: #0000008c;
|
|
39
|
-
--shadow-glass: inset 0 1px 0 0 rgba(255,255,255,0.
|
|
41
|
+
--shadow-glass: inset 0 1px 1px rgba(255,255,255,0.45), inset 0 -1px 1px rgba(255,255,255,0.12), inset 0 0 20px rgba(255,255,255,0.08), 0 10px 30px -8px rgba(0,0,0,0.45);
|
|
40
42
|
--shadow-glow: 0 0 14px rgba(126,168,167,0.55);
|
|
41
43
|
--shadow-raised: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -4px rgba(0,0,0,0.1);
|
|
44
|
+
--glass-text-shadow: 0 1px 2px rgba(0,0,0,0.35);
|
|
42
45
|
}
|
|
43
46
|
|
|
44
47
|
[data-theme="light"] {
|
|
@@ -63,12 +66,14 @@
|
|
|
63
66
|
--line: #1b1b1b26;
|
|
64
67
|
--line-strong: var(--secondary-500);
|
|
65
68
|
--focus-ring: var(--accent);
|
|
66
|
-
--glass-regular-tint: #
|
|
69
|
+
--glass-regular-tint: #f2f1ec33;
|
|
67
70
|
--glass-thick-tint: #f2f1ecf0;
|
|
68
71
|
--glass-solid: var(--surface-raised);
|
|
69
72
|
--glass-clear-tint: #ffffff8c;
|
|
70
|
-
--glass-sheen: #
|
|
71
|
-
--glass-rim: #
|
|
73
|
+
--glass-sheen: #ffffff66;
|
|
74
|
+
--glass-rim: #ffffff;
|
|
75
|
+
--glass-rim-low: #ffffffb3;
|
|
76
|
+
--glass-edge: #1b1b1b29;
|
|
72
77
|
--glass-accent-tint: #7ea8a71f;
|
|
73
78
|
--glass-accent-sheen: #b9d8d759;
|
|
74
79
|
--success: #2d5b86;
|
|
@@ -76,9 +81,10 @@
|
|
|
76
81
|
--danger: #a1342a;
|
|
77
82
|
--on-danger: #ffffff;
|
|
78
83
|
--scrim: #1b1b1b59;
|
|
79
|
-
--shadow-glass: inset 0 1px 0 0 rgba(255,255,255,0.
|
|
84
|
+
--shadow-glass: inset 0 1px 1px rgba(255,255,255,0.9), inset 0 -1px 1px rgba(255,255,255,0.4), inset 0 0 20px rgba(255,255,255,0.25), 0 10px 30px -8px rgba(27,27,27,0.25);
|
|
80
85
|
--shadow-glow: 0 0 14px rgba(63,107,106,0.35);
|
|
81
86
|
--shadow-raised: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -4px rgba(0,0,0,0.1);
|
|
87
|
+
--glass-text-shadow: 0 1px 1px rgba(255,255,255,0.6);
|
|
82
88
|
}
|
|
83
89
|
|
|
84
90
|
:root {
|
|
@@ -98,9 +104,9 @@
|
|
|
98
104
|
--radius-2xl: 24px;
|
|
99
105
|
--content-max: 1152px;
|
|
100
106
|
--sidebar-width: 64px;
|
|
101
|
-
--glass-blur: blur(
|
|
107
|
+
--glass-blur: blur(6px) saturate(180%);
|
|
102
108
|
--glass-thick-blur: blur(20px) saturate(150%);
|
|
103
|
-
--glass-accent-blur: blur(
|
|
109
|
+
--glass-accent-blur: blur(6px) saturate(200%);
|
|
104
110
|
--font-sans: Raleway, "Segoe UI", system-ui, sans-serif;
|
|
105
111
|
--font-mono: "JetBrains Mono", ui-monospace, Consolas, monospace;
|
|
106
112
|
}
|
package/dist/tokens.json
CHANGED
|
@@ -158,10 +158,10 @@
|
|
|
158
158
|
{
|
|
159
159
|
"name": "glass-regular-tint",
|
|
160
160
|
"value": {
|
|
161
|
-
"dark": "#
|
|
162
|
-
"light": "#
|
|
161
|
+
"dark": "#1b1b1b4d",
|
|
162
|
+
"light": "#f2f1ec33"
|
|
163
163
|
},
|
|
164
|
-
"usage": "Regular glass, the default
|
|
164
|
+
"usage": "Regular glass, the default for bars, sidebars, menus, toasts and floating buttons: 30% in dark, 20% in light, so the content behind stays visible. Ink keeps 4.5:1 or more over mid-grey content; over imagery much brighter (dark theme) or darker (light theme) than mid-grey, give the glass the other theme with data-theme."
|
|
165
165
|
},
|
|
166
166
|
{
|
|
167
167
|
"name": "glass-thick-tint",
|
|
@@ -187,18 +187,34 @@
|
|
|
187
187
|
{
|
|
188
188
|
"name": "glass-sheen",
|
|
189
189
|
"value": {
|
|
190
|
-
"dark": "#
|
|
191
|
-
"light": "#
|
|
190
|
+
"dark": "#ffffff2e",
|
|
191
|
+
"light": "#ffffff66"
|
|
192
192
|
},
|
|
193
|
-
"usage": "Start of the 135deg sheen gradient on
|
|
193
|
+
"usage": "Start of the 135deg sheen gradient on glass, fading to transparent at 42%."
|
|
194
194
|
},
|
|
195
195
|
{
|
|
196
196
|
"name": "glass-rim",
|
|
197
197
|
"value": {
|
|
198
|
-
"dark": "#
|
|
199
|
-
"light": "#
|
|
198
|
+
"dark": "#ffffffd9",
|
|
199
|
+
"light": "#ffffff"
|
|
200
|
+
},
|
|
201
|
+
"usage": "The lit rim at the top-left of glass surfaces, where the light catches the edge."
|
|
202
|
+
},
|
|
203
|
+
{
|
|
204
|
+
"name": "glass-rim-low",
|
|
205
|
+
"value": {
|
|
206
|
+
"dark": "#ffffff80",
|
|
207
|
+
"light": "#ffffffb3"
|
|
200
208
|
},
|
|
201
|
-
"usage": "
|
|
209
|
+
"usage": "The softer rim at the bottom-right of glass surfaces."
|
|
210
|
+
},
|
|
211
|
+
{
|
|
212
|
+
"name": "glass-edge",
|
|
213
|
+
"value": {
|
|
214
|
+
"dark": "#ffffff1f",
|
|
215
|
+
"light": "#1b1b1b29"
|
|
216
|
+
},
|
|
217
|
+
"usage": "A hairline around glass so its shape reads even where the rim fades, especially on light content."
|
|
202
218
|
},
|
|
203
219
|
{
|
|
204
220
|
"name": "glass-accent-tint",
|
|
@@ -457,10 +473,10 @@
|
|
|
457
473
|
{
|
|
458
474
|
"name": "shadow-glass",
|
|
459
475
|
"value": {
|
|
460
|
-
"dark": "inset 0 1px 0 0 rgba(255,255,255,0.
|
|
461
|
-
"light": "inset 0 1px 0 0 rgba(255,255,255,0.
|
|
476
|
+
"dark": "inset 0 1px 1px rgba(255,255,255,0.45), inset 0 -1px 1px rgba(255,255,255,0.12), inset 0 0 20px rgba(255,255,255,0.08), 0 10px 30px -8px rgba(0,0,0,0.45)",
|
|
477
|
+
"light": "inset 0 1px 1px rgba(255,255,255,0.9), inset 0 -1px 1px rgba(255,255,255,0.4), inset 0 0 20px rgba(255,255,255,0.25), 0 10px 30px -8px rgba(27,27,27,0.25)"
|
|
462
478
|
},
|
|
463
|
-
"usage": "
|
|
479
|
+
"usage": "Glass surfaces: lit top and bottom inner edges, a soft inner glow and a drop shadow."
|
|
464
480
|
},
|
|
465
481
|
{
|
|
466
482
|
"name": "shadow-glow",
|
|
@@ -474,6 +490,14 @@
|
|
|
474
490
|
"name": "shadow-raised",
|
|
475
491
|
"value": "0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -4px rgba(0,0,0,0.1)",
|
|
476
492
|
"usage": "Cards and menus lifted off the page."
|
|
493
|
+
},
|
|
494
|
+
{
|
|
495
|
+
"name": "glass-text-shadow",
|
|
496
|
+
"value": {
|
|
497
|
+
"dark": "0 1px 2px rgba(0,0,0,0.35)",
|
|
498
|
+
"light": "0 1px 1px rgba(255,255,255,0.6)"
|
|
499
|
+
},
|
|
500
|
+
"usage": "Text shadow for words on glass, separating them from the moving backdrop."
|
|
477
501
|
}
|
|
478
502
|
]
|
|
479
503
|
},
|
|
@@ -482,8 +506,8 @@
|
|
|
482
506
|
"tokens": [
|
|
483
507
|
{
|
|
484
508
|
"name": "glass-blur",
|
|
485
|
-
"value": "blur(
|
|
486
|
-
"usage": "Regular and clear glass:
|
|
509
|
+
"value": "blur(6px) saturate(180%)",
|
|
510
|
+
"usage": "Regular and clear glass: a light blur keeps the shapes behind recognisable. With the edge lens in Chromium the blur drops to 4px."
|
|
487
511
|
},
|
|
488
512
|
{
|
|
489
513
|
"name": "glass-thick-blur",
|
|
@@ -492,7 +516,7 @@
|
|
|
492
516
|
},
|
|
493
517
|
{
|
|
494
518
|
"name": "glass-accent-blur",
|
|
495
|
-
"value": "blur(
|
|
519
|
+
"value": "blur(6px) saturate(200%)",
|
|
496
520
|
"usage": "Accent glass: a single prominent floating control."
|
|
497
521
|
}
|
|
498
522
|
]
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hemerson/design-system",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "Liquid-glass design system: tokens, styles and React components for Hemerson's projects.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Hemerson Oliveira",
|
|
@@ -37,6 +37,14 @@
|
|
|
37
37
|
"types": "./dist/index.d.ts",
|
|
38
38
|
"import": "./dist/index.js"
|
|
39
39
|
},
|
|
40
|
+
"./glass": {
|
|
41
|
+
"types": "./dist/glass/index.d.ts",
|
|
42
|
+
"import": "./dist/glass.js"
|
|
43
|
+
},
|
|
44
|
+
"./appearance": {
|
|
45
|
+
"types": "./dist/appearance/index.d.ts",
|
|
46
|
+
"import": "./dist/appearance.js"
|
|
47
|
+
},
|
|
40
48
|
"./styles.css": "./dist/styles.css",
|
|
41
49
|
"./tokens.css": "./dist/tokens.css",
|
|
42
50
|
"./tokens.json": "./dist/tokens.json"
|
|
@@ -51,13 +59,18 @@
|
|
|
51
59
|
"typecheck": "tsc --noEmit",
|
|
52
60
|
"lint": "eslint .",
|
|
53
61
|
"prepare": "husky",
|
|
54
|
-
"prepublishOnly": "npm run lint && npm run typecheck && npm test && npm run build"
|
|
62
|
+
"prepublishOnly": "npm run lint && npm run typecheck && npm test && npm run build",
|
|
63
|
+
"changeset": "changeset",
|
|
64
|
+
"version-packages": "changeset version",
|
|
65
|
+
"release": "changeset publish"
|
|
55
66
|
},
|
|
56
67
|
"peerDependencies": {
|
|
57
68
|
"react": ">=18.2 <20",
|
|
58
69
|
"react-dom": ">=18.2 <20"
|
|
59
70
|
},
|
|
60
71
|
"devDependencies": {
|
|
72
|
+
"@changesets/changelog-github": "^1.0.1",
|
|
73
|
+
"@changesets/cli": "^3.0.3",
|
|
61
74
|
"@eslint/js": "^10.0.1",
|
|
62
75
|
"@storybook/addon-a11y": "^10.6.2",
|
|
63
76
|
"@storybook/addon-docs": "^10.6.2",
|