@sableui/react 0.18.0 → 0.19.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 +129 -0
- package/bin/sable.mjs +108 -14
- package/dist/{_contract-CDa9-NdB.d.ts → _contract-DlklV0Im.d.ts} +2 -2
- package/dist/blocks/index.d.ts +1 -1
- package/dist/components/avatar/avatar.js +16 -7
- package/dist/components/avatar/avatar.meta.js +43 -10
- package/dist/components/avatar/avatar.variants.js +26 -2
- package/dist/components/collapsible/collapsible.js +6 -5
- package/dist/components/collapsible/collapsible.meta.js +14 -5
- package/dist/components/data-table/data-table.js +132 -45
- package/dist/components/data-table/data-table.meta.js +63 -4
- package/dist/components/date-picker/date-picker.js +13 -6
- package/dist/components/date-picker/date-picker.meta.js +22 -0
- package/dist/components/menu/menu.js +2 -0
- package/dist/components/menu/menu.meta.js +2 -2
- package/dist/components/panel-group/panel-group.js +17 -1
- package/dist/components/panel-group/panel-group.meta.js +43 -3
- package/dist/components/side-nav/side-nav.variants.js +8 -3
- package/dist/components/sidebar/index.js +4 -0
- package/dist/components/sidebar/sidebar.js +90 -11
- package/dist/components/sidebar/sidebar.meta.js +38 -4
- package/dist/components/table/table.js +7 -3
- package/dist/components/tabs/tabs.js +10 -2
- package/dist/components/tabs/tabs.meta.js +4 -0
- package/dist/components/workspace/workspace.js +13 -3
- package/dist/components/workspace/workspace.meta.js +109 -1
- package/dist/file-hashes.json +53 -49
- package/dist/foundations/typography.js +13 -0
- package/dist/icon/Icon.js +21 -2
- package/dist/icon/index.d.ts +36 -1
- package/dist/icon/index.js +5 -0
- package/dist/icon/names.js +240 -0
- package/dist/icon-sets/reicon.js +19 -1
- package/dist/index.d.ts +272 -50
- package/dist/index.js +11 -1
- package/dist/lib/chart/heat.js +1 -1
- package/dist/lib/cn.js +1 -0
- package/dist/lib/use-media-query.js +41 -0
- package/dist/{meta-DX5r5wQL.d.ts → meta-Dfm9AExe.d.ts} +6 -0
- package/dist/patterns/dashboard-page.js +23 -17
- package/dist/patterns/index.d.ts +7 -2
- package/dist/patterns/index.js +5 -1
- package/dist/patterns/tracker-page.js +392 -0
- package/dist/patterns/tracker-page.meta.js +40 -0
- package/dist/presets/index.d.ts +1 -1
- package/dist/styles.css +179 -74
- package/dist/{theme-provider-BydfM5Z0.d.ts → theme-provider-BUBealk_.d.ts} +1 -1
- package/dist/themes/_contract.js +9 -1
- package/dist/themes/atelier/index.d.ts +1 -1
- package/dist/themes/ember/index.d.ts +1 -1
- package/dist/themes/index.d.ts +2 -2
- package/dist/themes/meridian/index.d.ts +1 -1
- package/dist/themes/poppy/index.d.ts +1 -1
- package/dist/themes/prism/index.d.ts +1 -1
- package/dist/themes/sable/index.d.ts +1 -1
- package/dist/themes/verdant/index.d.ts +1 -1
- package/llms/components/avatar.md +32 -9
- package/llms/components/collapsible.md +12 -4
- package/llms/components/data-table.md +40 -3
- package/llms/components/date-picker.md +15 -1
- package/llms/components/menu.md +1 -1
- package/llms/components/panel-group.md +34 -2
- package/llms/components/sidebar.md +17 -4
- package/llms/components/tabs.md +1 -0
- package/llms/components/workspace.md +81 -1
- package/llms/foundations/typography.md +4 -1
- package/llms/patterns/dashboard-page.md +18 -15
- package/llms/patterns/tracker-page.md +450 -0
- package/llms/reference/token-intent.md +3 -1
- package/llms/reference/utilities.md +4 -1
- package/llms/tasks/auditing-an-app.md +4 -1
- package/llms/tasks/building-a-page.md +3 -2
- package/llms/tasks/building-a-tool.md +101 -5
- package/llms/tasks/building-with-sable.md +11 -3
- package/llms/tasks/creating-a-preset.md +9 -0
- package/llms-full.txt +843 -54
- package/llms.txt +8 -7
- package/package.json +2 -1
- package/registry.json +491 -36
- package/scripts/adoption.mjs +15 -2
- package/scripts/app-css.mjs +129 -0
- package/scripts/grade.mjs +161 -2
- package/scripts/lint-rules.mjs +126 -0
- package/skills/sable/SKILL.md +33 -4
package/dist/styles.css
CHANGED
|
@@ -203,6 +203,17 @@
|
|
|
203
203
|
See DESIGN.md → Layering.
|
|
204
204
|
========================================================================== */
|
|
205
205
|
|
|
206
|
+
/* The mobile bar height BottomNav, AppHeader, AppShell's bottom padding and
|
|
207
|
+
Workspace's bottomNav row share. In the base layer so a theme or an app that
|
|
208
|
+
declares its own (unlayered) wins; declared here because only the Sable
|
|
209
|
+
theme did, and AppShell reads it with no fallback, so under every other
|
|
210
|
+
theme its calc() was invalid and the padding under a BottomNav vanished. */
|
|
211
|
+
@layer base {
|
|
212
|
+
:root {
|
|
213
|
+
--nav-height: 56px;
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
|
|
206
217
|
:root {
|
|
207
218
|
--z-sticky: 30; /* sticky in-content chrome: table headers, sticky banners */
|
|
208
219
|
--z-nav: 40; /* app chrome: AppHeader, Sidebar, BottomNav, status banners */
|
|
@@ -298,6 +309,12 @@
|
|
|
298
309
|
Routed through a --theme-* hook rather than hardcoded, so a theme can still
|
|
299
310
|
choose its own button shape without fighting this scope. */
|
|
300
311
|
--button-radius: var(--theme-button-radius, 9999px);
|
|
312
|
+
|
|
313
|
+
/* Table geometry. Unset here so Table's own fallbacks (h-10 head, py-2.5
|
|
314
|
+
cells, on the spacing scale) apply — and declared, for the same symmetry:
|
|
315
|
+
a comfortable form nested in a compact tool gets the page table back. */
|
|
316
|
+
--table-head-h: initial;
|
|
317
|
+
--table-cell-py: initial;
|
|
301
318
|
}
|
|
302
319
|
|
|
303
320
|
/* Workspace register — measured from the Figma and Paper editors (2026-07-26),
|
|
@@ -337,6 +354,30 @@
|
|
|
337
354
|
--tree-rail: 8px;
|
|
338
355
|
--tree-column: 18px;
|
|
339
356
|
--tree-indent: 18px;
|
|
357
|
+
|
|
358
|
+
/* Table geometry: a head row on the sm rung and one baseline step of block
|
|
359
|
+
padding, so a 16px ui line makes a 32px row — Linear's list row, and the
|
|
360
|
+
size a table in a tool panel was being forced to by hand (thirteen
|
|
361
|
+
consumer rules overriding th/td heights, padding and size in one app). */
|
|
362
|
+
--table-head-h: var(--control-sm);
|
|
363
|
+
--table-cell-py: calc(var(--spacing) * 2);
|
|
364
|
+
}
|
|
365
|
+
|
|
366
|
+
/* A finger is not a denser pointer. The compact ladder is measured from mouse-
|
|
367
|
+
driven editors (Figma, Paper), where a 24px target is aimed with a cursor; on
|
|
368
|
+
a phone or tablet the same tool chrome needs the page register's targets, so
|
|
369
|
+
on a coarse pointer compact keeps its type, radius and panel geometry and
|
|
370
|
+
takes the comfortable ladder's heights. Without this, every Workspace app
|
|
371
|
+
re-tuned `--control-*` by hand below some breakpoint — and a breakpoint is
|
|
372
|
+
the wrong question: a touch laptop is wide, a phone with a mouse is narrow. */
|
|
373
|
+
@media (pointer: coarse) {
|
|
374
|
+
[data-density="compact"] {
|
|
375
|
+
--control-xs: 28px;
|
|
376
|
+
--control-sm: 32px;
|
|
377
|
+
--control-md: 40px;
|
|
378
|
+
--control-cta: 44px;
|
|
379
|
+
--control-lg: 48px;
|
|
380
|
+
}
|
|
340
381
|
}
|
|
341
382
|
|
|
342
383
|
/* ==========================================================================
|
|
@@ -348,6 +389,13 @@
|
|
|
348
389
|
Paper's entire panel ladder spans 249 → 242 → 238 (3-7 RGB units) and lets a
|
|
349
390
|
1px low-contrast edge do the structural work. In this register hairlines carry
|
|
350
391
|
structure INSTEAD of tonal steps — the reverse of the page register's rule.
|
|
392
|
+
|
|
393
|
+
Every mix here is `in oklab`, never `in oklch`. These blend a near-neutral
|
|
394
|
+
surface with its ink, so there is no hue worth interpolating, and oklch
|
|
395
|
+
loses it: measured in Chrome, `color-mix(in oklch, #141519 97%, #e4e5ea)`
|
|
396
|
+
resolves to `oklch(0.218 0.008 none)` and paints a missing hue as 0°, a
|
|
397
|
+
brown cast on a cool graphite preset's canvas. Bundled themes write oklch
|
|
398
|
+
and never showed it; presets and apps write hex.
|
|
351
399
|
========================================================================== */
|
|
352
400
|
|
|
353
401
|
/* Declared on every element that can re-declare the base colors, not just
|
|
@@ -361,32 +409,32 @@
|
|
|
361
409
|
/* The work surface. NOT `background`: the artboard is the subject, not the
|
|
362
410
|
page behind the UI. Pulled a touch away from the page so docked panels can
|
|
363
411
|
sit above it without a border. */
|
|
364
|
-
--canvas: var(--theme-canvas, color-mix(in
|
|
412
|
+
--canvas: var(--theme-canvas, color-mix(in oklab, var(--background) 97%, var(--foreground)));
|
|
365
413
|
--canvas-foreground: var(--theme-canvas-foreground, var(--foreground));
|
|
366
414
|
|
|
367
415
|
/* Docked chrome, one compressed step off the canvas. */
|
|
368
416
|
--panel: var(--theme-panel, var(--background));
|
|
369
417
|
--panel-foreground: var(--theme-panel-foreground, var(--foreground));
|
|
370
|
-
--panel-raised: var(--theme-panel-raised, color-mix(in
|
|
418
|
+
--panel-raised: var(--theme-panel-raised, color-mix(in oklab, var(--background) 94%, var(--foreground)));
|
|
371
419
|
|
|
372
420
|
/* A compact control docked in a panel: the xs field rung and a field-style
|
|
373
421
|
button. Mixed from the panel it sits in, a further step under the pointer.
|
|
374
422
|
It used to borrow the canvas tone (3% ink), which measured 1.04:1 against
|
|
375
423
|
a dark panel: the field all but vanished. 9% is what a shipped inspector
|
|
376
424
|
settled on (1.15:1 dark, 1.25:1 light). */
|
|
377
|
-
--panel-field: var(--theme-panel-field, color-mix(in
|
|
378
|
-
--panel-field-hover: var(--theme-panel-field-hover, color-mix(in
|
|
425
|
+
--panel-field: var(--theme-panel-field, color-mix(in oklab, var(--panel) 91%, var(--panel-foreground)));
|
|
426
|
+
--panel-field-hover: var(--theme-panel-field-hover, color-mix(in oklab, var(--panel) 88%, var(--panel-foreground)));
|
|
379
427
|
|
|
380
428
|
/* The structural edge. Alpha-based so it holds over any surface beneath it. */
|
|
381
|
-
--hairline: var(--theme-hairline, color-mix(in
|
|
382
|
-
--hairline-strong: var(--theme-hairline-strong, color-mix(in
|
|
429
|
+
--hairline: var(--theme-hairline, color-mix(in oklab, transparent 93%, var(--foreground)));
|
|
430
|
+
--hairline-strong: var(--theme-hairline-strong, color-mix(in oklab, transparent 86%, var(--foreground)));
|
|
383
431
|
|
|
384
432
|
/* The edge of a FLOATING surface (popover, menu, select, tooltip, a floating
|
|
385
433
|
panel). Lighter than `--border` on purpose: the shadow carries the
|
|
386
434
|
elevation, and a full hairline plus a shadow stacks into a dark outline.
|
|
387
435
|
Alpha-based, so it defines the shape on a same-colour page in light mode
|
|
388
436
|
and reads as a faint lit edge in dark mode, where shadows barely show. */
|
|
389
|
-
--border-floating: var(--theme-border-floating, color-mix(in
|
|
437
|
+
--border-floating: var(--theme-border-floating, color-mix(in oklab, transparent 92%, var(--foreground)));
|
|
390
438
|
|
|
391
439
|
/* The text field: its fill and its outline. Outlined on the card by default;
|
|
392
440
|
a theme fills its fields instead with `--theme-field: var(--muted)` and
|
|
@@ -399,7 +447,7 @@
|
|
|
399
447
|
the gap around the raised main panel. One step off the rail toward its ink,
|
|
400
448
|
because most themes paint the rail the page's colour and the panel would
|
|
401
449
|
otherwise sit on its own colour. */
|
|
402
|
-
--shell-ground: var(--theme-shell-ground, color-mix(in
|
|
450
|
+
--shell-ground: var(--theme-shell-ground, color-mix(in oklab, var(--sidebar) 97%, var(--sidebar-foreground)));
|
|
403
451
|
|
|
404
452
|
/* Status and tone colours at graphic strength: a meter's fill, a segmented
|
|
405
453
|
bar, a status dot, a chart series, a soft tint. The label fill is dark
|
|
@@ -493,7 +541,7 @@
|
|
|
493
541
|
2px,
|
|
494
542
|
round(
|
|
495
543
|
nearest,
|
|
496
|
-
calc(var(--type-body-md-size, 0.9375rem) * var(--type-body-md-leading, 1.55) * var(--leading-scale) / var(--baseline-split)),
|
|
544
|
+
calc(var(--type-body-md-size, 0.9375rem) * var(--type-base, 16) / 16 * var(--type-body-md-leading, 1.55) * var(--leading-scale) / var(--baseline-split)),
|
|
497
545
|
1px
|
|
498
546
|
)
|
|
499
547
|
);
|
|
@@ -527,39 +575,62 @@
|
|
|
527
575
|
--leading-scale, so Airy opens the text itself; display, heading and label
|
|
528
576
|
leading is a shape the theme chose and only snaps. The `ui-*` tier is
|
|
529
577
|
already whole px on its own 4px grid (the workspace register).
|
|
578
|
+
|
|
579
|
+
── The base size: one number rebuilds the scale ───────────────────────────
|
|
580
|
+
Every page tier is authored on a 16px base (1rem is title-lg; body-md is
|
|
581
|
+
15/16 of it). `--type-base` is that base as a unitless px number, so
|
|
582
|
+
`--type-base: 14` rebuilds the whole scale at 14: each tier keeps its ratio
|
|
583
|
+
to the base, the headings stay a heading's distance from the body, and the
|
|
584
|
+
baseline step (and with it `--spacing`) follows the body down. It is the
|
|
585
|
+
standard "set the base font size" knob, scoped to type and rhythm: unlike
|
|
586
|
+
changing the root font-size, it leaves the control ladder and every rem the
|
|
587
|
+
app wrote itself where they were.
|
|
588
|
+
|
|
589
|
+
Applied where the size is USED — `calc(var(--type-<tier>-size, <rem>) *
|
|
590
|
+
var(--type-base, 16) / 16)` — not where a theme declares it, so it scales a
|
|
591
|
+
theme's own tier values and a consumer's per-tier overrides alike, and works
|
|
592
|
+
on any element: set it on :root, a `[data-sable-theme]` scope or a preset
|
|
593
|
+
(`tokens.shared["type-base"]`) and the spacing follows too; on any other
|
|
594
|
+
subtree the type rescales and the rhythm stays the page's. Unitless, because
|
|
595
|
+
CSS cannot divide one length by another: `14`, never `14px`.
|
|
596
|
+
|
|
597
|
+
The `ui-*` tiers do NOT take it. They are absolute px measured from tool
|
|
598
|
+
chrome (Figma, Paper) and sit on their own 4px grid; the compact register's
|
|
599
|
+
`min(page, ui)` remaps already follow a smaller base down, so a 13px-base app
|
|
600
|
+
still never gets chrome type larger than its page type.
|
|
530
601
|
========================================================================== */
|
|
531
602
|
|
|
532
603
|
@utility text-display-4xl {
|
|
533
604
|
font-family: var(--font-display, var(--font-sans));
|
|
534
|
-
font-size: var(--type-display-4xl-size, clamp(4.5rem, 12vw, 12rem));
|
|
605
|
+
font-size: calc(var(--type-display-4xl-size, clamp(4.5rem, 12vw, 12rem)) * var(--type-base, 16) / 16);
|
|
535
606
|
font-weight: var(--type-display-4xl-weight, 800);
|
|
536
607
|
line-height: round(nearest, calc(var(--type-display-4xl-leading, 0.9) * 1em), var(--baseline-step, 0.25rem));
|
|
537
608
|
letter-spacing: var(--type-display-4xl-tracking, -0.05em);
|
|
538
609
|
}
|
|
539
610
|
@utility text-display-3xl {
|
|
540
611
|
font-family: var(--font-display, var(--font-sans));
|
|
541
|
-
font-size: var(--type-display-3xl-size, 6rem);
|
|
612
|
+
font-size: calc(var(--type-display-3xl-size, 6rem) * var(--type-base, 16) / 16);
|
|
542
613
|
font-weight: var(--type-display-3xl-weight, 700);
|
|
543
614
|
line-height: round(nearest, calc(var(--type-display-3xl-leading, 0.95) * 1em), var(--baseline-step, 0.25rem));
|
|
544
615
|
letter-spacing: var(--type-display-3xl-tracking, -0.045em);
|
|
545
616
|
}
|
|
546
617
|
@utility text-display-2xl {
|
|
547
618
|
font-family: var(--font-display, var(--font-sans));
|
|
548
|
-
font-size: var(--type-display-2xl-size, 4.5rem);
|
|
619
|
+
font-size: calc(var(--type-display-2xl-size, 4.5rem) * var(--type-base, 16) / 16);
|
|
549
620
|
font-weight: var(--type-display-2xl-weight, 700);
|
|
550
621
|
line-height: round(nearest, calc(var(--type-display-2xl-leading, 1) * 1em), var(--baseline-step, 0.25rem));
|
|
551
622
|
letter-spacing: var(--type-display-2xl-tracking, -0.04em);
|
|
552
623
|
}
|
|
553
624
|
@utility text-display-xl {
|
|
554
625
|
font-family: var(--font-display, var(--font-sans));
|
|
555
|
-
font-size: var(--type-display-xl-size, 3.75rem);
|
|
626
|
+
font-size: calc(var(--type-display-xl-size, 3.75rem) * var(--type-base, 16) / 16);
|
|
556
627
|
font-weight: var(--type-display-xl-weight, 700);
|
|
557
628
|
line-height: round(nearest, calc(var(--type-display-xl-leading, 1.05) * 1em), var(--baseline-step, 0.25rem));
|
|
558
629
|
letter-spacing: var(--type-display-xl-tracking, -0.035em);
|
|
559
630
|
}
|
|
560
631
|
@utility text-display-lg {
|
|
561
632
|
font-family: var(--font-display, var(--font-sans));
|
|
562
|
-
font-size: var(--type-display-lg-size, 3rem);
|
|
633
|
+
font-size: calc(var(--type-display-lg-size, 3rem) * var(--type-base, 16) / 16);
|
|
563
634
|
font-weight: var(--type-display-lg-weight, 700);
|
|
564
635
|
line-height: round(nearest, calc(var(--type-display-lg-leading, 1.1) * 1em), var(--baseline-step, 0.25rem));
|
|
565
636
|
letter-spacing: var(--type-display-lg-tracking, -0.03em);
|
|
@@ -567,28 +638,28 @@
|
|
|
567
638
|
|
|
568
639
|
@utility text-heading-1 {
|
|
569
640
|
font-family: var(--font-display, var(--font-sans));
|
|
570
|
-
font-size: var(--type-heading-1-size, 2.25rem);
|
|
641
|
+
font-size: calc(var(--type-heading-1-size, 2.25rem) * var(--type-base, 16) / 16);
|
|
571
642
|
font-weight: var(--type-heading-weight, 600);
|
|
572
643
|
line-height: round(nearest, calc(var(--type-heading-1-leading, 1.15) * 1em), var(--baseline-step, 0.25rem));
|
|
573
644
|
letter-spacing: var(--type-heading-1-tracking, -0.025em);
|
|
574
645
|
}
|
|
575
646
|
@utility text-heading-2 {
|
|
576
647
|
font-family: var(--font-display, var(--font-sans));
|
|
577
|
-
font-size: var(--type-heading-2-size, 1.75rem);
|
|
648
|
+
font-size: calc(var(--type-heading-2-size, 1.75rem) * var(--type-base, 16) / 16);
|
|
578
649
|
font-weight: var(--type-heading-weight, 600);
|
|
579
650
|
line-height: round(nearest, calc(var(--type-heading-2-leading, 1.2) * 1em), var(--baseline-step, 0.25rem));
|
|
580
651
|
letter-spacing: var(--type-heading-2-tracking, -0.02em);
|
|
581
652
|
}
|
|
582
653
|
@utility text-heading-3 {
|
|
583
654
|
font-family: var(--font-display, var(--font-sans));
|
|
584
|
-
font-size: var(--type-heading-3-size, 1.375rem);
|
|
655
|
+
font-size: calc(var(--type-heading-3-size, 1.375rem) * var(--type-base, 16) / 16);
|
|
585
656
|
font-weight: var(--type-heading-weight, 600);
|
|
586
657
|
line-height: round(nearest, calc(var(--type-heading-3-leading, 1.25) * 1em), var(--baseline-step, 0.25rem));
|
|
587
658
|
letter-spacing: var(--type-heading-3-tracking, -0.015em);
|
|
588
659
|
}
|
|
589
660
|
@utility text-heading-4 {
|
|
590
661
|
font-family: var(--font-display, var(--font-sans));
|
|
591
|
-
font-size: var(--type-heading-4-size, 1.125rem);
|
|
662
|
+
font-size: calc(var(--type-heading-4-size, 1.125rem) * var(--type-base, 16) / 16);
|
|
592
663
|
font-weight: var(--type-heading-weight, 600);
|
|
593
664
|
line-height: round(nearest, calc(var(--type-heading-4-leading, 1.3) * 1em), var(--baseline-step, 0.25rem));
|
|
594
665
|
letter-spacing: var(--type-heading-4-tracking, -0.01em);
|
|
@@ -603,13 +674,13 @@
|
|
|
603
674
|
(a trading desk, an operator console) needs its own body/label/mono sizes,
|
|
604
675
|
and pinning them in a page's own <style> block is a patch, not a theme. */
|
|
605
676
|
@utility text-title-lg {
|
|
606
|
-
font-size: var(--type-title-lg-size, 1rem);
|
|
677
|
+
font-size: calc(var(--type-title-lg-size, 1rem) * var(--type-base, 16) / 16);
|
|
607
678
|
font-weight: var(--type-title-weight, 600);
|
|
608
679
|
line-height: round(nearest, calc(var(--type-title-leading, 1.4) * var(--leading-scale, 1) * 1em), var(--baseline-step, 0.25rem));
|
|
609
680
|
letter-spacing: var(--type-title-tracking, -0.01em);
|
|
610
681
|
}
|
|
611
682
|
@utility text-title-sm {
|
|
612
|
-
font-size: var(--type-title-sm-size, 0.875rem);
|
|
683
|
+
font-size: calc(var(--type-title-sm-size, 0.875rem) * var(--type-base, 16) / 16);
|
|
613
684
|
font-weight: var(--type-title-weight, 600);
|
|
614
685
|
line-height: round(nearest, calc(var(--type-title-leading, 1.4) * var(--leading-scale, 1) * 1em), var(--baseline-step, 0.25rem));
|
|
615
686
|
letter-spacing: var(--type-title-sm-tracking, -0.005em);
|
|
@@ -628,20 +699,20 @@
|
|
|
628
699
|
`pretty` costs layout work over many lines to fix a break nobody reads as an
|
|
629
700
|
error. Ledes are short by definition, so the cost is bounded here. */
|
|
630
701
|
@utility text-body-lg {
|
|
631
|
-
font-size: var(--type-body-lg-size, 1.0625rem);
|
|
702
|
+
font-size: calc(var(--type-body-lg-size, 1.0625rem) * var(--type-base, 16) / 16);
|
|
632
703
|
font-weight: var(--type-body-lg-weight, 400);
|
|
633
704
|
line-height: round(nearest, calc(var(--type-body-lg-leading, 1.6) * var(--leading-scale, 1) * 1em), var(--baseline-step, 0.25rem));
|
|
634
705
|
letter-spacing: var(--type-body-lg-tracking, -0.005em);
|
|
635
706
|
text-wrap: pretty;
|
|
636
707
|
}
|
|
637
708
|
@utility text-body-md {
|
|
638
|
-
font-size: var(--type-body-md-size, 0.9375rem);
|
|
709
|
+
font-size: calc(var(--type-body-md-size, 0.9375rem) * var(--type-base, 16) / 16);
|
|
639
710
|
font-weight: var(--type-body-md-weight, 400);
|
|
640
711
|
line-height: round(nearest, calc(var(--type-body-md-leading, 1.55) * var(--leading-scale, 1) * 1em), var(--baseline-step, 0.25rem));
|
|
641
712
|
letter-spacing: var(--type-body-md-tracking, -0.005em);
|
|
642
713
|
}
|
|
643
714
|
@utility text-body-sm {
|
|
644
|
-
font-size: var(--type-body-sm-size, 0.8125rem);
|
|
715
|
+
font-size: calc(var(--type-body-sm-size, 0.8125rem) * var(--type-base, 16) / 16);
|
|
645
716
|
font-weight: var(--type-body-sm-weight, 400);
|
|
646
717
|
line-height: round(nearest, calc(var(--type-body-sm-leading, 1.5) * var(--leading-scale, 1) * 1em), var(--baseline-step, 0.25rem));
|
|
647
718
|
letter-spacing: var(--type-body-sm-tracking, 0);
|
|
@@ -650,7 +721,7 @@
|
|
|
650
721
|
dense table cells, and metadata. Same size as text-caption but with body
|
|
651
722
|
leading: caption is tuned for one-line annotation, body-xs for wrapping. */
|
|
652
723
|
@utility text-body-xs {
|
|
653
|
-
font-size: var(--type-body-xs-size, 0.75rem);
|
|
724
|
+
font-size: calc(var(--type-body-xs-size, 0.75rem) * var(--type-base, 16) / 16);
|
|
654
725
|
font-weight: var(--type-body-xs-weight, 400);
|
|
655
726
|
line-height: round(nearest, calc(var(--type-body-xs-leading, 1.5) * var(--leading-scale, 1) * 1em), var(--baseline-step, 0.25rem));
|
|
656
727
|
letter-spacing: var(--type-body-xs-tracking, 0);
|
|
@@ -678,7 +749,7 @@
|
|
|
678
749
|
@utility sable-list {
|
|
679
750
|
list-style: disc;
|
|
680
751
|
padding-inline-start: 1.25em;
|
|
681
|
-
font-size: var(--type-body-md-size, 0.9375rem);
|
|
752
|
+
font-size: calc(var(--type-body-md-size, 0.9375rem) * var(--type-base, 16) / 16);
|
|
682
753
|
line-height: round(nearest, calc(var(--type-body-md-leading, 1.55) * var(--leading-scale, 1) * 1em), var(--baseline-step, 0.25rem));
|
|
683
754
|
color: var(--foreground);
|
|
684
755
|
& > li + li {
|
|
@@ -692,7 +763,7 @@
|
|
|
692
763
|
@utility sable-list-numbered {
|
|
693
764
|
list-style: decimal;
|
|
694
765
|
padding-inline-start: 1.5em;
|
|
695
|
-
font-size: var(--type-body-md-size, 0.9375rem);
|
|
766
|
+
font-size: calc(var(--type-body-md-size, 0.9375rem) * var(--type-base, 16) / 16);
|
|
696
767
|
line-height: round(nearest, calc(var(--type-body-md-leading, 1.55) * var(--leading-scale, 1) * 1em), var(--baseline-step, 0.25rem));
|
|
697
768
|
color: var(--foreground);
|
|
698
769
|
& > li + li {
|
|
@@ -714,12 +785,12 @@
|
|
|
714
785
|
/* The values' type and ink live on the list and the <dd>s inherit them, so a
|
|
715
786
|
text-* utility on a <dd> (text-success, text-mono-md) simply wins. The term
|
|
716
787
|
and the wrapping rules sit in :where(), which adds no specificity. */
|
|
717
|
-
font-size: var(--type-body-md-size, 0.9375rem);
|
|
788
|
+
font-size: calc(var(--type-body-md-size, 0.9375rem) * var(--type-base, 16) / 16);
|
|
718
789
|
line-height: round(nearest, calc(var(--type-body-md-leading, 1.55) * var(--leading-scale, 1) * 1em), var(--baseline-step, 0.25rem));
|
|
719
790
|
letter-spacing: var(--type-body-md-tracking, -0.005em);
|
|
720
791
|
color: var(--foreground);
|
|
721
792
|
& > :where(dt) {
|
|
722
|
-
font-size: var(--type-label-md-size, 0.75rem);
|
|
793
|
+
font-size: calc(var(--type-label-md-size, 0.75rem) * var(--type-base, 16) / 16);
|
|
723
794
|
font-weight: var(--type-label-md-weight, 600);
|
|
724
795
|
line-height: round(nearest, calc(var(--type-label-md-leading, 1.2) * 1em), var(--baseline-step, 0.25rem));
|
|
725
796
|
letter-spacing: var(--type-label-md-tracking, 0);
|
|
@@ -738,19 +809,19 @@
|
|
|
738
809
|
}
|
|
739
810
|
|
|
740
811
|
@utility text-label-lg {
|
|
741
|
-
font-size: var(--type-label-lg-size, 0.875rem);
|
|
812
|
+
font-size: calc(var(--type-label-lg-size, 0.875rem) * var(--type-base, 16) / 16);
|
|
742
813
|
font-weight: var(--type-label-lg-weight, 600);
|
|
743
814
|
line-height: round(nearest, calc(var(--type-label-lg-leading, 1.25) * 1em), var(--baseline-step, 0.25rem));
|
|
744
815
|
letter-spacing: var(--type-label-lg-tracking, -0.005em);
|
|
745
816
|
}
|
|
746
817
|
@utility text-label-md {
|
|
747
|
-
font-size: var(--type-label-md-size, 0.75rem);
|
|
818
|
+
font-size: calc(var(--type-label-md-size, 0.75rem) * var(--type-base, 16) / 16);
|
|
748
819
|
font-weight: var(--type-label-md-weight, 600);
|
|
749
820
|
line-height: round(nearest, calc(var(--type-label-md-leading, 1.2) * 1em), var(--baseline-step, 0.25rem));
|
|
750
821
|
letter-spacing: var(--type-label-md-tracking, 0);
|
|
751
822
|
}
|
|
752
823
|
@utility text-label-sm {
|
|
753
|
-
font-size: var(--type-label-sm-size, 0.6875rem);
|
|
824
|
+
font-size: calc(var(--type-label-sm-size, 0.6875rem) * var(--type-base, 16) / 16);
|
|
754
825
|
font-weight: var(--type-label-sm-weight, 600);
|
|
755
826
|
line-height: round(nearest, calc(var(--type-label-sm-leading, 1.2) * 1em), var(--baseline-step, 0.25rem));
|
|
756
827
|
letter-spacing: var(--type-label-sm-tracking, 0);
|
|
@@ -760,14 +831,14 @@
|
|
|
760
831
|
it (Label `eyebrow`) rather than getting caps from the smallest label. The
|
|
761
832
|
transform stays a themeable hook for a theme that wants caps here. */
|
|
762
833
|
@utility text-label-xs {
|
|
763
|
-
font-size: var(--type-label-xs-size, 0.6875rem);
|
|
834
|
+
font-size: calc(var(--type-label-xs-size, 0.6875rem) * var(--type-base, 16) / 16);
|
|
764
835
|
font-weight: var(--type-label-xs-weight, 600);
|
|
765
836
|
line-height: round(nearest, calc(var(--type-label-xs-leading, 1.2) * 1em), var(--baseline-step, 0.25rem));
|
|
766
837
|
letter-spacing: var(--type-label-xs-tracking, 0.01em);
|
|
767
838
|
text-transform: var(--type-label-xs-transform, none);
|
|
768
839
|
}
|
|
769
840
|
@utility text-caption {
|
|
770
|
-
font-size: var(--type-caption-size, 0.75rem);
|
|
841
|
+
font-size: calc(var(--type-caption-size, 0.75rem) * var(--type-base, 16) / 16);
|
|
771
842
|
font-weight: var(--type-caption-weight, 400);
|
|
772
843
|
line-height: round(nearest, calc(var(--type-caption-leading, 1.4) * var(--leading-scale, 1) * 1em), var(--baseline-step, 0.25rem));
|
|
773
844
|
letter-spacing: var(--type-caption-tracking, 0);
|
|
@@ -778,7 +849,7 @@
|
|
|
778
849
|
via TYPE_OVERLINE_TOKENS (see _contract.ts); `--type-overline-transform`
|
|
779
850
|
lets a theme opt out of all-caps rather than hardcoding `uppercase`. */
|
|
780
851
|
@utility text-overline {
|
|
781
|
-
font-size: var(--type-overline-size, 0.75rem);
|
|
852
|
+
font-size: calc(var(--type-overline-size, 0.75rem) * var(--type-base, 16) / 16);
|
|
782
853
|
font-weight: var(--type-overline-weight, 600);
|
|
783
854
|
line-height: round(nearest, calc(var(--type-overline-leading, 1.2) * 1em), var(--baseline-step, 0.25rem));
|
|
784
855
|
letter-spacing: var(--type-overline-tracking, 0.08em);
|
|
@@ -790,7 +861,7 @@
|
|
|
790
861
|
the technical voice) rather than a heading tier — headings stay semantic. */
|
|
791
862
|
@utility text-mono-xl {
|
|
792
863
|
font-family: var(--font-mono);
|
|
793
|
-
font-size: var(--type-mono-xl-size, 1.75rem);
|
|
864
|
+
font-size: calc(var(--type-mono-xl-size, 1.75rem) * var(--type-base, 16) / 16);
|
|
794
865
|
font-weight: var(--type-mono-xl-weight, 500);
|
|
795
866
|
line-height: round(nearest, calc(var(--type-mono-xl-leading, 1.15) * 1em), var(--baseline-step, 0.25rem));
|
|
796
867
|
letter-spacing: var(--type-mono-xl-tracking, -0.01em);
|
|
@@ -798,7 +869,7 @@
|
|
|
798
869
|
}
|
|
799
870
|
@utility text-mono-lg {
|
|
800
871
|
font-family: var(--font-mono);
|
|
801
|
-
font-size: var(--type-mono-lg-size, 1.25rem);
|
|
872
|
+
font-size: calc(var(--type-mono-lg-size, 1.25rem) * var(--type-base, 16) / 16);
|
|
802
873
|
font-weight: var(--type-mono-lg-weight, 500);
|
|
803
874
|
line-height: round(nearest, calc(var(--type-mono-lg-leading, 1.25) * 1em), var(--baseline-step, 0.25rem));
|
|
804
875
|
letter-spacing: var(--type-mono-lg-tracking, 0);
|
|
@@ -806,7 +877,7 @@
|
|
|
806
877
|
}
|
|
807
878
|
@utility text-mono-md {
|
|
808
879
|
font-family: var(--font-mono);
|
|
809
|
-
font-size: var(--type-mono-md-size, 0.8125rem);
|
|
880
|
+
font-size: calc(var(--type-mono-md-size, 0.8125rem) * var(--type-base, 16) / 16);
|
|
810
881
|
font-weight: var(--type-mono-md-weight, 400);
|
|
811
882
|
line-height: round(nearest, calc(var(--type-mono-md-leading, 1.5) * var(--leading-scale, 1) * 1em), var(--baseline-step, 0.25rem));
|
|
812
883
|
letter-spacing: var(--type-mono-md-tracking, 0);
|
|
@@ -817,7 +888,7 @@
|
|
|
817
888
|
`font-mono text-caption` recomposition. */
|
|
818
889
|
@utility text-mono-caption {
|
|
819
890
|
font-family: var(--font-mono);
|
|
820
|
-
font-size: var(--type-mono-caption-size, 0.75rem);
|
|
891
|
+
font-size: calc(var(--type-mono-caption-size, 0.75rem) * var(--type-base, 16) / 16);
|
|
821
892
|
font-weight: var(--type-mono-caption-weight, 400);
|
|
822
893
|
line-height: round(nearest, calc(var(--type-mono-caption-leading, 1.4) * var(--leading-scale, 1) * 1em), var(--baseline-step, 0.25rem));
|
|
823
894
|
letter-spacing: var(--type-mono-caption-tracking, 0);
|
|
@@ -825,7 +896,7 @@
|
|
|
825
896
|
}
|
|
826
897
|
@utility text-mono-sm {
|
|
827
898
|
font-family: var(--font-mono);
|
|
828
|
-
font-size: var(--type-mono-sm-size, 0.6875rem);
|
|
899
|
+
font-size: calc(var(--type-mono-sm-size, 0.6875rem) * var(--type-base, 16) / 16);
|
|
829
900
|
font-weight: var(--type-mono-sm-weight, 500);
|
|
830
901
|
line-height: round(nearest, calc(var(--type-mono-sm-leading, 1.2) * 1em), var(--baseline-step, 0.25rem));
|
|
831
902
|
letter-spacing: var(--type-mono-sm-tracking, 0.02em);
|
|
@@ -932,6 +1003,20 @@
|
|
|
932
1003
|
letter-spacing: 0.005em;
|
|
933
1004
|
}
|
|
934
1005
|
|
|
1006
|
+
/* The title of what a panel or inspector is showing — the open issue, the
|
|
1007
|
+
selected object. One step above ui-md on the chrome ladder (10 / 11 / 12 /
|
|
1008
|
+
14): far enough above its 12px description to lead without weight alone,
|
|
1009
|
+
short of the 16px page title so it still reads as chrome. Linear's issue
|
|
1010
|
+
peek, Figma's selection header and Paper's inspector title all sit at
|
|
1011
|
+
13-15px. On a 20px leading, the ui grid's next 4px step. Compact `text-title-lg`
|
|
1012
|
+
resolves here, so a page-register title dropped into a panel lands on it. */
|
|
1013
|
+
@utility text-ui-title {
|
|
1014
|
+
font-size: var(--type-ui-title-size, 14px);
|
|
1015
|
+
font-weight: var(--type-ui-title-weight, 600);
|
|
1016
|
+
line-height: var(--type-ui-title-leading, 20px);
|
|
1017
|
+
letter-spacing: -0.005em;
|
|
1018
|
+
}
|
|
1019
|
+
|
|
935
1020
|
/* The reading variant — descriptions and help text inside chrome. */
|
|
936
1021
|
@utility text-ui-body {
|
|
937
1022
|
font-size: var(--type-ui-md-size, 12px);
|
|
@@ -1599,6 +1684,17 @@
|
|
|
1599
1684
|
========================================================================== */
|
|
1600
1685
|
[data-density="compact"] {
|
|
1601
1686
|
/*
|
|
1687
|
+
* The remap stops at a comfortable boundary. A reading view inside a tool —
|
|
1688
|
+
* an issue's overview, a settings form — is wrapped in
|
|
1689
|
+
* `<Density value="comfortable">` to get page type back, and the descendant
|
|
1690
|
+
* selectors alone still matched it, so the wrapper restored the control
|
|
1691
|
+
* ladder and left the prose at 11px. `:not(compact comfortable *)` rather
|
|
1692
|
+
* than `@scope (compact) to (comfortable)`: @scope would be the exact tool,
|
|
1693
|
+
* but a browser without it (Safari < 17.4, older Firefox — inside Tailwind
|
|
1694
|
+
* v4's support range) drops the whole block, and the register's type with
|
|
1695
|
+
* it. Limit: a compact scope nested inside that comfortable one gets page
|
|
1696
|
+
* type too, a third level of nesting nothing ships.
|
|
1697
|
+
*
|
|
1602
1698
|
* Every value is `min(page, workspace)`, so the register can only ever
|
|
1603
1699
|
* COMPRESS. Without it these grow on some apps: the page tiers are `rem`
|
|
1604
1700
|
* and the workspace tiers are absolute px, so at a 14px root
|
|
@@ -1606,59 +1702,63 @@
|
|
|
1606
1702
|
* tool panel — a "denser" register rendering larger text than the page it
|
|
1607
1703
|
* sits beside. `min()` makes that impossible at any root size.
|
|
1608
1704
|
*/
|
|
1609
|
-
& .text-body-lg {
|
|
1610
|
-
font-size: min(1.0625rem, var(--type-ui-md-size, 12px));
|
|
1705
|
+
& .text-body-lg:not([data-density="compact"] [data-density="comfortable"], [data-density="compact"] [data-density="comfortable"] *) {
|
|
1706
|
+
font-size: min(calc(1.0625rem * var(--type-base, 16) / 16), var(--type-ui-md-size, 12px));
|
|
1611
1707
|
line-height: var(--type-ui-leading, 16px);
|
|
1612
1708
|
}
|
|
1613
|
-
& .text-body-md {
|
|
1614
|
-
font-size: min(0.9375rem, var(--type-ui-md-size, 12px));
|
|
1709
|
+
& .text-body-md:not([data-density="compact"] [data-density="comfortable"], [data-density="compact"] [data-density="comfortable"] *) {
|
|
1710
|
+
font-size: min(calc(0.9375rem * var(--type-base, 16) / 16), var(--type-ui-md-size, 12px));
|
|
1615
1711
|
line-height: var(--type-ui-leading, 16px);
|
|
1616
1712
|
}
|
|
1617
|
-
& .text-body-sm {
|
|
1618
|
-
font-size: min(0.8125rem, var(--type-ui-sm-size, 11px));
|
|
1713
|
+
& .text-body-sm:not([data-density="compact"] [data-density="comfortable"], [data-density="compact"] [data-density="comfortable"] *) {
|
|
1714
|
+
font-size: min(calc(0.8125rem * var(--type-base, 16) / 16), var(--type-ui-sm-size, 11px));
|
|
1619
1715
|
line-height: var(--type-ui-leading, 16px);
|
|
1620
1716
|
}
|
|
1621
|
-
& .text-body-xs,
|
|
1622
|
-
& .text-caption {
|
|
1623
|
-
font-size: min(0.75rem, var(--type-ui-sm-size, 11px));
|
|
1717
|
+
& .text-body-xs:not([data-density="compact"] [data-density="comfortable"], [data-density="compact"] [data-density="comfortable"] *),
|
|
1718
|
+
& .text-caption:not([data-density="compact"] [data-density="comfortable"], [data-density="compact"] [data-density="comfortable"] *) {
|
|
1719
|
+
font-size: min(calc(0.75rem * var(--type-base, 16) / 16), var(--type-ui-sm-size, 11px));
|
|
1624
1720
|
line-height: var(--type-ui-leading, 16px);
|
|
1625
1721
|
}
|
|
1626
|
-
& .text-label-lg {
|
|
1627
|
-
font-size: min(0.875rem, var(--type-ui-md-size, 12px));
|
|
1722
|
+
& .text-label-lg:not([data-density="compact"] [data-density="comfortable"], [data-density="compact"] [data-density="comfortable"] *) {
|
|
1723
|
+
font-size: min(calc(0.875rem * var(--type-base, 16) / 16), var(--type-ui-md-size, 12px));
|
|
1628
1724
|
font-weight: var(--type-ui-md-weight, 500);
|
|
1629
1725
|
line-height: var(--type-ui-leading, 16px);
|
|
1630
1726
|
}
|
|
1631
|
-
& .text-label-md {
|
|
1632
|
-
font-size: min(0.75rem, var(--type-ui-md-size, 12px));
|
|
1727
|
+
& .text-label-md:not([data-density="compact"] [data-density="comfortable"], [data-density="compact"] [data-density="comfortable"] *) {
|
|
1728
|
+
font-size: min(calc(0.75rem * var(--type-base, 16) / 16), var(--type-ui-md-size, 12px));
|
|
1633
1729
|
font-weight: var(--type-ui-md-weight, 500);
|
|
1634
1730
|
line-height: var(--type-ui-leading, 16px);
|
|
1635
1731
|
}
|
|
1636
1732
|
/* The list utilities carry their own type, so they follow the same tiers:
|
|
1637
1733
|
items and values as body-md, terms as label-md. */
|
|
1638
|
-
& :is(.sable-list, .sable-list-numbered, .sable-list-dl) {
|
|
1639
|
-
font-size: min(0.9375rem, var(--type-ui-md-size, 12px));
|
|
1734
|
+
& :is(.sable-list, .sable-list-numbered, .sable-list-dl):not([data-density="compact"] [data-density="comfortable"], [data-density="compact"] [data-density="comfortable"] *) {
|
|
1735
|
+
font-size: min(calc(0.9375rem * var(--type-base, 16) / 16), var(--type-ui-md-size, 12px));
|
|
1640
1736
|
line-height: var(--type-ui-leading, 16px);
|
|
1641
1737
|
}
|
|
1642
|
-
& .sable-list-dl > :where(dt) {
|
|
1643
|
-
font-size: min(0.75rem, var(--type-ui-md-size, 12px));
|
|
1738
|
+
& .sable-list-dl > :where(dt):not([data-density="compact"] [data-density="comfortable"], [data-density="compact"] [data-density="comfortable"] *) {
|
|
1739
|
+
font-size: min(calc(0.75rem * var(--type-base, 16) / 16), var(--type-ui-md-size, 12px));
|
|
1644
1740
|
font-weight: var(--type-ui-md-weight, 500);
|
|
1645
1741
|
line-height: var(--type-ui-leading, 16px);
|
|
1646
1742
|
}
|
|
1647
|
-
& .text-label-sm,
|
|
1648
|
-
& .text-label-xs {
|
|
1649
|
-
font-size: min(0.6875rem, var(--type-ui-micro-size, 10px));
|
|
1743
|
+
& .text-label-sm:not([data-density="compact"] [data-density="comfortable"], [data-density="compact"] [data-density="comfortable"] *),
|
|
1744
|
+
& .text-label-xs:not([data-density="compact"] [data-density="comfortable"], [data-density="compact"] [data-density="comfortable"] *) {
|
|
1745
|
+
font-size: min(calc(0.6875rem * var(--type-base, 16) / 16), var(--type-ui-micro-size, 10px));
|
|
1650
1746
|
font-weight: var(--type-ui-micro-weight, 450);
|
|
1651
1747
|
line-height: 14px;
|
|
1652
1748
|
}
|
|
1653
|
-
& .text-title-sm {
|
|
1654
|
-
font-size: min(0.875rem, var(--type-ui-md-size, 12px));
|
|
1749
|
+
& .text-title-sm:not([data-density="compact"] [data-density="comfortable"], [data-density="compact"] [data-density="comfortable"] *) {
|
|
1750
|
+
font-size: min(calc(0.875rem * var(--type-base, 16) / 16), var(--type-ui-md-size, 12px));
|
|
1655
1751
|
font-weight: var(--type-ui-section-weight, 550);
|
|
1656
1752
|
line-height: var(--type-ui-leading, 16px);
|
|
1657
1753
|
}
|
|
1658
|
-
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1754
|
+
/* title-lg names the thing a panel is about (the issue open in an inspector,
|
|
1755
|
+
the selected layer), so it takes the ui TITLE tier rather than ui-md. On
|
|
1756
|
+
ui-md it measured 12px/550 against a 12px description beneath it — the
|
|
1757
|
+
title and its own body the same size, hierarchy carried by weight alone. */
|
|
1758
|
+
& .text-title-lg:not([data-density="compact"] [data-density="comfortable"], [data-density="compact"] [data-density="comfortable"] *) {
|
|
1759
|
+
font-size: min(calc(1rem * var(--type-base, 16) / 16), var(--type-ui-title-size, 14px));
|
|
1760
|
+
font-weight: var(--type-ui-title-weight, 600);
|
|
1761
|
+
line-height: var(--type-ui-title-leading, 20px);
|
|
1662
1762
|
}
|
|
1663
1763
|
}
|
|
1664
1764
|
|
|
@@ -1706,9 +1806,16 @@
|
|
|
1706
1806
|
top-right one.
|
|
1707
1807
|
- Where there is room, a stack on the sheet's side moves beside it. The sheet
|
|
1708
1808
|
publishes its real width (--sable-sheet-right-w / -left-w) while mounted.
|
|
1709
|
-
- On a narrower screen the sheet leaves no room beside it
|
|
1710
|
-
|
|
1711
|
-
header.
|
|
1809
|
+
- On a narrower screen the sheet leaves no room beside it and both of its
|
|
1810
|
+
edges hold controls: a footer of actions (a composer, Check out) and a
|
|
1811
|
+
header with its close button. So every stack — any position, either side
|
|
1812
|
+
— moves to the top and drops below a PROTECTED INSET: the sheet's padding
|
|
1813
|
+
plus one control row, which clears a padded SheetHeader with a close
|
|
1814
|
+
button and a 48px bar alike. It then covers the top of the sheet's
|
|
1815
|
+
scrolling content, never an action. The first version moved bottom stacks
|
|
1816
|
+
to the top edge itself, straight over the close button, and an app worked
|
|
1817
|
+
around it by switching to bottom-center — over its composer's send button.
|
|
1818
|
+
A sheet whose header is taller sets `--sable-sheet-top-inset` on <html>.
|
|
1712
1819
|
- A bottom sheet sends a bottom stack to the top, a top sheet sends a top
|
|
1713
1820
|
stack to the bottom, at any width.
|
|
1714
1821
|
A stack that moves to the other edge re-anchors its stacked toasts too: they
|
|
@@ -1723,13 +1830,11 @@
|
|
|
1723
1830
|
}
|
|
1724
1831
|
}
|
|
1725
1832
|
@media (width < 52rem) {
|
|
1726
|
-
:root:has([data-sable-sheet="right"][data-open]) [data-sable-toast-viewport]
|
|
1727
|
-
|
|
1728
|
-
top: calc(var(--spacing) * 4);
|
|
1833
|
+
:root:has(:is([data-sable-sheet="right"], [data-sable-sheet="left"])[data-open]) [data-sable-toast-viewport] {
|
|
1834
|
+
top: var(--sable-sheet-top-inset, calc(var(--spacing) * 8 + var(--control-md)));
|
|
1729
1835
|
bottom: auto;
|
|
1730
1836
|
}
|
|
1731
|
-
:root:has([data-sable-sheet="right"][data-open]) [data-sable-toast-viewport][data-position
|
|
1732
|
-
:root:has([data-sable-sheet="left"][data-open]) [data-sable-toast-viewport][data-position="bottom-left"] [data-sable-toast-stacked] {
|
|
1837
|
+
:root:has(:is([data-sable-sheet="right"], [data-sable-sheet="left"])[data-open]) [data-sable-toast-viewport][data-position^="bottom"] [data-sable-toast-stacked] {
|
|
1733
1838
|
top: 0;
|
|
1734
1839
|
bottom: auto;
|
|
1735
1840
|
transform-origin: top;
|
|
@@ -2051,7 +2156,7 @@
|
|
|
2051
2156
|
@utility checkerboard {
|
|
2052
2157
|
background-image: repeating-conic-gradient(
|
|
2053
2158
|
var(--panel) 0% 25%,
|
|
2054
|
-
var(--checkerboard-alt, color-mix(in
|
|
2159
|
+
var(--checkerboard-alt, color-mix(in oklab, var(--panel) 88%, var(--foreground)))
|
|
2055
2160
|
0% 50%
|
|
2056
2161
|
);
|
|
2057
2162
|
background-size: var(--checkerboard-size, 16px) var(--checkerboard-size, 16px);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
-
import { T as ThemeManifest } from './_contract-
|
|
3
|
+
import { T as ThemeManifest } from './_contract-DlklV0Im.js';
|
|
4
4
|
|
|
5
5
|
declare const SABLE_THEME_ATTRIBUTE: "data-sable-theme";
|
|
6
6
|
declare const DEFAULT_THEME_ID: string;
|
package/dist/themes/_contract.js
CHANGED
|
@@ -150,6 +150,10 @@ var TYPE_SCALE_TOKENS = [
|
|
|
150
150
|
"type-title-sm-tracking"
|
|
151
151
|
];
|
|
152
152
|
var TYPE_REFINEMENT_TOKENS = [
|
|
153
|
+
// The base the page scale is built on, as a unitless px number (default 16).
|
|
154
|
+
// `14` rebuilds every page tier, and the baseline rhythm, at 14 — see
|
|
155
|
+
// styles.css → Typography → "The base size".
|
|
156
|
+
"type-base",
|
|
153
157
|
"type-display-4xl-size",
|
|
154
158
|
"type-title-lg-size",
|
|
155
159
|
"type-title-sm-size",
|
|
@@ -331,7 +335,11 @@ var TYPE_UI_TOKENS = [
|
|
|
331
335
|
"type-ui-leading",
|
|
332
336
|
"type-ui-section-weight",
|
|
333
337
|
"type-ui-micro-size",
|
|
334
|
-
"type-ui-micro-weight"
|
|
338
|
+
"type-ui-micro-weight",
|
|
339
|
+
// The panel/inspector title, one step above ui-md (compact `text-title-lg`).
|
|
340
|
+
"type-ui-title-size",
|
|
341
|
+
"type-ui-title-weight",
|
|
342
|
+
"type-ui-title-leading"
|
|
335
343
|
];
|
|
336
344
|
export {
|
|
337
345
|
APP_SHELL_TOKENS,
|
package/dist/themes/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { A as AnyThemeId, D as DEFAULT_THEME_ID, S as SABLE_COLOR_STORAGE_KEY, a as SABLE_THEME_ATTRIBUTE, b as SABLE_THEME_STORAGE_KEY, c as SableColorMode, d as SableThemeContextValue, e as SableThemePreference, f as SableThemeProvider, g as SableThemeProviderProps, T as ThemeId, h as applySableColorMode, i as applySableTheme, j as buildThemeManifestById, k as defaultThemeId, l as featuredThemeManifests, m as getThemeManifest, n as isKnownThemeId, o as isThemeId, t as themeIds, p as themeManifestById, q as themeManifests, u as useSableTheme } from '../theme-provider-
|
|
1
|
+
export { A as AnyThemeId, D as DEFAULT_THEME_ID, S as SABLE_COLOR_STORAGE_KEY, a as SABLE_THEME_ATTRIBUTE, b as SABLE_THEME_STORAGE_KEY, c as SableColorMode, d as SableThemeContextValue, e as SableThemePreference, f as SableThemeProvider, g as SableThemeProviderProps, T as ThemeId, h as applySableColorMode, i as applySableTheme, j as buildThemeManifestById, k as defaultThemeId, l as featuredThemeManifests, m as getThemeManifest, n as isKnownThemeId, o as isThemeId, t as themeIds, p as themeManifestById, q as themeManifests, u as useSableTheme } from '../theme-provider-BUBealk_.js';
|
|
2
2
|
export { atelierTheme } from './atelier/index.js';
|
|
3
3
|
export { default as emberTheme } from './ember/index.js';
|
|
4
4
|
export { default as meridianTheme } from './meridian/index.js';
|
|
@@ -7,4 +7,4 @@ export { default as prismTheme } from './prism/index.js';
|
|
|
7
7
|
export { default as sableTheme } from './sable/index.js';
|
|
8
8
|
export { default as verdantTheme } from './verdant/index.js';
|
|
9
9
|
import 'react';
|
|
10
|
-
import '../_contract-
|
|
10
|
+
import '../_contract-DlklV0Im.js';
|