@nqmcreative/ui 0.4.1 → 0.4.3
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 +1 -1
- package/dist/core/index.d.ts +1 -1
- package/dist/core/index.js +1 -1
- package/dist/core/tones.d.ts +10 -0
- package/dist/core/tones.js +19 -0
- package/dist/core/trigger.d.ts +8 -0
- package/dist/core/trigger.js +11 -0
- package/dist/styles/matte/Alert.svelte +1 -1
- package/dist/styles/matte/Avatar.svelte +16 -3
- package/dist/styles/matte/Button.svelte +9 -2
- package/dist/styles/matte/Checkbox.svelte +49 -30
- package/dist/styles/matte/CheckboxGroup.svelte +15 -4
- package/dist/styles/matte/Combobox.svelte +12 -3
- package/dist/styles/matte/CommandPalette.svelte +1 -1
- package/dist/styles/matte/ConfirmDialog.svelte +10 -2
- package/dist/styles/matte/ContextMenu.svelte +1 -1
- package/dist/styles/matte/DatePicker.svelte +10 -3
- package/dist/styles/matte/Divider.svelte +1 -1
- package/dist/styles/matte/Drawer.svelte +10 -2
- package/dist/styles/matte/Dropdown.svelte +1 -1
- package/dist/styles/matte/Field.svelte +59 -3
- package/dist/styles/matte/Footer.svelte +14 -3
- package/dist/styles/matte/Input.svelte +9 -2
- package/dist/styles/matte/Label.svelte +3 -1
- package/dist/styles/matte/Link.svelte +13 -2
- package/dist/styles/matte/MenuItem.svelte +11 -4
- package/dist/styles/matte/Modal.svelte +11 -3
- package/dist/styles/matte/MultiSelect.svelte +1 -1
- package/dist/styles/matte/Navbar.svelte +2 -2
- package/dist/styles/matte/Popover.svelte +1 -1
- package/dist/styles/matte/Radio.svelte +41 -22
- package/dist/styles/matte/RadioGroup.svelte +15 -4
- package/dist/styles/matte/Select.svelte +4 -2
- package/dist/styles/matte/Skeleton.svelte +2 -1
- package/dist/styles/matte/Stat.svelte +27 -3
- package/dist/styles/matte/Switch.svelte +6 -1
- package/dist/styles/matte/Tabs.svelte +1 -1
- package/dist/styles/matte/Textarea.svelte +4 -2
- package/dist/styles/matte/Toaster.svelte +21 -3
- package/dist/styles/matte/Tooltip.svelte +8 -1
- package/dist/styles/matte/index.d.ts +1 -1
- package/dist/styles/matte/index.js +1 -1
- package/dist/styles/matte/theme.css +64 -1
- package/dist/styles/paper/AccordionItem.svelte +38 -11
- package/dist/styles/paper/AccordionItem.svelte.d.ts +1 -1
- package/dist/styles/paper/Alert.svelte +2 -2
- package/dist/styles/paper/Avatar.svelte +14 -3
- package/dist/styles/paper/Button.svelte +9 -2
- package/dist/styles/paper/Card.svelte +1 -1
- package/dist/styles/paper/Checkbox.svelte +55 -36
- package/dist/styles/paper/CheckboxGroup.svelte +15 -4
- package/dist/styles/paper/Combobox.svelte +12 -3
- package/dist/styles/paper/CommandPalette.svelte +1 -1
- package/dist/styles/paper/ConfirmDialog.svelte +8 -2
- package/dist/styles/paper/ContextMenu.svelte +1 -1
- package/dist/styles/paper/DatePicker.svelte +10 -3
- package/dist/styles/paper/Divider.svelte +1 -1
- package/dist/styles/paper/Drawer.svelte +8 -2
- package/dist/styles/paper/Dropdown.svelte +1 -1
- package/dist/styles/paper/Field.svelte +59 -3
- package/dist/styles/paper/Footer.svelte +14 -3
- package/dist/styles/paper/Input.svelte +9 -2
- package/dist/styles/paper/Label.svelte +3 -1
- package/dist/styles/paper/Link.svelte +13 -2
- package/dist/styles/paper/MenuItem.svelte +11 -4
- package/dist/styles/paper/Modal.svelte +9 -3
- package/dist/styles/paper/MultiSelect.svelte +1 -1
- package/dist/styles/paper/Navbar.svelte +2 -2
- package/dist/styles/paper/Popover.svelte +1 -1
- package/dist/styles/paper/Radio.svelte +41 -22
- package/dist/styles/paper/RadioGroup.svelte +15 -4
- package/dist/styles/paper/SegmentedControl.svelte +2 -2
- package/dist/styles/paper/Select.svelte +4 -2
- package/dist/styles/paper/Skeleton.svelte +2 -1
- package/dist/styles/paper/Stat.svelte +24 -2
- package/dist/styles/paper/Switch.svelte +6 -1
- package/dist/styles/paper/Tabs.svelte +1 -1
- package/dist/styles/paper/Textarea.svelte +4 -2
- package/dist/styles/paper/Toaster.svelte +19 -3
- package/dist/styles/paper/Tooltip.svelte +8 -1
- package/dist/styles/paper/index.d.ts +1 -1
- package/dist/styles/paper/index.js +1 -1
- package/dist/styles/paper/theme.css +85 -13
- package/dist/styles/sprout/Alert.svelte +3 -3
- package/dist/styles/sprout/Avatar.svelte +14 -3
- package/dist/styles/sprout/Breadcrumb.svelte +1 -1
- package/dist/styles/sprout/Button.svelte +8 -4
- package/dist/styles/sprout/Calendar.svelte +1 -1
- package/dist/styles/sprout/Card.svelte +2 -2
- package/dist/styles/sprout/Checkbox.svelte +55 -36
- package/dist/styles/sprout/CheckboxGroup.svelte +15 -4
- package/dist/styles/sprout/ColorInput.svelte +1 -1
- package/dist/styles/sprout/Combobox.svelte +12 -3
- package/dist/styles/sprout/ConfirmDialog.svelte +8 -2
- package/dist/styles/sprout/DatePicker.svelte +11 -4
- package/dist/styles/sprout/Divider.svelte +1 -1
- package/dist/styles/sprout/Drawer.svelte +8 -2
- package/dist/styles/sprout/Dropzone.svelte +1 -1
- package/dist/styles/sprout/Field.svelte +59 -3
- package/dist/styles/sprout/FileInput.svelte +3 -3
- package/dist/styles/sprout/Footer.svelte +14 -3
- package/dist/styles/sprout/Input.svelte +9 -2
- package/dist/styles/sprout/Label.svelte +3 -1
- package/dist/styles/sprout/Link.svelte +13 -2
- package/dist/styles/sprout/LogoCloud.svelte +1 -1
- package/dist/styles/sprout/MenuItem.svelte +11 -4
- package/dist/styles/sprout/Modal.svelte +8 -2
- package/dist/styles/sprout/MultiSelect.svelte +3 -3
- package/dist/styles/sprout/Navbar.svelte +2 -2
- package/dist/styles/sprout/Radio.svelte +41 -22
- package/dist/styles/sprout/RadioGroup.svelte +15 -4
- package/dist/styles/sprout/SearchInput.svelte +1 -1
- package/dist/styles/sprout/SegmentedControl.svelte +2 -2
- package/dist/styles/sprout/Select.svelte +4 -2
- package/dist/styles/sprout/Sidebar.svelte +2 -1
- package/dist/styles/sprout/Skeleton.svelte +2 -1
- package/dist/styles/sprout/Stat.svelte +24 -2
- package/dist/styles/sprout/Switch.svelte +6 -1
- package/dist/styles/sprout/Table.svelte +1 -1
- package/dist/styles/sprout/Tabs.svelte +1 -1
- package/dist/styles/sprout/TagsInput.svelte +1 -1
- package/dist/styles/sprout/Textarea.svelte +4 -2
- package/dist/styles/sprout/TimeInput.svelte +1 -1
- package/dist/styles/sprout/Toaster.svelte +22 -6
- package/dist/styles/sprout/Tooltip.svelte +8 -1
- package/dist/styles/sprout/index.d.ts +2 -2
- package/dist/styles/sprout/index.js +2 -2
- package/dist/styles/sprout/lift.d.ts +14 -0
- package/dist/styles/sprout/lift.js +23 -0
- package/dist/styles/sprout/theme.css +68 -24
- package/package.json +1 -1
- package/registry.json +4 -2
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* sprout — design tokens.
|
|
3
3
|
*
|
|
4
|
-
* The warm one: leaf green on
|
|
4
|
+
* The warm one: leaf green on white, fully rounded corners, and a display face
|
|
5
5
|
* with round terminals. Built for school, community and family sites, where the
|
|
6
6
|
* reader is a parent on a phone rather than an operator at a desk. Import this
|
|
7
7
|
* after `@import "tailwindcss";` in your app's CSS entry point.
|
|
@@ -17,16 +17,21 @@
|
|
|
17
17
|
*/
|
|
18
18
|
@theme {
|
|
19
19
|
/*
|
|
20
|
-
* Surfaces are
|
|
21
|
-
*
|
|
22
|
-
*
|
|
20
|
+
* Surfaces are white, and the greys under them are near-neutral with only a
|
|
21
|
+
* hair of warmth. The green belongs to the brand, not to the paper: a page
|
|
22
|
+
* whose every secondary surface and every hover is tinted reads as tiring
|
|
23
|
+
* long before it reads as warm, so the neutrals stay out of the way.
|
|
24
|
+
*
|
|
25
|
+
* `--color-bg` is the face of a card; `--color-bg-alt` is the ground it sits
|
|
26
|
+
* on. Put `bg-bg-alt` on the body and cards float as white, which is the
|
|
27
|
+
* layering this style was drawn from.
|
|
23
28
|
*/
|
|
24
29
|
/* --- surfaces --- */
|
|
25
|
-
--color-bg: #
|
|
26
|
-
--color-bg-alt: #
|
|
27
|
-
--color-bg-inset: #
|
|
28
|
-
--color-hairline: #
|
|
29
|
-
--color-hairline-strong: #
|
|
30
|
+
--color-bg: #ffffff;
|
|
31
|
+
--color-bg-alt: #f7f7f4;
|
|
32
|
+
--color-bg-inset: #edede8;
|
|
33
|
+
--color-hairline: #e6e6e0;
|
|
34
|
+
--color-hairline-strong: #cfcfc7;
|
|
30
35
|
|
|
31
36
|
/* --- text --- */
|
|
32
37
|
--color-text: #1a3a1f;
|
|
@@ -124,6 +129,24 @@
|
|
|
124
129
|
*/
|
|
125
130
|
--ease-brand: cubic-bezier(0.34, 1.4, 0.64, 1);
|
|
126
131
|
--ease-brand-out: cubic-bezier(0.22, 1, 0.36, 1);
|
|
132
|
+
/* Overlay entrances — sprout pops in with a little overshoot, on the same
|
|
133
|
+
* `enter`/`reveal` token names matte and paper use. Declared here so the
|
|
134
|
+
* three styles stay in token-name parity; sprout's overlay components adopt
|
|
135
|
+
* them in a later pass. */
|
|
136
|
+
--animate-enter: nqm-pop 240ms var(--ease-brand);
|
|
137
|
+
--animate-reveal: nqm-pop 220ms var(--ease-brand);
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
@keyframes nqm-fade {
|
|
141
|
+
from {
|
|
142
|
+
opacity: 0;
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
@keyframes nqm-pop {
|
|
146
|
+
from {
|
|
147
|
+
opacity: 0;
|
|
148
|
+
transform: scale(0.96);
|
|
149
|
+
}
|
|
127
150
|
}
|
|
128
151
|
|
|
129
152
|
/*
|
|
@@ -136,25 +159,25 @@
|
|
|
136
159
|
* Every utility built on these tokens follows automatically, so components
|
|
137
160
|
* need no `dark:` classes of their own.
|
|
138
161
|
*
|
|
139
|
-
* The dark palette is
|
|
140
|
-
*
|
|
141
|
-
* against them.
|
|
162
|
+
* The dark palette is lamplight rather than a neutral slate: the surfaces carry
|
|
163
|
+
* the same honey cast as the light ones, and every hue lifts a step or two so
|
|
164
|
+
* it still reads against them.
|
|
142
165
|
*/
|
|
143
166
|
@custom-variant dark (&:where(.dark, .dark *));
|
|
144
167
|
|
|
145
168
|
.dark {
|
|
146
169
|
color-scheme: dark;
|
|
147
170
|
|
|
148
|
-
--color-bg: #
|
|
149
|
-
--color-bg-alt: #
|
|
150
|
-
--color-bg-inset: #
|
|
151
|
-
--color-hairline: #
|
|
152
|
-
--color-hairline-strong: #
|
|
171
|
+
--color-bg: #17140e;
|
|
172
|
+
--color-bg-alt: #211c13;
|
|
173
|
+
--color-bg-inset: #2d261a;
|
|
174
|
+
--color-hairline: #2a2317;
|
|
175
|
+
--color-hairline-strong: #453a27;
|
|
153
176
|
|
|
154
177
|
--color-text: #f0f7f0;
|
|
155
178
|
--color-text-secondary: #cadfcd;
|
|
156
179
|
--color-text-muted: #94ad99;
|
|
157
|
-
--color-text-inverse: #
|
|
180
|
+
--color-text-inverse: #17140e;
|
|
158
181
|
|
|
159
182
|
--color-brand: #4ade80;
|
|
160
183
|
--color-brand-hover: #86efac;
|
|
@@ -201,16 +224,16 @@
|
|
|
201
224
|
:root:not(.light) {
|
|
202
225
|
color-scheme: dark;
|
|
203
226
|
|
|
204
|
-
--color-bg: #
|
|
205
|
-
--color-bg-alt: #
|
|
206
|
-
--color-bg-inset: #
|
|
207
|
-
--color-hairline: #
|
|
208
|
-
--color-hairline-strong: #
|
|
227
|
+
--color-bg: #17140e;
|
|
228
|
+
--color-bg-alt: #211c13;
|
|
229
|
+
--color-bg-inset: #2d261a;
|
|
230
|
+
--color-hairline: #2a2317;
|
|
231
|
+
--color-hairline-strong: #453a27;
|
|
209
232
|
|
|
210
233
|
--color-text: #f0f7f0;
|
|
211
234
|
--color-text-secondary: #cadfcd;
|
|
212
235
|
--color-text-muted: #94ad99;
|
|
213
|
-
--color-text-inverse: #
|
|
236
|
+
--color-text-inverse: #17140e;
|
|
214
237
|
|
|
215
238
|
--color-brand: #4ade80;
|
|
216
239
|
--color-brand-hover: #86efac;
|
|
@@ -253,3 +276,24 @@
|
|
|
253
276
|
--color-neutral-border: #2f4a36;
|
|
254
277
|
}
|
|
255
278
|
}
|
|
279
|
+
|
|
280
|
+
/*
|
|
281
|
+
* The surfaces the browser draws for us.
|
|
282
|
+
*
|
|
283
|
+
* A caret and a highlight in the user-agent's blue belong to no design system,
|
|
284
|
+
* and they are the two the reader touches most: one sits in every field they
|
|
285
|
+
* type into, the other appears the moment they drag across a paragraph. The
|
|
286
|
+
* selection is mixed from the brand rather than pinned to a token so it stays
|
|
287
|
+
* a wash — the text underneath keeps its own colour and its own contrast.
|
|
288
|
+
*/
|
|
289
|
+
@layer base {
|
|
290
|
+
::selection {
|
|
291
|
+
background-color: color-mix(in oklab, var(--color-brand) 24%, transparent);
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
input,
|
|
295
|
+
textarea,
|
|
296
|
+
[contenteditable] {
|
|
297
|
+
caret-color: var(--color-brand);
|
|
298
|
+
}
|
|
299
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nqmcreative/ui",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.3",
|
|
4
4
|
"description": "Svelte 5 + Tailwind CSS v4 component library — three styles (matte, paper, sprout), 70 components each, one shared behaviour core. No runtime dependencies.",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"dev": "vite dev",
|
package/registry.json
CHANGED
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
{
|
|
22
22
|
"name": "sprout",
|
|
23
23
|
"title": "Sprout",
|
|
24
|
-
"description": "Warm and fully rounded — leaf green on
|
|
24
|
+
"description": "Warm and fully rounded — leaf green on white, pill buttons, and a round display face. For school, community and family sites.",
|
|
25
25
|
"fonts": true,
|
|
26
26
|
"extra": []
|
|
27
27
|
}
|
|
@@ -1122,7 +1122,9 @@
|
|
|
1122
1122
|
"sprout": "@nqmcreative/ui/sprout/tooltip"
|
|
1123
1123
|
},
|
|
1124
1124
|
"uses": [],
|
|
1125
|
-
"modules": [
|
|
1125
|
+
"modules": [
|
|
1126
|
+
"trigger"
|
|
1127
|
+
]
|
|
1126
1128
|
}
|
|
1127
1129
|
]
|
|
1128
1130
|
}
|