viewkitjs 0.30.0 → 0.31.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/CHANGELOG.md +30 -6
- package/package.json +4 -2
- package/views/dist/controls/avatar/avatar.d.ts +10 -4
- package/views/dist/controls/avatar/avatar.js +5 -3
- package/views/dist/controls/avatar/tokens.d.ts +60 -0
- package/views/dist/controls/avatar/tokens.js +15 -0
- package/views/dist/controls/avatar.css +29 -15
- package/views/dist/controls/button/map-button.d.ts +5 -3
- package/views/dist/controls/button/map-button.js +14 -7
- package/views/dist/controls/index.d.ts +3 -2
- package/views/dist/controls/index.js +2 -1
- package/views/dist/controls/input/input.d.ts +12 -1
- package/views/dist/controls/input/input.js +7 -6
- package/views/dist/controls/input/save-mark.d.ts +8 -0
- package/views/dist/controls/input/save-mark.js +26 -0
- package/views/dist/controls/input/tokens.d.ts +16 -0
- package/views/dist/controls/input/tokens.js +4 -0
- package/views/dist/controls/input.css +18 -0
- package/views/dist/controls/radio/radio.d.ts +7 -0
- package/views/dist/controls/radio/radio.js +8 -4
- package/views/dist/controls/radio/tokens.d.ts +40 -0
- package/views/dist/controls/radio/tokens.js +10 -0
- package/views/dist/controls/radio.css +52 -3
- package/views/dist/controls/select/select.d.ts +8 -2
- package/views/dist/controls/select/select.js +6 -4
- package/views/dist/controls/setting-row/looks.d.ts +10 -0
- package/views/dist/controls/setting-row/looks.js +17 -0
- package/views/dist/controls/setting-row/setting-row.d.ts +65 -0
- package/views/dist/controls/setting-row/setting-row.js +66 -0
- package/views/dist/controls/setting-row/tokens.d.ts +84 -0
- package/views/dist/controls/setting-row/tokens.js +23 -0
- package/views/dist/controls/setting-row.css +94 -0
- package/views/dist/controls/switch-row/switch-row.d.ts +1 -15
- package/views/dist/controls/switch-row/switch-row.js +1 -9
- package/views/dist/controls/tokens.js +2 -0
- package/views/dist/looks/index.d.ts +1 -0
- package/views/dist/looks/index.js +1 -0
- package/views/dist/looks/pieces.js +2 -0
- package/views/dist/panels/react/views-row/FoldingViewRow.js +3 -4
- package/views/dist/styles.css +182 -19
- package/views/dist/styles.unlayered.css +182 -19
- package/views/docs/controls/avatar.md +15 -0
- package/views/docs/controls/input.md +8 -0
- package/views/docs/controls/radio.md +18 -0
- package/views/docs/controls/select.md +4 -0
- package/views/docs/controls/setting-row.md +26 -0
- package/views/docs/reference/controls.md +27 -10
- package/views/docs/reference/looks.md +3 -0
package/views/dist/styles.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! viewkitjs 0.
|
|
1
|
+
/*! viewkitjs 0.31.0 · viewkitjs/views/styles.css: ViewKit's look, its defaults the Outright look */
|
|
2
2
|
/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */
|
|
3
3
|
@layer theme, base, components, utilities;
|
|
4
4
|
@layer base {
|
|
@@ -480,48 +480,60 @@
|
|
|
480
480
|
.o-avatar-letters svg { width: 55%; height: 55%; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; }
|
|
481
481
|
|
|
482
482
|
/* ── Sizes: 16 in a typed Select's chip, its initials at the 3xs type size; 20 in chips and text, 24 in dense rows and stacks,
|
|
483
|
-
40 in headers, 64 on a record's page ── */
|
|
483
|
+
40 in headers, 56 at a settings page's head, 64 on a record's page ── */
|
|
484
484
|
.o-avatar.o-avatar-2xs { width: calc(var(--vk-spacing) * 4); height: calc(var(--vk-spacing) * 4); font-size: var(--vk-font-size-3xs); }
|
|
485
485
|
.o-avatar.o-avatar-xs { width: calc(var(--vk-spacing) * 5); height: calc(var(--vk-spacing) * 5); font-size: var(--vk-font-size-2xs); }
|
|
486
486
|
.o-avatar.o-avatar-sm { width: calc(var(--vk-spacing) * 6); height: calc(var(--vk-spacing) * 6); font-size: var(--vk-font-size-2xs); }
|
|
487
487
|
.o-avatar.o-avatar-lg { width: calc(var(--vk-spacing) * 10); height: calc(var(--vk-spacing) * 10); font-size: var(--vk-font-size-sm); }
|
|
488
|
+
.o-avatar.o-avatar-56 { width: calc(var(--vk-spacing) * 14); height: calc(var(--vk-spacing) * 14); font-size: var(--vk-font-size-xl); }
|
|
488
489
|
.o-avatar.o-avatar-xl { width: calc(var(--vk-spacing) * 16); height: calc(var(--vk-spacing) * 16); font-size: var(--vk-font-size-2xl); }
|
|
489
490
|
|
|
490
491
|
/* ── A thing: a square, its corners a step that grows with it, on the neutral ground, its edge inside ─ */
|
|
491
492
|
.o-avatar.o-avatar-thing { border-radius: var(--avatar-r); background-color: var(--vk-neutral); color: var(--vk-fg-subtle); box-shadow: inset 0 0 0 var(--vk-border-width) var(--vk-border-subtle); }
|
|
492
493
|
/* The workspace: the one square in the brand. */
|
|
493
494
|
.o-avatar.o-avatar-workspace { background-color: var(--vk-brand); color: var(--vk-fg-on-brand); box-shadow: none; }
|
|
495
|
+
/* A square's own colour, the workspace's included: on the hue's fill, what it holds in the hue's strong ink, with no edge; grey
|
|
496
|
+
the neutral ground in the quieter ink. */
|
|
497
|
+
.o-avatar.o-avatar-thing[data-colour] { box-shadow: none; }
|
|
498
|
+
.o-avatar.o-avatar-thing[data-colour="blue"] { background-color: var(--vk-label-blue-fill); color: var(--vk-label-blue-strong); }
|
|
499
|
+
.o-avatar.o-avatar-thing[data-colour="green"] { background-color: var(--vk-label-green-fill); color: var(--vk-label-green-strong); }
|
|
500
|
+
.o-avatar.o-avatar-thing[data-colour="amber"] { background-color: var(--vk-label-amber-fill); color: var(--vk-label-amber-strong); }
|
|
501
|
+
.o-avatar.o-avatar-thing[data-colour="red"] { background-color: var(--vk-label-red-fill); color: var(--vk-label-red-strong); }
|
|
502
|
+
.o-avatar.o-avatar-thing[data-colour="purple"] { background-color: var(--vk-label-purple-fill); color: var(--vk-label-purple-strong); }
|
|
503
|
+
.o-avatar.o-avatar-thing[data-colour="pink"] { background-color: var(--vk-label-pink-fill); color: var(--vk-label-pink-strong); }
|
|
504
|
+
.o-avatar.o-avatar-thing[data-colour="teal"] { background-color: var(--vk-label-teal-fill); color: var(--vk-label-teal-strong); }
|
|
505
|
+
.o-avatar.o-avatar-thing[data-colour="grey"] { background-color: var(--vk-neutral); color: var(--vk-fg-subtle); }
|
|
494
506
|
/* An agent: a thing's square holding its own icon. Its mark comes in its own fills, so it is filled, never drawn as a
|
|
495
507
|
line as a record's icon is; a mark with no colour of its own (Codex's, Grok's) takes the text's ink, as the canvas drew it. */
|
|
496
508
|
.o-avatar-agent .o-avatar-letters svg { fill: var(--vk-fg); stroke: none; }
|
|
497
509
|
|
|
498
|
-
/* ── Corners: a radius token per size, in steps; Medium with nothing set: xs at 20, sm at 24 and 32, md at 40, lg at 64,
|
|
510
|
+
/* ── Corners: a radius token per size, in steps, 56 taking 64's; Medium with nothing set: xs at 20, sm at 24 and 32, md at 40, lg at 56 and 64,
|
|
499
511
|
between Small and Large, the tokens holding nothing between xs and sm ────────────────────────────── */
|
|
500
512
|
.o-avatar.o-avatar-thing { --avatar-r: var(--vk-radius-sm); }
|
|
501
513
|
.o-avatar.o-avatar-thing:is(.o-avatar-2xs, .o-avatar-xs) { --avatar-r: var(--vk-radius-xs); }
|
|
502
514
|
.o-avatar.o-avatar-thing.o-avatar-lg { --avatar-r: var(--vk-radius-md); }
|
|
503
|
-
.o-avatar.o-avatar-thing.o-avatar-xl { --avatar-r: var(--vk-radius-lg); }
|
|
504
|
-
/* Small: xs at 20 and 24, sm at 32 and 40, md at 64. */
|
|
515
|
+
.o-avatar.o-avatar-thing:is(.o-avatar-56, .o-avatar-xl) { --avatar-r: var(--vk-radius-lg); }
|
|
516
|
+
/* Small: xs at 20 and 24, sm at 32 and 40, md at 56 and 64. */
|
|
505
517
|
[data-avatar-corners="small"] .o-avatar.o-avatar-thing { --avatar-r: var(--vk-radius-sm); }
|
|
506
518
|
[data-avatar-corners="small"] .o-avatar.o-avatar-thing:is(.o-avatar-2xs, .o-avatar-xs, .o-avatar-sm) { --avatar-r: var(--vk-radius-xs); }
|
|
507
|
-
[data-avatar-corners="small"] .o-avatar.o-avatar-thing.o-avatar-xl { --avatar-r: var(--vk-radius-md); }
|
|
508
|
-
/* Large, the radii before Medium came: sm at 20 and 24, md at 32, lg at 40, xl at 64. */
|
|
519
|
+
[data-avatar-corners="small"] .o-avatar.o-avatar-thing:is(.o-avatar-56, .o-avatar-xl) { --avatar-r: var(--vk-radius-md); }
|
|
520
|
+
/* Large, the radii before Medium came: sm at 20 and 24, md at 32, lg at 40, xl at 56 and 64. */
|
|
509
521
|
[data-avatar-corners="large"] .o-avatar.o-avatar-thing { --avatar-r: var(--vk-radius-md); }
|
|
510
522
|
[data-avatar-corners="large"] .o-avatar.o-avatar-thing:is(.o-avatar-2xs, .o-avatar-xs, .o-avatar-sm) { --avatar-r: var(--vk-radius-sm); }
|
|
511
523
|
[data-avatar-corners="large"] .o-avatar.o-avatar-thing.o-avatar-lg { --avatar-r: var(--vk-radius-lg); }
|
|
512
|
-
[data-avatar-corners="large"] .o-avatar.o-avatar-thing.o-avatar-xl { --avatar-r: var(--vk-radius-xl); }
|
|
513
|
-
/* Extra large: md at 20 and 24, lg at 32, xl at 40, 2xl at 64. */
|
|
524
|
+
[data-avatar-corners="large"] .o-avatar.o-avatar-thing:is(.o-avatar-56, .o-avatar-xl) { --avatar-r: var(--vk-radius-xl); }
|
|
525
|
+
/* Extra large: md at 20 and 24, lg at 32, xl at 40, 2xl at 56 and 64. */
|
|
514
526
|
[data-avatar-corners="xlarge"] .o-avatar.o-avatar-thing { --avatar-r: var(--vk-radius-lg); }
|
|
515
527
|
[data-avatar-corners="xlarge"] .o-avatar.o-avatar-thing:is(.o-avatar-2xs, .o-avatar-xs, .o-avatar-sm) { --avatar-r: var(--vk-radius-md); }
|
|
516
528
|
[data-avatar-corners="xlarge"] .o-avatar.o-avatar-thing.o-avatar-lg { --avatar-r: var(--vk-radius-xl); }
|
|
517
|
-
[data-avatar-corners="xlarge"] .o-avatar.o-avatar-thing.o-avatar-xl { --avatar-r: var(--vk-radius-2xl); }
|
|
529
|
+
[data-avatar-corners="xlarge"] .o-avatar.o-avatar-thing:is(.o-avatar-56, .o-avatar-xl) { --avatar-r: var(--vk-radius-2xl); }
|
|
518
530
|
|
|
519
531
|
/* ── Corner smoothing: Smooth, with nothing set, draws a square's corners with the smooth outline (smooth.css),
|
|
520
532
|
every browser that knows shape() showing it; one that doesn't keeps the quarter circles above, and so does Round. Its
|
|
521
533
|
smoothing eases off where a side is too short for 1.7 radii at each end, as the canvas drew it (o-smooth-ease, from its size and
|
|
522
534
|
its radius, both tokens, so it follows Corner radius). The outline would cut the edge drawn inside the square, so under it the
|
|
523
535
|
edge is a ring of its own (::before), between the outline and the same outline drawn a hairline in, under whatever the square
|
|
524
|
-
holds; the workspace
|
|
536
|
+
holds; the workspace and a square on its own colour have none. Its smoothing is its own Corner smoothing, never a host's: the outline's amount inherits, and a
|
|
525
537
|
crumb, a tab or a list's card that follows the token sets it on itself, so the square sets it back. ─────── */
|
|
526
538
|
@supports (clip-path: shape(evenodd from 0 0, curve by 1px 1px with 1px 0 / 1px 0, close, move to 0 0, hline to 1px, close)) and (width: calc(tan(atan2(1px, 1px)) * 1px)) {
|
|
527
539
|
.o-avatar.o-avatar-thing { --smooth-amount: initial; }
|
|
@@ -529,8 +541,9 @@
|
|
|
529
541
|
--avatar-rr: min(var(--avatar-r), var(--avatar-size) / 2); --smooth-t: var(--avatar-rr); --smooth-side: var(--avatar-size);
|
|
530
542
|
position: relative; box-shadow: none; clip-path: shape(var(--smooth-outline));
|
|
531
543
|
}
|
|
532
|
-
/* Its edge, a hairline ring along the outline, under the picture or the letters it holds; the workspace
|
|
533
|
-
|
|
544
|
+
/* Its edge, a hairline ring along the outline, under the picture or the letters it holds; the workspace and a square on its
|
|
545
|
+
own colour have none. */
|
|
546
|
+
.o-avatar.o-avatar-thing:not(.o-avatar-workspace):not([data-colour]):not([data-avatar-smoothing="round"] *)::before {
|
|
534
547
|
--smooth-t: calc(var(--avatar-rr) - var(--vk-border-width)); --smooth-in: var(--vk-border-width);
|
|
535
548
|
content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; background-color: var(--vk-border-subtle);
|
|
536
549
|
clip-path: shape(var(--smooth-ring));
|
|
@@ -576,13 +589,14 @@
|
|
|
576
589
|
/* The rest, as a count in a neutral circle. */
|
|
577
590
|
.o-avatar.o-avatar-more { background-color: var(--vk-neutral); color: var(--vk-fg-subtle); font-variant-numeric: tabular-nums; }
|
|
578
591
|
/* ── Presence and the badge: a dot on the corner, its size stepping with the avatar's (6,
|
|
579
|
-
8, 10, 12, 16), cut out of whatever the avatar stands on by a mask, never a ring painted in the page's colour. The mask stands
|
|
592
|
+
8, 10, 12, 14, 16), cut out of whatever the avatar stands on by a mask, never a ring painted in the page's colour. The mask stands
|
|
580
593
|
only on a badged avatar and a stack's faces: a mask clips what is outside the box and makes a stacking context. ──────── */
|
|
581
594
|
:is(.o-avatar, .o-avatar-badged) { --avatar-size: calc(var(--vk-spacing) * 8); --avatar-dot: calc(var(--vk-spacing) * 2.5); --avatar-cut: calc(var(--vk-spacing) * 0.5); --avatar-dot-inset: 0px; }
|
|
582
595
|
.o-avatar.o-avatar-2xs { --avatar-size: calc(var(--vk-spacing) * 4); }
|
|
583
596
|
:is(.o-avatar.o-avatar-xs, .o-avatar-badged[data-size="20"]) { --avatar-size: calc(var(--vk-spacing) * 5); --avatar-dot: var(--vk-dot-size); --avatar-cut: calc(var(--vk-spacing) * 0.375); }
|
|
584
597
|
:is(.o-avatar.o-avatar-sm, .o-avatar-badged[data-size="24"]) { --avatar-size: calc(var(--vk-spacing) * 6); --avatar-dot: calc(var(--vk-spacing) * 2); }
|
|
585
598
|
:is(.o-avatar.o-avatar-lg, .o-avatar-badged[data-size="40"]) { --avatar-size: calc(var(--vk-spacing) * 10); --avatar-dot: calc(var(--vk-spacing) * 3); }
|
|
599
|
+
:is(.o-avatar.o-avatar-56, .o-avatar-badged[data-size="56"]) { --avatar-size: calc(var(--vk-spacing) * 14); --avatar-dot: calc(var(--vk-spacing) * 3.5); --avatar-dot-inset: calc(var(--vk-spacing) * 0.5); }
|
|
586
600
|
:is(.o-avatar.o-avatar-xl, .o-avatar-badged[data-size="64"]) { --avatar-size: calc(var(--vk-spacing) * 16); --avatar-dot: calc(var(--vk-spacing) * 4); --avatar-dot-inset: calc(var(--vk-spacing) * 0.5); }
|
|
587
601
|
:is(.o-avatar.o-avatar-thing, .o-avatar-badged[data-thing]) { --avatar-dot-inset: calc(var(--vk-spacing) * -0.75); }
|
|
588
602
|
.o-avatar-badged { position: relative; display: inline-flex; flex: none; vertical-align: middle; isolation: isolate; }
|
|
@@ -594,7 +608,7 @@
|
|
|
594
608
|
background-color: var(--vk-brand); color: var(--vk-fg-on-brand);
|
|
595
609
|
}
|
|
596
610
|
.o-avatar-badge > svg { display: none; width: 70%; height: 70%; fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
|
|
597
|
-
.o-avatar-badged:is([data-size="32"], [data-size="40"], [data-size="64"]) > .o-avatar-badge > svg { display: block; }
|
|
611
|
+
.o-avatar-badged:is([data-size="32"], [data-size="40"], [data-size="56"], [data-size="64"]) > .o-avatar-badge > svg { display: block; }
|
|
598
612
|
/* Here, a green dot; away, a hollow ring whose middle shows the ground. */
|
|
599
613
|
.o-avatar-badge[data-presence="here"] { background-color: var(--vk-success-bold); }
|
|
600
614
|
.o-avatar-badge[data-presence="away"] { background-color: transparent; box-shadow: inset 0 0 0 calc(var(--vk-border-width) * 2) var(--vk-fg-subtlest); }
|
|
@@ -2439,6 +2453,23 @@ textarea.o-input-control.o-input-lines { flex: none; min-height: 0; max-height:
|
|
|
2439
2453
|
|
|
2440
2454
|
@media (prefers-reduced-motion: reduce) { .o-input { transition: none; } .o-input.o-smooth::before, .o-input.o-smooth::after { transition: none; } }
|
|
2441
2455
|
|
|
2456
|
+
/* ── Saving and Saved (VK-921; the settings canvas, round 2, Every part: Saving): at the field's end, where its sides stand,
|
|
2457
|
+
while the app saves what was typed or picked and just after. Saving, the Spinner in the quietest words; saved, a check and
|
|
2458
|
+
Saved, small, in the success colour, announced, fading after --vk-saved-hold, after which save-mark.tsx takes it out of
|
|
2459
|
+
the field. In its field it keeps the box's padding at its end; in a group it stands after the end side; in a Select's
|
|
2460
|
+
field, just before the chevron. A page holds Saved with data-force="saved". ─────────────────────────────────────── */
|
|
2461
|
+
.o-input-save {
|
|
2462
|
+
flex: none; display: inline-flex; align-items: center; gap: calc(var(--vk-spacing) * 1.5);
|
|
2463
|
+
font-size: var(--vk-font-size-xs); line-height: var(--vk-line-height-xs); color: var(--vk-fg-subtlest); white-space: nowrap; user-select: none;
|
|
2464
|
+
}
|
|
2465
|
+
.o-input-lone > .o-input-save { padding-inline-end: var(--input-pad-inline); }
|
|
2466
|
+
.o-input-group:not(.o-select-field) > .o-input-save { order: 1; }
|
|
2467
|
+
.o-input-save > svg { flex: none; width: calc(var(--vk-spacing) * 3.5); height: calc(var(--vk-spacing) * 3.5); }
|
|
2468
|
+
.o-input-save[data-save="saved"] { color: var(--vk-success); animation: o-input-saved-leave var(--vk-duration-base) var(--vk-ease-in) var(--vk-saved-hold) forwards; }
|
|
2469
|
+
[data-force="saved"] .o-input-save { animation: none; }
|
|
2470
|
+
@keyframes o-input-saved-leave { to { opacity: 0; } }
|
|
2471
|
+
@media (prefers-reduced-motion: reduce) { .o-input-save[data-save="saved"] { animation-duration: 1ms; } }
|
|
2472
|
+
|
|
2442
2473
|
/* ── A key: a 20px cap on the raised ground, half the radius's corners, its bottom edge twice as heavy so
|
|
2443
2474
|
it reads as a key; its label in the quieter text colour ───────────────────────────────────────────── */
|
|
2444
2475
|
.o-kbd {
|
|
@@ -4041,7 +4072,7 @@ span.o-number-editor-code { color: var(--vk-fg-subtle); }
|
|
|
4041
4072
|
/* Marked cards in a row: two across, as New view's layouts; one under another on a phone. Marked cards, as a row or as tiles, keep
|
|
4042
4073
|
room on every side for what stands outside a card's edge, the chosen one's ring and the focus outline, so a holder that clips
|
|
4043
4074
|
its sides (the Pane's body) never cuts either (KIT-816); the map's tiles stand as far in. */
|
|
4044
|
-
.o-radio-group.o-radio-row:has(> .o-radio-marked.o-choice-card) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
|
4075
|
+
.o-radio-group.o-radio-row:has(> .o-radio-marked.o-choice-card):not(:has(> .o-radio-pictured)) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
|
4045
4076
|
.o-radio-group:where(.o-radio-row, .o-radio-tiles):has(> .o-radio-marked.o-choice-card) { padding: calc(var(--vk-focus-width) + var(--vk-focus-offset)); }
|
|
4046
4077
|
|
|
4047
4078
|
/* ── Tiles: marked cards three across, each centred, its mark over its name in the card's quieter words; chosen, the mark
|
|
@@ -4064,14 +4095,63 @@ span.o-number-editor-code { color: var(--vk-fg-subtle); }
|
|
|
4064
4095
|
.o-choice-card.o-radio-marked:has(> [data-disabled]) { border-style: dashed; border-color: var(--vk-border-input); box-shadow: none; background-color: transparent; cursor: not-allowed; }
|
|
4065
4096
|
.o-choice-card.o-radio-marked:has(> [data-disabled]) :is(.o-radio-mark, .o-choice-label, .o-choice-note) { color: var(--vk-fg-disabled); }
|
|
4066
4097
|
|
|
4098
|
+
/* ── A swatch (VK-920; the settings canvas, round 2, Workspace's Colour): a label colour in place of the ring, a 24px dot
|
|
4099
|
+
named by its aria-label. Chosen, a thin ring of the ground and the selected colour just outside it; under the pointer the
|
|
4100
|
+
same ring in the field's hovered edge; focus outlines it outside that ring; disabled, grey and dashed, which the arrows pass
|
|
4101
|
+
by, its ring kept in the field's edge when it is the chosen one. A row of them stands 10 apart. ──────────────────────────────────────────────────────────────────────────────────── */
|
|
4102
|
+
.o-radio-swatched { align-items: center; }
|
|
4103
|
+
.o-radio-swatch {
|
|
4104
|
+
flex: none; box-sizing: border-box; width: calc(var(--vk-spacing) * 6); height: calc(var(--vk-spacing) * 6);
|
|
4105
|
+
border-radius: var(--vk-radius-full); outline: none; transition: box-shadow var(--vk-duration-fast) var(--vk-ease-out);
|
|
4106
|
+
}
|
|
4107
|
+
.o-radio-swatch[data-colour="blue"] { background-color: var(--vk-label-blue-fill); }
|
|
4108
|
+
.o-radio-swatch[data-colour="green"] { background-color: var(--vk-label-green-fill); }
|
|
4109
|
+
.o-radio-swatch[data-colour="amber"] { background-color: var(--vk-label-amber-fill); }
|
|
4110
|
+
.o-radio-swatch[data-colour="red"] { background-color: var(--vk-label-red-fill); }
|
|
4111
|
+
.o-radio-swatch[data-colour="purple"] { background-color: var(--vk-label-purple-fill); }
|
|
4112
|
+
.o-radio-swatch[data-colour="pink"] { background-color: var(--vk-label-pink-fill); }
|
|
4113
|
+
.o-radio-swatch[data-colour="teal"] { background-color: var(--vk-label-teal-fill); }
|
|
4114
|
+
.o-radio-swatch[data-colour="grey"] { background-color: var(--vk-neutral); }
|
|
4115
|
+
.o-radio-swatch[data-force="hover"]:not([data-checked], [data-disabled]) { box-shadow: 0 0 0 var(--vk-focus-offset) var(--vk-ground), 0 0 0 calc(var(--vk-focus-offset) + var(--vk-focus-width)) var(--vk-border-input-hovered); }
|
|
4116
|
+
@media (hover: hover) { .o-radio:hover > .o-radio-swatch:not([data-checked], [data-disabled]) { box-shadow: 0 0 0 var(--vk-focus-offset) var(--vk-ground), 0 0 0 calc(var(--vk-focus-offset) + var(--vk-focus-width)) var(--vk-border-input-hovered); } }
|
|
4117
|
+
.o-radio-swatch[data-checked] { box-shadow: 0 0 0 var(--vk-focus-offset) var(--vk-ground), 0 0 0 calc(var(--vk-focus-offset) + var(--vk-focus-width)) var(--vk-border-selected); }
|
|
4118
|
+
.o-radio-swatch:is(:focus-visible, [data-force="focus"]) { outline: var(--vk-focus-width) solid var(--vk-border-brand); outline-offset: calc(var(--vk-focus-offset) * 2 + var(--vk-focus-width)); }
|
|
4119
|
+
.o-radio-swatch[data-disabled] { background-color: var(--vk-neutral); border: var(--vk-border-width) dashed var(--vk-border-input); box-shadow: none; }
|
|
4120
|
+
.o-radio-swatch[data-disabled][data-checked] { box-shadow: 0 0 0 var(--vk-focus-offset) var(--vk-ground), 0 0 0 calc(var(--vk-focus-offset) + var(--vk-focus-width)) var(--vk-border-input); }
|
|
4121
|
+
.o-radio:has(> .o-radio-swatch[data-disabled]) { cursor: not-allowed; }
|
|
4122
|
+
.o-radio-group.o-radio-row:has(> .o-radio-swatched) { gap: calc(var(--vk-spacing) * 2.5); align-items: center; min-height: calc(var(--vk-spacing) * 9); }
|
|
4123
|
+
|
|
4124
|
+
/* ── A marked card's picture (VK-920; round 2, Preferences' Appearance): what the app draws, the card's width and 120 tall,
|
|
4125
|
+
its mark and its name side by side and centred under it, in the card's quieter words; chosen, ringed as any marked card,
|
|
4126
|
+
its words in the text colour, the name a little heavier, the mark not in the brand. A row of them stands one beside
|
|
4127
|
+
another at equal widths, on a phone too. ──────────────────────────────────────────────────────────────────────────── */
|
|
4128
|
+
.o-choice-card.o-radio-marked.o-radio-pictured {
|
|
4129
|
+
display: grid; grid-template-columns: minmax(0, 1fr) auto auto minmax(0, 1fr); align-items: center; column-gap: calc(var(--vk-spacing) * 2); row-gap: 0;
|
|
4130
|
+
padding: calc(var(--vk-spacing) * 1.5) calc(var(--vk-spacing) * 1.5) 0; color: var(--vk-fg-subtle);
|
|
4131
|
+
}
|
|
4132
|
+
.o-radio-picture {
|
|
4133
|
+
grid-column: 1 / -1; justify-self: stretch; display: flex; box-sizing: border-box; height: calc(var(--vk-spacing) * 30); overflow: hidden;
|
|
4134
|
+
border: var(--vk-border-width) solid var(--vk-border-subtle); border-radius: var(--vk-radius-sm);
|
|
4135
|
+
}
|
|
4136
|
+
.o-radio-pictured > :is(.o-radio-mark, .o-choice-text) { min-height: calc(var(--vk-spacing) * 11); display: flex; align-items: center; }
|
|
4137
|
+
/* The picture spans the card; the mark and the name stand in the two middle columns, centred as a pair under it. */
|
|
4138
|
+
.o-radio-pictured > .o-radio-mark { grid-column: 2; }
|
|
4139
|
+
.o-radio-pictured > .o-choice-text { grid-column: 3; }
|
|
4140
|
+
.o-radio-pictured > .o-radio-mark, .o-radio-pictured > .o-radio-mark[data-checked] { color: inherit; }
|
|
4141
|
+
.o-radio-pictured > .o-radio-mark > svg { width: calc(var(--vk-spacing) * 4); height: calc(var(--vk-spacing) * 4); }
|
|
4142
|
+
.o-radio-pictured .o-choice-label { font-weight: var(--vk-font-weight-normal); color: inherit; }
|
|
4143
|
+
.o-choice-card.o-radio-pictured:has(> [data-checked]) { color: var(--vk-fg); }
|
|
4144
|
+
.o-choice-card.o-radio-pictured:has(> [data-checked]) .o-choice-label { font-weight: var(--vk-font-weight-medium); }
|
|
4145
|
+
.o-radio-group.o-radio-row:has(> .o-radio-pictured) { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); grid-template-columns: none; gap: calc(var(--vk-spacing) * 3); }
|
|
4146
|
+
|
|
4067
4147
|
/* On a phone (`data-vk-phone`, the group's own mark from the device, or a phone frame round it): marked cards one under
|
|
4068
4148
|
another, tiles on one card. */
|
|
4069
|
-
.o-radio-group.o-radio-row:where([data-vk-phone], [data-vk-phone] *):has(> .o-radio-marked.o-choice-card) { grid-template-columns: minmax(0, 1fr); }
|
|
4149
|
+
.o-radio-group.o-radio-row:where([data-vk-phone], [data-vk-phone] *):has(> .o-radio-marked.o-choice-card):not(:has(> .o-radio-pictured)) { grid-template-columns: minmax(0, 1fr); }
|
|
4070
4150
|
.o-radio-group.o-radio-tiles:where([data-vk-phone], [data-vk-phone] *):has(> .o-choice-card) { gap: calc(var(--vk-spacing) * 2); padding: calc(var(--vk-spacing) * 3); border-radius: var(--vk-radius-xl); background-color: var(--vk-overlay-card); }
|
|
4071
4151
|
.o-radio-tiles:where([data-vk-phone], [data-vk-phone] *) > .o-choice-card.o-radio-marked { justify-content: center; min-height: calc(var(--vk-spacing) * 18); }
|
|
4072
4152
|
.o-radio-tiles:where([data-vk-phone], [data-vk-phone] *) > .o-radio-marked > .o-radio-mark > svg { width: calc(var(--vk-spacing) * 5.5); height: calc(var(--vk-spacing) * 5.5); }
|
|
4073
4153
|
|
|
4074
|
-
@media (prefers-reduced-motion: reduce) { .o-radio-ring, .o-radio-dot, .o-radio-mark { transition: none; } }
|
|
4154
|
+
@media (prefers-reduced-motion: reduce) { .o-radio-ring, .o-radio-dot, .o-radio-mark, .o-radio-swatch { transition: none; } }
|
|
4075
4155
|
|
|
4076
4156
|
/* Doubled, so a component's own overflow: auto in the same layer never brings the sideways scroll back. */
|
|
4077
4157
|
[data-scrollbar][data-scrollbar] { overflow-x: hidden; }
|
|
@@ -4184,6 +4264,88 @@ span.o-number-editor-code { color: var(--vk-fg-subtle); }
|
|
|
4184
4264
|
|
|
4185
4265
|
@media (prefers-reduced-motion: reduce) { .o-select-chevron { transition: none; } }
|
|
4186
4266
|
|
|
4267
|
+
/* ── The options: each value sets the card's or the rows' own names, read below ─────────────────────────────────────── */
|
|
4268
|
+
:where([data-setting-row-card="raised"]) .o-setting-rows { --setting-rows-edge: var(--vk-border-subtle); --setting-rows-ground: var(--vk-raised); }
|
|
4269
|
+
:where([data-setting-row-rows="roomy"]) :is(.o-setting-rows, .o-setting-row) {
|
|
4270
|
+
--setting-rows-pad: calc(var(--vk-spacing) * 3) calc(var(--vk-spacing) * 4.5); --setting-rows-height: calc(var(--vk-spacing) * 16);
|
|
4271
|
+
--setting-rows-side: calc(var(--vk-spacing) * 16);
|
|
4272
|
+
}
|
|
4273
|
+
.o-setting-rows.o-setting-rows-danger { --setting-rows-edge: var(--vk-border-danger); }
|
|
4274
|
+
|
|
4275
|
+
/* ── The card, on a computer: the rows in a box, a line between each ───────────────────────────────────────────────── */
|
|
4276
|
+
.o-setting-rows:not(.o-field-rows) {
|
|
4277
|
+
display: grid; border: var(--vk-border-width) solid var(--setting-rows-edge, var(--vk-border)); border-radius: var(--vk-radius-lg); overflow: hidden;
|
|
4278
|
+
background-color: var(--setting-rows-ground, transparent);
|
|
4279
|
+
}
|
|
4280
|
+
|
|
4281
|
+
/* ── A row, on a computer: its start, its words, its end ───────────────────────────────────────────────────────────── */
|
|
4282
|
+
.o-setting-row:not(.o-field-row) {
|
|
4283
|
+
display: flex; align-items: center; justify-content: space-between; gap: calc(var(--vk-spacing) * 4); box-sizing: border-box;
|
|
4284
|
+
min-height: var(--setting-rows-height, auto); margin: 0; padding: var(--setting-rows-pad, calc(var(--vk-spacing) * 3.5) calc(var(--vk-spacing) * 4));
|
|
4285
|
+
border: 0; border-top: var(--vk-border-width) solid var(--vk-border-subtle);
|
|
4286
|
+
-webkit-tap-highlight-color: transparent; transition: background-color var(--vk-duration-fast) var(--vk-ease-out);
|
|
4287
|
+
}
|
|
4288
|
+
.o-setting-row:not(.o-field-row):first-child { border-top: 0; }
|
|
4289
|
+
.o-setting-row:not(.o-field-row) > .o-choice-text { flex: 1 1 auto; }
|
|
4290
|
+
.o-setting-row:not(.o-field-row) .o-choice-label { font-weight: var(--vk-font-weight-medium); }
|
|
4291
|
+
/* The rows that are a press as a whole: the switch's (a label) and the one opening its page (a button). */
|
|
4292
|
+
button.o-setting-row { width: 100%; font: inherit; color: inherit; text-align: left; background-color: transparent; }
|
|
4293
|
+
.o-setting-row:is([data-setting-row-kind="switch"], [data-setting-row-kind="open"]):not(.o-field-row) { cursor: pointer; }
|
|
4294
|
+
@media (hover: hover) { .o-setting-row:is([data-setting-row-kind="switch"], [data-setting-row-kind="open"]):not(.o-field-row):hover { background-color: var(--vk-hovered); } }
|
|
4295
|
+
.o-setting-row:not(.o-field-row):is([data-locked], :has(.o-switch[data-disabled])) { cursor: not-allowed; background-color: transparent; }
|
|
4296
|
+
|
|
4297
|
+
/* Its start: a mark as given; an icon in its box. */
|
|
4298
|
+
.o-setting-row > :not(.o-choice-text) { flex: none; }
|
|
4299
|
+
.o-setting-row-icon {
|
|
4300
|
+
display: inline-flex; align-items: center; justify-content: center; box-sizing: border-box; width: calc(var(--vk-spacing) * 8); height: calc(var(--vk-spacing) * 8);
|
|
4301
|
+
border: var(--vk-border-width) solid var(--vk-border-subtle); border-radius: var(--vk-radius-md); background-color: var(--vk-raised); color: var(--vk-fg-subtle);
|
|
4302
|
+
}
|
|
4303
|
+
.o-setting-row-icon > svg { width: calc(var(--vk-spacing) * 4); height: calc(var(--vk-spacing) * 4); }
|
|
4304
|
+
|
|
4305
|
+
/* Its end: the reason, then the control; the Select 220 wide; the value and ›. */
|
|
4306
|
+
.o-setting-row-end { display: flex; align-items: center; gap: calc(var(--vk-spacing) * 2); margin-left: auto; min-width: 0; }
|
|
4307
|
+
.o-setting-row-select { width: calc(var(--vk-spacing) * 55); }
|
|
4308
|
+
.o-setting-row-select .o-select-field { width: 100%; }
|
|
4309
|
+
.o-setting-row-reason { font-size: var(--vk-font-size-xs); line-height: calc(var(--vk-font-size-xs) * var(--vk-line-height-xs)); color: var(--vk-fg-subtlest); }
|
|
4310
|
+
.o-setting-row-reason + .o-switch { margin-left: calc(var(--vk-spacing) * -2); }
|
|
4311
|
+
.o-setting-row-value { font-size: var(--vk-font-size-sm); line-height: calc(var(--vk-font-size-sm) * var(--vk-line-height-sm)); color: var(--vk-fg-subtle); }
|
|
4312
|
+
.o-setting-row-chevron { flex: none; width: calc(var(--vk-spacing) * 4); height: calc(var(--vk-spacing) * 4); color: var(--vk-fg-subtlest); }
|
|
4313
|
+
/* Locked: its control greyed (a switch keeps its own locked state), its words as they are. */
|
|
4314
|
+
.o-setting-row[data-locked] :is(.o-setting-row-select, .o-button, .o-setting-row-value, .o-setting-row-chevron) { opacity: 0.45; }
|
|
4315
|
+
|
|
4316
|
+
/* A lone row: bare, no card, no line, no room round it. */
|
|
4317
|
+
.o-setting-row[data-alone]:not(.o-field-row) { min-height: 0; padding: 0; border-top: 0; background-color: transparent; }
|
|
4318
|
+
|
|
4319
|
+
/* ── On a phone: Field rows' card and rows; a setting's words, value and › in them ─────────────────────────────────── */
|
|
4320
|
+
.o-setting-row.o-field-row > .o-choice-text { flex: 1 1 auto; }
|
|
4321
|
+
.o-setting-row-press {
|
|
4322
|
+
display: flex; flex: 1 1 auto; align-items: center; gap: calc(var(--vk-spacing) * 3); align-self: stretch; min-width: 0; margin: 0; padding: 0;
|
|
4323
|
+
border: 0; font: inherit; color: inherit; text-align: left; background-color: transparent; cursor: pointer; -webkit-tap-highlight-color: transparent;
|
|
4324
|
+
}
|
|
4325
|
+
.o-setting-row.o-field-row .o-setting-row-end { flex: 0 1 auto; }
|
|
4326
|
+
.o-setting-row.o-field-row .o-setting-row-value { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: inherit; line-height: inherit; }
|
|
4327
|
+
.o-setting-rows-danger.o-field-rows .o-choice-label { color: var(--vk-danger); }
|
|
4328
|
+
|
|
4329
|
+
@media (prefers-reduced-motion: reduce) { .o-setting-row { transition: none; } }
|
|
4330
|
+
|
|
4331
|
+
/* ── The card's corners smooth: following the token corner-smoothing, drawn with the smooth outline (smooth.css) in every
|
|
4332
|
+
browser that knows shape(); one that doesn't keeps the corners above. Its round part is fitted to its smallest row, as a
|
|
4333
|
+
control's is. Nothing stands outside it (its rows were hidden past its edge), so it is clipped itself, its rows with it; its
|
|
4334
|
+
edge is a ring along the curve over its rows (::after), in the card's edge colour. ── */
|
|
4335
|
+
@supports (clip-path: shape(evenodd from 0 0, curve by 1px 1px with 1px 0 / 1px 0, close, move to 0 0, hline to 1px, close)) and (width: calc(tan(atan2(1px, 1px)) * 1px)) {
|
|
4336
|
+
.o-setting-rows:not(.o-field-rows) {
|
|
4337
|
+
--smooth-amount: var(--vk-corner-smoothing);
|
|
4338
|
+
--setting-rows-fit: min(var(--vk-radius-lg), var(--setting-rows-side, calc(var(--vk-spacing) * 7 + var(--vk-font-size-sm) * var(--vk-line-height-sm))) / (2 + 2 * var(--smooth-amount, 0.7)));
|
|
4339
|
+
--smooth-t: var(--setting-rows-fit); --smooth-side: var(--setting-rows-side, calc(var(--vk-spacing) * 7 + var(--vk-font-size-sm) * var(--vk-line-height-sm)));
|
|
4340
|
+
position: relative; overflow: visible; border-color: transparent; border-radius: var(--setting-rows-fit); clip-path: shape(var(--smooth-outline));
|
|
4341
|
+
}
|
|
4342
|
+
.o-setting-rows:not(.o-field-rows)::after {
|
|
4343
|
+
--smooth-t: max(0px, var(--setting-rows-fit) - var(--vk-border-width)); --smooth-in: var(--vk-border-width);
|
|
4344
|
+
content: ""; position: absolute; inset: calc(var(--vk-border-width) * -1); z-index: 1; pointer-events: none;
|
|
4345
|
+
background-color: var(--setting-rows-edge, var(--vk-border)); clip-path: shape(var(--smooth-ring));
|
|
4346
|
+
}
|
|
4347
|
+
}
|
|
4348
|
+
|
|
4187
4349
|
.o-sheet, .o-sheet-backdrop, .o-sheet-below {
|
|
4188
4350
|
--sheet-spring: var(--vk-spring-quick); --sheet-spring-ease: var(--vk-ease-spring-quick); --sheet-spring-time: var(--vk-duration-spring-quick);
|
|
4189
4351
|
}
|
|
@@ -8250,6 +8412,7 @@ span.o-number-editor-code { color: var(--vk-fg-subtle); }
|
|
|
8250
8412
|
--vk-font-size-2xl: 24px;
|
|
8251
8413
|
--vk-font-size-2xs: 10px;
|
|
8252
8414
|
--vk-font-size-3xs: 8px;
|
|
8415
|
+
--vk-font-size-xl: 20px;
|
|
8253
8416
|
--vk-font-size-xs: 12px;
|
|
8254
8417
|
--vk-radius-md: 7.5px;
|
|
8255
8418
|
--vk-radius-sm: 5px;
|
|
@@ -8316,7 +8479,6 @@ span.o-number-editor-code { color: var(--vk-fg-subtle); }
|
|
|
8316
8479
|
--vk-ease-out-sharp: cubic-bezier(0.23, 1, 0.32, 1);
|
|
8317
8480
|
--vk-ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
|
|
8318
8481
|
--vk-border-accent: hsl(219 90% 65.5%);
|
|
8319
|
-
--vk-font-size-xl: 20px;
|
|
8320
8482
|
--vk-font-weight-normal: 400;
|
|
8321
8483
|
--vk-tracking-wide: 0.025em;
|
|
8322
8484
|
--vk-border-overlay-card: hsl(220 3% 86%);
|
|
@@ -8334,6 +8496,7 @@ span.o-number-editor-code { color: var(--vk-fg-subtle); }
|
|
|
8334
8496
|
--vk-brand-300: hsl(218 100% 89%);
|
|
8335
8497
|
--vk-border-input-strong: hsl(210 1% 72%);
|
|
8336
8498
|
--vk-font-mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
|
|
8499
|
+
--vk-saved-hold: 2000ms;
|
|
8337
8500
|
--vk-shadow-field: 0 1px 1px 0 rgb(16 17 26 / 0.08);
|
|
8338
8501
|
--vk-shadow-field-focus: 0 0 10px 0 hsl(219 90% 65.5% / 0.3);
|
|
8339
8502
|
--vk-shadow-field-focus-danger: 0 0 10px 0 hsl(3 87% 68% / 0.3);
|