@dorsk/tsumikit 0.81.0 → 0.82.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 +180 -2
- package/dist/breakpoints.d.ts +15 -0
- package/dist/breakpoints.js +14 -0
- package/dist/components/atoms/Badge.svelte +1 -0
- package/dist/components/atoms/Button.svelte +16 -5
- package/dist/components/atoms/Button.svelte.d.ts +2 -0
- package/dist/components/atoms/Input.svelte +1 -0
- package/dist/components/atoms/Slider.svelte +1 -1
- package/dist/components/atoms/Text.svelte +4 -4
- package/dist/components/atoms/Text.svelte.d.ts +1 -1
- package/dist/components/layouts/AppShell.svelte +14 -0
- package/dist/components/layouts/Backdrop.svelte +152 -0
- package/dist/components/layouts/Backdrop.svelte.d.ts +30 -0
- package/dist/components/layouts/NavSection.svelte +1 -1
- package/dist/components/molecules/AttachmentList.svelte +1 -1
- package/dist/components/molecules/CapBar.svelte +1 -1
- package/dist/components/molecules/Composer.svelte +1 -1
- package/dist/components/molecules/Dropzone.svelte +1 -1
- package/dist/components/molecules/EmptyState.svelte +13 -6
- package/dist/components/molecules/EmptyState.svelte.d.ts +3 -0
- package/dist/components/molecules/Field.svelte +1 -1
- package/dist/components/molecules/FilterInput.svelte +5 -3
- package/dist/components/molecules/Meter.svelte +1 -1
- package/dist/components/molecules/Metric.svelte +3 -1
- package/dist/components/molecules/Modal.svelte +4 -4
- package/dist/components/molecules/Pagination.svelte +26 -2
- package/dist/components/molecules/Pagination.svelte.d.ts +3 -1
- package/dist/components/molecules/Prose.svelte +1 -0
- package/dist/components/molecules/RadioGroup.svelte +2 -2
- package/dist/components/molecules/RichSelect.svelte.d.ts +2 -2
- package/dist/components/molecules/SectionHeader.svelte +1 -1
- package/dist/components/molecules/SegmentedControl.svelte +55 -22
- package/dist/components/molecules/SegmentedControl.svelte.d.ts +4 -0
- package/dist/components/molecules/SortableList.svelte +1 -1
- package/dist/components/molecules/StatusBar.svelte +2 -2
- package/dist/components/molecules/Tabs.svelte +32 -0
- package/dist/components/molecules/Tabs.svelte.d.ts +4 -0
- package/dist/components/molecules/ThemePicker.svelte +3 -3
- package/dist/components/molecules/VolumeSlider.svelte.d.ts +1 -1
- package/dist/components/organisms/DataTable.svelte +2 -2
- package/dist/dev-audit.d.ts +19 -0
- package/dist/dev-audit.js +259 -0
- package/dist/index.d.ts +6 -1
- package/dist/index.js +6 -1
- package/dist/media.svelte.d.ts +8 -0
- package/dist/media.svelte.js +26 -0
- package/dist/pending.svelte.d.ts +16 -0
- package/dist/pending.svelte.js +75 -0
- package/dist/stores/toast.svelte.d.ts +22 -0
- package/dist/stores/toast.svelte.js +54 -2
- package/dist/styles/app.css +2 -1
- package/dist/styles/font.css +19 -0
- package/dist/styles/fonts/LICENSE-Inter.txt +92 -0
- package/dist/styles/fonts/inter.woff2 +0 -0
- package/dist/styles/themes.css +58 -58
- package/dist/styles/tokens.css +15 -9
- package/dist/url-state.svelte.d.ts +22 -0
- package/dist/url-state.svelte.js +64 -0
- package/lint/breakpoints.mjs +33 -0
- package/lint/cli.mjs +99 -0
- package/lint/context.mjs +242 -0
- package/lint/index.mjs +97 -0
- package/lint/rules/breakpoints.mjs +25 -0
- package/lint/rules/img-alt.mjs +13 -0
- package/lint/rules/motion.mjs +85 -0
- package/lint/rules/no-raw-color.mjs +59 -0
- package/lint/rules/no-raw-control.mjs +23 -0
- package/lint/rules/no-raw-font.mjs +64 -0
- package/lint/rules/one-primary.mjs +74 -0
- package/lint/rules/spacing-scale.mjs +66 -0
- package/package.json +12 -2
- package/principles/01-visibility-of-status.md +32 -0
- package/principles/02-one-primary-action.md +31 -0
- package/principles/03-emphasise-by-de-emphasising.md +31 -0
- package/principles/04-labels-last-resort.md +30 -0
- package/principles/05-tint-the-greys.md +30 -0
- package/principles/06-depth-from-shade.md +30 -0
- package/principles/07-one-accent.md +31 -0
- package/principles/08-spacing-scale.md +30 -0
- package/principles/09-group-with-space.md +31 -0
- package/principles/10-real-typeface-fixed-scale.md +33 -0
- package/principles/11-mono-only-for-code.md +30 -0
- package/principles/12-measure.md +29 -0
- package/principles/13-imagery-sets-the-mood.md +32 -0
- package/principles/14-instant-calm-feedback.md +32 -0
- package/principles/15-undo-over-confirm.md +30 -0
- package/principles/16-empty-states.md +31 -0
- package/principles/17-errors-in-plain-words.md +31 -0
- package/principles/18-match-the-real-world.md +31 -0
- package/principles/19-consistency-and-standards.md +32 -0
- package/principles/20-error-prevention.md +31 -0
- package/principles/21-recognition-over-recall.md +31 -0
- package/principles/22-flexibility-and-shortcuts.md +31 -0
- package/principles/23-url-is-state.md +31 -0
- package/principles/24-links-are-links.md +31 -0
- package/principles/25-visible-focus.md +32 -0
- package/principles/26-generous-targets.md +31 -0
- package/principles/27-cheap-motion-respect-preferences.md +32 -0
- package/principles/28-less-but-better.md +31 -0
- package/principles/29-colour-is-not-the-only-cue.md +31 -0
- package/principles/30-help-where-needed.md +31 -0
- package/principles/README.md +62 -0
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
Copyright (c) 2016 The Inter Project Authors (https://github.com/rsms/inter)
|
|
2
|
+
|
|
3
|
+
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
|
4
|
+
This license is copied below, and is also available with a FAQ at:
|
|
5
|
+
http://scripts.sil.org/OFL
|
|
6
|
+
|
|
7
|
+
-----------------------------------------------------------
|
|
8
|
+
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
|
9
|
+
-----------------------------------------------------------
|
|
10
|
+
|
|
11
|
+
PREAMBLE
|
|
12
|
+
The goals of the Open Font License (OFL) are to stimulate worldwide
|
|
13
|
+
development of collaborative font projects, to support the font creation
|
|
14
|
+
efforts of academic and linguistic communities, and to provide a free and
|
|
15
|
+
open framework in which fonts may be shared and improved in partnership
|
|
16
|
+
with others.
|
|
17
|
+
|
|
18
|
+
The OFL allows the licensed fonts to be used, studied, modified and
|
|
19
|
+
redistributed freely as long as they are not sold by themselves. The
|
|
20
|
+
fonts, including any derivative works, can be bundled, embedded,
|
|
21
|
+
redistributed and/or sold with any software provided that any reserved
|
|
22
|
+
names are not used by derivative works. The fonts and derivatives,
|
|
23
|
+
however, cannot be released under any other type of license. The
|
|
24
|
+
requirement for fonts to remain under this license does not apply
|
|
25
|
+
to any document created using the fonts or their derivatives.
|
|
26
|
+
|
|
27
|
+
DEFINITIONS
|
|
28
|
+
"Font Software" refers to the set of files released by the Copyright
|
|
29
|
+
Holder(s) under this license and clearly marked as such. This may
|
|
30
|
+
include source files, build scripts and documentation.
|
|
31
|
+
|
|
32
|
+
"Reserved Font Name" refers to any names specified as such after the
|
|
33
|
+
copyright statement(s).
|
|
34
|
+
|
|
35
|
+
"Original Version" refers to the collection of Font Software components as
|
|
36
|
+
distributed by the Copyright Holder(s).
|
|
37
|
+
|
|
38
|
+
"Modified Version" refers to any derivative made by adding to, deleting,
|
|
39
|
+
or substituting -- in part or in whole -- any of the components of the
|
|
40
|
+
Original Version, by changing formats or by porting the Font Software to a
|
|
41
|
+
new environment.
|
|
42
|
+
|
|
43
|
+
"Author" refers to any designer, engineer, programmer, technical
|
|
44
|
+
writer or other person who contributed to the Font Software.
|
|
45
|
+
|
|
46
|
+
PERMISSION AND CONDITIONS
|
|
47
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
|
48
|
+
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
|
49
|
+
redistribute, and sell modified and unmodified copies of the Font
|
|
50
|
+
Software, subject to the following conditions:
|
|
51
|
+
|
|
52
|
+
1) Neither the Font Software nor any of its individual components,
|
|
53
|
+
in Original or Modified Versions, may be sold by itself.
|
|
54
|
+
|
|
55
|
+
2) Original or Modified Versions of the Font Software may be bundled,
|
|
56
|
+
redistributed and/or sold with any software, provided that each copy
|
|
57
|
+
contains the above copyright notice and this license. These can be
|
|
58
|
+
included either as stand-alone text files, human-readable headers or
|
|
59
|
+
in the appropriate machine-readable metadata fields within text or
|
|
60
|
+
binary files as long as those fields can be easily viewed by the user.
|
|
61
|
+
|
|
62
|
+
3) No Modified Version of the Font Software may use the Reserved Font
|
|
63
|
+
Name(s) unless explicit written permission is granted by the corresponding
|
|
64
|
+
Copyright Holder. This restriction only applies to the primary font name as
|
|
65
|
+
presented to the users.
|
|
66
|
+
|
|
67
|
+
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
|
68
|
+
Software shall not be used to promote, endorse or advertise any
|
|
69
|
+
Modified Version, except to acknowledge the contribution(s) of the
|
|
70
|
+
Copyright Holder(s) and the Author(s) or with their explicit written
|
|
71
|
+
permission.
|
|
72
|
+
|
|
73
|
+
5) The Font Software, modified or unmodified, in part or in whole,
|
|
74
|
+
must be distributed entirely under this license, and must not be
|
|
75
|
+
distributed under any other license. The requirement for fonts to
|
|
76
|
+
remain under this license does not apply to any document created
|
|
77
|
+
using the Font Software.
|
|
78
|
+
|
|
79
|
+
TERMINATION
|
|
80
|
+
This license becomes null and void if any of the above conditions are
|
|
81
|
+
not met.
|
|
82
|
+
|
|
83
|
+
DISCLAIMER
|
|
84
|
+
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
85
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
|
86
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
|
87
|
+
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
|
88
|
+
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
89
|
+
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
|
90
|
+
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
91
|
+
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
|
92
|
+
OTHER DEALINGS IN THE FONT SOFTWARE.
|
|
Binary file
|
package/dist/styles/themes.css
CHANGED
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
--c-border-strong: #7f858d;
|
|
21
21
|
--c-text: #1a1d23;
|
|
22
22
|
--c-text-muted: #5b6472;
|
|
23
|
-
--c-text-faint: #
|
|
24
|
-
--c-accent: #
|
|
23
|
+
--c-text-faint: #7d8495;
|
|
24
|
+
--c-accent: #0b5cad;
|
|
25
25
|
--c-accent-ink: #ffffff;
|
|
26
|
-
--c-accent-dim: #
|
|
26
|
+
--c-accent-dim: #87aad6;
|
|
27
27
|
--c-blue: #0f64c0;
|
|
28
28
|
--c-amber: #926100;
|
|
29
29
|
--c-red: #c63732;
|
|
@@ -53,10 +53,10 @@
|
|
|
53
53
|
--c-border-strong: #8f7c57;
|
|
54
54
|
--c-text: #3b2f1e;
|
|
55
55
|
--c-text-muted: #6c5a3f;
|
|
56
|
-
--c-text-faint: #
|
|
57
|
-
--c-accent: #
|
|
56
|
+
--c-text-faint: #8e7b5d;
|
|
57
|
+
--c-accent: #2f6786;
|
|
58
58
|
--c-accent-ink: #faf3e3;
|
|
59
|
-
--c-accent-dim: #
|
|
59
|
+
--c-accent-dim: #91a8b0;
|
|
60
60
|
--c-blue: #1d628e;
|
|
61
61
|
--c-amber: #875b00;
|
|
62
62
|
--c-red: #b03b35;
|
|
@@ -84,7 +84,7 @@
|
|
|
84
84
|
--c-border-strong: #888ca2;
|
|
85
85
|
--c-text: #cdd6f4;
|
|
86
86
|
--c-text-muted: #bac2de;
|
|
87
|
-
--c-text-faint: #
|
|
87
|
+
--c-text-faint: #878ea4;
|
|
88
88
|
--c-accent: #cba6f7;
|
|
89
89
|
--c-accent-ink: #1e1e2e;
|
|
90
90
|
--c-accent-dim: #6c7086;
|
|
@@ -114,7 +114,7 @@
|
|
|
114
114
|
--c-border-strong: #8394c8;
|
|
115
115
|
--c-text: #f8f8f2;
|
|
116
116
|
--c-text-muted: #c7c9d1;
|
|
117
|
-
--c-text-faint: #
|
|
117
|
+
--c-text-faint: #8395ca;
|
|
118
118
|
--c-accent: #cfb1ff;
|
|
119
119
|
--c-accent-ink: #1d1726;
|
|
120
120
|
--c-accent-dim: #6f558f;
|
|
@@ -144,7 +144,7 @@
|
|
|
144
144
|
--c-border-strong: #7a9fcc;
|
|
145
145
|
--c-text: #eceff4;
|
|
146
146
|
--c-text-muted: #d8dee9;
|
|
147
|
-
--c-text-faint: #
|
|
147
|
+
--c-text-faint: #78a5a5;
|
|
148
148
|
--c-accent: #9cd5e5;
|
|
149
149
|
--c-accent-ink: #1f242d;
|
|
150
150
|
--c-accent-dim: #5e81ac;
|
|
@@ -174,7 +174,7 @@
|
|
|
174
174
|
--c-border-strong: #71799c;
|
|
175
175
|
--c-text: #c0caf5;
|
|
176
176
|
--c-text-muted: #9aa5ce;
|
|
177
|
-
--c-text-faint: #
|
|
177
|
+
--c-text-faint: #6f79a3;
|
|
178
178
|
--c-accent: #7aa2f7;
|
|
179
179
|
--c-accent-ink: #11121d;
|
|
180
180
|
--c-accent-dim: #3d59a1;
|
|
@@ -203,13 +203,13 @@
|
|
|
203
203
|
--c-border-strong: #8f857d;
|
|
204
204
|
--c-text: #ebdbb2;
|
|
205
205
|
--c-text-muted: #d5c4a1;
|
|
206
|
-
--c-text-faint: #
|
|
206
|
+
--c-text-faint: #958670;
|
|
207
207
|
--c-accent: #ff821e;
|
|
208
208
|
--c-accent-ink: #1d1a14;
|
|
209
209
|
--c-accent-dim: #af3a03;
|
|
210
210
|
--c-blue: #8dafa2;
|
|
211
211
|
--c-amber: #fabd2f;
|
|
212
|
-
--c-red: #
|
|
212
|
+
--c-red: #ff9494;
|
|
213
213
|
--c-green: #b8bb26;
|
|
214
214
|
--c-violet: #df91a6;
|
|
215
215
|
--c-gold: #fabd2f;
|
|
@@ -232,7 +232,7 @@
|
|
|
232
232
|
--c-border-strong: #758c93;
|
|
233
233
|
--c-text: #eee8d5;
|
|
234
234
|
--c-text-muted: #a3b2b2;
|
|
235
|
-
--c-text-faint: #
|
|
235
|
+
--c-text-faint: #768d93;
|
|
236
236
|
--c-accent: #4ebdb3;
|
|
237
237
|
--c-accent-ink: #002b36;
|
|
238
238
|
--c-accent-dim: #1a6b66;
|
|
@@ -261,7 +261,7 @@
|
|
|
261
261
|
--c-border-strong: #77748b;
|
|
262
262
|
--c-text: #e0def4;
|
|
263
263
|
--c-text-muted: #9c98b6;
|
|
264
|
-
--c-text-faint: #
|
|
264
|
+
--c-text-faint: #767490;
|
|
265
265
|
--c-accent: #c4a7e7;
|
|
266
266
|
--c-accent-ink: #14121d;
|
|
267
267
|
--c-accent-dim: #6c5d8a;
|
|
@@ -290,7 +290,7 @@
|
|
|
290
290
|
--c-border-strong: #838b9e;
|
|
291
291
|
--c-text: #bdc4d1;
|
|
292
292
|
--c-text-muted: #abb3c2;
|
|
293
|
-
--c-text-faint: #
|
|
293
|
+
--c-text-faint: #848c9a;
|
|
294
294
|
--c-accent: #6ebcfd;
|
|
295
295
|
--c-accent-ink: #11151c;
|
|
296
296
|
--c-accent-dim: #2c6da3;
|
|
@@ -319,10 +319,10 @@
|
|
|
319
319
|
--c-border-strong: #8d989e;
|
|
320
320
|
--c-text: #ddd0b4;
|
|
321
321
|
--c-text-muted: #bbc4b7;
|
|
322
|
-
--c-text-faint: #
|
|
323
|
-
--c-accent: #
|
|
322
|
+
--c-text-faint: #8b9b8f;
|
|
323
|
+
--c-accent: #85dadf;
|
|
324
324
|
--c-accent-ink: #1c2226;
|
|
325
|
-
--c-accent-dim: #
|
|
325
|
+
--c-accent-dim: #588388;
|
|
326
326
|
--c-blue: #99d7ce;
|
|
327
327
|
--c-amber: #e6c689;
|
|
328
328
|
--c-red: #ffb7b6;
|
|
@@ -348,10 +348,10 @@
|
|
|
348
348
|
--c-border-strong: #8b8a7c;
|
|
349
349
|
--c-text: #f8f8f2;
|
|
350
350
|
--c-text-muted: #cfcfc2;
|
|
351
|
-
--c-text-faint: #
|
|
352
|
-
--c-accent: #
|
|
351
|
+
--c-text-faint: #8d8a74;
|
|
352
|
+
--c-accent: #66d9ef;
|
|
353
353
|
--c-accent-ink: #14160f;
|
|
354
|
-
--c-accent-dim: #
|
|
354
|
+
--c-accent-dim: #4a7b81;
|
|
355
355
|
--c-blue: #66d9ef;
|
|
356
356
|
--c-amber: #fd971f;
|
|
357
357
|
--c-red: #ff7495;
|
|
@@ -381,10 +381,10 @@
|
|
|
381
381
|
--c-border-strong: #c8c8c8;
|
|
382
382
|
--c-text: #ffffff;
|
|
383
383
|
--c-text-muted: #c8c8c8;
|
|
384
|
-
--c-text-faint: #
|
|
385
|
-
--c-accent: #
|
|
384
|
+
--c-text-faint: #696968;
|
|
385
|
+
--c-accent: #38d0ff;
|
|
386
386
|
--c-accent-ink: #000000;
|
|
387
|
-
--c-accent-dim: #
|
|
387
|
+
--c-accent-dim: #0f4f63;
|
|
388
388
|
--c-blue: #4db5ff;
|
|
389
389
|
--c-amber: #ffc24b;
|
|
390
390
|
--c-red: #ff6b6b;
|
|
@@ -416,10 +416,10 @@
|
|
|
416
416
|
--c-border-strong: #707070;
|
|
417
417
|
--c-text: #000000;
|
|
418
418
|
--c-text-muted: #2e2e2e;
|
|
419
|
-
--c-text-faint: #
|
|
420
|
-
--c-accent: #
|
|
419
|
+
--c-text-faint: #6c6b6b;
|
|
420
|
+
--c-accent: #0a4fc4;
|
|
421
421
|
--c-accent-ink: #ffffff;
|
|
422
|
-
--c-accent-dim: #
|
|
422
|
+
--c-accent-dim: #87aae6;
|
|
423
423
|
--c-blue: #0b5fc4;
|
|
424
424
|
--c-amber: #946100;
|
|
425
425
|
--c-red: #c4150c;
|
|
@@ -452,7 +452,7 @@
|
|
|
452
452
|
--c-border-strong: #737986;
|
|
453
453
|
--c-text: #f2f4f8;
|
|
454
454
|
--c-text-muted: #b6bdc9;
|
|
455
|
-
--c-text-faint: #
|
|
455
|
+
--c-text-faint: #717b89;
|
|
456
456
|
--c-accent: #56b4e9; /* sky blue — distinct from the green "ok" */
|
|
457
457
|
--c-accent-ink: #06131c;
|
|
458
458
|
--c-accent-dim: #2c6f93;
|
|
@@ -479,7 +479,7 @@
|
|
|
479
479
|
light, soft shadows, pale-tint/dark-ink machine badges.
|
|
480
480
|
=================================================================== */
|
|
481
481
|
|
|
482
|
-
/* ---- Gruvbox Light (medium) — warm wood/cream,
|
|
482
|
+
/* ---- Gruvbox Light (medium) — warm wood/cream, deep teal accent. */
|
|
483
483
|
[data-theme="gruvboxlight"] {
|
|
484
484
|
color-scheme: light;
|
|
485
485
|
--c-bg: #fbf1c7;
|
|
@@ -490,10 +490,10 @@
|
|
|
490
490
|
--c-border-strong: #887a60;
|
|
491
491
|
--c-text: #3c3836;
|
|
492
492
|
--c-text-muted: #504945;
|
|
493
|
-
--c-text-faint: #
|
|
494
|
-
--c-accent: #
|
|
493
|
+
--c-text-faint: #86786e;
|
|
494
|
+
--c-accent: #0b5f6a;
|
|
495
495
|
--c-accent-ink: #fbf1c7;
|
|
496
|
-
--c-accent-dim: #
|
|
496
|
+
--c-accent-dim: #8aa699;
|
|
497
497
|
--c-blue: #076678;
|
|
498
498
|
--c-amber: #875500;
|
|
499
499
|
--c-red: #9d0006;
|
|
@@ -521,7 +521,7 @@
|
|
|
521
521
|
--c-border-strong: #88826c;
|
|
522
522
|
--c-text: #073642;
|
|
523
523
|
--c-text-muted: #4f646b;
|
|
524
|
-
--c-text-faint: #
|
|
524
|
+
--c-text-faint: #748486;
|
|
525
525
|
--c-accent: #00736c;
|
|
526
526
|
--c-accent-ink: #fdf6e3;
|
|
527
527
|
--c-accent-dim: #2aa198;
|
|
@@ -552,10 +552,10 @@
|
|
|
552
552
|
--c-border-strong: #7c816e;
|
|
553
553
|
--c-text: #445159;
|
|
554
554
|
--c-text-muted: #516069;
|
|
555
|
-
--c-text-faint: #
|
|
556
|
-
--c-accent: #
|
|
555
|
+
--c-text-faint: #768174;
|
|
556
|
+
--c-accent: #1a6a8c;
|
|
557
557
|
--c-accent-ink: #fdf6e3;
|
|
558
|
-
--c-accent-dim: #
|
|
558
|
+
--c-accent-dim: #90afb8;
|
|
559
559
|
--c-blue: #006a98;
|
|
560
560
|
--c-amber: #835c00;
|
|
561
561
|
--c-red: #bf1422;
|
|
@@ -583,7 +583,7 @@
|
|
|
583
583
|
--c-border-strong: #868285;
|
|
584
584
|
--c-text: #534e75;
|
|
585
585
|
--c-text-muted: #625e7b;
|
|
586
|
-
--c-text-faint: #
|
|
586
|
+
--c-text-faint: #858092;
|
|
587
587
|
--c-accent: #6f5986;
|
|
588
588
|
--c-accent-ink: #faf4ed;
|
|
589
589
|
--c-accent-dim: #907aa9;
|
|
@@ -614,7 +614,7 @@
|
|
|
614
614
|
--c-border-strong: #767985;
|
|
615
615
|
--c-text: #474a63;
|
|
616
616
|
--c-text-muted: #555870;
|
|
617
|
-
--c-text-faint: #
|
|
617
|
+
--c-text-faint: #757889;
|
|
618
618
|
--c-accent: #771eda;
|
|
619
619
|
--c-accent-ink: #eff1f5;
|
|
620
620
|
--c-accent-dim: #8839ef;
|
|
@@ -646,7 +646,7 @@
|
|
|
646
646
|
--c-border-strong: #7a808c;
|
|
647
647
|
--c-text: #2e3440;
|
|
648
648
|
--c-text-muted: #434c5e;
|
|
649
|
-
--c-text-faint: #
|
|
649
|
+
--c-text-faint: #758094;
|
|
650
650
|
--c-accent: #486a94;
|
|
651
651
|
--c-accent-ink: #eceff4;
|
|
652
652
|
--c-accent-dim: #5e81ac;
|
|
@@ -678,7 +678,7 @@
|
|
|
678
678
|
--c-border-strong: #70748b;
|
|
679
679
|
--c-text: #1c419d;
|
|
680
680
|
--c-text-muted: #42518c;
|
|
681
|
-
--c-text-faint: #
|
|
681
|
+
--c-text-faint: #6c729a;
|
|
682
682
|
--c-accent: #0051b0;
|
|
683
683
|
--c-accent-ink: #ffffff;
|
|
684
684
|
--c-accent-dim: #2e7de9;
|
|
@@ -710,7 +710,7 @@
|
|
|
710
710
|
--c-border-strong: #7e764c;
|
|
711
711
|
--c-text: #464656;
|
|
712
712
|
--c-text-muted: #5b5074;
|
|
713
|
-
--c-text-faint: #
|
|
713
|
+
--c-text-faint: #777382;
|
|
714
714
|
--c-accent: #624c83;
|
|
715
715
|
--c-accent-ink: #f2ecbc;
|
|
716
716
|
--c-accent-dim: #624c83;
|
|
@@ -746,7 +746,7 @@
|
|
|
746
746
|
--c-border-strong: #9faabb;
|
|
747
747
|
--c-text: #e6eaf0;
|
|
748
748
|
--c-text-muted: #cfd7e1;
|
|
749
|
-
--c-text-faint: #
|
|
749
|
+
--c-text-faint: #a2abb8;
|
|
750
750
|
--c-accent: #c8e0ff;
|
|
751
751
|
--c-accent-ink: #1d232b;
|
|
752
752
|
--c-accent-dim: #4f6680;
|
|
@@ -775,10 +775,10 @@
|
|
|
775
775
|
--c-border-strong: #9da798;
|
|
776
776
|
--c-text: #e4e8dc;
|
|
777
777
|
--c-text-muted: #cdd3c5;
|
|
778
|
-
--c-text-faint: #
|
|
779
|
-
--c-accent: #
|
|
778
|
+
--c-text-faint: #a0a897;
|
|
779
|
+
--c-accent: #a8dff5;
|
|
780
780
|
--c-accent-ink: #1f251c;
|
|
781
|
-
--c-accent-dim: #
|
|
781
|
+
--c-accent-dim: #6e8b90;
|
|
782
782
|
--c-blue: #b0dcfb;
|
|
783
783
|
--c-amber: #f2d087;
|
|
784
784
|
--c-red: #ffc8c1;
|
|
@@ -804,10 +804,10 @@
|
|
|
804
804
|
--c-border-strong: #b09d8c;
|
|
805
805
|
--c-text: #f0e6da;
|
|
806
806
|
--c-text-muted: #d8caba;
|
|
807
|
-
--c-text-faint: #
|
|
808
|
-
--c-accent: #
|
|
807
|
+
--c-text-faint: #af9f8b;
|
|
808
|
+
--c-accent: #9bdbe8;
|
|
809
809
|
--c-accent-ink: #2a2019;
|
|
810
|
-
--c-accent-dim: #
|
|
810
|
+
--c-accent-dim: #728787;
|
|
811
811
|
--c-blue: #b1d1e9;
|
|
812
812
|
--c-amber: #f5c77f;
|
|
813
813
|
--c-red: #ffbfb0;
|
|
@@ -833,10 +833,10 @@
|
|
|
833
833
|
--c-border-strong: #a6a6a6;
|
|
834
834
|
--c-text: #e5e5d5;
|
|
835
835
|
--c-text-muted: #d4d4c3;
|
|
836
|
-
--c-text-faint: #
|
|
837
|
-
--c-accent: #
|
|
836
|
+
--c-text-faint: #a9a898;
|
|
837
|
+
--c-accent: #abdbfe;
|
|
838
838
|
--c-accent-ink: #2b2b2b;
|
|
839
|
-
--c-accent-dim: #
|
|
839
|
+
--c-accent-dim: #738999;
|
|
840
840
|
--c-blue: #a0e5e8;
|
|
841
841
|
--c-amber: #ffcead;
|
|
842
842
|
--c-red: #ffcccb;
|
|
@@ -863,10 +863,10 @@
|
|
|
863
863
|
--c-border-strong: #736b5e;
|
|
864
864
|
--c-text: #2a2620;
|
|
865
865
|
--c-text-muted: #4d473e;
|
|
866
|
-
--c-text-faint: #
|
|
867
|
-
--c-accent: #
|
|
866
|
+
--c-text-faint: #726a60;
|
|
867
|
+
--c-accent: #2b5577;
|
|
868
868
|
--c-accent-ink: #f3f0ea;
|
|
869
|
-
--c-accent-dim: #
|
|
869
|
+
--c-accent-dim: #7f92a0;
|
|
870
870
|
--c-blue: #1e4f79;
|
|
871
871
|
--c-amber: #6f4d00;
|
|
872
872
|
--c-red: #913328;
|
|
@@ -893,7 +893,7 @@
|
|
|
893
893
|
--c-border-strong: #636e7b;
|
|
894
894
|
--c-text: #1f252c;
|
|
895
895
|
--c-text-muted: #3e4753;
|
|
896
|
-
--c-text-faint: #
|
|
896
|
+
--c-text-faint: #646d7b;
|
|
897
897
|
--c-accent: #235591;
|
|
898
898
|
--c-accent-ink: #f2f5f8;
|
|
899
899
|
--c-accent-dim: #9bb2cf;
|
|
@@ -923,10 +923,10 @@
|
|
|
923
923
|
--c-border-strong: #66715d;
|
|
924
924
|
--c-text: #232a20;
|
|
925
925
|
--c-text-muted: #424b3e;
|
|
926
|
-
--c-text-faint: #
|
|
927
|
-
--c-accent: #
|
|
926
|
+
--c-text-faint: #667062;
|
|
927
|
+
--c-accent: #2f5a78;
|
|
928
928
|
--c-accent-ink: #f1f4ee;
|
|
929
|
-
--c-accent-dim: #
|
|
929
|
+
--c-accent-dim: #7d96a1;
|
|
930
930
|
--c-blue: #235272;
|
|
931
931
|
--c-amber: #724d04;
|
|
932
932
|
--c-red: #93352f;
|
package/dist/styles/tokens.css
CHANGED
|
@@ -22,11 +22,11 @@
|
|
|
22
22
|
--c-border-strong: #757d8b;
|
|
23
23
|
--c-text: #e6e9ef;
|
|
24
24
|
--c-text-muted: #9aa3b2;
|
|
25
|
-
--c-text-faint: #
|
|
25
|
+
--c-text-faint: #747e8e;
|
|
26
26
|
|
|
27
|
-
--c-accent: #
|
|
27
|
+
--c-accent: #4cc3f0;
|
|
28
28
|
--c-accent-ink: #04130c;
|
|
29
|
-
--c-accent-dim: #
|
|
29
|
+
--c-accent-dim: #306379;
|
|
30
30
|
|
|
31
31
|
--c-blue: #5aa9ff;
|
|
32
32
|
--c-amber: #f0b454;
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
--syn-keyword: var(--c-violet);
|
|
56
56
|
--syn-string: var(--c-green);
|
|
57
57
|
--syn-number: var(--c-amber);
|
|
58
|
-
--syn-comment: var(--c-text-
|
|
58
|
+
--syn-comment: var(--c-text-muted);
|
|
59
59
|
--syn-function: var(--c-blue);
|
|
60
60
|
--syn-punct: var(--c-text-muted);
|
|
61
61
|
|
|
@@ -107,16 +107,22 @@
|
|
|
107
107
|
--mach-border-sl: 45% 35%;
|
|
108
108
|
|
|
109
109
|
/* ---- Typography ---- */
|
|
110
|
+
/* "Inter" resolves only when font.css (bundled, app.css imports it) is loaded;
|
|
111
|
+
otherwise the system stack applies. */
|
|
110
112
|
--font-sans:
|
|
111
|
-
ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto,
|
|
113
|
+
"Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto,
|
|
112
114
|
"Helvetica Neue", Arial, sans-serif;
|
|
113
115
|
--font-mono:
|
|
114
116
|
ui-monospace, "SF Mono", "JetBrains Mono", "Fira Code", Menlo, Consolas,
|
|
115
117
|
monospace;
|
|
116
|
-
/* Non-code UI text: counts and stat values (--font-numeric
|
|
117
|
-
and shortcut hints (--font-label). Code-ish
|
|
118
|
-
|
|
119
|
-
|
|
118
|
+
/* Non-code UI text: counts and stat values (--font-numeric, pair with
|
|
119
|
+
tabular-nums), eyebrow labels and shortcut hints (--font-label). Code-ish
|
|
120
|
+
slots keep --font-mono. Revert to the pre-0.82 look with
|
|
121
|
+
--font-numeric: var(--font-mono). */
|
|
122
|
+
--font-numeric: var(--font-sans);
|
|
123
|
+
--font-label: var(--font-sans);
|
|
124
|
+
/* Line length cap for reading text (Prose, Text `measure`); `none` lifts it. */
|
|
125
|
+
--measure: 68ch;
|
|
120
126
|
|
|
121
127
|
/* Text-scale factor (CCT-305). The UI font control multiplies ONLY the
|
|
122
128
|
font-size tokens by this — not the root font-size — so bumping the size up
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export interface UrlStateOptions<T> {
|
|
2
|
+
/** Value when the param is absent; a value serializing to the same string removes the param. */
|
|
3
|
+
default: T;
|
|
4
|
+
parse?: (raw: string) => T;
|
|
5
|
+
serialize?: (value: T) => string;
|
|
6
|
+
/** Add a history entry per change instead of replacing the current one. */
|
|
7
|
+
push?: boolean;
|
|
8
|
+
}
|
|
9
|
+
export interface UrlState<T> {
|
|
10
|
+
value: T;
|
|
11
|
+
/** The current URL with the param set to `value` — for `href` on Tabs, SegmentedControl and Pagination. */
|
|
12
|
+
href(value: T): string;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* One search param as reactive state: `value` reads the param (or `default`),
|
|
16
|
+
* assigning writes it back with `history.replaceState` (`pushState` with
|
|
17
|
+
* `push`), and the browser's back/forward keep it in sync. Without a `window`
|
|
18
|
+
* it holds `default`, so it is safe to create during SSR.
|
|
19
|
+
*/
|
|
20
|
+
export declare function urlState<T = string>(key: string, options: UrlStateOptions<T>): UrlState<T>;
|
|
21
|
+
/** A click the browser should keep: modifier keys or a non-primary button (open in a new tab/window). */
|
|
22
|
+
export declare function isModifiedClick(e: MouseEvent): boolean;
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { createSubscriber } from 'svelte/reactivity';
|
|
2
|
+
/**
|
|
3
|
+
* One search param as reactive state: `value` reads the param (or `default`),
|
|
4
|
+
* assigning writes it back with `history.replaceState` (`pushState` with
|
|
5
|
+
* `push`), and the browser's back/forward keep it in sync. Without a `window`
|
|
6
|
+
* it holds `default`, so it is safe to create during SSR.
|
|
7
|
+
*/
|
|
8
|
+
export function urlState(key, options) {
|
|
9
|
+
const parse = options.parse ?? ((raw) => raw);
|
|
10
|
+
const serialize = options.serialize ?? ((value) => String(value));
|
|
11
|
+
const fallback = serialize(options.default);
|
|
12
|
+
const read = () => {
|
|
13
|
+
if (typeof window === 'undefined')
|
|
14
|
+
return options.default;
|
|
15
|
+
const raw = new URLSearchParams(window.location.search).get(key);
|
|
16
|
+
return raw === null ? options.default : parse(raw);
|
|
17
|
+
};
|
|
18
|
+
const urlFor = (value) => {
|
|
19
|
+
const url = new URL(window.location.href);
|
|
20
|
+
const raw = serialize(value);
|
|
21
|
+
if (raw === fallback)
|
|
22
|
+
url.searchParams.delete(key);
|
|
23
|
+
else
|
|
24
|
+
url.searchParams.set(key, raw);
|
|
25
|
+
return url;
|
|
26
|
+
};
|
|
27
|
+
let current = $state.raw(read());
|
|
28
|
+
const subscribe = createSubscriber(() => {
|
|
29
|
+
const sync = () => {
|
|
30
|
+
current = read();
|
|
31
|
+
};
|
|
32
|
+
window.addEventListener('popstate', sync);
|
|
33
|
+
return () => window.removeEventListener('popstate', sync);
|
|
34
|
+
});
|
|
35
|
+
return {
|
|
36
|
+
get value() {
|
|
37
|
+
if (typeof window === 'undefined')
|
|
38
|
+
return current;
|
|
39
|
+
if (!$effect.tracking())
|
|
40
|
+
return read();
|
|
41
|
+
subscribe();
|
|
42
|
+
return current;
|
|
43
|
+
},
|
|
44
|
+
set value(next) {
|
|
45
|
+
current = next;
|
|
46
|
+
if (typeof window === 'undefined')
|
|
47
|
+
return;
|
|
48
|
+
const url = urlFor(next);
|
|
49
|
+
if (url.href === window.location.href)
|
|
50
|
+
return;
|
|
51
|
+
window.history[options.push ? 'pushState' : 'replaceState'](window.history.state, '', url);
|
|
52
|
+
},
|
|
53
|
+
href(value) {
|
|
54
|
+
if (typeof window === 'undefined')
|
|
55
|
+
return `?${key}=${encodeURIComponent(serialize(value))}`;
|
|
56
|
+
const url = urlFor(value);
|
|
57
|
+
return `${url.pathname}${url.search}${url.hash}`;
|
|
58
|
+
},
|
|
59
|
+
};
|
|
60
|
+
}
|
|
61
|
+
/** A click the browser should keep: modifier keys or a non-primary button (open in a new tab/window). */
|
|
62
|
+
export function isModifiedClick(e) {
|
|
63
|
+
return e.button !== 0 || e.ctrlKey || e.metaKey || e.shiftKey || e.altKey;
|
|
64
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The kit's breakpoint contract. Media queries in consumer apps should only use
|
|
3
|
+
* these widths (min-width form) or their max-width complements (one unit below,
|
|
4
|
+
* e.g. 39.999rem / 639px / 639.98px).
|
|
5
|
+
*/
|
|
6
|
+
export const BREAKPOINTS = [
|
|
7
|
+
{ name: 'sm', rem: 40, px: 640 },
|
|
8
|
+
{ name: 'md', rem: 48, px: 768 },
|
|
9
|
+
{ name: 'lg', rem: 64, px: 1024 }
|
|
10
|
+
];
|
|
11
|
+
|
|
12
|
+
const LENGTH = /^(-?\d*\.?\d+)(px|rem|em)$/;
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* True when a media-query width token (e.g. "640px", "47.999rem") is one of the
|
|
16
|
+
* kit's breakpoints or a max-width complement of one. `em` in a media query
|
|
17
|
+
* resolves against the root font size, so it is treated like `rem`.
|
|
18
|
+
* @param {string} token
|
|
19
|
+
*/
|
|
20
|
+
export function isAllowedBreakpointWidth(token) {
|
|
21
|
+
const m = LENGTH.exec(token.trim());
|
|
22
|
+
if (!m) return false;
|
|
23
|
+
const value = Number(m[1]);
|
|
24
|
+
const key = m[2] === 'px' ? 'px' : 'rem';
|
|
25
|
+
return BREAKPOINTS.some((bp) => {
|
|
26
|
+
const target = bp[key];
|
|
27
|
+
return value === target || (value >= target - 1 && value < target);
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
export function describeBreakpoints() {
|
|
32
|
+
return BREAKPOINTS.map((bp) => `${bp.rem}rem/${bp.px}px`).join(', ');
|
|
33
|
+
}
|