@nyxwire/css 0.0.0-stage → 0.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/LICENSE +21 -0
- package/README.md +133 -2
- package/dist/base.css +850 -0
- package/dist/components.css +10508 -0
- package/dist/docs/components/accordion.md +83 -0
- package/dist/docs/components/alert.md +52 -0
- package/dist/docs/components/avatar.md +55 -0
- package/dist/docs/components/badge.md +64 -0
- package/dist/docs/components/breadcrumbs.md +64 -0
- package/dist/docs/components/button.md +197 -0
- package/dist/docs/components/card.md +103 -0
- package/dist/docs/components/checkbox.md +45 -0
- package/dist/docs/components/chip.md +30 -0
- package/dist/docs/components/cluster.md +33 -0
- package/dist/docs/components/code.md +65 -0
- package/dist/docs/components/container.md +24 -0
- package/dist/docs/components/dialog.md +199 -0
- package/dist/docs/components/divider.md +31 -0
- package/dist/docs/components/dl.md +24 -0
- package/dist/docs/components/effect-utilities.md +82 -0
- package/dist/docs/components/empty.md +40 -0
- package/dist/docs/components/frame.md +27 -0
- package/dist/docs/components/grid.md +31 -0
- package/dist/docs/components/hud.md +75 -0
- package/dist/docs/components/input-group.md +28 -0
- package/dist/docs/components/input.md +52 -0
- package/dist/docs/components/kbd.md +42 -0
- package/dist/docs/components/label-and-field.md +31 -0
- package/dist/docs/components/link.md +41 -0
- package/dist/docs/components/list.md +67 -0
- package/dist/docs/components/menu.md +85 -0
- package/dist/docs/components/meter.md +77 -0
- package/dist/docs/components/navbar.md +66 -0
- package/dist/docs/components/pagination.md +64 -0
- package/dist/docs/components/popover.md +59 -0
- package/dist/docs/components/progress.md +32 -0
- package/dist/docs/components/prose.md +29 -0
- package/dist/docs/components/select.md +51 -0
- package/dist/docs/components/sidebar.md +35 -0
- package/dist/docs/components/sidenav.md +45 -0
- package/dist/docs/components/skeleton.md +36 -0
- package/dist/docs/components/slider.md +32 -0
- package/dist/docs/components/spinner.md +30 -0
- package/dist/docs/components/stack.md +26 -0
- package/dist/docs/components/steps.md +49 -0
- package/dist/docs/components/switch.md +19 -0
- package/dist/docs/components/table.md +83 -0
- package/dist/docs/components/tabs.md +207 -0
- package/dist/docs/components/textarea.md +13 -0
- package/dist/docs/components/toast.md +86 -0
- package/dist/docs/components/tooltip.md +39 -0
- package/dist/docs/components/typography-classes.md +38 -0
- package/dist/docs/families/data-display.md +15 -0
- package/dist/docs/families/feedback.md +13 -0
- package/dist/docs/families/forms.md +141 -0
- package/dist/docs/families/layout-typography.md +17 -0
- package/dist/docs/families/navigation.md +13 -0
- package/dist/docs/families/overlays.md +13 -0
- package/dist/docs/families/surfaces.md +11 -0
- package/dist/docs/foundations/accessibility.md +71 -0
- package/dist/docs/foundations/color-roles.md +114 -0
- package/dist/docs/foundations/effects-motion.md +150 -0
- package/dist/docs/foundations/flavors.md +156 -0
- package/dist/docs/foundations/icons.md +45 -0
- package/dist/docs/foundations/palette.md +180 -0
- package/dist/docs/foundations/spacing-elevation.md +168 -0
- package/dist/docs/foundations/typography.md +80 -0
- package/dist/docs/index.md +233 -0
- package/dist/docs/manifest.json +859 -0
- package/dist/fonts/inter-OFL.txt +93 -0
- package/dist/fonts/inter-latin-ext-wght-italic.woff2 +0 -0
- package/dist/fonts/inter-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/inter-latin-wght-italic.woff2 +0 -0
- package/dist/fonts/inter-latin-wght-normal.woff2 +0 -0
- package/dist/fonts/martian-mono-OFL.txt +93 -0
- package/dist/fonts/martian-mono-latin-ext-wdth-normal.woff2 +0 -0
- package/dist/fonts/martian-mono-latin-wdth-normal.woff2 +0 -0
- package/dist/fonts/space-grotesk-OFL.txt +93 -0
- package/dist/fonts/space-grotesk-latin-ext-wght-normal.woff2 +0 -0
- package/dist/fonts/space-grotesk-latin-wght-normal.woff2 +0 -0
- package/dist/fonts.css +73 -0
- package/dist/nyxwire.css +12183 -0
- package/dist/tokens.css +579 -0
- package/dist/utilities.css +176 -0
- package/nyxwire.d.ts +2 -0
- package/package.json +66 -3
- package/skills/nyxwire/SKILL.md +63 -0
- package/src/base.css +158 -0
- package/src/components/accordion.css +280 -0
- package/src/components/alert.css +176 -0
- package/src/components/avatar.css +262 -0
- package/src/components/badge.css +193 -0
- package/src/components/breadcrumbs.css +209 -0
- package/src/components/btn.css +517 -0
- package/src/components/card.css +327 -0
- package/src/components/checkbox.css +202 -0
- package/src/components/chip.css +345 -0
- package/src/components/code.css +340 -0
- package/src/components/dialog.css +411 -0
- package/src/components/divider.css +201 -0
- package/src/components/empty.css +216 -0
- package/src/components/field.css +161 -0
- package/src/components/hud.css +212 -0
- package/src/components/index.css +50 -0
- package/src/components/input.css +383 -0
- package/src/components/kbd.css +197 -0
- package/src/components/layout.css +344 -0
- package/src/components/link.css +178 -0
- package/src/components/list.css +353 -0
- package/src/components/menu.css +347 -0
- package/src/components/meter.css +238 -0
- package/src/components/navbar.css +309 -0
- package/src/components/pagination.css +302 -0
- package/src/components/popover.css +352 -0
- package/src/components/progress.css +241 -0
- package/src/components/select.css +121 -0
- package/src/components/sidenav.css +326 -0
- package/src/components/skeleton.css +193 -0
- package/src/components/slider.css +201 -0
- package/src/components/spinner.css +200 -0
- package/src/components/stat.css +263 -0
- package/src/components/steps.css +311 -0
- package/src/components/switch.css +183 -0
- package/src/components/table.css +290 -0
- package/src/components/tabs.css +271 -0
- package/src/components/toast.css +413 -0
- package/src/components/tooltip.css +288 -0
- package/src/fonts.css +92 -0
- package/src/index.css +6 -0
- package/src/motion.css +177 -0
- package/src/semantic.css +85 -0
- package/src/tokens.css +276 -0
- package/src/typography.css +430 -0
- package/src/utilities.css +198 -0
|
@@ -0,0 +1,216 @@
|
|
|
1
|
+
/* Empty state: no results, nothing here yet, or a filtered list with nothing to show. The action
|
|
2
|
+
row offers the next step; it is not a decorative illustration.
|
|
3
|
+
|
|
4
|
+
<div class="nw-empty nw-empty-bordered">
|
|
5
|
+
<span class="nw-empty-icon" aria-hidden="true">svg</span>
|
|
6
|
+
<h3 class="nw-empty-title">No nodes connected</h3>
|
|
7
|
+
<p class="nw-empty-description">Add a node to start routing traffic.</p>
|
|
8
|
+
<div class="nw-empty-actions">
|
|
9
|
+
<button class="nw-btn nw-btn-primary nw-btn-sm">Add node</button>
|
|
10
|
+
<button class="nw-btn nw-btn-ghost nw-btn-sm">Read the docs</button>
|
|
11
|
+
</div>
|
|
12
|
+
</div>
|
|
13
|
+
|
|
14
|
+
Variants: -bordered, -dashed, -cut and -inline (a compact row for a sidebar or table footer).
|
|
15
|
+
Sizes sm..lg scale the padding and the icon; intents tint the icon. */
|
|
16
|
+
@layer components {
|
|
17
|
+
.nw-empty {
|
|
18
|
+
--_intent: var(--nw-primary);
|
|
19
|
+
--_on: var(--nw-on-primary);
|
|
20
|
+
--_soft: var(--nw-primary-soft);
|
|
21
|
+
--_fill: var(--nw-panel);
|
|
22
|
+
--_p: var(--nw-space-10);
|
|
23
|
+
--_icon: var(--nw-space-12);
|
|
24
|
+
--_icon-ink: var(--nw-fg-faint);
|
|
25
|
+
|
|
26
|
+
display: grid;
|
|
27
|
+
justify-items: center;
|
|
28
|
+
gap: var(--nw-space-3);
|
|
29
|
+
max-inline-size: 36rem;
|
|
30
|
+
margin-inline: auto;
|
|
31
|
+
padding: var(--_p) var(--nw-space-6);
|
|
32
|
+
text-align: center;
|
|
33
|
+
color: var(--nw-fg);
|
|
34
|
+
}
|
|
35
|
+
.nw-empty-icon {
|
|
36
|
+
display: inline-grid;
|
|
37
|
+
place-items: center;
|
|
38
|
+
inline-size: var(--_icon);
|
|
39
|
+
block-size: var(--_icon);
|
|
40
|
+
margin-block-end: var(--nw-space-1);
|
|
41
|
+
border-radius: var(--nw-radius-md);
|
|
42
|
+
color: var(--_icon-ink);
|
|
43
|
+
background-color: color-mix(in oklab, var(--_intent) 8%, transparent);
|
|
44
|
+
}
|
|
45
|
+
.nw-empty-icon > svg {
|
|
46
|
+
inline-size: calc(var(--_icon) / 2);
|
|
47
|
+
block-size: calc(var(--_icon) / 2);
|
|
48
|
+
}
|
|
49
|
+
.nw-empty-title {
|
|
50
|
+
font-family: var(--nw-font-display);
|
|
51
|
+
font-size: var(--nw-text-lg);
|
|
52
|
+
font-weight: 600;
|
|
53
|
+
line-height: var(--nw-leading-snug);
|
|
54
|
+
letter-spacing: var(--nw-tracking-tight);
|
|
55
|
+
text-wrap: balance;
|
|
56
|
+
}
|
|
57
|
+
.nw-empty-description {
|
|
58
|
+
max-inline-size: 42ch;
|
|
59
|
+
font-size: var(--nw-text-sm);
|
|
60
|
+
line-height: var(--nw-leading-normal);
|
|
61
|
+
color: var(--nw-fg-muted);
|
|
62
|
+
text-wrap: pretty;
|
|
63
|
+
}
|
|
64
|
+
.nw-empty-actions {
|
|
65
|
+
display: flex;
|
|
66
|
+
flex-wrap: wrap;
|
|
67
|
+
justify-content: center;
|
|
68
|
+
gap: var(--nw-space-3);
|
|
69
|
+
margin-block-start: var(--nw-space-2);
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/* Sizes ------------------------------------------------------------------------------------ */
|
|
73
|
+
|
|
74
|
+
.nw-empty-sm {
|
|
75
|
+
--_p: var(--nw-space-6);
|
|
76
|
+
--_icon: var(--nw-space-10);
|
|
77
|
+
}
|
|
78
|
+
.nw-empty-md {
|
|
79
|
+
--_p: var(--nw-space-10);
|
|
80
|
+
--_icon: var(--nw-space-12);
|
|
81
|
+
}
|
|
82
|
+
.nw-empty-lg {
|
|
83
|
+
--_p: var(--nw-space-16);
|
|
84
|
+
--_icon: var(--nw-space-16);
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
/* Intents ---------------------------------------------------------------------------------- */
|
|
88
|
+
|
|
89
|
+
.nw-empty-primary {
|
|
90
|
+
--_intent: var(--nw-primary);
|
|
91
|
+
--_on: var(--nw-on-primary);
|
|
92
|
+
--_soft: var(--nw-primary-soft);
|
|
93
|
+
--_icon-ink: color-mix(in oklab, var(--_intent) var(--nw-soft-ink), var(--nw-fg));
|
|
94
|
+
}
|
|
95
|
+
.nw-empty-secondary {
|
|
96
|
+
--_intent: var(--nw-secondary);
|
|
97
|
+
--_on: var(--nw-on-secondary);
|
|
98
|
+
--_soft: var(--nw-secondary-soft);
|
|
99
|
+
--_icon-ink: color-mix(in oklab, var(--_intent) var(--nw-soft-ink), var(--nw-fg));
|
|
100
|
+
}
|
|
101
|
+
.nw-empty-tertiary {
|
|
102
|
+
--_intent: var(--nw-tertiary);
|
|
103
|
+
--_on: var(--nw-on-tertiary);
|
|
104
|
+
--_soft: var(--nw-tertiary-soft);
|
|
105
|
+
--_icon-ink: color-mix(in oklab, var(--_intent) var(--nw-soft-ink), var(--nw-fg));
|
|
106
|
+
}
|
|
107
|
+
.nw-empty-neutral {
|
|
108
|
+
--_intent: var(--nw-fg-muted);
|
|
109
|
+
--_on: var(--nw-canvas);
|
|
110
|
+
--_soft: color-mix(in oklab, var(--nw-fg) 10%, transparent);
|
|
111
|
+
--_icon-ink: var(--nw-fg-subtle);
|
|
112
|
+
}
|
|
113
|
+
.nw-empty-info {
|
|
114
|
+
--_intent: var(--nw-info);
|
|
115
|
+
--_on: var(--nw-on-info);
|
|
116
|
+
--_soft: var(--nw-info-soft);
|
|
117
|
+
--_icon-ink: color-mix(in oklab, var(--_intent) var(--nw-soft-ink), var(--nw-fg));
|
|
118
|
+
}
|
|
119
|
+
.nw-empty-success {
|
|
120
|
+
--_intent: var(--nw-success);
|
|
121
|
+
--_on: var(--nw-on-success);
|
|
122
|
+
--_soft: var(--nw-success-soft);
|
|
123
|
+
--_icon-ink: color-mix(in oklab, var(--_intent) var(--nw-soft-ink), var(--nw-fg));
|
|
124
|
+
}
|
|
125
|
+
.nw-empty-warning {
|
|
126
|
+
--_intent: var(--nw-warning);
|
|
127
|
+
--_on: var(--nw-on-warning);
|
|
128
|
+
--_soft: var(--nw-warning-soft);
|
|
129
|
+
--_icon-ink: color-mix(in oklab, var(--_intent) var(--nw-soft-ink), var(--nw-fg));
|
|
130
|
+
}
|
|
131
|
+
.nw-empty-danger {
|
|
132
|
+
--_intent: var(--nw-danger);
|
|
133
|
+
--_on: var(--nw-on-danger);
|
|
134
|
+
--_soft: var(--nw-danger-soft);
|
|
135
|
+
--_icon-ink: color-mix(in oklab, var(--_intent) var(--nw-soft-ink), var(--nw-fg));
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
/* Variants --------------------------------------------------------------------------------- */
|
|
139
|
+
|
|
140
|
+
.nw-empty-bordered {
|
|
141
|
+
border: 1px solid var(--nw-line);
|
|
142
|
+
border-radius: var(--nw-radius-md);
|
|
143
|
+
background-color: var(--_fill);
|
|
144
|
+
}
|
|
145
|
+
.nw-empty-dashed {
|
|
146
|
+
border: 1px dashed var(--nw-line-strong);
|
|
147
|
+
border-radius: var(--nw-radius-md);
|
|
148
|
+
}
|
|
149
|
+
.nw-empty-cut {
|
|
150
|
+
--nw-fill: var(--_fill);
|
|
151
|
+
--nw-cut: var(--nw-space-5);
|
|
152
|
+
position: relative;
|
|
153
|
+
isolation: isolate;
|
|
154
|
+
border: 0;
|
|
155
|
+
border-radius: 0;
|
|
156
|
+
background: var(--nw-cut-surface);
|
|
157
|
+
}
|
|
158
|
+
.nw-empty-cut::before {
|
|
159
|
+
content: '';
|
|
160
|
+
position: absolute;
|
|
161
|
+
inset: 0;
|
|
162
|
+
z-index: 1;
|
|
163
|
+
pointer-events: none;
|
|
164
|
+
background: var(--nw-line-strong);
|
|
165
|
+
clip-path: var(--nw-cut-ring);
|
|
166
|
+
}
|
|
167
|
+
.nw-empty-inline {
|
|
168
|
+
grid-template-columns: auto minmax(0, 1fr);
|
|
169
|
+
justify-items: start;
|
|
170
|
+
align-items: center;
|
|
171
|
+
gap: var(--nw-space-1) var(--nw-space-4);
|
|
172
|
+
max-inline-size: none;
|
|
173
|
+
margin-inline: 0;
|
|
174
|
+
padding: var(--nw-space-4);
|
|
175
|
+
text-align: start;
|
|
176
|
+
}
|
|
177
|
+
.nw-empty-inline .nw-empty-icon {
|
|
178
|
+
grid-row: 1 / span 2;
|
|
179
|
+
inline-size: var(--nw-space-8);
|
|
180
|
+
block-size: var(--nw-space-8);
|
|
181
|
+
margin-block-end: 0;
|
|
182
|
+
}
|
|
183
|
+
.nw-empty-inline .nw-empty-title {
|
|
184
|
+
font-size: var(--nw-text-sm);
|
|
185
|
+
}
|
|
186
|
+
.nw-empty-inline .nw-empty-description {
|
|
187
|
+
font-size: var(--nw-text-xs);
|
|
188
|
+
}
|
|
189
|
+
.nw-empty-inline .nw-empty-actions {
|
|
190
|
+
grid-column: 1 / -1;
|
|
191
|
+
justify-content: flex-start;
|
|
192
|
+
margin-block-start: var(--nw-space-2);
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
@media (max-width: 40rem) {
|
|
196
|
+
.nw-empty {
|
|
197
|
+
--_p: var(--nw-space-8);
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
@media (forced-colors: active) {
|
|
202
|
+
.nw-empty-bordered,
|
|
203
|
+
.nw-empty-dashed,
|
|
204
|
+
.nw-empty-cut {
|
|
205
|
+
border: 1px solid CanvasText;
|
|
206
|
+
background: Canvas;
|
|
207
|
+
}
|
|
208
|
+
.nw-empty-cut::before {
|
|
209
|
+
display: none;
|
|
210
|
+
}
|
|
211
|
+
.nw-empty-icon {
|
|
212
|
+
color: CanvasText;
|
|
213
|
+
background: Canvas;
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
}
|
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
/* Field: the label, the control, the hint and the error of one form value.
|
|
2
|
+
<div class="nw-field">
|
|
3
|
+
<label class="nw-label" for="x">Label</label>
|
|
4
|
+
<input class="nw-input" id="x" aria-describedby="x-hint" />
|
|
5
|
+
<p class="nw-field-hint" id="x-hint">Hint</p>
|
|
6
|
+
<p class="nw-field-error">Error</p> shown only while the field is invalid
|
|
7
|
+
</div>
|
|
8
|
+
A field is invalid when a descendant has aria-invalid='true', or with .nw-field-invalid.
|
|
9
|
+
.nw-field-group is a fieldset of related fields; .nw-field-legend styles its legend.
|
|
10
|
+
A .nw-label also wraps a checkbox, radio or switch: the control aligns to the first text line
|
|
11
|
+
through the lh unit, and the text stays clickable. */
|
|
12
|
+
@layer components {
|
|
13
|
+
.nw-field {
|
|
14
|
+
display: flex;
|
|
15
|
+
flex-direction: column;
|
|
16
|
+
gap: var(--nw-space-1-5);
|
|
17
|
+
min-inline-size: 0;
|
|
18
|
+
}
|
|
19
|
+
.nw-field-sm {
|
|
20
|
+
--_label-fs: var(--nw-text-xs);
|
|
21
|
+
}
|
|
22
|
+
.nw-field-md {
|
|
23
|
+
--_label-fs: var(--nw-text-sm);
|
|
24
|
+
}
|
|
25
|
+
.nw-field-lg {
|
|
26
|
+
--_label-fs: var(--nw-text-base);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/* Label ---------------------------------------------------------------------------------- */
|
|
30
|
+
.nw-label {
|
|
31
|
+
display: inline-flex;
|
|
32
|
+
align-items: flex-start;
|
|
33
|
+
gap: var(--nw-space-2);
|
|
34
|
+
min-inline-size: 0;
|
|
35
|
+
font-family: var(--nw-font-sans);
|
|
36
|
+
font-size: var(--_label-fs, var(--nw-text-sm));
|
|
37
|
+
font-weight: 500;
|
|
38
|
+
line-height: var(--nw-leading-normal);
|
|
39
|
+
color: var(--nw-fg);
|
|
40
|
+
cursor: default;
|
|
41
|
+
}
|
|
42
|
+
.nw-label[for],
|
|
43
|
+
label.nw-label {
|
|
44
|
+
cursor: pointer;
|
|
45
|
+
}
|
|
46
|
+
.nw-label-sm {
|
|
47
|
+
--_label-fs: var(--nw-text-xs);
|
|
48
|
+
}
|
|
49
|
+
.nw-label-md {
|
|
50
|
+
--_label-fs: var(--nw-text-sm);
|
|
51
|
+
}
|
|
52
|
+
.nw-label-lg {
|
|
53
|
+
--_label-fs: var(--nw-text-base);
|
|
54
|
+
}
|
|
55
|
+
/* Text column of a wrapping label, so a hint can sit under the label text. */
|
|
56
|
+
.nw-label-text {
|
|
57
|
+
display: grid;
|
|
58
|
+
gap: var(--nw-space-0-5);
|
|
59
|
+
min-inline-size: 0;
|
|
60
|
+
}
|
|
61
|
+
.nw-label:has(> :disabled) {
|
|
62
|
+
color: var(--nw-fg-disabled);
|
|
63
|
+
cursor: not-allowed;
|
|
64
|
+
}
|
|
65
|
+
.nw-choice {
|
|
66
|
+
display: inline-flex;
|
|
67
|
+
align-items: center;
|
|
68
|
+
gap: var(--nw-space-2);
|
|
69
|
+
min-block-size: var(--nw-space-6);
|
|
70
|
+
font-family: var(--nw-font-sans);
|
|
71
|
+
font-size: var(--nw-text-sm);
|
|
72
|
+
line-height: var(--nw-leading-normal);
|
|
73
|
+
color: var(--nw-fg);
|
|
74
|
+
cursor: pointer;
|
|
75
|
+
}
|
|
76
|
+
.nw-choice:has(> :disabled) {
|
|
77
|
+
color: var(--nw-fg-disabled);
|
|
78
|
+
cursor: not-allowed;
|
|
79
|
+
}
|
|
80
|
+
.nw-label-required::after {
|
|
81
|
+
content: '*';
|
|
82
|
+
color: var(--nw-danger);
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
/* Hint and error ------------------------------------------------------------------------- */
|
|
86
|
+
.nw-field-hint,
|
|
87
|
+
.nw-field-error {
|
|
88
|
+
margin: 0;
|
|
89
|
+
font-size: var(--nw-text-xs);
|
|
90
|
+
font-weight: 400;
|
|
91
|
+
line-height: var(--nw-leading-normal);
|
|
92
|
+
}
|
|
93
|
+
.nw-field-hint {
|
|
94
|
+
color: var(--nw-fg-subtle);
|
|
95
|
+
}
|
|
96
|
+
.nw-field-error {
|
|
97
|
+
display: none;
|
|
98
|
+
align-items: flex-start;
|
|
99
|
+
gap: var(--nw-space-1-5);
|
|
100
|
+
color: var(--nw-danger);
|
|
101
|
+
font-weight: 500;
|
|
102
|
+
}
|
|
103
|
+
.nw-field-error > svg {
|
|
104
|
+
flex: none;
|
|
105
|
+
inline-size: 1em;
|
|
106
|
+
block-size: 1em;
|
|
107
|
+
margin-block: calc((1lh - 1em) / 2);
|
|
108
|
+
}
|
|
109
|
+
.nw-field:has([aria-invalid='true']) > .nw-field-error,
|
|
110
|
+
.nw-field-invalid > .nw-field-error {
|
|
111
|
+
display: flex;
|
|
112
|
+
}
|
|
113
|
+
/* Outside a field the error is a standalone message and always shows. */
|
|
114
|
+
.nw-field-error:not(.nw-field > *) {
|
|
115
|
+
display: flex;
|
|
116
|
+
}
|
|
117
|
+
.nw-field:has([aria-invalid='true']) > .nw-label,
|
|
118
|
+
.nw-field-invalid > .nw-label {
|
|
119
|
+
color: var(--nw-danger);
|
|
120
|
+
}
|
|
121
|
+
.nw-field:has(:disabled) > .nw-label,
|
|
122
|
+
.nw-field-disabled > .nw-label,
|
|
123
|
+
.nw-field:has(:disabled) > .nw-field-hint,
|
|
124
|
+
.nw-field-disabled > .nw-field-hint {
|
|
125
|
+
color: var(--nw-fg-disabled);
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
/* A fieldset of related fields ----------------------------------------------------------- */
|
|
129
|
+
.nw-field-group {
|
|
130
|
+
display: flex;
|
|
131
|
+
flex-direction: column;
|
|
132
|
+
gap: var(--nw-space-3);
|
|
133
|
+
min-inline-size: 0;
|
|
134
|
+
margin: 0;
|
|
135
|
+
padding: 0;
|
|
136
|
+
border: 0;
|
|
137
|
+
}
|
|
138
|
+
.nw-field-legend {
|
|
139
|
+
margin-block-end: var(--nw-space-1);
|
|
140
|
+
padding: 0;
|
|
141
|
+
font-size: var(--nw-text-sm);
|
|
142
|
+
font-weight: 600;
|
|
143
|
+
line-height: var(--nw-leading-snug);
|
|
144
|
+
color: var(--nw-fg);
|
|
145
|
+
}
|
|
146
|
+
.nw-field-group:disabled > .nw-field-legend {
|
|
147
|
+
color: var(--nw-fg-disabled);
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
@media (forced-colors: active) {
|
|
151
|
+
.nw-field-error,
|
|
152
|
+
.nw-field:has([aria-invalid='true']) > .nw-label,
|
|
153
|
+
.nw-field-invalid > .nw-label {
|
|
154
|
+
color: CanvasText;
|
|
155
|
+
}
|
|
156
|
+
.nw-field-error::before {
|
|
157
|
+
content: '!';
|
|
158
|
+
font-weight: 700;
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
}
|
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
@layer components {
|
|
2
|
+
.nw-hud {
|
|
3
|
+
--_intent: var(--nw-primary);
|
|
4
|
+
--_pad: var(--nw-space-4);
|
|
5
|
+
--_fill: var(--nw-panel);
|
|
6
|
+
--_edge: var(--nw-line-strong);
|
|
7
|
+
--_ink: color-mix(in oklab, var(--_intent) 45%, var(--nw-fg));
|
|
8
|
+
|
|
9
|
+
position: relative;
|
|
10
|
+
isolation: isolate;
|
|
11
|
+
display: flex;
|
|
12
|
+
flex-direction: column;
|
|
13
|
+
min-inline-size: 0;
|
|
14
|
+
border: 1px solid var(--_edge);
|
|
15
|
+
border-radius: var(--nw-radius-md);
|
|
16
|
+
color: var(--nw-fg);
|
|
17
|
+
background-color: var(--_fill);
|
|
18
|
+
box-shadow: var(--nw-shadow-sm);
|
|
19
|
+
overflow-wrap: anywhere;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.nw-hud-header,
|
|
23
|
+
.nw-hud-footer {
|
|
24
|
+
display: flex;
|
|
25
|
+
flex-wrap: wrap;
|
|
26
|
+
align-items: center;
|
|
27
|
+
gap: var(--nw-space-2) var(--nw-space-3);
|
|
28
|
+
padding: var(--nw-space-2-5) var(--_pad);
|
|
29
|
+
}
|
|
30
|
+
.nw-hud-header {
|
|
31
|
+
border-block-end: 1px solid var(--nw-line);
|
|
32
|
+
}
|
|
33
|
+
.nw-hud-title {
|
|
34
|
+
margin: 0;
|
|
35
|
+
font-family: var(--nw-font-display);
|
|
36
|
+
font-size: var(--nw-text-lg);
|
|
37
|
+
font-weight: 600;
|
|
38
|
+
line-height: var(--nw-leading-snug);
|
|
39
|
+
}
|
|
40
|
+
.nw-hud-status {
|
|
41
|
+
display: inline-flex;
|
|
42
|
+
align-items: baseline;
|
|
43
|
+
gap: var(--nw-space-1-5);
|
|
44
|
+
font-size: var(--nw-text-xs);
|
|
45
|
+
font-weight: 600;
|
|
46
|
+
color: var(--_ink);
|
|
47
|
+
}
|
|
48
|
+
.nw-hud-status::before {
|
|
49
|
+
content: '';
|
|
50
|
+
flex: none;
|
|
51
|
+
inline-size: var(--nw-space-1-5);
|
|
52
|
+
block-size: var(--nw-space-1-5);
|
|
53
|
+
background: currentColor;
|
|
54
|
+
rotate: 45deg;
|
|
55
|
+
}
|
|
56
|
+
.nw-hud-actions {
|
|
57
|
+
display: inline-flex;
|
|
58
|
+
flex-wrap: wrap;
|
|
59
|
+
align-items: center;
|
|
60
|
+
gap: var(--nw-space-2);
|
|
61
|
+
margin-inline-start: auto;
|
|
62
|
+
}
|
|
63
|
+
.nw-hud-body {
|
|
64
|
+
flex: 1 1 auto;
|
|
65
|
+
min-inline-size: 0;
|
|
66
|
+
padding: var(--_pad);
|
|
67
|
+
font-size: var(--nw-text-sm);
|
|
68
|
+
line-height: var(--nw-leading-normal);
|
|
69
|
+
}
|
|
70
|
+
.nw-hud-footer {
|
|
71
|
+
border-block-start: 1px solid var(--nw-line);
|
|
72
|
+
color: var(--nw-fg-subtle);
|
|
73
|
+
font-size: var(--nw-text-xs);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.nw-hud-primary {
|
|
77
|
+
--_intent: var(--nw-primary);
|
|
78
|
+
}
|
|
79
|
+
.nw-hud-secondary {
|
|
80
|
+
--_intent: var(--nw-secondary);
|
|
81
|
+
}
|
|
82
|
+
.nw-hud-tertiary {
|
|
83
|
+
--_intent: var(--nw-tertiary);
|
|
84
|
+
}
|
|
85
|
+
.nw-hud-neutral {
|
|
86
|
+
--_intent: var(--nw-fg-muted);
|
|
87
|
+
}
|
|
88
|
+
.nw-hud-info {
|
|
89
|
+
--_intent: var(--nw-info);
|
|
90
|
+
}
|
|
91
|
+
.nw-hud-success {
|
|
92
|
+
--_intent: var(--nw-success);
|
|
93
|
+
}
|
|
94
|
+
.nw-hud-warning {
|
|
95
|
+
--_intent: var(--nw-warning);
|
|
96
|
+
}
|
|
97
|
+
.nw-hud-danger {
|
|
98
|
+
--_intent: var(--nw-danger);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.nw-hud-xs {
|
|
102
|
+
--_pad: var(--nw-space-2-5);
|
|
103
|
+
}
|
|
104
|
+
.nw-hud-sm {
|
|
105
|
+
--_pad: var(--nw-space-3);
|
|
106
|
+
}
|
|
107
|
+
.nw-hud-md {
|
|
108
|
+
--_pad: var(--nw-space-4);
|
|
109
|
+
}
|
|
110
|
+
.nw-hud-lg {
|
|
111
|
+
--_pad: var(--nw-space-6);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.nw-hud-solid {
|
|
115
|
+
--_fill: var(--nw-canvas-sunken);
|
|
116
|
+
}
|
|
117
|
+
.nw-hud-wire {
|
|
118
|
+
--_edge: var(--nw-gradient-wire);
|
|
119
|
+
|
|
120
|
+
border-color: transparent;
|
|
121
|
+
background:
|
|
122
|
+
linear-gradient(var(--_fill), var(--_fill)) padding-box,
|
|
123
|
+
var(--_edge) border-box;
|
|
124
|
+
}
|
|
125
|
+
/* Only the paint is cut, so focus outlines and child popovers aren't clipped. */
|
|
126
|
+
.nw-hud-cut {
|
|
127
|
+
--nw-fill: var(--_fill);
|
|
128
|
+
|
|
129
|
+
border-color: transparent;
|
|
130
|
+
border-radius: 0;
|
|
131
|
+
background: var(--nw-cut-surface) border-box;
|
|
132
|
+
box-shadow: none;
|
|
133
|
+
}
|
|
134
|
+
.nw-hud-cut::before,
|
|
135
|
+
.nw-hud-scanlines::after {
|
|
136
|
+
content: '';
|
|
137
|
+
position: absolute;
|
|
138
|
+
inset: -1px;
|
|
139
|
+
pointer-events: none;
|
|
140
|
+
}
|
|
141
|
+
.nw-hud-cut::before {
|
|
142
|
+
background: var(--_edge);
|
|
143
|
+
clip-path: var(--nw-cut-ring);
|
|
144
|
+
}
|
|
145
|
+
.nw-hud-scanlines::after {
|
|
146
|
+
z-index: -1;
|
|
147
|
+
border-radius: inherit;
|
|
148
|
+
background-image: var(--nw-scanlines);
|
|
149
|
+
}
|
|
150
|
+
.nw-hud-cut.nw-hud-scanlines::after {
|
|
151
|
+
clip-path: var(--nw-cut-path);
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
.nw-hud-interactive {
|
|
155
|
+
cursor: pointer;
|
|
156
|
+
text-decoration: none;
|
|
157
|
+
}
|
|
158
|
+
.nw-hud-interactive:hover:not(:disabled, [aria-disabled='true']) {
|
|
159
|
+
--_fill: var(--nw-panel-hover);
|
|
160
|
+
}
|
|
161
|
+
.nw-hud-interactive:active:not(:disabled, [aria-disabled='true']) {
|
|
162
|
+
--_fill: var(--nw-panel-active);
|
|
163
|
+
}
|
|
164
|
+
.nw-hud:focus-visible {
|
|
165
|
+
outline: var(--nw-ring-width) solid var(--nw-ring);
|
|
166
|
+
outline-offset: var(--nw-ring-offset);
|
|
167
|
+
}
|
|
168
|
+
.nw-hud:is(:disabled, [aria-disabled='true']) {
|
|
169
|
+
--_ink: var(--nw-fg-disabled);
|
|
170
|
+
--_edge: var(--nw-line);
|
|
171
|
+
|
|
172
|
+
color: var(--nw-fg-disabled);
|
|
173
|
+
box-shadow: none;
|
|
174
|
+
cursor: not-allowed;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
/* Keep the status text steady; only its decorative marker pulses. */
|
|
178
|
+
.nw-hud-alarm:not(:disabled, [aria-disabled='true']) .nw-hud-status::before {
|
|
179
|
+
animation: nw-pulse calc(3 * var(--nw-duration-slower)) var(--nw-ease-standard) infinite;
|
|
180
|
+
}
|
|
181
|
+
@media (prefers-reduced-motion: reduce) {
|
|
182
|
+
.nw-hud-alarm:not(:disabled, [aria-disabled='true']) .nw-hud-status::before {
|
|
183
|
+
animation: none;
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
@media (forced-colors: active) {
|
|
187
|
+
.nw-hud,
|
|
188
|
+
.nw-hud-wire,
|
|
189
|
+
.nw-hud-cut {
|
|
190
|
+
border-color: CanvasText;
|
|
191
|
+
color: CanvasText;
|
|
192
|
+
background: Canvas;
|
|
193
|
+
box-shadow: none;
|
|
194
|
+
}
|
|
195
|
+
.nw-hud-header,
|
|
196
|
+
.nw-hud-footer {
|
|
197
|
+
border-color: CanvasText;
|
|
198
|
+
}
|
|
199
|
+
.nw-hud:focus-visible {
|
|
200
|
+
outline-color: Highlight;
|
|
201
|
+
}
|
|
202
|
+
.nw-hud-cut::before,
|
|
203
|
+
.nw-hud-scanlines::after,
|
|
204
|
+
.nw-hud-status::before {
|
|
205
|
+
display: none;
|
|
206
|
+
}
|
|
207
|
+
.nw-hud:is(:disabled, [aria-disabled='true']) {
|
|
208
|
+
color: GrayText;
|
|
209
|
+
border-color: GrayText;
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/* Ordered from primitives to composites: on a specificity tie a later file wins, so a composite
|
|
2
|
+
can restyle the primitives it contains. */
|
|
3
|
+
|
|
4
|
+
/* Layout and content */
|
|
5
|
+
@import './layout.css';
|
|
6
|
+
@import './divider.css';
|
|
7
|
+
@import './link.css';
|
|
8
|
+
@import './list.css';
|
|
9
|
+
@import './kbd.css';
|
|
10
|
+
@import './code.css';
|
|
11
|
+
@import './avatar.css';
|
|
12
|
+
@import './badge.css';
|
|
13
|
+
@import './chip.css';
|
|
14
|
+
|
|
15
|
+
/* Actions and forms */
|
|
16
|
+
@import './btn.css';
|
|
17
|
+
@import './field.css';
|
|
18
|
+
@import './input.css';
|
|
19
|
+
@import './select.css';
|
|
20
|
+
@import './checkbox.css';
|
|
21
|
+
@import './switch.css';
|
|
22
|
+
@import './slider.css';
|
|
23
|
+
|
|
24
|
+
/* Surfaces and navigation */
|
|
25
|
+
@import './card.css';
|
|
26
|
+
@import './hud.css';
|
|
27
|
+
@import './alert.css';
|
|
28
|
+
@import './tabs.css';
|
|
29
|
+
@import './breadcrumbs.css';
|
|
30
|
+
@import './pagination.css';
|
|
31
|
+
@import './menu.css';
|
|
32
|
+
@import './navbar.css';
|
|
33
|
+
@import './sidenav.css';
|
|
34
|
+
@import './accordion.css';
|
|
35
|
+
@import './steps.css';
|
|
36
|
+
|
|
37
|
+
/* Data and feedback */
|
|
38
|
+
@import './table.css';
|
|
39
|
+
@import './stat.css';
|
|
40
|
+
@import './empty.css';
|
|
41
|
+
@import './progress.css';
|
|
42
|
+
@import './meter.css';
|
|
43
|
+
@import './spinner.css';
|
|
44
|
+
@import './skeleton.css';
|
|
45
|
+
|
|
46
|
+
/* Overlays */
|
|
47
|
+
@import './popover.css';
|
|
48
|
+
@import './tooltip.css';
|
|
49
|
+
@import './dialog.css';
|
|
50
|
+
@import './toast.css';
|