@atom63/cli 0.1.0-beta.2 → 0.1.0-beta.4
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/generated/agent-index.json +1223 -85
- package/package.json +1 -1
- package/src/agents-md.mjs +24 -4
- package/src/rules.mjs +25 -6
|
@@ -3438,15 +3438,18 @@
|
|
|
3438
3438
|
"accordionIconVariants",
|
|
3439
3439
|
"accordionPattern",
|
|
3440
3440
|
"accordionSlots",
|
|
3441
|
+
"accordionStateAliases",
|
|
3441
3442
|
"accordionStates",
|
|
3442
3443
|
"accordionVisualArchetypes",
|
|
3443
3444
|
"alertContract",
|
|
3444
3445
|
"alertDialogContract",
|
|
3445
3446
|
"alertDialogFooterVariants",
|
|
3446
3447
|
"alertDialogPattern",
|
|
3448
|
+
"alertDialogSizeAliases",
|
|
3447
3449
|
"alertDialogSizes",
|
|
3448
3450
|
"alertDialogSlots",
|
|
3449
3451
|
"alertDialogStates",
|
|
3452
|
+
"alertDialogVariantAliases",
|
|
3450
3453
|
"alertDialogVariants",
|
|
3451
3454
|
"alertDialogVisualArchetypes",
|
|
3452
3455
|
"alertSlots",
|
|
@@ -3469,7 +3472,16 @@
|
|
|
3469
3472
|
"appViewSlots",
|
|
3470
3473
|
"appViewTopBarSpans",
|
|
3471
3474
|
"appViewVisualArchetypes",
|
|
3475
|
+
"artPlateContract",
|
|
3476
|
+
"artPlateSafeAreas",
|
|
3477
|
+
"artPlateSizes",
|
|
3478
|
+
"artPlateSlots",
|
|
3479
|
+
"artPlateStates",
|
|
3480
|
+
"artPlateTones",
|
|
3481
|
+
"artPlateVeils",
|
|
3482
|
+
"artPlateVisualArchetypes",
|
|
3472
3483
|
"autocompleteContract",
|
|
3484
|
+
"autocompleteSizeAliases",
|
|
3473
3485
|
"autocompleteSizes",
|
|
3474
3486
|
"autocompleteSlots",
|
|
3475
3487
|
"autocompleteStates",
|
|
@@ -3478,6 +3490,7 @@
|
|
|
3478
3490
|
"avatarContract",
|
|
3479
3491
|
"avatarRings",
|
|
3480
3492
|
"avatarShapes",
|
|
3493
|
+
"avatarSizeAliases",
|
|
3481
3494
|
"avatarSizes",
|
|
3482
3495
|
"avatarSlots",
|
|
3483
3496
|
"avatarStates",
|
|
@@ -3489,6 +3502,7 @@
|
|
|
3489
3502
|
"badgeSizes",
|
|
3490
3503
|
"badgeSlots",
|
|
3491
3504
|
"badgeSolidVariants",
|
|
3505
|
+
"badgeStateAliases",
|
|
3492
3506
|
"badgeStates",
|
|
3493
3507
|
"badgeVariants",
|
|
3494
3508
|
"badgeVisualArchetypes",
|
|
@@ -3496,11 +3510,13 @@
|
|
|
3496
3510
|
"breadcrumbCompositions",
|
|
3497
3511
|
"breadcrumbContract",
|
|
3498
3512
|
"breadcrumbSlots",
|
|
3513
|
+
"breadcrumbStateAliases",
|
|
3499
3514
|
"breadcrumbStates",
|
|
3500
3515
|
"breadcrumbVisualArchetypes",
|
|
3501
3516
|
"buttonContract",
|
|
3502
3517
|
"buttonGroupContract",
|
|
3503
3518
|
"buttonGroupOrientations",
|
|
3519
|
+
"buttonGroupSizeAliases",
|
|
3504
3520
|
"buttonGroupSizes",
|
|
3505
3521
|
"buttonGroupSlots",
|
|
3506
3522
|
"buttonGroupStates",
|
|
@@ -3508,6 +3524,7 @@
|
|
|
3508
3524
|
"buttonShapes",
|
|
3509
3525
|
"buttonSizes",
|
|
3510
3526
|
"buttonSlots",
|
|
3527
|
+
"buttonStateAliases",
|
|
3511
3528
|
"buttonStates",
|
|
3512
3529
|
"buttonTokenSlots",
|
|
3513
3530
|
"buttonTones",
|
|
@@ -3599,6 +3616,7 @@
|
|
|
3599
3616
|
"dialogFooterVariants",
|
|
3600
3617
|
"dialogMobilePlacements",
|
|
3601
3618
|
"dialogModalPattern",
|
|
3619
|
+
"dialogSizeAliases",
|
|
3602
3620
|
"dialogSizes",
|
|
3603
3621
|
"dialogSlots",
|
|
3604
3622
|
"dialogStates",
|
|
@@ -3623,6 +3641,7 @@
|
|
|
3623
3641
|
"feedbackStateKinds",
|
|
3624
3642
|
"feedbackStateSizes",
|
|
3625
3643
|
"feedbackStateSlots",
|
|
3644
|
+
"feedbackStateStateAliases",
|
|
3626
3645
|
"feedbackStateStates",
|
|
3627
3646
|
"feedbackStateVisualArchetypes",
|
|
3628
3647
|
"fieldContract",
|
|
@@ -3634,6 +3653,7 @@
|
|
|
3634
3653
|
"fonts",
|
|
3635
3654
|
"formContract",
|
|
3636
3655
|
"formSlots",
|
|
3656
|
+
"formStateAliases",
|
|
3637
3657
|
"formStates",
|
|
3638
3658
|
"formVisualArchetypes",
|
|
3639
3659
|
"frameBorders",
|
|
@@ -3641,6 +3661,7 @@
|
|
|
3641
3661
|
"framePanelSurfaces",
|
|
3642
3662
|
"framePresets",
|
|
3643
3663
|
"frameSlots",
|
|
3664
|
+
"frameStateAliases",
|
|
3644
3665
|
"frameStates",
|
|
3645
3666
|
"frameTrays",
|
|
3646
3667
|
"frameVariants",
|
|
@@ -3659,6 +3680,7 @@
|
|
|
3659
3680
|
"inputGroupVisualArchetypes",
|
|
3660
3681
|
"inputOTPContract",
|
|
3661
3682
|
"inputOTPSlots",
|
|
3683
|
+
"inputOTPStateAliases",
|
|
3662
3684
|
"inputOTPStates",
|
|
3663
3685
|
"inputOTPVisualArchetypes",
|
|
3664
3686
|
"inputSizes",
|
|
@@ -3672,8 +3694,10 @@
|
|
|
3672
3694
|
"itemGroupSurfaces",
|
|
3673
3695
|
"itemGroupVariants",
|
|
3674
3696
|
"itemMediaVariants",
|
|
3697
|
+
"itemSizeAliases",
|
|
3675
3698
|
"itemSizes",
|
|
3676
3699
|
"itemSlots",
|
|
3700
|
+
"itemStateAliases",
|
|
3677
3701
|
"itemStates",
|
|
3678
3702
|
"itemTones",
|
|
3679
3703
|
"itemVariants",
|
|
@@ -3687,6 +3711,12 @@
|
|
|
3687
3711
|
"labelSlots",
|
|
3688
3712
|
"labelStates",
|
|
3689
3713
|
"labelVisualArchetypes",
|
|
3714
|
+
"layeredSceneContract",
|
|
3715
|
+
"layeredScenePlacements",
|
|
3716
|
+
"layeredSceneSlots",
|
|
3717
|
+
"layeredSceneStates",
|
|
3718
|
+
"layeredSceneVisualArchetypes",
|
|
3719
|
+
"layeredSceneWidths",
|
|
3690
3720
|
"loadMoreTriggerContract",
|
|
3691
3721
|
"loadMoreTriggerSlots",
|
|
3692
3722
|
"loadMoreTriggerStates",
|
|
@@ -3718,6 +3748,7 @@
|
|
|
3718
3748
|
"modes",
|
|
3719
3749
|
"navigationMenuContract",
|
|
3720
3750
|
"navigationMenuSlots",
|
|
3751
|
+
"navigationMenuStateAliases",
|
|
3721
3752
|
"navigationMenuStates",
|
|
3722
3753
|
"navigationMenuVisualArchetypes",
|
|
3723
3754
|
"osSystems",
|
|
@@ -3768,6 +3799,7 @@
|
|
|
3768
3799
|
"resizableContract",
|
|
3769
3800
|
"resizableOrientations",
|
|
3770
3801
|
"resizableSlots",
|
|
3802
|
+
"resizableStateAliases",
|
|
3771
3803
|
"resizableStates",
|
|
3772
3804
|
"resizableVariants",
|
|
3773
3805
|
"resizableVisualArchetypes",
|
|
@@ -3776,12 +3808,14 @@
|
|
|
3776
3808
|
"scrollAreaOptions",
|
|
3777
3809
|
"scrollAreaOrientations",
|
|
3778
3810
|
"scrollAreaSlots",
|
|
3811
|
+
"scrollAreaStateAliases",
|
|
3779
3812
|
"scrollAreaStates",
|
|
3780
3813
|
"scrollAreaVisualArchetypes",
|
|
3781
3814
|
"scrollableListContract",
|
|
3782
3815
|
"scrollableListLayouts",
|
|
3783
3816
|
"scrollableListOptions",
|
|
3784
3817
|
"scrollableListSlots",
|
|
3818
|
+
"scrollableListStateAliases",
|
|
3785
3819
|
"scrollableListStates",
|
|
3786
3820
|
"scrollableListVisualArchetypes",
|
|
3787
3821
|
"searchFieldContract",
|
|
@@ -3823,6 +3857,7 @@
|
|
|
3823
3857
|
"sidebarMenuSubButtonSizes",
|
|
3824
3858
|
"sidebarNavTreeContract",
|
|
3825
3859
|
"sidebarNavTreeParts",
|
|
3860
|
+
"sidebarNavTreeStateAliases",
|
|
3826
3861
|
"sidebarNavTreeStates",
|
|
3827
3862
|
"sidebarNavTreeTones",
|
|
3828
3863
|
"sidebarNavTreeVisualArchetypes",
|
|
@@ -3854,6 +3889,7 @@
|
|
|
3854
3889
|
"switchStates",
|
|
3855
3890
|
"switchVisualArchetypes",
|
|
3856
3891
|
"tableContract",
|
|
3892
|
+
"tableSizeAliases",
|
|
3857
3893
|
"tableSizes",
|
|
3858
3894
|
"tableSlots",
|
|
3859
3895
|
"tableStates",
|
|
@@ -3864,6 +3900,7 @@
|
|
|
3864
3900
|
"tabsContract",
|
|
3865
3901
|
"tabsOrientations",
|
|
3866
3902
|
"tabsPattern",
|
|
3903
|
+
"tabsSizeAliases",
|
|
3867
3904
|
"tabsSizes",
|
|
3868
3905
|
"tabsSlots",
|
|
3869
3906
|
"tabsStates",
|
|
@@ -3892,12 +3929,14 @@
|
|
|
3892
3929
|
"toggleGroupOrientations",
|
|
3893
3930
|
"toggleGroupSelectionModes",
|
|
3894
3931
|
"toggleGroupSlots",
|
|
3932
|
+
"toggleGroupStateAliases",
|
|
3895
3933
|
"toggleGroupStates",
|
|
3896
3934
|
"toggleGroupTokenSlots",
|
|
3897
3935
|
"toggleGroupVariants",
|
|
3898
3936
|
"toggleGroupVisualArchetypes",
|
|
3899
3937
|
"toggleSizes",
|
|
3900
3938
|
"toggleSlots",
|
|
3939
|
+
"toggleStateAliases",
|
|
3901
3940
|
"toggleStates",
|
|
3902
3941
|
"toggleTokenSlots",
|
|
3903
3942
|
"toggleTones",
|
|
@@ -3956,6 +3995,7 @@
|
|
|
3956
3995
|
"AlertTitle",
|
|
3957
3996
|
"Amount",
|
|
3958
3997
|
"AnimatedCheck",
|
|
3998
|
+
"ArtPlate",
|
|
3959
3999
|
"Atom63Theme",
|
|
3960
4000
|
"Autocomplete",
|
|
3961
4001
|
"AutocompleteClear",
|
|
@@ -4175,6 +4215,11 @@
|
|
|
4175
4215
|
"Kbd",
|
|
4176
4216
|
"KbdGroup",
|
|
4177
4217
|
"Label",
|
|
4218
|
+
"LayeredScene",
|
|
4219
|
+
"LayeredSceneContent",
|
|
4220
|
+
"LayeredSceneForeground",
|
|
4221
|
+
"LayeredScenePlate",
|
|
4222
|
+
"LayeredSceneStage",
|
|
4178
4223
|
"LoadMoreTrigger",
|
|
4179
4224
|
"Marquee",
|
|
4180
4225
|
"Menubar",
|
|
@@ -4612,7 +4657,7 @@
|
|
|
4612
4657
|
"StatCard": "One metric with a label and an optional change. `trend` colours the change: `up` and `down` use status colours, `neutral` stays muted.\n\n```tsx\n<StatCard change=\"+1 this quarter\" label=\"Themes\" trend=\"up\" value=\"4\" />\n```\n\nProps of `StatCard`:\n\n- `label`: `string` (required). Small muted caption above the value.\n- `value`: `ReactNode` (required). The prominent metric.\n- `change`: `ReactNode`. Optional secondary change indicator, colored by `trend`.\n- `className`: `string`\n- `trend`: `'neutral' | 'up' | 'down'` (default `'neutral'`). Semantic direction of `change`; drives the token color.",
|
|
4613
4658
|
"StatGrid": "A responsive grid of `StatCard`s.\n\n```tsx\n<StatGrid>\n <StatCard label=\"Blocks\" value=\"30\" />\n <StatCard change=\"-5\" label=\"Open issues\" trend=\"down\" value=\"3\" />\n <StatCard label=\"Themes\" value=\"4\" />\n</StatGrid>\n```\n\nProps of `StatGrid`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`",
|
|
4614
4659
|
"Steps": "Numbered steps for a procedure. Numbers and the connecting line come from document order; do not number titles by hand.\n\n```tsx\n<Steps>\n <Steps.Step title=\"Install the package\">Run pnpm add @atom63/mdx.</Steps.Step>\n <Steps.Step title=\"Load the styles\">Import @atom63/mdx/styles/a63.css once.</Steps.Step>\n <Steps.Step title=\"Wrap the page\">Render it inside MDXContentProvider.</Steps.Step>\n</Steps>\n```\n\nProps of `Steps`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n\nProps of `Steps.Step`:\n\n- `children`: `ReactNode` (required)\n- `title`: `ReactNode` (required). Bold heading for the step.\n- `className`: `string`\n- `index`: `number` (default `1`). Injected by `Steps` — the 1-indexed position in document order.",
|
|
4615
|
-
"Tabs": "Tabbed panels in prose, such as the same step for npm and pnpm. It is the `Tabs` component of `@atom63/ui-react` with MDX spacing, and takes its props: `atom63 component tabs`.\n\n```tsx\n<Tabs defaultValue=\"pnpm\">\n <Tabs.List>\n <Tabs.Tab value=\"pnpm\">pnpm</Tabs.Tab>\n <Tabs.Tab value=\"npm\">npm</Tabs.Tab>\n </Tabs.List>\n <Tabs.Panel value=\"pnpm\">pnpm add @atom63/mdx</Tabs.Panel>\n <Tabs.Panel value=\"npm\">npm install @atom63/mdx</Tabs.Panel>\n</Tabs>\n```\n\n`Tabs` adds no props of its own.\n\nProps of `Tabs.List`:\n\n- `size`: `'sm' | 'default' | 'lg' | 'xs'` (default `tabsContract.defaultSize`)
|
|
4660
|
+
"Tabs": "Tabbed panels in prose, such as the same step for npm and pnpm. It is the `Tabs` component of `@atom63/ui-react` with MDX spacing, and takes its props: `atom63 component tabs`.\n\n```tsx\n<Tabs defaultValue=\"pnpm\">\n <Tabs.List>\n <Tabs.Tab value=\"pnpm\">pnpm</Tabs.Tab>\n <Tabs.Tab value=\"npm\">npm</Tabs.Tab>\n </Tabs.List>\n <Tabs.Panel value=\"pnpm\">pnpm add @atom63/mdx</Tabs.Panel>\n <Tabs.Panel value=\"npm\">npm install @atom63/mdx</Tabs.Panel>\n</Tabs>\n```\n\n`Tabs` adds no props of its own.\n\nProps of `Tabs.List`:\n\n- `size`: `'sm' | 'default' | 'lg' | 'xs' | 'md'` (default `tabsContract.defaultSize`). `'default'` is a deprecated alias of `'md'`.\n- `variant`: `'default' | 'underline' | 'attached'` (default `tabsContract.defaultVariant`)\n\nProps of `Tabs.Panel`:\n\n- `animated`: `boolean` (default `false`)\n\nProps of `Tabs.Tab`:\n\n- `size`: `'sm' | 'default' | 'lg' | 'xs' | 'md'`. `'default'` is a deprecated alias of `'md'`.",
|
|
4616
4661
|
"Timeline": "Dated events in order: a release history, a project log. Each item has a date, a title and a short body.\n\n```tsx\n<Timeline>\n <Timeline.Item date=\"2025\" title=\"Primitive layer\">Colour ramps, type scale, spacing.</Timeline.Item>\n <Timeline.Item date=\"2026\" title=\"Semantic layer\">Tokens map primitives to intent.</Timeline.Item>\n</Timeline>\n```\n\nProps of `Timeline`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n\nProps of `Timeline.Item`:\n\n- `children`: `ReactNode` (required)\n- `date`: `ReactNode` (required). Date or label shown in the left column (e.g. a year).\n- `title`: `ReactNode` (required). Bold heading for the event.\n- `className`: `string`",
|
|
4617
4662
|
"VideoBlock": "A video figure with native controls and an optional caption. A video with speech needs a caption track (`trackSrc`); mark a purely visual loop `captionPolicy=\"decorative\"` instead. With `autoPlay` and no `controls`, it draws its own pause button and stays still under reduced motion.\n\n```mdx\n<VideoBlock src=\"/media/talk.mp4\" title=\"Design tokens talk\" trackSrc=\"/media/talk.en.vtt\" />\n\n<VideoBlock\n autoPlay\n captionPolicy=\"decorative\"\n controls={false}\n loop\n muted\n src=\"/media/loop.mp4\"\n title=\"Theme switching loop\"\n/>\n```\n\nProps of `VideoBlock`:\n\n- `src`: `string` (required)\n- `title`: `string` (required)\n- `autoPlay`: `boolean` (default `false`). Start playing, muted, on load. Ignored when the reader prefers reduced motion. Without `controls`, a pause and play toggle sits over the video.\n- `caption`: `string`\n- `captionPolicy`: `'required' | 'decorative'`. Video has spoken or meaningful audio and must provide captions. Video is decorative or purely visual; no caption track is required.\n- `className`: `string`\n- `controls`: `boolean` (default `true`)\n- `fit`: `'contain' | 'cover'` (default `'contain'`)\n- `loop`: `boolean` (default `false`)\n- `muted`: `boolean` (default `false`)\n- `pauseLabel`: `string` (default `'Pause video'`). Name of the toggle while the video plays. Defaults to \"Pause video\".\n- `playLabel`: `string` (default `'Play video'`). Name of the toggle while the video is paused. Defaults to \"Play video\".\n- `showCaption`: `boolean` (default `false`)\n- `spacing`: `'none' | 'sm' | 'default' | 'lg'` (default `'default'`)\n- `trackLabel`: `string`. Name of the caption track in the player's caption menu. Defaults to the track language's own name, such as \"English\" or \"Deutsch\".\n- `trackLang`: `string` (default `'en'`). BCP 47 language of the caption track (`srclang`). Defaults to `en`.\n- `trackSrc`: `string`"
|
|
4618
4663
|
}
|
|
@@ -4933,7 +4978,7 @@
|
|
|
4933
4978
|
"rest": "Resting appearance.",
|
|
4934
4979
|
"hover": "Pointer over an enabled button.",
|
|
4935
4980
|
"pressed": "While pressed, or held with data-pressed.",
|
|
4936
|
-
"
|
|
4981
|
+
"focus-visible": "Keyboard focus only; drawn as an outline.",
|
|
4937
4982
|
"disabled": "A neutral grey fill and muted label; ghost, link, overlay and glass fade only the label.",
|
|
4938
4983
|
"loading": "Label keeps its width; the spinner overlays it."
|
|
4939
4984
|
}
|
|
@@ -5032,18 +5077,20 @@
|
|
|
5032
5077
|
},
|
|
5033
5078
|
"exportName": "buttonContract",
|
|
5034
5079
|
"slots": [
|
|
5035
|
-
"
|
|
5036
|
-
"label",
|
|
5037
|
-
"
|
|
5038
|
-
"
|
|
5039
|
-
"indicator"
|
|
5080
|
+
"button",
|
|
5081
|
+
"button-label",
|
|
5082
|
+
"button-spinner",
|
|
5083
|
+
"button-indicator"
|
|
5040
5084
|
],
|
|
5041
5085
|
"source": "packages/ui-foundation/contracts/components/button.json",
|
|
5086
|
+
"stateAliases": {
|
|
5087
|
+
"focusVisible": "focus-visible"
|
|
5088
|
+
},
|
|
5042
5089
|
"states": [
|
|
5043
5090
|
"rest",
|
|
5044
5091
|
"hover",
|
|
5045
5092
|
"pressed",
|
|
5046
|
-
"
|
|
5093
|
+
"focus-visible",
|
|
5047
5094
|
"disabled",
|
|
5048
5095
|
"loading"
|
|
5049
5096
|
],
|
|
@@ -5081,7 +5128,7 @@
|
|
|
5081
5128
|
],
|
|
5082
5129
|
"importPath": "@atom63/ui-react",
|
|
5083
5130
|
"label": "Button",
|
|
5084
|
-
"markdown": "# Button\n\nButton is the shared action primitive and defaults to safe non-submit behavior.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it for an in-place action such as submitting, saving, confirming or changing state; use a link when the outcome is navigation. Choose emphasis from the action hierarchy rather than making every action primary, and give icon-only buttons an accessible name. Draw secondary actions in toolbars, rows and card headers as variant=\"ghost\" with tone=\"muted\". shape=\"round\" makes icon buttons circles (a play button) and labelled buttons pills.\n- Keep the semantic action or link element intact when composing custom content.\n- Make loading, disabled, and destructive behavior explicit in the product flow.\n\n## Variants, sizes and states\n\n| Axis | Value | Guidance |\n| --- | --- | --- |\n| Variant | `primary` | The one primary action per view, when the product's main action is in its brand colour. |\n| Variant | `default` | Neutral solid: high emphasis without the brand colour (a white play button on dark, a black Pay button). |\n| Variant | `secondary` | Muted neutral action for supporting tasks. |\n| Variant | `raised` | Light fill, soft shadow, no border; with shape=\"round\", the floating button over a map or a light photo. |\n| Variant | `outline` | Lower-emphasis alternative (Duplicate). |\n| Variant | `dashed` | Add or filter affordance drawn as a dashed pill (+ Status). |\n| Variant | `ghost` | Lowest emphasis; toolbars and dismissals, with tone=\"muted\" for quiet secondary actions. |\n| Variant | `link` | Inline action styled as text; navigation should use a real link. |\n| Variant | `destructive` | Only when the outcome destroys data. |\n| Variant | `destructive-outline` | Quieter destructive action, beside a safe default. |\n| Variant | `overlay` | Forced contrast over media and imagery; the floating button over dark media. |\n| Variant | `glass` | Compatibility alias of overlay; new work uses overlay. |\n| Size | `xs` | Dense UI. |\n| Size | `sm` | Compact rows and toolbars. |\n| Size | `md` | Default. |\n| Size | `lg` | Prominent calls to action. |\n| Size | `xl` | Hero and marketing surfaces. |\n| State | `rest` | Resting appearance. |\n| State | `hover` | Pointer over an enabled button. |\n| State | `pressed` | While pressed, or held with data-pressed. |\n| State | `
|
|
5131
|
+
"markdown": "# Button\n\nButton is the shared action primitive and defaults to safe non-submit behavior.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it for an in-place action such as submitting, saving, confirming or changing state; use a link when the outcome is navigation. Choose emphasis from the action hierarchy rather than making every action primary, and give icon-only buttons an accessible name. Draw secondary actions in toolbars, rows and card headers as variant=\"ghost\" with tone=\"muted\". shape=\"round\" makes icon buttons circles (a play button) and labelled buttons pills.\n- Keep the semantic action or link element intact when composing custom content.\n- Make loading, disabled, and destructive behavior explicit in the product flow.\n\n## Variants, sizes and states\n\n| Axis | Value | Guidance |\n| --- | --- | --- |\n| Variant | `primary` | The one primary action per view, when the product's main action is in its brand colour. |\n| Variant | `default` | Neutral solid: high emphasis without the brand colour (a white play button on dark, a black Pay button). |\n| Variant | `secondary` | Muted neutral action for supporting tasks. |\n| Variant | `raised` | Light fill, soft shadow, no border; with shape=\"round\", the floating button over a map or a light photo. |\n| Variant | `outline` | Lower-emphasis alternative (Duplicate). |\n| Variant | `dashed` | Add or filter affordance drawn as a dashed pill (+ Status). |\n| Variant | `ghost` | Lowest emphasis; toolbars and dismissals, with tone=\"muted\" for quiet secondary actions. |\n| Variant | `link` | Inline action styled as text; navigation should use a real link. |\n| Variant | `destructive` | Only when the outcome destroys data. |\n| Variant | `destructive-outline` | Quieter destructive action, beside a safe default. |\n| Variant | `overlay` | Forced contrast over media and imagery; the floating button over dark media. |\n| Variant | `glass` | Compatibility alias of overlay; new work uses overlay. |\n| Size | `xs` | Dense UI. |\n| Size | `sm` | Compact rows and toolbars. |\n| Size | `md` | Default. |\n| Size | `lg` | Prominent calls to action. |\n| Size | `xl` | Hero and marketing surfaces. |\n| State | `rest` | Resting appearance. |\n| State | `hover` | Pointer over an enabled button. |\n| State | `pressed` | While pressed, or held with data-pressed. |\n| State | `focus-visible` | Keyboard focus only; drawn as an outline. |\n| State | `disabled` | A neutral grey fill and muted label; ghost, link, overlay and glass fade only the label. |\n| State | `loading` | Label keeps its width; the spinner overlays it. |\n\n## Usage\n\n```tsx\nimport { Button } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Button`\n\n**Types:** `ButtonProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/button.json` (`buttonContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `shapes` | `default`, `round` | `default` |\n| `tones` | `neutral`, `muted` | `neutral` |\n| `variants` | `default`, `primary`, `secondary`, `raised`, `destructive`, `destructive-outline`, `outline`, `dashed`, `ghost`, `link`, `overlay`, `glass` | `default` |\n| `sizes` | `xs`, `sm`, `md`, `lg`, `xl`, `tile`, `icon-xs`, `icon-sm`, `icon`, `icon-lg`, `icon-xl` | `md` |\n\n**Deprecated aliases:** `focusVisible` → `focus-visible` (states)\n\n**Slots:** `button`, `button-label`, `button-spinner`, `button-indicator`\n\n**States:** `rest`, `hover`, `pressed`, `focus-visible`, `disabled`, `loading`\n\n**Token slots:** `button.background`, `button.foreground`, `button.border.color`, `button.border.width`, `button.radius`, `button.shadow`, `button.focusRing`, `button.height`, `button.paddingInline`, `button.gap`, `button.iconSize`, `button.motion.press`\n\n**Visual archetype:** Action controls — Momentary controls that perform an action now.\n\n### Web and iOS\n\nTrigger a user-initiated action with explicit hierarchy and feedback. Rendered by `AtomButton` in SwiftUI, with `recipe` parity.\n\n**Required states:** `rest`, `pressed`, `disabled`, `loading`\n\n**Shared outcomes:**\n\n- Action fires once\n- Loading blocks repeat activation\n- Disabled prevents activation\n\n**Accessibility outcomes:**\n\n- Exposes label\n- Announces loading\n- Disabled while loading\n\n**Platform adaptations:**\n\n- React: Uses HTML button semantics with pointer and focus-visible feedback.\n- SwiftUI: Uses SwiftUI Button with native touch and keyboard activation.\n- SwiftUI: The round shape is a capsule: a circle at the icon size, a pill with a label.\n- SwiftUI: The raised emphasis uses the panel fill and a soft shadow with no border; muted tone only quiets ghost labels.\n\n## Related components\n\n- [Button Group](/components/component-button-group)\n- [Toggle](/components/component-toggle)\n- [Copy Button](/components/component-copy-button)\n",
|
|
5085
5132
|
"related": [
|
|
5086
5133
|
"button-group",
|
|
5087
5134
|
"toggle",
|
|
@@ -5150,7 +5197,7 @@
|
|
|
5150
5197
|
"values": [
|
|
5151
5198
|
"xs",
|
|
5152
5199
|
"sm",
|
|
5153
|
-
"
|
|
5200
|
+
"md",
|
|
5154
5201
|
"lg",
|
|
5155
5202
|
"xl",
|
|
5156
5203
|
"icon-xs",
|
|
@@ -5159,7 +5206,10 @@
|
|
|
5159
5206
|
"icon-lg",
|
|
5160
5207
|
"icon-xl"
|
|
5161
5208
|
],
|
|
5162
|
-
"
|
|
5209
|
+
"deprecatedAliases": {
|
|
5210
|
+
"default": "md"
|
|
5211
|
+
},
|
|
5212
|
+
"default": "md"
|
|
5163
5213
|
}
|
|
5164
5214
|
],
|
|
5165
5215
|
"exportName": "buttonGroupContract",
|
|
@@ -5199,7 +5249,7 @@
|
|
|
5199
5249
|
],
|
|
5200
5250
|
"importPath": "@atom63/ui-react",
|
|
5201
5251
|
"label": "Button Group",
|
|
5202
|
-
"markdown": "# Button Group\n\nButton Group welds adjacent controls into one visual run without changing their semantics.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use Toggle Group or Segmented Control when the group itself represents persistent selection.\n- Keep the semantic action or link element intact when composing custom content.\n- Make loading, disabled, and destructive behavior explicit in the product flow.\n\n## Usage\n\n```tsx\nimport { ButtonGroup, ButtonGroupText, ButtonGroupSeparator } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `ButtonGroup`, `ButtonGroupProvider`, `ButtonGroupSeparator`, `ButtonGroupText`, `useButtonGroupContext`\n\n**Types:** `ButtonGroupProps`, `ButtonGroupSeparatorProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/button-group.json` (`buttonGroupContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `orientations` | `horizontal`, `vertical` | `horizontal` |\n| `sizes` | `xs`, `sm`, `
|
|
5252
|
+
"markdown": "# Button Group\n\nButton Group welds adjacent controls into one visual run without changing their semantics.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use Toggle Group or Segmented Control when the group itself represents persistent selection.\n- Keep the semantic action or link element intact when composing custom content.\n- Make loading, disabled, and destructive behavior explicit in the product flow.\n\n## Usage\n\n```tsx\nimport { ButtonGroup, ButtonGroupText, ButtonGroupSeparator } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `ButtonGroup`, `ButtonGroupProvider`, `ButtonGroupSeparator`, `ButtonGroupText`, `useButtonGroupContext`\n\n**Types:** `ButtonGroupProps`, `ButtonGroupSeparatorProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/button-group.json` (`buttonGroupContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `orientations` | `horizontal`, `vertical` | `horizontal` |\n| `sizes` | `xs`, `sm`, `md`, `lg`, `xl`, `icon-xs`, `icon-sm`, `icon`, `icon-lg`, `icon-xl` | `md` |\n\n**Deprecated aliases:** `default` → `md` (sizes)\n\n**Slots:** `button-group`, `button-group-text`, `button-group-separator`\n\n**States:** `rest`, `focus-within`\n\n**Visual archetype:** Action controls — Momentary controls that perform an action now.; Segmented selection — One-of-many peer selections presented as a shared track or grouped row.\n\n## Related components\n\n- [Button](/components/component-button)\n- [Toggle Group](/components/component-toggle-group)\n- [Segmented Control](/components/component-segmented-control)\n",
|
|
5203
5253
|
"related": [
|
|
5204
5254
|
"button",
|
|
5205
5255
|
"toggle-group",
|
|
@@ -5221,7 +5271,7 @@
|
|
|
5221
5271
|
"Endpoints",
|
|
5222
5272
|
"ContractMetadata"
|
|
5223
5273
|
],
|
|
5224
|
-
"source": "import { buttonGroupContract, themes } from '@atom63/ui-foundation'\nimport {\n Button,\n ButtonGroup,\n ButtonGroupSeparator,\n ButtonGroupText,\n Input,\n UIProvider,\n} from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\nconst meta = {\n title: 'UI React/ButtonGroup',\n component: ButtonGroup,\n} satisfies Meta<typeof ButtonGroup>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nexport const Playground: Story = {\n render: () => (\n <ButtonGroup>\n <Button variant=\"secondary\">Left</Button>\n <Button variant=\"secondary\">Middle</Button>\n <Button variant=\"secondary\">Right</Button>\n </ButtonGroup>\n ),\n}\n\nexport const Vertical: Story = {\n render: () => (\n <ButtonGroup orientation=\"vertical\">\n <Button variant=\"secondary\">Top</Button>\n <Button variant=\"secondary\">Middle</Button>\n <Button variant=\"secondary\">Bottom</Button>\n </ButtonGroup>\n ),\n}\n\n/* A non-interactive text prefix welded to an action. */\nexport const WithText: Story = {\n render: () => (\n <ButtonGroup>\n <ButtonGroupText>https://</ButtonGroupText>\n <Button variant=\"secondary\">Copy</Button>\n </ButtonGroup>\n ),\n}\n\n/* A separator dividing two runs of actions. */\nexport const WithSeparator: Story = {\n render: () => (\n <ButtonGroup>\n <Button variant=\"secondary\">Cut</Button>\n <Button variant=\"secondary\">Copy</Button>\n <ButtonGroupSeparator />\n <Button variant=\"secondary\">Paste</Button>\n </ButtonGroup>\n ),\n}\n\nexport const Sizes: Story = {\n render: () => (\n <div style={{ alignItems: 'flex-start', display: 'grid', gap: 12 }}>\n {(['xs', 'sm', '
|
|
5274
|
+
"source": "import { buttonGroupContract, themes } from '@atom63/ui-foundation'\nimport {\n Button,\n ButtonGroup,\n ButtonGroupSeparator,\n ButtonGroupText,\n Input,\n UIProvider,\n} from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\nconst meta = {\n title: 'UI React/ButtonGroup',\n component: ButtonGroup,\n} satisfies Meta<typeof ButtonGroup>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nexport const Playground: Story = {\n render: () => (\n <ButtonGroup>\n <Button variant=\"secondary\">Left</Button>\n <Button variant=\"secondary\">Middle</Button>\n <Button variant=\"secondary\">Right</Button>\n </ButtonGroup>\n ),\n}\n\nexport const Vertical: Story = {\n render: () => (\n <ButtonGroup orientation=\"vertical\">\n <Button variant=\"secondary\">Top</Button>\n <Button variant=\"secondary\">Middle</Button>\n <Button variant=\"secondary\">Bottom</Button>\n </ButtonGroup>\n ),\n}\n\n/* A non-interactive text prefix welded to an action. */\nexport const WithText: Story = {\n render: () => (\n <ButtonGroup>\n <ButtonGroupText>https://</ButtonGroupText>\n <Button variant=\"secondary\">Copy</Button>\n </ButtonGroup>\n ),\n}\n\n/* A separator dividing two runs of actions. */\nexport const WithSeparator: Story = {\n render: () => (\n <ButtonGroup>\n <Button variant=\"secondary\">Cut</Button>\n <Button variant=\"secondary\">Copy</Button>\n <ButtonGroupSeparator />\n <Button variant=\"secondary\">Paste</Button>\n </ButtonGroup>\n ),\n}\n\nexport const Sizes: Story = {\n render: () => (\n <div style={{ alignItems: 'flex-start', display: 'grid', gap: 12 }}>\n {(['xs', 'sm', 'md', 'lg', 'xl'] as const).map(size => (\n <ButtonGroup key={size} size={size}>\n <Button variant=\"secondary\">One</Button>\n <Button variant=\"secondary\">Two</Button>\n <Button variant=\"secondary\">Three</Button>\n </ButtonGroup>\n ))}\n </div>\n ),\n}\n\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={`${theme}-${mode}`} mode={mode} theme={theme}>\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: '0.75rem',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 96 }}>\n {theme} / {mode}\n </span>\n <ButtonGroup>\n <Button type=\"button\" variant=\"secondary\">\n Cut\n </Button>\n <Button type=\"button\" variant=\"secondary\">\n Copy\n </Button>\n <Button type=\"button\" variant=\"secondary\">\n Paste\n </Button>\n </ButtonGroup>\n <ButtonGroup size=\"icon-sm\">\n <Button aria-pressed type=\"button\" variant=\"ghost\">\n On\n </Button>\n <Button type=\"button\" variant=\"ghost\">\n Off\n </Button>\n <Button type=\"button\" variant=\"ghost\">\n Off\n </Button>\n </ButtonGroup>\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\n/* Height parity — a group sits next to an Input at the same size; both resolve\n the same --a63-control-height ramp x density, so their heights line up. */\nexport const WithInput: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 16 }}>\n {(['md', 'sm', 'lg'] as const).map(size => (\n <div key={size} style={{ display: 'flex', gap: 8, alignItems: 'center' }}>\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 56 }}>\n {size}\n </span>\n <Input\n aria-label=\"Example text field\"\n placeholder=\"Search…\"\n size={size}\n style={{ width: 180 }}\n />\n <ButtonGroup size={size}>\n <Button variant=\"secondary\">Cut</Button>\n <Button variant=\"secondary\">Copy</Button>\n <Button variant=\"secondary\">Paste</Button>\n </ButtonGroup>\n </div>\n ))}\n </div>\n ),\n}\n\n/* The same welded action run reviewed against target host contexts. */\nexport const Endpoints: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {[\n {\n label: 'Web',\n props: { density: 'comfortable', designLanguage: 'web', input: 'pointer' } as const,\n },\n {\n label: 'iOS touch',\n props: { density: 'comfortable', designLanguage: 'ios', input: 'touch' } as const,\n },\n {\n label: 'Compact extension',\n props: {\n density: 'compact',\n designLanguage: 'web',\n input: 'pointer',\n surface: 'n2',\n } as const,\n },\n ].map(endpoint => (\n <UIProvider key={endpoint.label} {...endpoint.props}>\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 112 }}>\n {endpoint.label}\n </span>\n <ButtonGroup size={endpoint.label === 'Compact extension' ? 'sm' : 'md'}>\n <Button variant=\"secondary\">Cut</Button>\n <Button variant=\"secondary\">Copy</Button>\n <Button variant=\"secondary\">Paste</Button>\n </ButtonGroup>\n <ButtonGroup size={endpoint.label === 'Compact extension' ? 'sm' : 'md'}>\n <Button variant=\"ghost\">Bold</Button>\n <Button variant=\"ghost\">Italic</Button>\n <Button variant=\"ghost\">Under</Button>\n </ButtonGroup>\n </div>\n </UIProvider>\n ))}\n </div>\n ),\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(buttonGroupContract, null, 2)}\n </pre>\n ),\n}\n"
|
|
5225
5275
|
},
|
|
5226
5276
|
"summary": "Button Group welds adjacent controls into one visual run without changing their semantics.",
|
|
5227
5277
|
"usage": "Use Toggle Group or Segmented Control when the group itself represents persistent selection.",
|
|
@@ -5510,10 +5560,13 @@
|
|
|
5510
5560
|
"name": "sizes",
|
|
5511
5561
|
"values": [
|
|
5512
5562
|
"sm",
|
|
5513
|
-
"
|
|
5563
|
+
"md",
|
|
5514
5564
|
"lg"
|
|
5515
5565
|
],
|
|
5516
|
-
"
|
|
5566
|
+
"deprecatedAliases": {
|
|
5567
|
+
"default": "md"
|
|
5568
|
+
},
|
|
5569
|
+
"default": "md"
|
|
5517
5570
|
}
|
|
5518
5571
|
],
|
|
5519
5572
|
"exportName": "autocompleteContract",
|
|
@@ -5587,7 +5640,7 @@
|
|
|
5587
5640
|
],
|
|
5588
5641
|
"importPath": "@atom63/ui-react",
|
|
5589
5642
|
"label": "Autocomplete",
|
|
5590
|
-
"markdown": "# Autocomplete\n\nAutocomplete combines text entry with a filtered, keyboard-navigable collection.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it when typing should filter available values; use Select when scanning the list is enough.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Usage\n\n```tsx\nimport { Autocomplete, AutocompleteInput, AutocompletePopup, AutocompleteItem } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Autocomplete`, `AutocompleteClear`, `AutocompleteCollection`, `AutocompleteEmpty`, `AutocompleteGroup`, `AutocompleteGroupLabel`, `AutocompleteInput`, `AutocompleteItem`, `AutocompleteList`, `AutocompletePopup`, `AutocompletePrimitive`, `AutocompleteRow`, `AutocompleteSeparator`, `AutocompleteStatus`, `AutocompleteTrigger`, `AutocompleteValue`, `useAutocompleteFilter`\n\n**Types:** `AutocompleteInputProps`, `AutocompletePopupProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/autocomplete.json` (`autocompleteContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `sizes` | `sm`, `
|
|
5643
|
+
"markdown": "# Autocomplete\n\nAutocomplete combines text entry with a filtered, keyboard-navigable collection.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it when typing should filter available values; use Select when scanning the list is enough.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Usage\n\n```tsx\nimport { Autocomplete, AutocompleteInput, AutocompletePopup, AutocompleteItem } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Autocomplete`, `AutocompleteClear`, `AutocompleteCollection`, `AutocompleteEmpty`, `AutocompleteGroup`, `AutocompleteGroupLabel`, `AutocompleteInput`, `AutocompleteItem`, `AutocompleteList`, `AutocompletePopup`, `AutocompletePrimitive`, `AutocompleteRow`, `AutocompleteSeparator`, `AutocompleteStatus`, `AutocompleteTrigger`, `AutocompleteValue`, `useAutocompleteFilter`\n\n**Types:** `AutocompleteInputProps`, `AutocompletePopupProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/autocomplete.json` (`autocompleteContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `sizes` | `sm`, `md`, `lg` | `md` |\n\n**Deprecated aliases:** `default` → `md` (sizes)\n\n**Slots:** `autocomplete-input-group`, `autocomplete-start-addon`, `autocomplete-input`, `autocomplete-trigger`, `autocomplete-icon`, `autocomplete-clear`, `autocomplete-positioner`, `autocomplete-surface`, `autocomplete-popup`, `autocomplete-list`, `autocomplete-item`, `autocomplete-separator`, `autocomplete-group`, `autocomplete-group-label`, `autocomplete-empty`, `autocomplete-row`, `autocomplete-value`, `autocomplete-status`, `autocomplete-collection`\n\n**States:** `closed`, `open`, `highlighted`, `hover`, `disabled`, `empty`, `loading`, `invalid`\n\n**Visual archetype:** Field controls — Editable or field-like data-entry surfaces.; Triggers — Controls whose primary job is to open another surface.; Overlay surfaces — Floating material above the page or current surface.; Menus and option lists — Dense action or selection rows inside a floating or embedded list.\n\n## Related components\n\n- [Input](/components/component-input)\n- [Command](/components/component-command)\n- [Select](/components/component-select)\n",
|
|
5591
5644
|
"related": [
|
|
5592
5645
|
"input",
|
|
5593
5646
|
"command",
|
|
@@ -5611,7 +5664,7 @@
|
|
|
5611
5664
|
"Endpoints",
|
|
5612
5665
|
"ContractMetadata"
|
|
5613
5666
|
],
|
|
5614
|
-
"source": "import { autocompleteContract, themes } from '@atom63/ui-foundation'\nimport {\n Autocomplete,\n AutocompleteEmpty,\n AutocompleteGroup,\n AutocompleteGroupLabel,\n AutocompleteInput,\n AutocompleteItem,\n AutocompleteList,\n AutocompletePopup,\n AutocompleteSeparator,\n AutocompleteStatus,\n UIProvider,\n} from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\nconst meta = {\n title: 'UI React/Autocomplete',\n component: Autocomplete,\n decorators: [\n Story => (\n <div style={{ padding: 'clamp(12px, 8vw, 48px)', width: 'min(320px, 100%)' }}>\n <Story />\n </div>\n ),\n ],\n} satisfies Meta<typeof Autocomplete>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nconst fruits = [\n 'Apple',\n 'Apricot',\n 'Banana',\n 'Blackberry',\n 'Blueberry',\n 'Cherry',\n 'Grape',\n 'Mango',\n 'Orange',\n 'Peach',\n]\n\nconst groupedFruits = {\n Recent: ['Apple', 'Banana', 'Cherry'],\n Citrus: ['Grapefruit', 'Lemon', 'Orange'],\n Berries: ['Blackberry', 'Blueberry', 'Strawberry'],\n}\n\nfunction Demo({\n disabled,\n invalid,\n size,\n}: {\n disabled?: boolean\n invalid?: boolean\n size?: 'sm' | '
|
|
5667
|
+
"source": "import { autocompleteContract, themes } from '@atom63/ui-foundation'\nimport {\n Autocomplete,\n AutocompleteEmpty,\n AutocompleteGroup,\n AutocompleteGroupLabel,\n AutocompleteInput,\n AutocompleteItem,\n AutocompleteList,\n AutocompletePopup,\n AutocompleteSeparator,\n AutocompleteStatus,\n UIProvider,\n} from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\nconst meta = {\n title: 'UI React/Autocomplete',\n component: Autocomplete,\n decorators: [\n Story => (\n <div style={{ padding: 'clamp(12px, 8vw, 48px)', width: 'min(320px, 100%)' }}>\n <Story />\n </div>\n ),\n ],\n} satisfies Meta<typeof Autocomplete>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nconst fruits = [\n 'Apple',\n 'Apricot',\n 'Banana',\n 'Blackberry',\n 'Blueberry',\n 'Cherry',\n 'Grape',\n 'Mango',\n 'Orange',\n 'Peach',\n]\n\nconst groupedFruits = {\n Recent: ['Apple', 'Banana', 'Cherry'],\n Citrus: ['Grapefruit', 'Lemon', 'Orange'],\n Berries: ['Blackberry', 'Blueberry', 'Strawberry'],\n}\n\nfunction Demo({\n disabled,\n invalid,\n size,\n}: {\n disabled?: boolean\n invalid?: boolean\n size?: 'sm' | 'md' | 'lg' | number\n}) {\n return (\n <Autocomplete items={fruits}>\n <AutocompleteInput\n aria-label=\"Search fruit\"\n disabled={disabled}\n invalid={invalid}\n placeholder=\"Search fruit…\"\n showClear\n showTrigger\n size={size}\n />\n <AutocompletePopup>\n <AutocompleteEmpty>No fruit found.</AutocompleteEmpty>\n <AutocompleteList>\n {(fruit: string) => <AutocompleteItem key={fruit}>{fruit}</AutocompleteItem>}\n </AutocompleteList>\n </AutocompletePopup>\n </Autocomplete>\n )\n}\n\nfunction GroupedDemo({ open, size }: { open?: boolean; size?: 'sm' | 'md' | 'lg' }) {\n return (\n <Autocomplete\n autoHighlight={open ? 'always' : undefined}\n defaultOpen={open}\n items={Object.values(groupedFruits).flat()}\n >\n <AutocompleteInput placeholder=\"Search fruit…\" showClear showTrigger size={size} />\n <AutocompletePopup>\n <AutocompleteEmpty>No fruit found.</AutocompleteEmpty>\n <AutocompleteList>\n {Object.entries(groupedFruits).map(([group, values], index) => (\n <AutocompleteGroup key={group}>\n {index > 0 ? <AutocompleteSeparator /> : null}\n <AutocompleteGroupLabel>{group}</AutocompleteGroupLabel>\n {values.map(value => (\n <AutocompleteItem key={value} value={value}>\n {value}\n </AutocompleteItem>\n ))}\n </AutocompleteGroup>\n ))}\n </AutocompleteList>\n </AutocompletePopup>\n </Autocomplete>\n )\n}\n\nexport const Playground: Story = {\n render: () => <Demo />,\n}\n\n/** Open on load with the first item highlighted, so the visual and axe runs\n * capture the popup, its groups and the highlighted row. */\nexport const MenuAnatomy: Story = {\n render: () => <GroupedDemo open />,\n}\n\n/** A query with no match shows the empty message in the open popup. */\nexport const Empty: Story = {\n render: () => (\n <Autocomplete defaultOpen defaultValue=\"Kiwano\" items={fruits}>\n <AutocompleteInput aria-label=\"Search fruit\" placeholder=\"Search fruit…\" showClear />\n <AutocompletePopup>\n <AutocompleteEmpty>No fruit found.</AutocompleteEmpty>\n <AutocompleteList>\n {(fruit: string) => <AutocompleteItem key={fruit}>{fruit}</AutocompleteItem>}\n </AutocompleteList>\n </AutocompletePopup>\n </Autocomplete>\n ),\n}\n\n/** While results load, the popup shows the status line in place of the list. */\nexport const Loading: Story = {\n render: () => (\n <Autocomplete defaultOpen defaultValue=\"Ber\" items={[] as string[]}>\n <AutocompleteInput aria-label=\"Search fruit\" placeholder=\"Search fruit…\" />\n <AutocompletePopup>\n <AutocompleteStatus>Searching fruit…</AutocompleteStatus>\n <AutocompleteList>\n {(fruit: string) => <AutocompleteItem key={fruit}>{fruit}</AutocompleteItem>}\n </AutocompleteList>\n </AutocompletePopup>\n </Autocomplete>\n ),\n}\n\nexport const Disabled: Story = {\n render: () => <Demo disabled />,\n}\n\n/** `invalid` (or `aria-invalid`, which FormControl sets) draws the danger edge. */\nexport const Invalid: Story = {\n render: () => <Demo invalid />,\n}\n\n// The `size` prop on AutocompleteInput accepts named recipe sizes\n// ('sm' | 'md' | 'lg') OR a number. A numeric value is forwarded to the\n// native <input size> attribute for character-width sizing.\nexport const Sizes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 16 }}>\n <div>\n <div style={{ fontSize: 12, color: 'var(--a63-text-secondary)', marginBottom: 6 }}>sm</div>\n <Demo size=\"sm\" />\n </div>\n <div>\n <div style={{ fontSize: 12, color: 'var(--a63-text-secondary)', marginBottom: 6 }}>md</div>\n <Demo size=\"md\" />\n </div>\n <div>\n <div style={{ fontSize: 12, color: 'var(--a63-text-secondary)', marginBottom: 6 }}>lg</div>\n <Demo size=\"lg\" />\n </div>\n <div>\n <div style={{ fontSize: 12, color: 'var(--a63-text-secondary)', marginBottom: 6 }}>\n size={'{'}12{'}'} (native char-width)\n </div>\n <Demo size={12} />\n </div>\n <div>\n <div style={{ fontSize: 12, color: 'var(--a63-text-secondary)', marginBottom: 6 }}>\n size={'{'}30{'}'} (native char-width)\n </div>\n <Demo size={30} />\n </div>\n </div>\n ),\n}\n\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={`${theme}-${mode}`} mode={mode} theme={theme}>\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: '0.75rem',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 96 }}>\n {theme} / {mode}\n </span>\n <Demo />\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\nexport const RadiusSpacing: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {[\n { label: 'Rounded items', radius: 'default' },\n { label: 'Flush square items', radius: 'none' },\n ].map(example => (\n <div\n key={example.radius}\n data-a63-radius={example.radius}\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 112 }}>\n {example.label}\n </span>\n <GroupedDemo />\n </div>\n ))}\n </div>\n ),\n}\n\n/* The same autocomplete reviewed against target host contexts. */\nexport const Endpoints: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {[\n {\n label: 'Web',\n props: { density: 'comfortable', designLanguage: 'web', input: 'pointer' } as const,\n },\n {\n label: 'iOS touch',\n props: { density: 'comfortable', designLanguage: 'ios', input: 'touch' } as const,\n },\n {\n label: 'Compact extension',\n props: {\n density: 'compact',\n designLanguage: 'web',\n input: 'pointer',\n surface: 'n2',\n } as const,\n },\n ].map(endpoint => (\n <UIProvider key={endpoint.label} {...endpoint.props}>\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 112 }}>\n {endpoint.label}\n </span>\n <GroupedDemo size={endpoint.label === 'Compact extension' ? 'sm' : 'md'} />\n </div>\n </UIProvider>\n ))}\n </div>\n ),\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(autocompleteContract, null, 2)}\n </pre>\n ),\n}\n"
|
|
5615
5668
|
},
|
|
5616
5669
|
"summary": "Autocomplete combines text entry with a filtered, keyboard-navigable collection.",
|
|
5617
5670
|
"usage": "Use it when typing should filter available values; use Select when scanning the list is enough.",
|
|
@@ -6128,8 +6181,11 @@
|
|
|
6128
6181
|
"form-message"
|
|
6129
6182
|
],
|
|
6130
6183
|
"source": "packages/ui-foundation/contracts/components/form.json",
|
|
6184
|
+
"stateAliases": {
|
|
6185
|
+
"default": "rest"
|
|
6186
|
+
},
|
|
6131
6187
|
"states": [
|
|
6132
|
-
"
|
|
6188
|
+
"rest",
|
|
6133
6189
|
"invalid"
|
|
6134
6190
|
],
|
|
6135
6191
|
"tokenSlots": []
|
|
@@ -6158,7 +6214,7 @@
|
|
|
6158
6214
|
],
|
|
6159
6215
|
"importPath": "@atom63/ui-react",
|
|
6160
6216
|
"label": "Form",
|
|
6161
|
-
"markdown": "# Form\n\nForm connects React Hook Form state to shared labels, controls, descriptions, and messages.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it when React Hook Form owns validation; use Field for framework-neutral layout.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Usage\n\n```tsx\nimport { Form, FormField, FormItem, FormControl, FormMessage } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Form`, `FormControl`, `FormDescription`, `FormField`, `FormItem`, `FormLabel`, `FormMessage`, `useFormField`\n\n**Types:** None.\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/form.json` (`formContract` in `@atom63/ui-foundation`).\n\n**Slots:** `form-item`, `form-label`, `form-control`, `form-description`, `form-message`\n\n**States:** `
|
|
6217
|
+
"markdown": "# Form\n\nForm connects React Hook Form state to shared labels, controls, descriptions, and messages.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it when React Hook Form owns validation; use Field for framework-neutral layout.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Usage\n\n```tsx\nimport { Form, FormField, FormItem, FormControl, FormMessage } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Form`, `FormControl`, `FormDescription`, `FormField`, `FormItem`, `FormLabel`, `FormMessage`, `useFormField`\n\n**Types:** None.\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/form.json` (`formContract` in `@atom63/ui-foundation`).\n\n**Deprecated aliases:** `default` → `rest` (states)\n\n**Slots:** `form-item`, `form-label`, `form-control`, `form-description`, `form-message`\n\n**States:** `rest`, `invalid`\n\n**Visual archetype:** Field controls — Editable or field-like data-entry surfaces.\n\n## Related components\n\n- [Field](/components/component-field)\n- [Input](/components/component-input)\n- [Button](/components/component-button)\n",
|
|
6162
6218
|
"related": [
|
|
6163
6219
|
"field",
|
|
6164
6220
|
"input",
|
|
@@ -6360,9 +6416,12 @@
|
|
|
6360
6416
|
"input-otp-separator"
|
|
6361
6417
|
],
|
|
6362
6418
|
"source": "packages/ui-foundation/contracts/components/input-otp.json",
|
|
6419
|
+
"stateAliases": {
|
|
6420
|
+
"active": "current"
|
|
6421
|
+
},
|
|
6363
6422
|
"states": [
|
|
6364
6423
|
"rest",
|
|
6365
|
-
"
|
|
6424
|
+
"current",
|
|
6366
6425
|
"disabled",
|
|
6367
6426
|
"invalid"
|
|
6368
6427
|
],
|
|
@@ -6388,7 +6447,7 @@
|
|
|
6388
6447
|
],
|
|
6389
6448
|
"importPath": "@atom63/ui-react",
|
|
6390
6449
|
"label": "Input OTP",
|
|
6391
|
-
"markdown": "# Input OTP\n\nInput OTP composes accessible one-time-code slots over the input-otp primitive.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Label the complete code field and let the slot group express presentation, not separate inputs.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Usage\n\n```tsx\nimport { InputOTP, InputOTPGroup, InputOTPSlot, InputOTPSeparator } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `InputOTP`, `InputOTPGroup`, `InputOTPSeparator`, `InputOTPSlot`\n\n**Types:** None.\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/input-otp.json` (`inputOTPContract` in `@atom63/ui-foundation`).\n\n**Slots:** `input-otp`, `input-otp-group`, `input-otp-slot`, `input-otp-separator`\n\n**States:** `rest`, `
|
|
6450
|
+
"markdown": "# Input OTP\n\nInput OTP composes accessible one-time-code slots over the input-otp primitive.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Label the complete code field and let the slot group express presentation, not separate inputs.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Usage\n\n```tsx\nimport { InputOTP, InputOTPGroup, InputOTPSlot, InputOTPSeparator } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `InputOTP`, `InputOTPGroup`, `InputOTPSeparator`, `InputOTPSlot`\n\n**Types:** None.\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/input-otp.json` (`inputOTPContract` in `@atom63/ui-foundation`).\n\n**Deprecated aliases:** `active` → `current` (states)\n\n**Slots:** `input-otp`, `input-otp-group`, `input-otp-slot`, `input-otp-separator`\n\n**States:** `rest`, `current`, `disabled`, `invalid`\n\n**Visual archetype:** Field controls — Editable or field-like data-entry surfaces.\n\n## Related components\n\n- [Input](/components/component-input)\n- [Field](/components/component-field)\n",
|
|
6392
6451
|
"related": [
|
|
6393
6452
|
"input",
|
|
6394
6453
|
"field"
|
|
@@ -6839,7 +6898,7 @@
|
|
|
6839
6898
|
"slots": [
|
|
6840
6899
|
"search-field",
|
|
6841
6900
|
"search-field-icon",
|
|
6842
|
-
"
|
|
6901
|
+
"input",
|
|
6843
6902
|
"search-field-clear",
|
|
6844
6903
|
"search-field-end"
|
|
6845
6904
|
],
|
|
@@ -6871,7 +6930,7 @@
|
|
|
6871
6930
|
],
|
|
6872
6931
|
"importPath": "@atom63/ui-react",
|
|
6873
6932
|
"label": "Search Field",
|
|
6874
|
-
"markdown": "# Search Field\n\nSearch Field provides a clearable search input with shared keyboard and form behavior.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it for text filtering and search queries; use Autocomplete when results also select a value.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Usage\n\n```tsx\nimport { SearchField } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `SearchField`\n\n**Types:** `SearchFieldProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/search-field.json` (`searchFieldContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `default`, `filled`, `plain` | `default` |\n\n**Slots:** `search-field`, `search-field-icon`, `
|
|
6933
|
+
"markdown": "# Search Field\n\nSearch Field provides a clearable search input with shared keyboard and form behavior.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it for text filtering and search queries; use Autocomplete when results also select a value.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Usage\n\n```tsx\nimport { SearchField } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `SearchField`\n\n**Types:** `SearchFieldProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/search-field.json` (`searchFieldContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `default`, `filled`, `plain` | `default` |\n\n**Slots:** `search-field`, `search-field-icon`, `input`, `search-field-clear`, `search-field-end`\n\n**States:** `empty`, `query`, `focus`, `disabled`\n\n**Visual archetype:** Field controls — Editable or field-like data-entry surfaces.; Action controls — Momentary controls that perform an action now.\n\n### Web and iOS\n\nFind or filter relevant content by editing a query without leaving the current collection. Rendered by `searchable(text:prompt:)` in SwiftUI, with `platform-adaptive` parity.\n\n**Required states:** `empty`, `query`, `focus`, `disabled`\n\n**Shared outcomes:**\n\n- Editing updates the query\n- Clear empties the query and preserves input context\n- Submit commits the current query once\n- Disabled search prevents editing and clear\n\n**Accessibility outcomes:**\n\n- Exposes search input role and label\n- Clear action has an accessible label\n- Disabled state is exposed\n\n**Platform adaptations:**\n\n- React: Uses a labeled native search input with an explicit clear button and native form submission.\n- SwiftUI: Uses searchable so placement, cancel, clear, suggestions, keyboard, and focus presentation follow the active Apple platform.\n\n## Related components\n\n- [Input](/components/component-input)\n- [Autocomplete](/components/component-autocomplete)\n- [Command](/components/component-command)\n",
|
|
6875
6934
|
"related": [
|
|
6876
6935
|
"input",
|
|
6877
6936
|
"autocomplete",
|
|
@@ -6946,7 +7005,7 @@
|
|
|
6946
7005
|
"parity": "platform-adaptive",
|
|
6947
7006
|
"platformAdaptations": {
|
|
6948
7007
|
"react": [
|
|
6949
|
-
"Uses a
|
|
7008
|
+
"Uses radiogroup and radio semantics on a segmented track, named by aria-label or aria-labelledby, with arrow-key selection, focus-visible feedback and an optional animated selection backplate."
|
|
6950
7009
|
],
|
|
6951
7010
|
"swiftUI": [
|
|
6952
7011
|
"Uses Picker with segmented style so geometry, typography, and selection feedback remain platform-native."
|
|
@@ -7003,7 +7062,7 @@
|
|
|
7003
7062
|
],
|
|
7004
7063
|
"importPath": "@atom63/ui-react",
|
|
7005
7064
|
"label": "Segmented Control",
|
|
7006
|
-
"markdown": "# Segmented Control\n\nSegmented Control presents one active value on a shared track with a moving indicator.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it for a small set of peer choices and keep labels short enough to survive narrow widths.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Usage\n\n```tsx\nimport { SegmentedControl } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `SegmentedControl`\n\n**Types:** `SegmentedControlItem`, `SegmentedControlProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/segmented-control.json` (`segmentedControlContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `sizes` | `sm`, `md`, `lg` | `md` |\n| `tones` | `neutral`, `accent` | `neutral` |\n| `variants` | `icon`, `label` | `label` |\n\n**Slots:** `segmented-control`, `segmented-control-track`, `segmented-control-item`, `segmented-control-icon`, `segmented-control-label`, `segmented-control-indicator`\n\n**States:** `rest`, `hover`, `selected`, `disabled`, `focus-visible`\n\n**Visual archetype:** Segmented selection — One-of-many peer selections presented as a shared track or grouped row.\n\n### Web and iOS\n\nSwitch a compact local mode or view between a small set of mutually exclusive options. Rendered by `Picker(.segmented)` in SwiftUI, with `platform-adaptive` parity.\n\n**Required states:** `rest`, `selected`, `disabled`\n\n**Shared outcomes:**\n\n- One segment is selected at a time\n- Activation updates the selection once\n- Disabled segment prevents selection\n\n**Accessibility outcomes:**\n\n- Exposes each segment label\n- Exposes selected state\n- Preserves single selection semantics\n\n**Platform adaptations:**\n\n- React: Uses a
|
|
7065
|
+
"markdown": "# Segmented Control\n\nSegmented Control presents one active value on a shared track with a moving indicator.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it for a small set of peer choices and keep labels short enough to survive narrow widths.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Usage\n\n```tsx\nimport { SegmentedControl } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `SegmentedControl`\n\n**Types:** `SegmentedControlItem`, `SegmentedControlProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/segmented-control.json` (`segmentedControlContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `sizes` | `sm`, `md`, `lg` | `md` |\n| `tones` | `neutral`, `accent` | `neutral` |\n| `variants` | `icon`, `label` | `label` |\n\n**Slots:** `segmented-control`, `segmented-control-track`, `segmented-control-item`, `segmented-control-icon`, `segmented-control-label`, `segmented-control-indicator`\n\n**States:** `rest`, `hover`, `selected`, `disabled`, `focus-visible`\n\n**Visual archetype:** Segmented selection — One-of-many peer selections presented as a shared track or grouped row.\n\n### Web and iOS\n\nSwitch a compact local mode or view between a small set of mutually exclusive options. Rendered by `Picker(.segmented)` in SwiftUI, with `platform-adaptive` parity.\n\n**Required states:** `rest`, `selected`, `disabled`\n\n**Shared outcomes:**\n\n- One segment is selected at a time\n- Activation updates the selection once\n- Disabled segment prevents selection\n\n**Accessibility outcomes:**\n\n- Exposes each segment label\n- Exposes selected state\n- Preserves single selection semantics\n\n**Platform adaptations:**\n\n- React: Uses radiogroup and radio semantics on a segmented track, named by aria-label or aria-labelledby, with arrow-key selection, focus-visible feedback and an optional animated selection backplate.\n- SwiftUI: Uses Picker with segmented style so geometry, typography, and selection feedback remain platform-native.\n\n## Related components\n\n- [Toggle Group](/components/component-toggle-group)\n- [Tabs](/components/component-tabs)\n- [Radio](/components/component-radio)\n",
|
|
7007
7066
|
"related": [
|
|
7008
7067
|
"toggle-group",
|
|
7009
7068
|
"tabs",
|
|
@@ -7026,7 +7085,7 @@
|
|
|
7026
7085
|
"Endpoints",
|
|
7027
7086
|
"ContractMetadata"
|
|
7028
7087
|
],
|
|
7029
|
-
"source": "import {\n segmentedControlContract,\n segmentedControlSizes,\n segmentedControlTones,\n segmentedControlVariants,\n themes,\n} from '@atom63/ui-foundation'\nimport { SegmentedControl, UIProvider } from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\nimport { GitBranch, Grid, List } from 'lucide-react'\nimport { type ReactNode, useState } from 'react'\n\nconst ITEMS = [\n { value: 'list', label: 'List' },\n { value: 'grid', label: 'Grid' },\n { value: 'tree', label: 'Tree' },\n]\n\nconst ICON_ITEMS = [\n { value: 'list', label: 'List', icon: <List /> },\n { value: 'grid', label: 'Grid', icon: <Grid /> },\n { value: 'tree', label: 'Tree', icon: <GitBranch /> },\n]\n\nconst LONG_ITEMS = [\n { value: 'list', label: 'Project overview' },\n { value: 'activity', label: 'Recent activity' },\n { value: 'permissions', label: 'Access permissions' },\n { value: 'integrations', label: 'Connected integrations' },\n]\n\nfunction Demo({\n animateBackplate,\n items = ITEMS,\n size,\n tabClassName,\n tone,\n variant,\n}: {\n animateBackplate?: boolean\n items?: typeof ITEMS\n size?: (typeof segmentedControlSizes)[number]\n tabClassName?: string\n tone?: (typeof segmentedControlTones)[number]\n variant?: (typeof segmentedControlVariants)[number]\n}) {\n const [value, setValue] = useState(
|
|
7088
|
+
"source": "import {\n segmentedControlContract,\n segmentedControlSizes,\n segmentedControlTones,\n segmentedControlVariants,\n themes,\n} from '@atom63/ui-foundation'\nimport { SegmentedControl, UIProvider } from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\nimport { GitBranch, Grid, List } from 'lucide-react'\nimport { type ReactNode, useState } from 'react'\n\nconst ITEMS = [\n { value: 'list', label: 'List' },\n { value: 'grid', label: 'Grid' },\n { value: 'tree', label: 'Tree' },\n]\n\nconst ICON_ITEMS = [\n { value: 'list', label: 'List', icon: <List /> },\n { value: 'grid', label: 'Grid', icon: <Grid /> },\n { value: 'tree', label: 'Tree', icon: <GitBranch /> },\n]\n\nconst LONG_ITEMS = [\n { value: 'list', label: 'Project overview' },\n { value: 'activity', label: 'Recent activity' },\n { value: 'permissions', label: 'Access permissions' },\n { value: 'integrations', label: 'Connected integrations' },\n]\n\nfunction Demo({\n animateBackplate,\n initialValue = 'list',\n items = ITEMS,\n size,\n tabClassName,\n tone,\n variant,\n}: {\n animateBackplate?: boolean\n initialValue?: string\n items?: typeof ITEMS\n size?: (typeof segmentedControlSizes)[number]\n tabClassName?: string\n tone?: (typeof segmentedControlTones)[number]\n variant?: (typeof segmentedControlVariants)[number]\n}) {\n const [value, setValue] = useState(initialValue)\n return (\n <SegmentedControl\n animateBackplate={animateBackplate}\n aria-label=\"View\"\n items={items}\n onValueChange={setValue}\n size={size}\n tabClassName={tabClassName}\n tone={tone}\n value={value}\n variant={variant}\n />\n )\n}\n\nconst meta = {\n title: 'UI React/SegmentedControl',\n component: SegmentedControl,\n argTypes: {\n size: { control: 'inline-radio', options: segmentedControlSizes },\n variant: { control: 'inline-radio', options: segmentedControlVariants },\n tone: { control: 'inline-radio', options: segmentedControlTones },\n animateBackplate: { control: 'boolean' },\n },\n args: {\n size: 'md',\n tone: 'neutral',\n variant: 'label',\n animateBackplate: true,\n // Required props; every story renders its own items and state.\n items: [],\n value: '',\n onValueChange: () => {},\n },\n} satisfies Meta<typeof SegmentedControl>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\n/* A radio group named \"View\": Tab enters at the selected segment and the arrow\n keys move and select. The APG radio pattern test plays this story, which\n starts on the second segment. */\nexport const Playground: Story = {\n render: ({ animateBackplate, size, tone, variant }) => (\n <Demo\n animateBackplate={animateBackplate}\n initialValue=\"grid\"\n size={size}\n tone={tone}\n variant={variant}\n />\n ),\n}\n\n// Documents `animateBackplate` (default true) — set false to drop the indicator's\n// sliding transition — and the `tabClassName` per-segment escape hatch.\nexport const Backplate: Story = {\n render: () => (\n <div style={{ display: 'flex', gap: 16, alignItems: 'center' }}>\n <Demo animateBackplate />\n <Demo animateBackplate={false} />\n <Demo tabClassName=\"uppercase\" />\n </div>\n ),\n}\n\nexport const Sizes: Story = {\n render: () => (\n <div style={{ display: 'flex', gap: 16, alignItems: 'center' }}>\n {segmentedControlSizes.map(size => (\n <Demo key={size} size={size} />\n ))}\n </div>\n ),\n}\n\nexport const MobileOverflow: Story = {\n tags: ['!manifest'],\n render: () => (\n <UIProvider input=\"touch\">\n <div style={{ maxWidth: 320, width: 'min(100%, calc(100vw - 2rem))' }}>\n <Demo items={LONG_ITEMS} />\n </div>\n </UIProvider>\n ),\n}\n\nexport const Variants: Story = {\n render: () => (\n <div style={{ display: 'flex', gap: 16, alignItems: 'center' }}>\n <Demo variant=\"label\" />\n <Demo items={ICON_ITEMS} variant=\"icon\" />\n </div>\n ),\n}\n\nexport const Tones: Story = {\n render: () => (\n <div style={{ display: 'flex', gap: 16, alignItems: 'center' }}>\n <Demo tone=\"neutral\" />\n <Demo tone=\"accent\" />\n </div>\n ),\n}\n\n/* Captured with forced colors on (Windows High Contrast): the selected segment\n of both tones takes the system selection colours. */\nexport const ForcedColors: Story = {\n render: () => (\n <div style={{ display: 'flex', gap: 16, alignItems: 'center' }}>\n <Demo tone=\"neutral\" />\n <Demo tone=\"accent\" />\n <Demo items={ICON_ITEMS} variant=\"icon\" />\n </div>\n ),\n}\n\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={`${theme}-${mode}`} mode={mode} theme={theme}>\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 96 }}>\n {theme} / {mode}\n </span>\n <Demo />\n <Demo tone=\"accent\" />\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\nfunction PreviewCard({ children, label }: { children: ReactNode; label: string }) {\n return (\n <div\n style={{\n background: 'var(--a63-surface-panel)',\n border: '1px solid var(--a63-border-subtle)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'grid',\n gap: '0.875rem',\n padding: '1rem',\n }}\n >\n <div\n style={{\n color: 'var(--a63-text-secondary)',\n fontFamily: 'Geist Mono, monospace',\n fontSize: '0.75rem',\n }}\n >\n {label}\n </div>\n {children}\n </div>\n )\n}\n\nexport const Endpoints: Story = {\n render: () => (\n <div\n style={{\n display: 'grid',\n gap: '1rem',\n gridTemplateColumns: 'repeat(auto-fit, minmax(15rem, 1fr))',\n }}\n >\n <UIProvider designLanguage=\"web\" input=\"pointer\" mode=\"light\">\n <PreviewCard label=\"web / light / pointer\">\n <Demo />\n </PreviewCard>\n </UIProvider>\n <UIProvider designLanguage=\"web\" input=\"pointer\" mode=\"dark\">\n <PreviewCard label=\"web / dark / pointer\">\n <Demo />\n </PreviewCard>\n </UIProvider>\n <UIProvider designLanguage=\"ios\" input=\"touch\" mode=\"light\">\n <PreviewCard label=\"ios / light / touch\">\n <Demo />\n </PreviewCard>\n </UIProvider>\n <UIProvider designLanguage=\"ios\" input=\"touch\" mode=\"dark\">\n <PreviewCard label=\"ios / dark / touch\">\n <Demo />\n </PreviewCard>\n </UIProvider>\n <UIProvider density=\"compact\" designLanguage=\"web\" input=\"pointer\" mode=\"light\">\n <PreviewCard label=\"compact extension / light\">\n <Demo />\n </PreviewCard>\n </UIProvider>\n <UIProvider density=\"compact\" designLanguage=\"web\" input=\"pointer\" mode=\"dark\">\n <PreviewCard label=\"compact extension / dark\">\n <Demo />\n </PreviewCard>\n </UIProvider>\n </div>\n ),\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(segmentedControlContract, null, 2)}\n </pre>\n ),\n}\n"
|
|
7030
7089
|
},
|
|
7031
7090
|
"summary": "Segmented Control presents one active value on a shared track with a moving indicator.",
|
|
7032
7091
|
"usage": "Use it for a small set of peer choices and keep labels short enough to survive narrow widths.",
|
|
@@ -7686,6 +7745,9 @@
|
|
|
7686
7745
|
"toggle-content"
|
|
7687
7746
|
],
|
|
7688
7747
|
"source": "packages/ui-foundation/contracts/components/toggle.json",
|
|
7748
|
+
"stateAliases": {
|
|
7749
|
+
"focus": "focus-visible"
|
|
7750
|
+
},
|
|
7689
7751
|
"states": [
|
|
7690
7752
|
"off",
|
|
7691
7753
|
"on",
|
|
@@ -7693,7 +7755,7 @@
|
|
|
7693
7755
|
"hover",
|
|
7694
7756
|
"pressed",
|
|
7695
7757
|
"disabled",
|
|
7696
|
-
"focus"
|
|
7758
|
+
"focus-visible"
|
|
7697
7759
|
],
|
|
7698
7760
|
"tokenSlots": [
|
|
7699
7761
|
"toggle.background",
|
|
@@ -7730,7 +7792,7 @@
|
|
|
7730
7792
|
],
|
|
7731
7793
|
"importPath": "@atom63/ui-react",
|
|
7732
7794
|
"label": "Toggle",
|
|
7733
|
-
"markdown": "# Toggle\n\nToggle is a pressed control for one independently persistent option.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Expose pressed state with a clear label; use Button for one-shot actions.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Usage\n\n```tsx\nimport { Toggle } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Toggle`\n\n**Types:** `ToggleProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/toggle.json` (`toggleContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `sizes` | `sm`, `md`, `lg` | `md` |\n| `tones` | `neutral`, `accent`, `subtle` | `neutral` |\n\n**Slots:** `toggle`, `toggle-content`\n\n**States:** `off`, `on`, `rest`, `hover`, `pressed`, `disabled`, `focus`\n\n**Token slots:** `toggle.background`, `toggle.foreground`, `toggle.hoverBackground`, `toggle.onBackground`, `toggle.onForeground`, `toggle.primaryBackground`, `toggle.primaryForeground`, `toggle.borderWidth`, `toggle.radius`, `toggle.gloss`, `toggle.shadow`, `toggle.shadowActive`, `toggle.textShadow`\n\n**Visual archetype:** Toggle controls — Persistent on/off or pressed controls.\n\n### Web and iOS\n\nSelect or deselect a compact option without leaving the current context. Rendered by `AtomChip` in SwiftUI, with `platform-adaptive` parity.\n\n**Required states:** `off`, `on`, `disabled`\n\n**Shared outcomes:**\n\n- Selected state is visible\n- Activation toggles selection\n- Disabled prevents change\n\n**Accessibility outcomes:**\n\n- Exposes label\n- Announces selected state\n- Preserves button role\n\n**Platform adaptations:**\n\n- React: Uses a pressed-state web toggle with hover and focus-visible feedback.\n- React: The subtle tone (accent color, no fill) is web-only.\n- SwiftUI: Uses a touch-sized button-backed chip for compact filter selection.\n\n## Related components\n\n- [Toggle Group](/components/component-toggle-group)\n- [Button](/components/component-button)\n- [Checkbox](/components/component-checkbox)\n",
|
|
7795
|
+
"markdown": "# Toggle\n\nToggle is a pressed control for one independently persistent option.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Expose pressed state with a clear label; use Button for one-shot actions.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Usage\n\n```tsx\nimport { Toggle } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Toggle`\n\n**Types:** `ToggleProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/toggle.json` (`toggleContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `sizes` | `sm`, `md`, `lg` | `md` |\n| `tones` | `neutral`, `accent`, `subtle` | `neutral` |\n\n**Deprecated aliases:** `focus` → `focus-visible` (states)\n\n**Slots:** `toggle`, `toggle-content`\n\n**States:** `off`, `on`, `rest`, `hover`, `pressed`, `disabled`, `focus-visible`\n\n**Token slots:** `toggle.background`, `toggle.foreground`, `toggle.hoverBackground`, `toggle.onBackground`, `toggle.onForeground`, `toggle.primaryBackground`, `toggle.primaryForeground`, `toggle.borderWidth`, `toggle.radius`, `toggle.gloss`, `toggle.shadow`, `toggle.shadowActive`, `toggle.textShadow`\n\n**Visual archetype:** Toggle controls — Persistent on/off or pressed controls.\n\n### Web and iOS\n\nSelect or deselect a compact option without leaving the current context. Rendered by `AtomChip` in SwiftUI, with `platform-adaptive` parity.\n\n**Required states:** `off`, `on`, `disabled`\n\n**Shared outcomes:**\n\n- Selected state is visible\n- Activation toggles selection\n- Disabled prevents change\n\n**Accessibility outcomes:**\n\n- Exposes label\n- Announces selected state\n- Preserves button role\n\n**Platform adaptations:**\n\n- React: Uses a pressed-state web toggle with hover and focus-visible feedback.\n- React: The subtle tone (accent color, no fill) is web-only.\n- SwiftUI: Uses a touch-sized button-backed chip for compact filter selection.\n\n## Related components\n\n- [Toggle Group](/components/component-toggle-group)\n- [Button](/components/component-button)\n- [Checkbox](/components/component-checkbox)\n",
|
|
7734
7796
|
"related": [
|
|
7735
7797
|
"toggle-group",
|
|
7736
7798
|
"button",
|
|
@@ -7843,10 +7905,13 @@
|
|
|
7843
7905
|
"toggle-group-separator"
|
|
7844
7906
|
],
|
|
7845
7907
|
"source": "packages/ui-foundation/contracts/components/toggle-group.json",
|
|
7908
|
+
"stateAliases": {
|
|
7909
|
+
"focus": "focus-visible"
|
|
7910
|
+
},
|
|
7846
7911
|
"states": [
|
|
7847
7912
|
"rest",
|
|
7848
7913
|
"hover",
|
|
7849
|
-
"focus",
|
|
7914
|
+
"focus-visible",
|
|
7850
7915
|
"selected",
|
|
7851
7916
|
"disabled"
|
|
7852
7917
|
],
|
|
@@ -7889,7 +7954,7 @@
|
|
|
7889
7954
|
],
|
|
7890
7955
|
"importPath": "@atom63/ui-react",
|
|
7891
7956
|
"label": "Toggle Group",
|
|
7892
|
-
"markdown": "# Toggle Group\n\nToggle Group coordinates single or multiple pressed controls on a shared track.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Choose single or multiple selection deliberately and label icon-only items.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Variants, sizes and states\n\n| Axis | Value | Guidance |\n| --- | --- | --- |\n| Variant | `segmented` | One welded bar for a mode switch (Left / Center / Right). |\n| Variant | `pills` | Separate filled capsules, the selected one solid, for a prominent filter row (Playlists / Artists / Albums). |\n| Variant | `ghost` | Plain text items, only the selected one softly filled, for quiet filters in a toolbar (All / Read / Unread). |\n\n## Usage\n\n```tsx\nimport { ToggleGroup, ToggleGroupItem, ToggleGroupSeparator } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `ToggleGroup`, `ToggleGroupItem`, `ToggleGroupSeparator`\n\n**Types:** `ToggleGroupItemProps`, `ToggleGroupProps`, `ToggleGroupSeparatorProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/toggle-group.json` (`toggleGroupContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `segmented`, `pills`, `ghost` | `segmented` |\n| `orientations` | `horizontal`, `vertical` | `horizontal` |\n| `selectionModes` | `single`, `multiple` | `single` |\n\n**Slots:** `toggle-group`, `toggle-group-item`, `toggle-group-separator`\n\n**States:** `rest`, `hover`, `focus`, `selected`, `disabled`\n\n**Token slots:** `segment.gap`, `segment.radius`, `segment.background`, `segment.gloss`, `segment.trackBorder`, `segment.seam`, `segment.selectedBackground`, `segment.selectedForeground`, `segment.selectedGloss`, `segment.selectedShadow`, `segment.primaryBackground`, `segment.primaryForeground`, `segment.primaryShadow`\n\n**Visual archetype:** Toggle controls — Persistent on/off or pressed controls.; Segmented selection — One-of-many peer selections presented as a shared track or grouped row.\n\n### Web and iOS\n\nChoose one or more options from a compact peer group. Rendered by `Picker(.segmented) / AtomGhostToggleGroup` in SwiftUI, with `platform-adaptive` parity.\n\n**Required states:** `rest`, `selected`, `disabled`\n\n**Shared outcomes:**\n\n- Selection state is visible\n- Disabled options cannot change selection\n\n**Accessibility outcomes:**\n\n- Exposes selection\n- Exposes disabled state\n\n**Platform adaptations:**\n\n- React: Supports segmented, pills, and ghost recipes with horizontal or vertical layout.\n- SwiftUI: Uses Picker with segmented style for the joined segmented variant.\n- SwiftUI: Uses AtomGhostToggleGroup with AtomGhostToggleGroupItem for quiet toolbar filters; each item remains a native Button with the selected trait.\n\n## Related components\n\n- [Toggle](/components/component-toggle)\n- [Segmented Control](/components/component-segmented-control)\n- [Button Group](/components/component-button-group)\n",
|
|
7957
|
+
"markdown": "# Toggle Group\n\nToggle Group coordinates single or multiple pressed controls on a shared track.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Choose single or multiple selection deliberately and label icon-only items.\n- Pair controls with persistent labels and explain errors beside the affected field.\n- Validate focus visibility, disabled state, invalid state, and touch input together.\n\n## Variants, sizes and states\n\n| Axis | Value | Guidance |\n| --- | --- | --- |\n| Variant | `segmented` | One welded bar for a mode switch (Left / Center / Right). |\n| Variant | `pills` | Separate filled capsules, the selected one solid, for a prominent filter row (Playlists / Artists / Albums). |\n| Variant | `ghost` | Plain text items, only the selected one softly filled, for quiet filters in a toolbar (All / Read / Unread). |\n\n## Usage\n\n```tsx\nimport { ToggleGroup, ToggleGroupItem, ToggleGroupSeparator } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `ToggleGroup`, `ToggleGroupItem`, `ToggleGroupSeparator`\n\n**Types:** `ToggleGroupItemProps`, `ToggleGroupProps`, `ToggleGroupSeparatorProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/toggle-group.json` (`toggleGroupContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `segmented`, `pills`, `ghost` | `segmented` |\n| `orientations` | `horizontal`, `vertical` | `horizontal` |\n| `selectionModes` | `single`, `multiple` | `single` |\n\n**Deprecated aliases:** `focus` → `focus-visible` (states)\n\n**Slots:** `toggle-group`, `toggle-group-item`, `toggle-group-separator`\n\n**States:** `rest`, `hover`, `focus-visible`, `selected`, `disabled`\n\n**Token slots:** `segment.gap`, `segment.radius`, `segment.background`, `segment.gloss`, `segment.trackBorder`, `segment.seam`, `segment.selectedBackground`, `segment.selectedForeground`, `segment.selectedGloss`, `segment.selectedShadow`, `segment.primaryBackground`, `segment.primaryForeground`, `segment.primaryShadow`\n\n**Visual archetype:** Toggle controls — Persistent on/off or pressed controls.; Segmented selection — One-of-many peer selections presented as a shared track or grouped row.\n\n### Web and iOS\n\nChoose one or more options from a compact peer group. Rendered by `Picker(.segmented) / AtomGhostToggleGroup` in SwiftUI, with `platform-adaptive` parity.\n\n**Required states:** `rest`, `selected`, `disabled`\n\n**Shared outcomes:**\n\n- Selection state is visible\n- Disabled options cannot change selection\n\n**Accessibility outcomes:**\n\n- Exposes selection\n- Exposes disabled state\n\n**Platform adaptations:**\n\n- React: Supports segmented, pills, and ghost recipes with horizontal or vertical layout.\n- SwiftUI: Uses Picker with segmented style for the joined segmented variant.\n- SwiftUI: Uses AtomGhostToggleGroup with AtomGhostToggleGroupItem for quiet toolbar filters; each item remains a native Button with the selected trait.\n\n## Related components\n\n- [Toggle](/components/component-toggle)\n- [Segmented Control](/components/component-segmented-control)\n- [Button Group](/components/component-button-group)\n",
|
|
7893
7958
|
"related": [
|
|
7894
7959
|
"toggle",
|
|
7895
7960
|
"segmented-control",
|
|
@@ -7951,10 +8016,13 @@
|
|
|
7951
8016
|
"breadcrumb-ellipsis"
|
|
7952
8017
|
],
|
|
7953
8018
|
"source": "packages/ui-foundation/contracts/components/breadcrumb.json",
|
|
8019
|
+
"stateAliases": {
|
|
8020
|
+
"focus": "focus-visible"
|
|
8021
|
+
},
|
|
7954
8022
|
"states": [
|
|
7955
8023
|
"rest",
|
|
7956
8024
|
"hover",
|
|
7957
|
-
"focus",
|
|
8025
|
+
"focus-visible",
|
|
7958
8026
|
"current"
|
|
7959
8027
|
],
|
|
7960
8028
|
"tokenSlots": []
|
|
@@ -7984,7 +8052,7 @@
|
|
|
7984
8052
|
],
|
|
7985
8053
|
"importPath": "@atom63/ui-react",
|
|
7986
8054
|
"label": "Breadcrumb",
|
|
7987
|
-
"markdown": "# Breadcrumb\n\nBreadcrumb exposes the current page within a navigable hierarchy.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Mark the final item as the current page and collapse only intermediate levels.\n- Preserve link, menu, command, or selection semantics instead of styling generic containers.\n- Expose current location when applicable and verify alternate input paths at narrow widths.\n\n## Usage\n\n```tsx\nimport { Breadcrumb, BreadcrumbList, BreadcrumbItem, BreadcrumbLink, BreadcrumbPage } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Breadcrumb`, `BreadcrumbEllipsis`, `BreadcrumbItem`, `BreadcrumbLink`, `BreadcrumbList`, `BreadcrumbPage`, `BreadcrumbSeparator`\n\n**Types:** `BreadcrumbLinkProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/breadcrumb.json` (`breadcrumbContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `compositions` | `full`, `collapsed`, `custom-separator` | — |\n\n**Slots:** `breadcrumb`, `breadcrumb-list`, `breadcrumb-item`, `breadcrumb-link`, `breadcrumb-page`, `breadcrumb-separator`, `breadcrumb-ellipsis`\n\n**States:** `rest`, `hover`, `focus`, `current`\n\n## Related components\n\n- [Pagination](/components/component-pagination)\n- [Navigation Menu](/components/component-navigation-menu)\n- [Sidebar Nav Tree](/components/component-sidebar-nav-tree)\n",
|
|
8055
|
+
"markdown": "# Breadcrumb\n\nBreadcrumb exposes the current page within a navigable hierarchy.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Mark the final item as the current page and collapse only intermediate levels.\n- Preserve link, menu, command, or selection semantics instead of styling generic containers.\n- Expose current location when applicable and verify alternate input paths at narrow widths.\n\n## Usage\n\n```tsx\nimport { Breadcrumb, BreadcrumbList, BreadcrumbItem, BreadcrumbLink, BreadcrumbPage } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Breadcrumb`, `BreadcrumbEllipsis`, `BreadcrumbItem`, `BreadcrumbLink`, `BreadcrumbList`, `BreadcrumbPage`, `BreadcrumbSeparator`\n\n**Types:** `BreadcrumbLinkProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/breadcrumb.json` (`breadcrumbContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `compositions` | `full`, `collapsed`, `custom-separator` | — |\n\n**Deprecated aliases:** `focus` → `focus-visible` (states)\n\n**Slots:** `breadcrumb`, `breadcrumb-list`, `breadcrumb-item`, `breadcrumb-link`, `breadcrumb-page`, `breadcrumb-separator`, `breadcrumb-ellipsis`\n\n**States:** `rest`, `hover`, `focus-visible`, `current`\n\n## Related components\n\n- [Pagination](/components/component-pagination)\n- [Navigation Menu](/components/component-navigation-menu)\n- [Sidebar Nav Tree](/components/component-sidebar-nav-tree)\n",
|
|
7988
8056
|
"related": [
|
|
7989
8057
|
"pagination",
|
|
7990
8058
|
"navigation-menu",
|
|
@@ -8596,10 +8664,13 @@
|
|
|
8596
8664
|
"navigation-menu-indicator"
|
|
8597
8665
|
],
|
|
8598
8666
|
"source": "packages/ui-foundation/contracts/components/navigation-menu.json",
|
|
8667
|
+
"stateAliases": {
|
|
8668
|
+
"active": "current"
|
|
8669
|
+
},
|
|
8599
8670
|
"states": [
|
|
8600
8671
|
"closed",
|
|
8601
8672
|
"open",
|
|
8602
|
-
"
|
|
8673
|
+
"current",
|
|
8603
8674
|
"disabled",
|
|
8604
8675
|
"starting",
|
|
8605
8676
|
"ending"
|
|
@@ -8635,7 +8706,7 @@
|
|
|
8635
8706
|
],
|
|
8636
8707
|
"importPath": "@atom63/ui-react",
|
|
8637
8708
|
"label": "Navigation Menu",
|
|
8638
|
-
"markdown": "# Navigation Menu\n\nNavigation Menu composes site links with optional positioned navigation panels.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Keep link semantics intact and avoid putting command-style actions in the navigation hierarchy.\n- Preserve link, menu, command, or selection semantics instead of styling generic containers.\n- Expose current location when applicable and verify alternate input paths at narrow widths.\n\n## Usage\n\n```tsx\nimport { NavigationMenu, NavigationMenuList, NavigationMenuItem, NavigationMenuTrigger, NavigationMenuContent } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `NavigationMenu`, `NavigationMenuContent`, `NavigationMenuIndicator`, `NavigationMenuItem`, `NavigationMenuLink`, `NavigationMenuList`, `NavigationMenuPositioner`, `NavigationMenuTrigger`, `NavigationMenuViewport`, `navigationMenuTriggerStyle`\n\n**Types:** `NavigationMenuPositionerProps`, `NavigationMenuProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/navigation-menu.json` (`navigationMenuContract` in `@atom63/ui-foundation`).\n\n**Slots:** `navigation-menu`, `navigation-menu-list`, `navigation-menu-item`, `navigation-menu-trigger`, `navigation-menu-content`, `navigation-menu-portal`, `navigation-menu-positioner`, `navigation-menu-popup`, `navigation-menu-viewport`, `navigation-menu-link`, `navigation-menu-indicator`\n\n**States:** `closed`, `open`, `
|
|
8709
|
+
"markdown": "# Navigation Menu\n\nNavigation Menu composes site links with optional positioned navigation panels.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Keep link semantics intact and avoid putting command-style actions in the navigation hierarchy.\n- Preserve link, menu, command, or selection semantics instead of styling generic containers.\n- Expose current location when applicable and verify alternate input paths at narrow widths.\n\n## Usage\n\n```tsx\nimport { NavigationMenu, NavigationMenuList, NavigationMenuItem, NavigationMenuTrigger, NavigationMenuContent } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `NavigationMenu`, `NavigationMenuContent`, `NavigationMenuIndicator`, `NavigationMenuItem`, `NavigationMenuLink`, `NavigationMenuList`, `NavigationMenuPositioner`, `NavigationMenuTrigger`, `NavigationMenuViewport`, `navigationMenuTriggerStyle`\n\n**Types:** `NavigationMenuPositionerProps`, `NavigationMenuProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/navigation-menu.json` (`navigationMenuContract` in `@atom63/ui-foundation`).\n\n**Deprecated aliases:** `active` → `current` (states)\n\n**Slots:** `navigation-menu`, `navigation-menu-list`, `navigation-menu-item`, `navigation-menu-trigger`, `navigation-menu-content`, `navigation-menu-portal`, `navigation-menu-positioner`, `navigation-menu-popup`, `navigation-menu-viewport`, `navigation-menu-link`, `navigation-menu-indicator`\n\n**States:** `closed`, `open`, `current`, `disabled`, `starting`, `ending`\n\n**Visual archetype:** Triggers — Controls whose primary job is to open another surface.; Overlay surfaces — Floating material above the page or current surface.; Static content surfaces — In-flow containers and content surfaces that do not inherently manipulate state.\n\n## Related components\n\n- [Menubar](/components/component-menubar)\n- [Breadcrumb](/components/component-breadcrumb)\n- [Dropdown Menu](/components/component-dropdown-menu)\n",
|
|
8639
8710
|
"related": [
|
|
8640
8711
|
"menubar",
|
|
8641
8712
|
"breadcrumb",
|
|
@@ -9014,10 +9085,13 @@
|
|
|
9014
9085
|
"exportName": "sidebarNavTreeContract",
|
|
9015
9086
|
"slots": [],
|
|
9016
9087
|
"source": "packages/ui-foundation/contracts/components/sidebar-nav-tree.json",
|
|
9088
|
+
"stateAliases": {
|
|
9089
|
+
"active": "current"
|
|
9090
|
+
},
|
|
9017
9091
|
"states": [
|
|
9018
9092
|
"rest",
|
|
9019
9093
|
"hover",
|
|
9020
|
-
"
|
|
9094
|
+
"current",
|
|
9021
9095
|
"expanded",
|
|
9022
9096
|
"collapsed",
|
|
9023
9097
|
"focus-visible"
|
|
@@ -9051,7 +9125,7 @@
|
|
|
9051
9125
|
],
|
|
9052
9126
|
"importPath": "@atom63/ui-react",
|
|
9053
9127
|
"label": "Sidebar Nav Tree",
|
|
9054
|
-
"markdown": "# Sidebar Nav Tree\n\nSidebar Nav Tree composes labelled navigation groups that can fold, links, sublists, and collapsible sections with icons.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Preserve link semantics and expose the current route independently from expanded branch state. Give SidebarNavLinkItem href and icon (or a router link as render) instead of a child element; a link component you pass as the child or as render must spread the props it receives onto the element it renders and forward its ref.\n- Preserve link, menu, command, or selection semantics instead of styling generic containers.\n- Expose current location when applicable and verify alternate input paths at narrow widths.\n\n## Usage\n\n```tsx\nimport { SidebarNavGroup, SidebarNavLinkItem, SidebarNavCollapsibleItem } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `SidebarNavCollapsibleItem`, `SidebarNavGroup`, `SidebarNavLinkItem`, `SidebarNavSubLinkItem`, `SidebarNavSubList`\n\n**Types:** `SidebarNavCollapsibleItemProps`, `SidebarNavGroupProps`, `SidebarNavLinkItemProps`, `SidebarNavSubLinkItemProps`, `SidebarNavSubListProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/sidebar-nav-tree.json` (`sidebarNavTreeContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `parts` | `group`, `group-trigger`, `link-item`, `collapsible-item`, `toggle`, `sub-list`, `sub-link-item` | — |\n| `tones` | `neutral`, `accent` | `neutral` |\n\n**States:** `rest`, `hover`, `
|
|
9128
|
+
"markdown": "# Sidebar Nav Tree\n\nSidebar Nav Tree composes labelled navigation groups that can fold, links, sublists, and collapsible sections with icons.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Preserve link semantics and expose the current route independently from expanded branch state. Give SidebarNavLinkItem href and icon (or a router link as render) instead of a child element; a link component you pass as the child or as render must spread the props it receives onto the element it renders and forward its ref.\n- Preserve link, menu, command, or selection semantics instead of styling generic containers.\n- Expose current location when applicable and verify alternate input paths at narrow widths.\n\n## Usage\n\n```tsx\nimport { SidebarNavGroup, SidebarNavLinkItem, SidebarNavCollapsibleItem } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `SidebarNavCollapsibleItem`, `SidebarNavGroup`, `SidebarNavLinkItem`, `SidebarNavSubLinkItem`, `SidebarNavSubList`\n\n**Types:** `SidebarNavCollapsibleItemProps`, `SidebarNavGroupProps`, `SidebarNavLinkItemProps`, `SidebarNavSubLinkItemProps`, `SidebarNavSubListProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/sidebar-nav-tree.json` (`sidebarNavTreeContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `parts` | `group`, `group-trigger`, `link-item`, `collapsible-item`, `toggle`, `sub-list`, `sub-link-item` | — |\n| `tones` | `neutral`, `accent` | `neutral` |\n\n**Deprecated aliases:** `active` → `current` (states)\n\n**States:** `rest`, `hover`, `current`, `expanded`, `collapsed`, `focus-visible`\n\n**Visual archetype:** Action controls — Momentary controls that perform an action now.; Triggers — Controls whose primary job is to open another surface.\n\n## Related components\n\n- [Sidebar](/components/component-sidebar)\n- [Breadcrumb](/components/component-breadcrumb)\n- [Collapsible](/components/component-collapsible)\n",
|
|
9055
9129
|
"related": [
|
|
9056
9130
|
"sidebar",
|
|
9057
9131
|
"breadcrumb",
|
|
@@ -9123,10 +9197,13 @@
|
|
|
9123
9197
|
"values": [
|
|
9124
9198
|
"xs",
|
|
9125
9199
|
"sm",
|
|
9126
|
-
"
|
|
9200
|
+
"md",
|
|
9127
9201
|
"lg"
|
|
9128
9202
|
],
|
|
9129
|
-
"
|
|
9203
|
+
"deprecatedAliases": {
|
|
9204
|
+
"default": "md"
|
|
9205
|
+
},
|
|
9206
|
+
"default": "md"
|
|
9130
9207
|
},
|
|
9131
9208
|
{
|
|
9132
9209
|
"name": "orientations",
|
|
@@ -9216,7 +9293,7 @@
|
|
|
9216
9293
|
],
|
|
9217
9294
|
"importPath": "@atom63/ui-react",
|
|
9218
9295
|
"label": "Tabs",
|
|
9219
|
-
"markdown": "# Tabs\n\nTabs coordinate one active panel, its tab list, keyboard behavior, and indicator.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use tabs for peer panels in one task; use navigation links when the destination has its own URL.\n- Preserve link, menu, command, or selection semantics instead of styling generic containers.\n- Expose current location when applicable and verify alternate input paths at narrow widths.\n\n## Usage\n\n```tsx\nimport { Tabs, TabsList, TabsTab, TabsPanel } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Tabs`, `TabsContent`, `TabsList`, `TabsPanel`, `TabsTab`, `TabsTrigger`\n\n**Types:** `TabsListProps`, `TabsPanelProps`, `TabsTabProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/tabs.json` (`tabsContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `default`, `underline`, `attached` | `default` |\n| `sizes` | `xs`, `sm`, `
|
|
9296
|
+
"markdown": "# Tabs\n\nTabs coordinate one active panel, its tab list, keyboard behavior, and indicator.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use tabs for peer panels in one task; use navigation links when the destination has its own URL.\n- Preserve link, menu, command, or selection semantics instead of styling generic containers.\n- Expose current location when applicable and verify alternate input paths at narrow widths.\n\n## Usage\n\n```tsx\nimport { Tabs, TabsList, TabsTab, TabsPanel } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Tabs`, `TabsContent`, `TabsList`, `TabsPanel`, `TabsTab`, `TabsTrigger`\n\n**Types:** `TabsListProps`, `TabsPanelProps`, `TabsTabProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/tabs.json` (`tabsContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `default`, `underline`, `attached` | `default` |\n| `sizes` | `xs`, `sm`, `md`, `lg` | `md` |\n| `orientations` | `horizontal`, `vertical` | — |\n\n**Deprecated aliases:** `default` → `md` (sizes)\n\n**Slots:** `tabs`, `tabs-list`, `tabs-tab`, `tab-indicator`, `tabs-content`\n\n**States:** `rest`, `hover`, `selected`, `focus-visible`, `disabled`\n\n**Visual archetype:** Segmented selection — One-of-many peer selections presented as a shared track or grouped row.; Static content surfaces — In-flow containers and content surfaces that do not inherently manipulate state.\n\n**Accessibility pattern:** [Tabs](https://www.w3.org/WAI/ARIA/apg/patterns/tabs/) (activation: manual)\n\n### Web and iOS\n\nSwitch between peer destinations or content views while keeping one selection active. Rendered by `Picker(.segmented) / AtomTabRow` in SwiftUI, with `platform-adaptive` parity.\n\n**SwiftUI renderer per variant:**\n\n- `default`: `Picker(.segmented)`\n- `underline`: `AtomTabRow`\n- `attached`: `AtomTabRow`\n\n**Required states:** `rest`, `selected`\n\n**Shared outcomes:**\n\n- One tab is selected at a time\n- Selection reveals the associated content\n- Selected tab remains visually distinguishable\n\n**Accessibility outcomes:**\n\n- Exposes tab labels\n- Exposes selected state\n- Associates selection with visible content\n\n**Platform adaptations:**\n\n- React: Uses tablist, tab, and tabpanel semantics with keyboard navigation and a visual indicator.\n- SwiftUI: The default variant is a segmented Picker above the content it selects, for a short second-level filter of two to four options.\n- SwiftUI: The underline variant is AtomTabRow, a row of text tabs over the content it selects: the selected tab reads text-primary over an accent bar, the others text-secondary. The row scrolls sideways when the tabs do not fit and keeps the selected tab in view. Each tab can show an SF Symbol over its label. The bar slides to the new tab, and jumps under Reduce Motion. Each tab is a named button with the selected trait inside a tab-bar container, and the row mirrors in right-to-left languages.\n- SwiftUI: The attached variant also renders as AtomTabRow: folder tabs are a pointer idiom with no iOS counterpart, and the underline row already sits flush on the content it selects.\n- SwiftUI: TabView stays the renderer for app-level sections such as a tab bar or sidebar.\n- SwiftUI: In a TabView, each tab's root is its ScrollView or List. From iOS 26 the glass tab bar floats over it: content scrolls under the bar at rest, and TabView insets the scroll content so the last row ends above the bar. Do not pad for the bar, draw content in a ZStack or overlay over the TabView, or apply ignoresSafeArea to the bottom edge; extra bottom chrome goes in safeAreaInset(edge: .bottom) on the tab's root.\n\n## Related components\n\n- [Segmented Control](/components/component-segmented-control)\n- [Collapsible](/components/component-collapsible)\n- [Navigation Menu](/components/component-navigation-menu)\n",
|
|
9220
9297
|
"related": [
|
|
9221
9298
|
"segmented-control",
|
|
9222
9299
|
"collapsible",
|
|
@@ -9230,6 +9307,7 @@
|
|
|
9230
9307
|
"names": [
|
|
9231
9308
|
"Playground",
|
|
9232
9309
|
"Variants",
|
|
9310
|
+
"Vertical",
|
|
9233
9311
|
"ForcedColors",
|
|
9234
9312
|
"Attached",
|
|
9235
9313
|
"Sizes",
|
|
@@ -9238,7 +9316,7 @@
|
|
|
9238
9316
|
"Endpoints",
|
|
9239
9317
|
"ContractMetadata"
|
|
9240
9318
|
],
|
|
9241
|
-
"source": "import { tabsContract, tabsSizes, tabsVariants, themes } from '@atom63/ui-foundation'\nimport { Tabs, TabsList, TabsPanel, TabsTab, UIProvider } from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\nconst meta = {\n title: 'UI React/Tabs',\n component: Tabs,\n} satisfies Meta<typeof Tabs>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nconst PANEL_STYLE = { color: 'var(--a63-text-secondary)', fontSize: 14, paddingTop: 8 }\n\nexport const Playground: Story = {\n render: () => (\n <Tabs defaultValue=\"overview\">\n <TabsList aria-label=\"Product details\">\n <TabsTab value=\"overview\">Overview</TabsTab>\n <TabsTab value=\"specs\">Specs</TabsTab>\n <TabsTab value=\"reviews\">Reviews</TabsTab>\n </TabsList>\n <TabsPanel style={PANEL_STYLE} value=\"overview\">\n Overview content\n </TabsPanel>\n <TabsPanel style={PANEL_STYLE} value=\"specs\">\n Specs content\n </TabsPanel>\n <TabsPanel style={PANEL_STYLE} value=\"reviews\">\n Reviews content\n </TabsPanel>\n </Tabs>\n ),\n}\n\nexport const Variants: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 24 }}>\n {tabsVariants.map(variant => (\n <div key={variant}>\n <p style={{ color: 'var(--a63-text-secondary)', fontSize: 12, marginBottom: 8 }}>\n {variant}\n </p>\n <Tabs defaultValue=\"one\">\n <TabsList variant={variant}>\n <TabsTab value=\"one\">First</TabsTab>\n <TabsTab value=\"two\">Second</TabsTab>\n <TabsTab value=\"three\">Third</TabsTab>\n </TabsList>\n </Tabs>\n </div>\n ))}\n </div>\n ),\n}\n\n/* Captured with forced colors on (Windows High Contrast): the selected tab of\n every variant takes the system selection colours. */\nexport const ForcedColors: Story = { render: Variants.render }\n\n/* attached — the connected \"folder\": the tab row sits flush on a card panel\n body, and the active tab merges into it (no bottom border, shares the panel\n surface). Only reads with a panel present, which Variants omits. */\nexport const Attached: Story = {\n render: () => (\n <Tabs defaultValue=\"overview\" style={{ maxWidth: 460 }}>\n <TabsList variant=\"attached\">\n <TabsTab value=\"overview\">Overview</TabsTab>\n <TabsTab value=\"specs\">Specs</TabsTab>\n <TabsTab value=\"reviews\">Reviews</TabsTab>\n </TabsList>\n <TabsPanel value=\"overview\">\n The active tab connects into this card panel — one continuous folder shape.\n </TabsPanel>\n <TabsPanel value=\"specs\">Specs content.</TabsPanel>\n <TabsPanel value=\"reviews\">Reviews content.</TabsPanel>\n </Tabs>\n ),\n}\n\nexport const Sizes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 16 }}>\n {tabsSizes.map(size => (\n <Tabs defaultValue=\"one\" key={size}>\n <TabsList size={size}>\n <TabsTab value=\"one\">List</TabsTab>\n <TabsTab value=\"two\">Grid</TabsTab>\n </TabsList>\n </Tabs>\n ))}\n </div>\n ),\n}\n\nexport const MobileOverflow: Story = {\n tags: ['!manifest'],\n render: () => (\n <UIProvider input=\"touch\">\n <div style={{ maxWidth: 320, width: 'min(100%, calc(100vw - 2rem))' }}>\n <Tabs defaultValue=\"overview\">\n <TabsList>\n <TabsTab value=\"overview\">Project overview</TabsTab>\n <TabsTab value=\"activity\">Recent activity</TabsTab>\n <TabsTab value=\"permissions\">Access permissions</TabsTab>\n <TabsTab value=\"integrations\">Connected integrations</TabsTab>\n </TabsList>\n </Tabs>\n </div>\n </UIProvider>\n ),\n}\n\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={`${theme}-${mode}`} mode={mode} theme={theme}>\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 96 }}>\n {theme} / {mode}\n </span>\n <Tabs defaultValue=\"one\">\n <TabsList variant=\"default\">\n <TabsTab value=\"one\">First</TabsTab>\n <TabsTab value=\"two\">Second</TabsTab>\n </TabsList>\n </Tabs>\n <Tabs defaultValue=\"one\">\n <TabsList variant=\"underline\">\n <TabsTab value=\"one\">First</TabsTab>\n <TabsTab value=\"two\">Second</TabsTab>\n </TabsList>\n </Tabs>\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\n/* Contract probe — remaps the control + surface + track contracts live. */\nexport const Endpoints: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n <UIProvider designLanguage=\"web\" input=\"pointer\">\n <EndpointTabs label=\"Web\" />\n </UIProvider>\n <UIProvider designLanguage=\"ios\" input=\"touch\">\n <EndpointTabs label=\"iOS touch\" />\n </UIProvider>\n <UIProvider density=\"compact\">\n <EndpointTabs label=\"Compact extension\" />\n </UIProvider>\n </div>\n ),\n}\n\nfunction EndpointTabs({ label }: { label: string }) {\n return (\n <div\n style={{\n background: 'var(--a63-surface-panel)',\n color: 'var(--a63-text-primary)',\n display: 'grid',\n gap: 8,\n padding: 12,\n }}\n >\n <span style={{ color: 'var(--a63-text-secondary)', fontSize: 12 }}>{label}</span>\n <Tabs defaultValue=\"one\">\n <TabsList>\n <TabsTab value=\"one\">First</TabsTab>\n <TabsTab value=\"two\">Second</TabsTab>\n </TabsList>\n </Tabs>\n </div>\n )\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(tabsContract, null, 2)}\n </pre>\n ),\n}\n"
|
|
9319
|
+
"source": "import { tabsContract, tabsSizes, tabsVariants, themes } from '@atom63/ui-foundation'\nimport { Tabs, TabsList, TabsPanel, TabsTab, UIProvider } from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\nconst meta = {\n title: 'UI React/Tabs',\n component: Tabs,\n} satisfies Meta<typeof Tabs>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nconst PANEL_STYLE = { color: 'var(--a63-text-secondary)', fontSize: 14, paddingTop: 8 }\n\nexport const Playground: Story = {\n render: () => (\n <Tabs defaultValue=\"overview\">\n <TabsList aria-label=\"Product details\">\n <TabsTab value=\"overview\">Overview</TabsTab>\n <TabsTab value=\"specs\">Specs</TabsTab>\n <TabsTab value=\"reviews\">Reviews</TabsTab>\n </TabsList>\n <TabsPanel style={PANEL_STYLE} value=\"overview\">\n Overview content\n </TabsPanel>\n <TabsPanel style={PANEL_STYLE} value=\"specs\">\n Specs content\n </TabsPanel>\n <TabsPanel style={PANEL_STYLE} value=\"reviews\">\n Reviews content\n </TabsPanel>\n </Tabs>\n ),\n}\n\nexport const Variants: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 24 }}>\n {tabsVariants.map(variant => (\n <div key={variant}>\n <p style={{ color: 'var(--a63-text-secondary)', fontSize: 12, marginBottom: 8 }}>\n {variant}\n </p>\n <Tabs defaultValue=\"one\">\n <TabsList variant={variant}>\n <TabsTab value=\"one\">First</TabsTab>\n <TabsTab value=\"two\">Second</TabsTab>\n <TabsTab value=\"three\">Third</TabsTab>\n </TabsList>\n </Tabs>\n </div>\n ))}\n </div>\n ),\n}\n\n/* Vertical orientation: the default track grows with its stacked tabs and the\n raised plate slides vertically to the selected tab; the underline bar moves\n to the inline end. The play function checks the plate follows a click. */\nexport const Vertical: Story = {\n render: () => (\n <div style={{ display: 'flex', gap: 32, alignItems: 'flex-start' }}>\n {(['default', 'underline'] as const).map(variant => (\n <Tabs defaultValue=\"overview\" key={variant} orientation=\"vertical\">\n <TabsList aria-label={`Settings (${variant})`} variant={variant}>\n <TabsTab value=\"overview\">Overview</TabsTab>\n <TabsTab value=\"specs\">Specs</TabsTab>\n <TabsTab value=\"reviews\">Reviews</TabsTab>\n </TabsList>\n <TabsPanel style={PANEL_STYLE} value=\"overview\">\n Overview content\n </TabsPanel>\n <TabsPanel style={PANEL_STYLE} value=\"specs\">\n Specs content\n </TabsPanel>\n <TabsPanel style={PANEL_STYLE} value=\"reviews\">\n Reviews content\n </TabsPanel>\n </Tabs>\n ))}\n </div>\n ),\n play: async ({ canvasElement }) => {\n const list = canvasElement.querySelector<HTMLElement>('.a63-Tabs-list[data-variant=\"default\"]')\n if (!list) throw new Error('Expected the default vertical list')\n const tabs = list.querySelectorAll<HTMLElement>('.a63-Tabs-tab')\n const indicator = list.querySelector<HTMLElement>('.a63-Tabs-indicator')\n if (tabs.length !== 3 || !indicator) throw new Error('Expected three tabs and an indicator')\n const listRect = list.getBoundingClientRect()\n const lastRect = tabs[2].getBoundingClientRect()\n if (lastRect.bottom > listRect.bottom + 0.5) {\n throw new Error(\n `Expected the track to contain every tab (tab bottom ${lastRect.bottom}, track bottom ${listRect.bottom})`\n )\n }\n for (const index of [2, 1, 0]) {\n tabs[index].click()\n await new Promise(resolve => setTimeout(resolve, 50))\n await Promise.all(indicator.getAnimations().map(animation => animation.finished))\n const tab = tabs[index].getBoundingClientRect()\n const plate = indicator.getBoundingClientRect()\n if (Math.abs(plate.top - tab.top) > 1 || Math.abs(plate.height - tab.height) > 1) {\n throw new Error(\n `Expected the indicator to cover tab ${index} (tab top ${tab.top}, indicator top ${plate.top})`\n )\n }\n }\n },\n}\n\n/* Captured with forced colors on (Windows High Contrast): the selected tab of\n every variant takes the system selection colours. */\nexport const ForcedColors: Story = { render: Variants.render }\n\n/* attached — the connected \"folder\": the tab row sits flush on a card panel\n body, and the active tab merges into it (no bottom border, shares the panel\n surface). Only reads with a panel present, which Variants omits. */\nexport const Attached: Story = {\n render: () => (\n <Tabs defaultValue=\"overview\" style={{ maxWidth: 460 }}>\n <TabsList variant=\"attached\">\n <TabsTab value=\"overview\">Overview</TabsTab>\n <TabsTab value=\"specs\">Specs</TabsTab>\n <TabsTab value=\"reviews\">Reviews</TabsTab>\n </TabsList>\n <TabsPanel value=\"overview\">\n The active tab connects into this card panel — one continuous folder shape.\n </TabsPanel>\n <TabsPanel value=\"specs\">Specs content.</TabsPanel>\n <TabsPanel value=\"reviews\">Reviews content.</TabsPanel>\n </Tabs>\n ),\n}\n\nexport const Sizes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 16 }}>\n {tabsSizes.map(size => (\n <Tabs defaultValue=\"one\" key={size}>\n <TabsList size={size}>\n <TabsTab value=\"one\">List</TabsTab>\n <TabsTab value=\"two\">Grid</TabsTab>\n </TabsList>\n </Tabs>\n ))}\n </div>\n ),\n}\n\nexport const MobileOverflow: Story = {\n tags: ['!manifest'],\n render: () => (\n <UIProvider input=\"touch\">\n <div style={{ maxWidth: 320, width: 'min(100%, calc(100vw - 2rem))' }}>\n <Tabs defaultValue=\"overview\">\n <TabsList>\n <TabsTab value=\"overview\">Project overview</TabsTab>\n <TabsTab value=\"activity\">Recent activity</TabsTab>\n <TabsTab value=\"permissions\">Access permissions</TabsTab>\n <TabsTab value=\"integrations\">Connected integrations</TabsTab>\n </TabsList>\n </Tabs>\n </div>\n </UIProvider>\n ),\n}\n\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={`${theme}-${mode}`} mode={mode} theme={theme}>\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 96 }}>\n {theme} / {mode}\n </span>\n <Tabs defaultValue=\"one\">\n <TabsList variant=\"default\">\n <TabsTab value=\"one\">First</TabsTab>\n <TabsTab value=\"two\">Second</TabsTab>\n </TabsList>\n </Tabs>\n <Tabs defaultValue=\"one\">\n <TabsList variant=\"underline\">\n <TabsTab value=\"one\">First</TabsTab>\n <TabsTab value=\"two\">Second</TabsTab>\n </TabsList>\n </Tabs>\n <Tabs defaultValue=\"two\" orientation=\"vertical\">\n <TabsList variant=\"default\">\n <TabsTab value=\"one\">First</TabsTab>\n <TabsTab value=\"two\">Second</TabsTab>\n </TabsList>\n </Tabs>\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\n/* Contract probe — remaps the control + surface + track contracts live. */\nexport const Endpoints: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n <UIProvider designLanguage=\"web\" input=\"pointer\">\n <EndpointTabs label=\"Web\" />\n </UIProvider>\n <UIProvider designLanguage=\"ios\" input=\"touch\">\n <EndpointTabs label=\"iOS touch\" />\n </UIProvider>\n <UIProvider density=\"compact\">\n <EndpointTabs label=\"Compact extension\" />\n </UIProvider>\n </div>\n ),\n}\n\nfunction EndpointTabs({ label }: { label: string }) {\n return (\n <div\n style={{\n background: 'var(--a63-surface-panel)',\n color: 'var(--a63-text-primary)',\n display: 'grid',\n gap: 8,\n padding: 12,\n }}\n >\n <span style={{ color: 'var(--a63-text-secondary)', fontSize: 12 }}>{label}</span>\n <Tabs defaultValue=\"one\">\n <TabsList>\n <TabsTab value=\"one\">First</TabsTab>\n <TabsTab value=\"two\">Second</TabsTab>\n </TabsList>\n </Tabs>\n </div>\n )\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(tabsContract, null, 2)}\n </pre>\n ),\n}\n"
|
|
9242
9320
|
},
|
|
9243
9321
|
"summary": "Tabs coordinate one active panel, its tab list, keyboard behavior, and indicator.",
|
|
9244
9322
|
"usage": "Use tabs for peer panels in one task; use navigation links when the destination has its own URL.",
|
|
@@ -9292,20 +9370,26 @@
|
|
|
9292
9370
|
{
|
|
9293
9371
|
"name": "sizes",
|
|
9294
9372
|
"values": [
|
|
9295
|
-
"
|
|
9373
|
+
"md",
|
|
9296
9374
|
"sm"
|
|
9297
9375
|
],
|
|
9298
|
-
"
|
|
9376
|
+
"deprecatedAliases": {
|
|
9377
|
+
"default": "md"
|
|
9378
|
+
},
|
|
9379
|
+
"default": "md"
|
|
9299
9380
|
},
|
|
9300
9381
|
{
|
|
9301
9382
|
"name": "variants",
|
|
9302
9383
|
"values": [
|
|
9303
9384
|
"default",
|
|
9304
|
-
"
|
|
9385
|
+
"error",
|
|
9305
9386
|
"info",
|
|
9306
9387
|
"success",
|
|
9307
9388
|
"warning"
|
|
9308
9389
|
],
|
|
9390
|
+
"deprecatedAliases": {
|
|
9391
|
+
"destructive": "error"
|
|
9392
|
+
},
|
|
9309
9393
|
"default": "default"
|
|
9310
9394
|
}
|
|
9311
9395
|
],
|
|
@@ -9393,7 +9477,7 @@
|
|
|
9393
9477
|
],
|
|
9394
9478
|
"importPath": "@atom63/ui-react",
|
|
9395
9479
|
"label": "Alert Dialog",
|
|
9396
|
-
"markdown": "# Alert Dialog\n\nAlert Dialog interrupts a flow to confirm a consequential decision.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Reserve it for decisions that need explicit acknowledgement, not routine information.\n- When the family opens a surface, preserve its focus, Escape, and dismissal semantics.\n- Check portal placement, stacking, and small-viewport containment in the consuming product.\n\n## Usage\n\n```tsx\nimport { AlertDialog, AlertDialogTrigger, AlertDialogContent, AlertDialogAction } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `AlertDialog`, `AlertDialogAction`, `AlertDialogBackdrop`, `AlertDialogCancel`, `AlertDialogClose`, `AlertDialogContent`, `AlertDialogCreateHandle`, `AlertDialogDescription`, `AlertDialogFooter`, `AlertDialogHeader`, `AlertDialogMedia`, `AlertDialogOverlay`, `AlertDialogPopup`, `AlertDialogPortal`, `AlertDialogPrimitive`, `AlertDialogTitle`, `AlertDialogTrigger`, `AlertDialogViewport`\n\n**Types:** None.\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/alert-dialog.json` (`alertDialogContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `footerVariants` | `default`, `bare` | `default` |\n| `sizes` | `
|
|
9480
|
+
"markdown": "# Alert Dialog\n\nAlert Dialog interrupts a flow to confirm a consequential decision.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Reserve it for decisions that need explicit acknowledgement, not routine information.\n- When the family opens a surface, preserve its focus, Escape, and dismissal semantics.\n- Check portal placement, stacking, and small-viewport containment in the consuming product.\n\n## Usage\n\n```tsx\nimport { AlertDialog, AlertDialogTrigger, AlertDialogContent, AlertDialogAction } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `AlertDialog`, `AlertDialogAction`, `AlertDialogBackdrop`, `AlertDialogCancel`, `AlertDialogClose`, `AlertDialogContent`, `AlertDialogCreateHandle`, `AlertDialogDescription`, `AlertDialogFooter`, `AlertDialogHeader`, `AlertDialogMedia`, `AlertDialogOverlay`, `AlertDialogPopup`, `AlertDialogPortal`, `AlertDialogPrimitive`, `AlertDialogTitle`, `AlertDialogTrigger`, `AlertDialogViewport`\n\n**Types:** None.\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/alert-dialog.json` (`alertDialogContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `footerVariants` | `default`, `bare` | `default` |\n| `sizes` | `md`, `sm` | `md` |\n| `variants` | `default`, `error`, `info`, `success`, `warning` | `default` |\n\n**Deprecated aliases:** `default` → `md` (sizes), `destructive` → `error` (variants)\n\n**Slots:** `alert-dialog-portal`, `alert-dialog-trigger`, `alert-dialog-backdrop`, `alert-dialog-viewport`, `alert-dialog-popup`, `alert-dialog-header`, `alert-dialog-footer`, `alert-dialog-media`, `alert-dialog-title`, `alert-dialog-description`, `alert-dialog-close`, `alert-dialog-action`, `alert-dialog-cancel`\n\n**States:** `closed`, `open`\n\n**Visual archetype:** Overlay surfaces — Floating material above the page or current surface.; Static content surfaces — In-flow containers and content surfaces that do not inherently manipulate state.; Triggers — Controls whose primary job is to open another surface.; Action controls — Momentary controls that perform an action now.\n\n**Accessibility pattern:** [Alert and Message Dialogs](https://www.w3.org/WAI/ARIA/apg/patterns/alertdialog/)\n\n### Web and iOS\n\nRequire an explicit decision before committing or abandoning a consequential action. Rendered by `alert(_:isPresented:actions:message:)` in SwiftUI, with `platform-adaptive` parity.\n\n**Required states:** `closed`, `open`\n\n**Shared outcomes:**\n\n- Consequential action requires explicit confirmation\n- Cancel dismisses without performing the action\n- Confirmation performs the action once and dismisses\n\n**Accessibility outcomes:**\n\n- Exposes alert dialog title\n- Exposes consequence description\n- Identifies cancel and confirm actions\n\n**Platform adaptations:**\n\n- React: Uses an alertdialog portal with guarded outside and Escape dismissal plus explicit action and cancel controls.\n- SwiftUI: Uses a native alert or confirmationDialog with platform button roles, ordering, and compact presentation.\n\n## Related components\n\n- [Dialog](/components/component-dialog)\n- [Sheet](/components/component-sheet)\n- [Drawer](/components/component-drawer)\n",
|
|
9397
9481
|
"related": [
|
|
9398
9482
|
"dialog",
|
|
9399
9483
|
"sheet",
|
|
@@ -9412,7 +9496,7 @@
|
|
|
9412
9496
|
"Endpoints",
|
|
9413
9497
|
"ContractMetadata"
|
|
9414
9498
|
],
|
|
9415
|
-
"source": "import { alertDialogContract, alertDialogVariants, themes } from '@atom63/ui-foundation'\nimport {\n AlertDialog,\n AlertDialogAction,\n AlertDialogCancel,\n AlertDialogDescription,\n AlertDialogFooter,\n AlertDialogHeader,\n AlertDialogMedia,\n AlertDialogPopup,\n AlertDialogTitle,\n AlertDialogTrigger,\n Button,\n Dialog,\n UIProvider,\n} from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport { AlertTriangle, CheckCircle2, Info } from 'lucide-react'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\nimport { type CSSProperties, type ReactNode, type RefObject, useRef } from 'react'\n\nconst meta = {\n title: 'UI React/AlertDialog',\n component: AlertDialog,\n decorators: [\n Story => (\n <div style={{ display: 'flex', gap: 24, padding: 48 }}>\n <Story />\n </div>\n ),\n ],\n} satisfies Meta<typeof AlertDialog>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nfunction VariantIcon({ variant }: { variant: (typeof alertDialogVariants)[number] }) {\n if (variant === 'success') {\n return <CheckCircle2 aria-hidden />\n }\n if (variant === 'default' || variant === 'info') {\n return <Info aria-hidden />\n }\n return <AlertTriangle aria-hidden />\n}\n\n/* A labelled stage cell. It paints its own panel surface so the label reads\n against the cell's theme and mode, not the light page behind the story. */\nconst cellStyle: CSSProperties = {\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'grid',\n gap: 6,\n padding: 12,\n}\n\n/*\n * A fixed-height box that holds one open overlay. The transform makes the box\n * the containing block of the popup's fixed-position backdrop and viewport, and\n * --a63-viewport-height sizes them to the box, so the overlay lays out as it\n * would over a short window.\n */\nfunction OverlayStage({\n children,\n height = 320,\n}: {\n children: (container: RefObject<HTMLDivElement | null>) => ReactNode\n height?: number\n}) {\n const containerRef = useRef<HTMLDivElement>(null)\n return (\n <div\n ref={containerRef}\n style={\n {\n '--a63-viewport-height': `${height}px`,\n background: 'var(--a63-surface-page)',\n blockSize: height,\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n overflow: 'hidden',\n position: 'relative',\n transform: 'translateZ(0)',\n } as CSSProperties\n }\n >\n {children(containerRef)}\n </div>\n )\n}\n\n/*\n * One alert dialog popup, open on load inside a stage, for the matrix stories.\n * An alert dialog is always modal, and two open modal dialogs each hide the\n * other from assistive tech, so these cells mount the same AlertDialogPopup\n * under a non-modal Dialog root (the alert dialog root is a Dialog root with\n * `modal` forced on). The Confirm story shows the real modal alert dialog.\n */\nfunction StagedAlert({\n label,\n variant,\n}: {\n label: string\n variant: (typeof alertDialogVariants)[number]\n}) {\n return (\n <div style={cellStyle}>\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)' }}>{label}</span>\n <OverlayStage>\n {container => (\n <Dialog defaultOpen modal={false}>\n <AlertDialogPopup initialFocus={false} portalProps={{ container }} variant={variant}>\n <AlertDialogHeader>\n <AlertDialogMedia>\n <VariantIcon variant={variant} />\n </AlertDialogMedia>\n <AlertDialogTitle>{variant} alert</AlertDialogTitle>\n <AlertDialogDescription>\n This popup uses the “{variant}” variant to carry its semantic tone.\n </AlertDialogDescription>\n </AlertDialogHeader>\n <AlertDialogFooter>\n <AlertDialogCancel>Cancel</AlertDialogCancel>\n <AlertDialogAction variant={variant === '
|
|
9499
|
+
"source": "import { alertDialogContract, alertDialogVariants, themes } from '@atom63/ui-foundation'\nimport {\n AlertDialog,\n AlertDialogAction,\n AlertDialogCancel,\n AlertDialogDescription,\n AlertDialogFooter,\n AlertDialogHeader,\n AlertDialogMedia,\n AlertDialogPopup,\n AlertDialogTitle,\n AlertDialogTrigger,\n Button,\n Dialog,\n UIProvider,\n} from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport { AlertTriangle, CheckCircle2, Info } from 'lucide-react'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\nimport { type CSSProperties, type ReactNode, type RefObject, useRef } from 'react'\n\nconst meta = {\n title: 'UI React/AlertDialog',\n component: AlertDialog,\n decorators: [\n Story => (\n <div style={{ display: 'flex', gap: 24, padding: 48 }}>\n <Story />\n </div>\n ),\n ],\n} satisfies Meta<typeof AlertDialog>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nfunction VariantIcon({ variant }: { variant: (typeof alertDialogVariants)[number] }) {\n if (variant === 'success') {\n return <CheckCircle2 aria-hidden />\n }\n if (variant === 'default' || variant === 'info') {\n return <Info aria-hidden />\n }\n return <AlertTriangle aria-hidden />\n}\n\n/* A labelled stage cell. It paints its own panel surface so the label reads\n against the cell's theme and mode, not the light page behind the story. */\nconst cellStyle: CSSProperties = {\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'grid',\n gap: 6,\n padding: 12,\n}\n\n/*\n * A fixed-height box that holds one open overlay. The transform makes the box\n * the containing block of the popup's fixed-position backdrop and viewport, and\n * --a63-viewport-height sizes them to the box, so the overlay lays out as it\n * would over a short window.\n */\nfunction OverlayStage({\n children,\n height = 320,\n}: {\n children: (container: RefObject<HTMLDivElement | null>) => ReactNode\n height?: number\n}) {\n const containerRef = useRef<HTMLDivElement>(null)\n return (\n <div\n ref={containerRef}\n style={\n {\n '--a63-viewport-height': `${height}px`,\n background: 'var(--a63-surface-page)',\n blockSize: height,\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n overflow: 'hidden',\n position: 'relative',\n transform: 'translateZ(0)',\n } as CSSProperties\n }\n >\n {children(containerRef)}\n </div>\n )\n}\n\n/*\n * One alert dialog popup, open on load inside a stage, for the matrix stories.\n * An alert dialog is always modal, and two open modal dialogs each hide the\n * other from assistive tech, so these cells mount the same AlertDialogPopup\n * under a non-modal Dialog root (the alert dialog root is a Dialog root with\n * `modal` forced on). The Confirm story shows the real modal alert dialog.\n */\nfunction StagedAlert({\n label,\n variant,\n}: {\n label: string\n variant: (typeof alertDialogVariants)[number]\n}) {\n return (\n <div style={cellStyle}>\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)' }}>{label}</span>\n <OverlayStage>\n {container => (\n <Dialog defaultOpen modal={false}>\n <AlertDialogPopup initialFocus={false} portalProps={{ container }} variant={variant}>\n <AlertDialogHeader>\n <AlertDialogMedia>\n <VariantIcon variant={variant} />\n </AlertDialogMedia>\n <AlertDialogTitle>{variant} alert</AlertDialogTitle>\n <AlertDialogDescription>\n This popup uses the “{variant}” variant to carry its semantic tone.\n </AlertDialogDescription>\n </AlertDialogHeader>\n <AlertDialogFooter>\n <AlertDialogCancel>Cancel</AlertDialogCancel>\n <AlertDialogAction variant={variant === 'error' ? 'destructive' : 'primary'}>\n Continue\n </AlertDialogAction>\n </AlertDialogFooter>\n </AlertDialogPopup>\n </Dialog>\n )}\n </OverlayStage>\n </div>\n )\n}\n\nexport const Playground: Story = {\n render: () => (\n <AlertDialog>\n <AlertDialogTrigger render={<Button variant=\"outline\">Delete project</Button>} />\n <AlertDialogPopup variant=\"error\">\n <AlertDialogHeader>\n <AlertDialogMedia>\n <VariantIcon variant=\"error\" />\n </AlertDialogMedia>\n <AlertDialogTitle>Delete this project?</AlertDialogTitle>\n <AlertDialogDescription>\n This permanently removes the project and all of its files. This action cannot be undone.\n </AlertDialogDescription>\n </AlertDialogHeader>\n <AlertDialogFooter>\n <AlertDialogCancel>Cancel</AlertDialogCancel>\n <AlertDialogAction variant=\"destructive\">Delete</AlertDialogAction>\n </AlertDialogFooter>\n </AlertDialogPopup>\n </AlertDialog>\n ),\n}\n\nexport const Confirm: Story = {\n render: () => (\n <AlertDialog defaultOpen>\n <AlertDialogPopup size=\"sm\">\n <AlertDialogHeader>\n <AlertDialogMedia>\n <VariantIcon variant=\"default\" />\n </AlertDialogMedia>\n <AlertDialogTitle>Publish changes?</AlertDialogTitle>\n <AlertDialogDescription>Your changes will go live immediately.</AlertDialogDescription>\n </AlertDialogHeader>\n <AlertDialogFooter>\n <AlertDialogCancel>Not yet</AlertDialogCancel>\n <AlertDialogAction variant=\"primary\">Publish</AlertDialogAction>\n </AlertDialogFooter>\n </AlertDialogPopup>\n </AlertDialog>\n ),\n}\n\n/** Every semantic popup variant, open. */\nexport const Variants: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12, inlineSize: '100%' }}>\n {alertDialogVariants.map(variant => (\n <StagedAlert key={variant} label={variant} variant={variant} />\n ))}\n </div>\n ),\n}\n\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12, inlineSize: '100%' }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={theme + mode} mode={mode} theme={theme}>\n <StagedAlert label={`${theme} / ${mode}`} variant=\"error\" />\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\n/* The same confirmation pattern reviewed against target host contexts. */\nexport const Endpoints: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12, inlineSize: '100%' }}>\n {[\n {\n label: 'Web',\n props: { density: 'comfortable', designLanguage: 'web', input: 'pointer' } as const,\n },\n {\n label: 'iOS touch',\n props: { density: 'comfortable', designLanguage: 'ios', input: 'touch' } as const,\n },\n {\n label: 'Compact extension',\n props: {\n density: 'compact',\n designLanguage: 'web',\n input: 'pointer',\n surface: 'n2',\n } as const,\n },\n ].map(endpoint => (\n <UIProvider key={endpoint.label} {...endpoint.props}>\n <StagedAlert label={endpoint.label} variant=\"error\" />\n </UIProvider>\n ))}\n </div>\n ),\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(alertDialogContract, null, 2)}\n </pre>\n ),\n}\n"
|
|
9416
9500
|
},
|
|
9417
9501
|
"summary": "Alert Dialog interrupts a flow to confirm a consequential decision.",
|
|
9418
9502
|
"usage": "Reserve it for decisions that need explicit acknowledgement, not routine information.",
|
|
@@ -9475,10 +9559,13 @@
|
|
|
9475
9559
|
"name": "sizes",
|
|
9476
9560
|
"values": [
|
|
9477
9561
|
"sm",
|
|
9478
|
-
"
|
|
9562
|
+
"md",
|
|
9479
9563
|
"lg"
|
|
9480
9564
|
],
|
|
9481
|
-
"
|
|
9565
|
+
"deprecatedAliases": {
|
|
9566
|
+
"default": "md"
|
|
9567
|
+
},
|
|
9568
|
+
"default": "md"
|
|
9482
9569
|
}
|
|
9483
9570
|
],
|
|
9484
9571
|
"crossRenderer": {
|
|
@@ -9570,7 +9657,7 @@
|
|
|
9570
9657
|
],
|
|
9571
9658
|
"importPath": "@atom63/ui-react",
|
|
9572
9659
|
"label": "Dialog",
|
|
9573
|
-
"markdown": "# Dialog\n\nDialog provides modal task structure, focus management, and responsive placement.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Give every dialog a title and a deliberate close path; use Alert Dialog for confirmation.\n- When the family opens a surface, preserve its focus, Escape, and dismissal semantics.\n- Check portal placement, stacking, and small-viewport containment in the consuming product.\n\n## Usage\n\n```tsx\nimport { Dialog, DialogTrigger, DialogContent } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Dialog`, `DialogBackdrop`, `DialogClose`, `DialogContent`, `DialogCreateHandle`, `DialogDescription`, `DialogFooter`, `DialogHeader`, `DialogOverlay`, `DialogPanel`, `DialogPopup`, `DialogPortal`, `DialogPrimitive`, `DialogTitle`, `DialogTrigger`, `DialogViewport`\n\n**Types:** `DialogFooterVariant`, `DialogMobilePlacement`, `DialogSize`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/dialog.json` (`dialogContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `footerVariants` | `default`, `bare` | `default` |\n| `mobilePlacements` | `bottom`, `center` | `bottom` |\n| `sizes` | `sm`, `
|
|
9660
|
+
"markdown": "# Dialog\n\nDialog provides modal task structure, focus management, and responsive placement.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Give every dialog a title and a deliberate close path; use Alert Dialog for confirmation.\n- When the family opens a surface, preserve its focus, Escape, and dismissal semantics.\n- Check portal placement, stacking, and small-viewport containment in the consuming product.\n\n## Usage\n\n```tsx\nimport { Dialog, DialogTrigger, DialogContent } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Dialog`, `DialogBackdrop`, `DialogClose`, `DialogContent`, `DialogCreateHandle`, `DialogDescription`, `DialogFooter`, `DialogHeader`, `DialogOverlay`, `DialogPanel`, `DialogPopup`, `DialogPortal`, `DialogPrimitive`, `DialogTitle`, `DialogTrigger`, `DialogViewport`\n\n**Types:** `DialogFooterVariant`, `DialogMobilePlacement`, `DialogSize`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/dialog.json` (`dialogContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `footerVariants` | `default`, `bare` | `default` |\n| `mobilePlacements` | `bottom`, `center` | `bottom` |\n| `sizes` | `sm`, `md`, `lg` | `md` |\n\n**Deprecated aliases:** `default` → `md` (sizes)\n\n**Slots:** `dialog-portal`, `dialog-trigger`, `dialog-backdrop`, `dialog-viewport`, `dialog-popup`, `dialog-close`, `dialog-close-button`, `dialog-header`, `dialog-title`, `dialog-description`, `dialog-panel`, `dialog-footer`\n\n**States:** `closed`, `open`, `starting`, `ending`, `focus-visible`\n\n**Visual archetype:** Overlay surfaces — Floating material above the page or current surface.; Static content surfaces — In-flow containers and content surfaces that do not inherently manipulate state.; Triggers — Controls whose primary job is to open another surface.; Action controls — Momentary controls that perform an action now.\n\n**Accessibility pattern:** [Dialog (Modal)](https://www.w3.org/WAI/ARIA/apg/patterns/dialog-modal/)\n\n### Web and iOS\n\nTemporarily move the user into a focused modal task without losing the originating context. Rendered by `sheet(isPresented:) / presentationDetents(_:)` in SwiftUI, with `platform-adaptive` parity.\n\n**Required states:** `closed`, `open`, `focus-visible`\n\n**Shared outcomes:**\n\n- Opening presents a modal context\n- Background interaction is blocked while open\n- Dismissal returns to the originating context\n\n**Accessibility outcomes:**\n\n- Exposes modal title\n- Keeps assistive focus in the modal context\n- Restores access to the originating control\n\n**Platform adaptations:**\n\n- React: Uses a compound modal dialog with a portal, focus containment, Escape dismissal, and trigger focus restoration.\n- SwiftUI: Uses the native sheet presentation, adaptive detents, swipe dismissal, and a NavigationStack for modal task hierarchy.\n\n## Related components\n\n- [Alert Dialog](/components/component-alert-dialog)\n- [Sheet](/components/component-sheet)\n- [Drawer](/components/component-drawer)\n",
|
|
9574
9661
|
"related": [
|
|
9575
9662
|
"alert-dialog",
|
|
9576
9663
|
"sheet",
|
|
@@ -9591,7 +9678,7 @@
|
|
|
9591
9678
|
"Endpoints",
|
|
9592
9679
|
"ContractMetadata"
|
|
9593
9680
|
],
|
|
9594
|
-
"source": "import { dialogContract, dialogSizes, themes } from '@atom63/ui-foundation'\nimport {\n Button,\n Dialog,\n DialogClose,\n DialogDescription,\n DialogFooter,\n DialogHeader,\n DialogPanel,\n DialogPopup,\n DialogTitle,\n DialogTrigger,\n UIProvider,\n} from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\nimport {\n type CSSProperties,\n type ComponentProps,\n type ReactNode,\n type RefObject,\n useRef,\n} from 'react'\n\nconst meta = {\n title: 'UI React/Dialog',\n component: Dialog,\n decorators: [\n Story => (\n <div style={{ display: 'flex', gap: 24, padding: 48 }}>\n <Story />\n </div>\n ),\n ],\n} satisfies Meta<typeof Dialog>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\n/*\n * `open` renders the dialog open on load so the visual and axe runs capture the\n * popup, not the trigger. `modal` is the dialog as an app shows it, over the\n * whole page (one per story). `inline` is non-modal and belongs inside an\n * OverlayStage, so several open dialogs can share one capture: two open modal\n * dialogs would each hide the other from assistive tech.\n */\ntype OpenMode = 'modal' | 'inline'\n\nfunction RenameDialog({\n open,\n portalContainerRef,\n size = '
|
|
9681
|
+
"source": "import { dialogContract, dialogSizes, themes } from '@atom63/ui-foundation'\nimport {\n Button,\n Dialog,\n DialogClose,\n DialogDescription,\n DialogFooter,\n DialogHeader,\n DialogPanel,\n DialogPopup,\n DialogTitle,\n DialogTrigger,\n UIProvider,\n} from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\nimport {\n type CSSProperties,\n type ComponentProps,\n type ReactNode,\n type RefObject,\n useRef,\n} from 'react'\n\nconst meta = {\n title: 'UI React/Dialog',\n component: Dialog,\n decorators: [\n Story => (\n <div style={{ display: 'flex', gap: 24, padding: 48 }}>\n <Story />\n </div>\n ),\n ],\n} satisfies Meta<typeof Dialog>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\n/*\n * `open` renders the dialog open on load so the visual and axe runs capture the\n * popup, not the trigger. `modal` is the dialog as an app shows it, over the\n * whole page (one per story). `inline` is non-modal and belongs inside an\n * OverlayStage, so several open dialogs can share one capture: two open modal\n * dialogs would each hide the other from assistive tech.\n */\ntype OpenMode = 'modal' | 'inline'\n\nfunction RenameDialog({\n open,\n portalContainerRef,\n size = 'md',\n triggerLabel = 'Rename project',\n}: {\n open?: OpenMode\n portalContainerRef?: RefObject<HTMLDivElement | null>\n size?: (typeof dialogSizes)[number]\n triggerLabel?: string\n}) {\n return (\n <Dialog defaultOpen={open !== undefined} modal={open === 'inline' ? false : undefined}>\n {open ? null : <DialogTrigger render={<Button variant=\"outline\">{triggerLabel}</Button>} />}\n <DialogPopup\n initialFocus={open === 'inline' ? false : undefined}\n portalProps={{ container: portalContainerRef }}\n size={size}\n >\n <DialogHeader>\n <DialogTitle>Rename project</DialogTitle>\n <DialogDescription>Give this project a new, memorable name.</DialogDescription>\n </DialogHeader>\n <DialogPanel>\n <p style={{ margin: 0 }}>Any content can live in the scrollable panel.</p>\n </DialogPanel>\n <DialogFooter>\n <DialogClose render={<Button variant=\"ghost\">Cancel</Button>} />\n <DialogClose render={<Button variant=\"primary\">Save</Button>} />\n </DialogFooter>\n </DialogPopup>\n </Dialog>\n )\n}\n\n/* A labelled stage cell. It paints its own panel surface so the label reads\n against the cell's theme and mode, not the light page behind the story. */\nconst cellStyle: CSSProperties = {\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'grid',\n gap: 6,\n padding: 12,\n}\n\n/*\n * A fixed-height box that holds one open overlay. The transform makes the box\n * the containing block of the popup's fixed-position backdrop and viewport, and\n * --a63-viewport-height sizes them to the box, so the overlay lays out as it\n * would over a short window.\n */\nfunction OverlayStage({\n children,\n height = 340,\n}: {\n children: (container: RefObject<HTMLDivElement | null>) => ReactNode\n height?: number\n}) {\n const containerRef = useRef<HTMLDivElement>(null)\n return (\n <div\n ref={containerRef}\n style={\n {\n '--a63-viewport-height': `${height}px`,\n background: 'var(--a63-surface-page)',\n blockSize: height,\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n overflow: 'hidden',\n position: 'relative',\n transform: 'translateZ(0)',\n } as CSSProperties\n }\n >\n {children(containerRef)}\n </div>\n )\n}\n\ntype ProviderProps = Omit<ComponentProps<typeof UIProvider>, 'children'>\n\nfunction ReviewCell({ label, providerProps }: { label: string; providerProps: ProviderProps }) {\n return (\n <UIProvider {...providerProps}>\n <div style={cellStyle}>\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)' }}>{label}</span>\n <OverlayStage>\n {container => <RenameDialog open=\"inline\" portalContainerRef={container} />}\n </OverlayStage>\n </div>\n </UIProvider>\n )\n}\n\nexport const Playground: Story = {\n render: () => <RenameDialog triggerLabel=\"Open dialog\" />,\n}\n\n/** The dialog open as an app shows it: modal, centred over the page. */\nexport const Open: Story = {\n render: () => <RenameDialog open=\"modal\" />,\n}\n\n/** Below `sm` the default popup sticks to the bottom edge. */\nexport const OpenPhone: Story = {\n render: () => <RenameDialog open=\"modal\" />,\n}\n\nexport const Sizes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12, inlineSize: '100%' }}>\n {dialogSizes.map(size => (\n <div key={size} style={cellStyle}>\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)' }}>{size}</span>\n <OverlayStage>\n {container => <RenameDialog open=\"inline\" portalContainerRef={container} size={size} />}\n </OverlayStage>\n </div>\n ))}\n </div>\n ),\n}\n\nexport const BareFooter: Story = {\n render: () => (\n <Dialog defaultOpen>\n <DialogPopup mobilePlacement=\"center\">\n <DialogHeader>\n <DialogTitle>Centered on mobile</DialogTitle>\n <DialogDescription>This popup stays centered at every breakpoint.</DialogDescription>\n </DialogHeader>\n <DialogFooter variant=\"bare\">\n <DialogClose render={<Button variant=\"primary\">Got it</Button>} />\n </DialogFooter>\n </DialogPopup>\n </Dialog>\n ),\n}\n\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12, inlineSize: '100%' }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <ReviewCell\n key={`${theme}-${mode}`}\n label={`${theme} / ${mode}`}\n providerProps={{ mode, theme }}\n />\n ))\n )}\n </div>\n ),\n}\n\nexport const Endpoints: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12, inlineSize: '100%' }}>\n <ReviewCell\n label=\"Web\"\n providerProps={{ density: 'comfortable', designLanguage: 'web', input: 'pointer' }}\n />\n <ReviewCell\n label=\"iOS touch\"\n providerProps={{ density: 'comfortable', designLanguage: 'ios', input: 'touch' }}\n />\n <ReviewCell\n label=\"Compact extension\"\n providerProps={{\n density: 'compact',\n designLanguage: 'web',\n input: 'pointer',\n surface: 'n2',\n }}\n />\n </div>\n ),\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(dialogContract, null, 2)}\n </pre>\n ),\n}\n"
|
|
9595
9682
|
},
|
|
9596
9683
|
"summary": "Dialog provides modal task structure, focus management, and responsive placement.",
|
|
9597
9684
|
"usage": "Give every dialog a title and a deliberate close path; use Alert Dialog for confirmation.",
|
|
@@ -10420,10 +10507,13 @@
|
|
|
10420
10507
|
"accordion-content-inner"
|
|
10421
10508
|
],
|
|
10422
10509
|
"source": "packages/ui-foundation/contracts/components/accordion.json",
|
|
10510
|
+
"stateAliases": {
|
|
10511
|
+
"focusVisible": "focus-visible"
|
|
10512
|
+
},
|
|
10423
10513
|
"states": [
|
|
10424
10514
|
"closed",
|
|
10425
10515
|
"open",
|
|
10426
|
-
"
|
|
10516
|
+
"focus-visible",
|
|
10427
10517
|
"disabled"
|
|
10428
10518
|
],
|
|
10429
10519
|
"tokenSlots": []
|
|
@@ -10451,7 +10541,7 @@
|
|
|
10451
10541
|
],
|
|
10452
10542
|
"importPath": "@atom63/ui-react",
|
|
10453
10543
|
"label": "Accordion",
|
|
10454
|
-
"markdown": "# Accordion\n\nAccordion coordinates a set of disclosure sections with shared keyboard behavior.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it when several related sections may be collapsed; use Collapsible for one disclosure.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { Accordion, AccordionItem, AccordionTrigger, AccordionContent } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Accordion`, `AccordionContent`, `AccordionItem`, `AccordionTrigger`\n\n**Types:** `AccordionProps`, `AccordionTriggerProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/accordion.json` (`accordionContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `iconVariants` | `chevron`, `plus-minus` | `chevron` |\n\n**Slots:** `accordion`, `accordion-item`, `accordion-trigger`, `accordion-indicator`, `accordion-content`, `accordion-content-inner`\n\n**States:** `closed`, `open`, `
|
|
10544
|
+
"markdown": "# Accordion\n\nAccordion coordinates a set of disclosure sections with shared keyboard behavior.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it when several related sections may be collapsed; use Collapsible for one disclosure.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { Accordion, AccordionItem, AccordionTrigger, AccordionContent } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Accordion`, `AccordionContent`, `AccordionItem`, `AccordionTrigger`\n\n**Types:** `AccordionProps`, `AccordionTriggerProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/accordion.json` (`accordionContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `iconVariants` | `chevron`, `plus-minus` | `chevron` |\n\n**Deprecated aliases:** `focusVisible` → `focus-visible` (states)\n\n**Slots:** `accordion`, `accordion-item`, `accordion-trigger`, `accordion-indicator`, `accordion-content`, `accordion-content-inner`\n\n**States:** `closed`, `open`, `focus-visible`, `disabled`\n\n**Visual archetype:** Static content surfaces — In-flow containers and content surfaces that do not inherently manipulate state.; Triggers — Controls whose primary job is to open another surface.\n\n**Accessibility pattern:** [Accordion](https://www.w3.org/WAI/ARIA/apg/patterns/accordion/) (collapse: collapsible, expand: single)\n\n### Web and iOS\n\nReveal or hide supporting content in place while preserving the surrounding context. Rendered by `DisclosureGroup` in SwiftUI, with `platform-adaptive` parity.\n\n**Required states:** `closed`, `open`, `disabled`\n\n**Shared outcomes:**\n\n- Activation toggles associated content visibility\n- Expanded state matches content visibility\n- Disabled trigger prevents disclosure change\n\n**Accessibility outcomes:**\n\n- Trigger exposes expanded state\n- Trigger is associated with disclosed content\n- Disabled trigger exposes disabled state\n\n**Platform adaptations:**\n\n- React: Uses button and region disclosure semantics with optional single or multiple open sections.\n- SwiftUI: Uses DisclosureGroup with native indicator geometry, animation, and list integration.\n\n## Related components\n\n- [Collapsible](/components/component-collapsible)\n- [Tabs](/components/component-tabs)\n",
|
|
10455
10545
|
"related": [
|
|
10456
10546
|
"collapsible",
|
|
10457
10547
|
"tabs"
|
|
@@ -10784,6 +10874,113 @@
|
|
|
10784
10874
|
"AppView"
|
|
10785
10875
|
]
|
|
10786
10876
|
},
|
|
10877
|
+
{
|
|
10878
|
+
"axisGuidance": null,
|
|
10879
|
+
"contract": {
|
|
10880
|
+
"archetypes": [
|
|
10881
|
+
{
|
|
10882
|
+
"description": "In-flow containers and content surfaces that do not inherently manipulate state.",
|
|
10883
|
+
"id": "surface",
|
|
10884
|
+
"label": "Static content surfaces"
|
|
10885
|
+
}
|
|
10886
|
+
],
|
|
10887
|
+
"axes": [
|
|
10888
|
+
{
|
|
10889
|
+
"name": "sizes",
|
|
10890
|
+
"values": [
|
|
10891
|
+
"viewport",
|
|
10892
|
+
"band",
|
|
10893
|
+
"card"
|
|
10894
|
+
],
|
|
10895
|
+
"default": "viewport"
|
|
10896
|
+
},
|
|
10897
|
+
{
|
|
10898
|
+
"name": "safeAreas",
|
|
10899
|
+
"values": [
|
|
10900
|
+
"top",
|
|
10901
|
+
"bottom",
|
|
10902
|
+
"center",
|
|
10903
|
+
"start",
|
|
10904
|
+
"end"
|
|
10905
|
+
],
|
|
10906
|
+
"default": "top"
|
|
10907
|
+
},
|
|
10908
|
+
{
|
|
10909
|
+
"name": "tones",
|
|
10910
|
+
"values": [
|
|
10911
|
+
"page",
|
|
10912
|
+
"media"
|
|
10913
|
+
],
|
|
10914
|
+
"default": "page"
|
|
10915
|
+
},
|
|
10916
|
+
{
|
|
10917
|
+
"name": "veils",
|
|
10918
|
+
"values": [
|
|
10919
|
+
"none",
|
|
10920
|
+
"soft",
|
|
10921
|
+
"strong"
|
|
10922
|
+
],
|
|
10923
|
+
"default": "none"
|
|
10924
|
+
}
|
|
10925
|
+
],
|
|
10926
|
+
"exportName": "artPlateContract",
|
|
10927
|
+
"slots": [
|
|
10928
|
+
"art-plate",
|
|
10929
|
+
"art-plate-image",
|
|
10930
|
+
"art-plate-content"
|
|
10931
|
+
],
|
|
10932
|
+
"source": "packages/ui-foundation/contracts/components/art-plate.json",
|
|
10933
|
+
"states": [
|
|
10934
|
+
"rest"
|
|
10935
|
+
],
|
|
10936
|
+
"tokenSlots": []
|
|
10937
|
+
},
|
|
10938
|
+
"exports": {
|
|
10939
|
+
"types": [
|
|
10940
|
+
"ArtPlateFocus",
|
|
10941
|
+
"ArtPlateProps"
|
|
10942
|
+
],
|
|
10943
|
+
"values": [
|
|
10944
|
+
"ArtPlate"
|
|
10945
|
+
]
|
|
10946
|
+
},
|
|
10947
|
+
"group": {
|
|
10948
|
+
"id": "content-and-surfaces",
|
|
10949
|
+
"title": "Content and surfaces"
|
|
10950
|
+
},
|
|
10951
|
+
"guidance": [
|
|
10952
|
+
"Use Art Plate for a landing hero, a section band or a portfolio cover where the picture leads and content sits in a calm region of it.",
|
|
10953
|
+
"Keep product data and fetching outside the presentational component.",
|
|
10954
|
+
"Test long, empty, and narrow content before adding local layout overrides."
|
|
10955
|
+
],
|
|
10956
|
+
"importPath": "@atom63/ui-react",
|
|
10957
|
+
"label": "Art Plate",
|
|
10958
|
+
"markdown": "# Art Plate\n\nArt Plate shows a full-bleed picture that owns its crop and keeps a safe area for headline and product UI.\n\n**Status:** Preview\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use Art Plate for a landing hero, a section band or a portfolio cover where the picture leads and content sits in a calm region of it.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { ArtPlate } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `ArtPlate`\n\n**Types:** `ArtPlateFocus`, `ArtPlateProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/art-plate.json` (`artPlateContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `sizes` | `viewport`, `band`, `card` | `viewport` |\n| `safeAreas` | `top`, `bottom`, `center`, `start`, `end` | `top` |\n| `tones` | `page`, `media` | `page` |\n| `veils` | `none`, `soft`, `strong` | `none` |\n\n**Slots:** `art-plate`, `art-plate-image`, `art-plate-content`\n\n**States:** `rest`\n\n**Visual archetype:** Static content surfaces — In-flow containers and content surfaces that do not inherently manipulate state.\n\n## Related components\n\n- [Card](/components/component-card)\n- [Frame](/components/component-frame)\n- [Progressive Blur](/components/component-progressive-blur)\n",
|
|
10959
|
+
"related": [
|
|
10960
|
+
"card",
|
|
10961
|
+
"frame",
|
|
10962
|
+
"progressive-blur"
|
|
10963
|
+
],
|
|
10964
|
+
"route": "/components/component-art-plate",
|
|
10965
|
+
"slug": "art-plate",
|
|
10966
|
+
"status": "preview",
|
|
10967
|
+
"stories": {
|
|
10968
|
+
"file": "packages/ui-react/src/components/art-plate/art-plate.stories.tsx",
|
|
10969
|
+
"names": [
|
|
10970
|
+
"Playground",
|
|
10971
|
+
"Viewport",
|
|
10972
|
+
"SafeAreas",
|
|
10973
|
+
"Card",
|
|
10974
|
+
"Themes"
|
|
10975
|
+
],
|
|
10976
|
+
"source": "import {\n artPlateSafeAreas,\n artPlateSizes,\n artPlateTones,\n artPlateVeils,\n themes,\n} from '@atom63/ui-foundation'\nimport { ArtPlate, Button, UIProvider } from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\n// Remote pictures are pinned to one placeholder in the visual and craft runs.\nconst PLATE = 'https://picsum.photos/id/1018/1920/1080'\n\nconst meta = {\n title: 'UI React/ArtPlate',\n component: ArtPlate,\n parameters: { layout: 'fullscreen' },\n argTypes: {\n safeArea: { control: 'inline-radio', options: artPlateSafeAreas },\n size: { control: 'inline-radio', options: artPlateSizes },\n tone: { control: 'inline-radio', options: artPlateTones },\n veil: { control: 'inline-radio', options: artPlateVeils },\n },\n args: {\n alt: '',\n focus: { x: 0.5, y: 0.7 },\n safeArea: 'top',\n size: 'band',\n src: PLATE,\n tone: 'media',\n veil: 'soft',\n },\n} satisfies Meta<typeof ArtPlate>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nfunction HeroCopy() {\n return (\n <div style={{ display: 'grid', gap: 'var(--a63-space-4)', maxInlineSize: '36rem' }}>\n <h1\n style={{\n margin: 0,\n fontSize: 'var(--a63-type-display-large-font-size)',\n lineHeight: 'var(--a63-type-display-large-line-height)',\n }}\n >\n Render at the speed of thought\n </h1>\n <p style={{ margin: 0 }}>A motion timeline that renders in the browser.</p>\n <div style={{ display: 'flex', gap: 'var(--a63-space-2)' }}>\n <Button>Start free</Button>\n <Button variant=\"outline\">Read the docs</Button>\n </div>\n </div>\n )\n}\n\nexport const Playground: Story = {\n render: args => (\n <ArtPlate {...args}>\n <HeroCopy />\n </ArtPlate>\n ),\n}\n\nexport const Viewport: Story = {\n args: { priority: true, size: 'viewport', safeArea: 'center' },\n render: args => (\n <ArtPlate {...args}>\n <HeroCopy />\n </ArtPlate>\n ),\n}\n\nexport const SafeAreas: Story = {\n render: args => (\n <div style={{ display: 'grid', gap: 'var(--a63-space-4)' }}>\n {artPlateSafeAreas.map(safeArea => (\n <ArtPlate key={safeArea} {...args} safeArea={safeArea}>\n <p style={{ margin: 0 }}>safeArea="{safeArea}"</p>\n </ArtPlate>\n ))}\n </div>\n ),\n}\n\nexport const Card: Story = {\n args: { size: 'card', safeArea: 'bottom', veil: 'strong' },\n render: args => (\n <div style={{ padding: 'var(--a63-space-6)' }}>\n <ArtPlate {...args}>\n <p style={{ margin: 0 }}>Ship your next render tonight.</p>\n </ArtPlate>\n </div>\n ),\n}\n\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 'var(--a63-space-3)' }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={`${theme}-${mode}`} mode={mode} theme={theme}>\n <div style={{ background: 'var(--a63-surface-page)', padding: 'var(--a63-space-3)' }}>\n <ArtPlate alt=\"\" safeArea=\"start\" size=\"card\" src={PLATE} tone=\"page\" veil=\"strong\">\n <p style={{ margin: 0 }}>\n {theme} / {mode}\n </p>\n </ArtPlate>\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n"
|
|
10977
|
+
},
|
|
10978
|
+
"summary": "Art Plate shows a full-bleed picture that owns its crop and keeps a safe area for headline and product UI.",
|
|
10979
|
+
"usage": "Use Art Plate for a landing hero, a section band or a portfolio cover where the picture leads and content sits in a calm region of it.",
|
|
10980
|
+
"usageExports": [
|
|
10981
|
+
"ArtPlate"
|
|
10982
|
+
]
|
|
10983
|
+
},
|
|
10787
10984
|
{
|
|
10788
10985
|
"axisGuidance": null,
|
|
10789
10986
|
"contract": {
|
|
@@ -10823,10 +11020,13 @@
|
|
|
10823
11020
|
"values": [
|
|
10824
11021
|
"xs",
|
|
10825
11022
|
"sm",
|
|
10826
|
-
"
|
|
11023
|
+
"md",
|
|
10827
11024
|
"lg"
|
|
10828
11025
|
],
|
|
10829
|
-
"
|
|
11026
|
+
"deprecatedAliases": {
|
|
11027
|
+
"default": "md"
|
|
11028
|
+
},
|
|
11029
|
+
"default": "md"
|
|
10830
11030
|
}
|
|
10831
11031
|
],
|
|
10832
11032
|
"crossRenderer": {
|
|
@@ -10901,7 +11101,7 @@
|
|
|
10901
11101
|
],
|
|
10902
11102
|
"importPath": "@atom63/ui-react",
|
|
10903
11103
|
"label": "Avatar",
|
|
10904
|
-
"markdown": "# Avatar\n\nAvatar composes an image, fallback, badge, and grouped identity presentation.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Provide meaningful image alternative text and a stable fallback for failed or missing media.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { Avatar, AvatarImage, AvatarFallback } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Avatar`, `AvatarBadge`, `AvatarFallback`, `AvatarGroup`, `AvatarGroupCount`, `AvatarImage`, `AvatarPrimitive`\n\n**Types:** `AvatarProps`, `AvatarSize`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/avatar.json` (`avatarContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `compositions` | `standalone`, `badge`, `group` | — |\n| `rings` | `unseen`, `seen` | — |\n| `shapes` | `circle`, `square` | `circle` |\n| `sizes` | `xs`, `sm`, `
|
|
11104
|
+
"markdown": "# Avatar\n\nAvatar composes an image, fallback, badge, and grouped identity presentation.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Provide meaningful image alternative text and a stable fallback for failed or missing media.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { Avatar, AvatarImage, AvatarFallback } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Avatar`, `AvatarBadge`, `AvatarFallback`, `AvatarGroup`, `AvatarGroupCount`, `AvatarImage`, `AvatarPrimitive`\n\n**Types:** `AvatarProps`, `AvatarSize`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/avatar.json` (`avatarContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `compositions` | `standalone`, `badge`, `group` | — |\n| `rings` | `unseen`, `seen` | — |\n| `shapes` | `circle`, `square` | `circle` |\n| `sizes` | `xs`, `sm`, `md`, `lg` | `md` |\n\n**Deprecated aliases:** `default` → `md` (sizes)\n\n**Slots:** `avatar`, `avatar-image`, `avatar-fallback`, `avatar-badge`, `avatar-group`, `avatar-group-count`\n\n**States:** `loading`, `loaded`, `fallback`\n\n**Visual archetype:** Markers and keycaps — Compact presentational labels, statuses, and keyboard hints.\n\n### Web and iOS\n\nRepresent a person or entity with an image and identity-preserving fallback. Rendered by `AtomAvatar` in SwiftUI, with `strict` parity.\n\n**Required states:** `loading`, `loaded`, `fallback`\n\n**Shared outcomes:**\n\n- Accessible name is preserved\n- Fallback preserves identity\n- Loading does not expose empty image\n\n**Accessibility outcomes:**\n\n- Exposes accessible name\n- Fallback preserves identity\n\n**Platform adaptations:**\n\n- React: Uses browser image loading and DOM fallback composition.\n- React: The square shape and the ring are web-only for now.\n- SwiftUI: Uses native image decoding and SwiftUI loading phases.\n- SwiftUI: AtomAvatar(badge:) pins a status dot (.dot) or a count (.count) to the corner, read after the name.\n\n## Related components\n\n- [Badge](/components/component-badge)\n- [Item](/components/component-item)\n",
|
|
10905
11105
|
"related": [
|
|
10906
11106
|
"badge",
|
|
10907
11107
|
"item"
|
|
@@ -10925,7 +11125,7 @@
|
|
|
10925
11125
|
"Endpoints",
|
|
10926
11126
|
"ContractMetadata"
|
|
10927
11127
|
],
|
|
10928
|
-
"source": "import { avatarContract, avatarSizes, themes } from '@atom63/ui-foundation'\nimport {\n Avatar,\n AvatarBadge,\n AvatarFallback,\n AvatarGroup,\n AvatarGroupCount,\n AvatarImage,\n UIProvider,\n} from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\nimport { Sparkles } from 'lucide-react'\nimport type { CSSProperties } from 'react'\n\nconst meta = {\n title: 'UI React/Avatar',\n component: Avatar,\n args: { size: '
|
|
11128
|
+
"source": "import { avatarContract, avatarSizes, themes } from '@atom63/ui-foundation'\nimport {\n Avatar,\n AvatarBadge,\n AvatarFallback,\n AvatarGroup,\n AvatarGroupCount,\n AvatarImage,\n UIProvider,\n} from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\nimport { Sparkles } from 'lucide-react'\nimport type { CSSProperties } from 'react'\n\nconst meta = {\n title: 'UI React/Avatar',\n component: Avatar,\n args: { size: 'md' },\n argTypes: { size: { control: 'inline-radio', options: avatarSizes } },\n} satisfies Meta<typeof Avatar>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nconst SRC = 'https://i.pravatar.cc/80?img=12'\n\nexport const Playground: Story = {\n render: args => (\n <Avatar {...args}>\n <AvatarImage src={SRC} alt=\"Ada\" />\n <AvatarFallback>AL</AvatarFallback>\n </Avatar>\n ),\n}\n\nexport const Sizes: Story = {\n render: () => (\n <div style={{ alignItems: 'center', display: 'flex', gap: 16 }}>\n <Avatar size=\"xs\">\n <AvatarImage src={SRC} alt=\"Ada\" />\n <AvatarFallback>AL</AvatarFallback>\n </Avatar>\n <Avatar size=\"sm\">\n <AvatarImage src={SRC} alt=\"Ada\" />\n <AvatarFallback>AL</AvatarFallback>\n </Avatar>\n <Avatar size=\"md\">\n <AvatarImage src={SRC} alt=\"Ada\" />\n <AvatarFallback>AL</AvatarFallback>\n </Avatar>\n <Avatar size=\"lg\">\n <AvatarImage src={SRC} alt=\"Ada\" />\n <AvatarFallback>AL</AvatarFallback>\n </Avatar>\n </div>\n ),\n}\n\n/* An icon fallback, such as an assistant's sparkle, sits in the filled circle at\n the control icon size for each size step. */\nexport const IconFallback: Story = {\n render: () => (\n <div style={{ alignItems: 'center', display: 'flex', gap: 16 }}>\n {avatarSizes.map(size => (\n <Avatar key={size} size={size}>\n <AvatarFallback>\n <Sparkles aria-hidden />\n </AvatarFallback>\n </Avatar>\n ))}\n </div>\n ),\n}\n\n/* A 76px avatar stays a circle: the default reads --a63-avatar-radius (50%), and\n without that contract the fallback is --radius-pill, not the soft --radius-full. */\nexport const LargeCircle: Story = {\n render: () => (\n <div style={{ alignItems: 'center', display: 'flex', gap: 16 }}>\n <Avatar data-testid=\"contract\" style={{ '--avatar-size': '76px' } as CSSProperties}>\n <AvatarFallback>AL</AvatarFallback>\n </Avatar>\n <Avatar\n data-testid=\"fallback\"\n style={{ '--avatar-size': '76px', '--a63-avatar-radius': 'initial' } as CSSProperties}\n >\n <AvatarFallback>YZ</AvatarFallback>\n </Avatar>\n </div>\n ),\n play: ({ canvasElement }) => {\n const radius = (testId: string) => {\n const avatar = canvasElement.querySelector<HTMLElement>(`[data-testid=\"${testId}\"]`)\n return avatar ? getComputedStyle(avatar).borderTopLeftRadius : null\n }\n const actual = [radius('contract'), radius('fallback')]\n if (actual[0] !== '50%' || actual[1] !== '9999px') {\n throw new Error(`Expected radii 50% and 9999px, got ${actual.join(' and ')}`)\n }\n },\n}\n\n/* shape=\"square\" for organisations and apps; ring marks new activity. */\nexport const ShapesAndRing: Story = {\n render: () => (\n <div style={{ alignItems: 'center', display: 'flex', gap: 16 }}>\n <Avatar>\n <AvatarFallback>AL</AvatarFallback>\n </Avatar>\n <Avatar shape=\"square\">\n <AvatarFallback>NW</AvatarFallback>\n </Avatar>\n <Avatar ring>\n <AvatarFallback>JL</AvatarFallback>\n </Avatar>\n <Avatar ring shape=\"square\" size=\"lg\">\n <AvatarFallback>PS</AvatarFallback>\n </Avatar>\n <Avatar shape=\"square\" size=\"xs\">\n <AvatarFallback>A</AvatarFallback>\n </Avatar>\n </div>\n ),\n}\n\n/*\n * Story rings: unseen draws --a63-avatar-ring-fill, which a product can set to a\n * gradient of the category palette (see the content-colors rule); seen is a\n * thin border-coloured ring.\n */\nexport const StoryRings: Story = {\n render: () => (\n <div\n style={\n {\n '--a63-avatar-ring-fill':\n 'conic-gradient(from 210deg, var(--a63-category-amber), var(--a63-category-orange), var(--a63-category-pink), var(--a63-category-purple), var(--a63-category-amber))',\n alignItems: 'flex-start',\n display: 'flex',\n gap: 20,\n padding: 8,\n } as CSSProperties\n }\n >\n {[\n { name: 'Your story', ring: 'unseen', initials: 'YZ' },\n { name: 'Ada', ring: 'unseen', initials: 'AD' },\n { name: 'Lin', ring: 'seen', initials: 'LI' },\n { name: 'Sam', ring: 'seen', initials: 'SA' },\n ].map(story => (\n <figure\n key={story.name}\n style={{\n alignItems: 'center',\n display: 'flex',\n flexDirection: 'column',\n gap: 8,\n margin: 0,\n }}\n >\n <Avatar ring={story.ring as 'unseen' | 'seen'} size=\"lg\">\n <AvatarFallback>{story.initials}</AvatarFallback>\n </Avatar>\n <figcaption style={{ fontSize: 12 }}>{story.name}</figcaption>\n </figure>\n ))}\n </div>\n ),\n}\n\n/* Fallback shows when no image resolves — the muted initials chip. */\nexport const Fallback: Story = {\n render: () => (\n <Avatar>\n <AvatarFallback>YZ</AvatarFallback>\n </Avatar>\n ),\n}\n\n/* A status Badge pinned to the corner, ringed against the page. */\nexport const WithBadge: Story = {\n render: () => (\n <Avatar>\n <AvatarImage src={SRC} alt=\"Ada\" />\n <AvatarFallback>AL</AvatarFallback>\n <AvatarBadge />\n </Avatar>\n ),\n}\n\n/* A stacked group with an overflow count. */\nexport const Group: Story = {\n render: () => (\n <AvatarGroup>\n <Avatar>\n <AvatarImage src=\"https://i.pravatar.cc/80?img=1\" alt=\"One\" />\n <AvatarFallback>1</AvatarFallback>\n </Avatar>\n <Avatar>\n <AvatarImage src=\"https://i.pravatar.cc/80?img=2\" alt=\"Two\" />\n <AvatarFallback>2</AvatarFallback>\n </Avatar>\n <Avatar>\n <AvatarImage src=\"https://i.pravatar.cc/80?img=3\" alt=\"Three\" />\n <AvatarFallback>3</AvatarFallback>\n </Avatar>\n <AvatarGroupCount>+5</AvatarGroupCount>\n </AvatarGroup>\n ),\n}\n\n/* The avatar frame, fallback chip and status badge across all 4 DS themes × light/dark. */\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={theme + mode} mode={mode} theme={theme}>\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 96 }}>\n {theme} / {mode}\n </span>\n <Avatar>\n <AvatarImage src={SRC} alt=\"Ada\" />\n <AvatarFallback>AL</AvatarFallback>\n <AvatarBadge />\n </Avatar>\n <Avatar>\n <AvatarFallback>YZ</AvatarFallback>\n </Avatar>\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\nexport const Endpoints: Story = {\n render: () => (\n <div\n style={{\n display: 'grid',\n gap: '1rem',\n gridTemplateColumns: 'repeat(auto-fit, minmax(14rem, 1fr))',\n }}\n >\n {[\n { label: 'web / pointer', props: { designLanguage: 'web', input: 'pointer' } as const },\n { label: 'ios / touch', props: { designLanguage: 'ios', input: 'touch' } as const },\n {\n label: 'extension / compact',\n props: { density: 'compact', designLanguage: 'web', input: 'pointer' } as const,\n },\n ].map(({ label, props }) => (\n <UIProvider key={label} {...props}>\n <div\n style={{\n background: 'var(--a63-surface-panel)',\n border: '1px solid var(--a63-border-subtle)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'grid',\n gap: '0.75rem',\n padding: '1rem',\n }}\n >\n <span style={{ color: 'var(--a63-text-secondary)', fontSize: 12 }}>{label}</span>\n <AvatarGroup>\n <Avatar>\n <AvatarImage alt=\"Ada\" src={SRC} />\n <AvatarFallback>AL</AvatarFallback>\n </Avatar>\n <Avatar>\n <AvatarFallback>YZ</AvatarFallback>\n </Avatar>\n <AvatarGroupCount>+3</AvatarGroupCount>\n </AvatarGroup>\n </div>\n </UIProvider>\n ))}\n </div>\n ),\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(avatarContract, null, 2)}\n </pre>\n ),\n}\n"
|
|
10929
11129
|
},
|
|
10930
11130
|
"summary": "Avatar composes an image, fallback, badge, and grouped identity presentation.",
|
|
10931
11131
|
"usage": "Provide meaningful image alternative text and a stable fallback for failed or missing media.",
|
|
@@ -11049,8 +11249,11 @@
|
|
|
11049
11249
|
"badge-dot"
|
|
11050
11250
|
],
|
|
11051
11251
|
"source": "packages/ui-foundation/contracts/components/badge.json",
|
|
11252
|
+
"stateAliases": {
|
|
11253
|
+
"resting": "rest"
|
|
11254
|
+
},
|
|
11052
11255
|
"states": [
|
|
11053
|
-
"
|
|
11256
|
+
"rest",
|
|
11054
11257
|
"interactive",
|
|
11055
11258
|
"disabled",
|
|
11056
11259
|
"focus-visible"
|
|
@@ -11076,7 +11279,7 @@
|
|
|
11076
11279
|
],
|
|
11077
11280
|
"importPath": "@atom63/ui-react",
|
|
11078
11281
|
"label": "Badge",
|
|
11079
|
-
"markdown": "# Badge\n\nBadge carries compact status or classification metadata beside primary content.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Keep badges short and non-interactive unless the surrounding semantic element owns the action.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { Badge } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Badge`\n\n**Types:** `BadgeProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/badge.json` (`badgeContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `default`, `primary`, `secondary`, `destructive`, `outline`, `glass`, `muted`, `accent`, `error`, `info`, `success`, `warning`, `red`, `orange`, `amber`, `yellow`, `lime`, `green`, `emerald`, `teal`, `cyan`, `sky`, `blue`, `indigo`, `violet`, `purple`, `fuchsia`, `pink`, `rose`, `neutral` | `default` |\n| `sizes` | `sm`, `md`, `lg` | `md` |\n| `dotColors` | `red`, `orange`, `amber`, `yellow`, `lime`, `green`, `emerald`, `teal`, `cyan`, `sky`, `blue`, `indigo`, `violet`, `purple`, `fuchsia`, `pink`, `rose`, `neutral` | — |\n\n**Slots:** `badge`, `badge-dot`\n\n**States:** `
|
|
11282
|
+
"markdown": "# Badge\n\nBadge carries compact status or classification metadata beside primary content.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Keep badges short and non-interactive unless the surrounding semantic element owns the action.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { Badge } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Badge`\n\n**Types:** `BadgeProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/badge.json` (`badgeContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `default`, `primary`, `secondary`, `destructive`, `outline`, `glass`, `muted`, `accent`, `error`, `info`, `success`, `warning`, `red`, `orange`, `amber`, `yellow`, `lime`, `green`, `emerald`, `teal`, `cyan`, `sky`, `blue`, `indigo`, `violet`, `purple`, `fuchsia`, `pink`, `rose`, `neutral` | `default` |\n| `sizes` | `sm`, `md`, `lg` | `md` |\n| `dotColors` | `red`, `orange`, `amber`, `yellow`, `lime`, `green`, `emerald`, `teal`, `cyan`, `sky`, `blue`, `indigo`, `violet`, `purple`, `fuchsia`, `pink`, `rose`, `neutral` | — |\n\n**Deprecated aliases:** `resting` → `rest` (states)\n\n**Slots:** `badge`, `badge-dot`\n\n**States:** `rest`, `interactive`, `disabled`, `focus-visible`\n\n**Visual archetype:** Markers and keycaps — Compact presentational labels, statuses, and keyboard hints.\n\n### Web and iOS\n\nCommunicate a compact label or semantic status alongside primary content. Rendered by `AtomBadge` in SwiftUI, with `strict` parity.\n\n**Required states:** `neutral`, `accent`, `success`, `warning`, `error`\n\n**Shared outcomes:**\n\n- Label remains readable without color\n- Semantic tone retains meaning\n\n**Accessibility outcomes:**\n\n- Text does not rely on color\n\n**Platform adaptations:**\n\n- React: May expose palette-only decorative variants outside the shared semantic subset.\n- React: May show a leading category dot (dot prop).\n- SwiftUI: Uses a compact capsule that expands for Dynamic Type.\n\n## Related components\n\n- [Avatar](/components/component-avatar)\n- [Kbd](/components/component-kbd)\n- [Alert](/components/component-alert)\n",
|
|
11080
11283
|
"related": [
|
|
11081
11284
|
"avatar",
|
|
11082
11285
|
"kbd",
|
|
@@ -12002,8 +12205,11 @@
|
|
|
12002
12205
|
"feedback-state-content"
|
|
12003
12206
|
],
|
|
12004
12207
|
"source": "packages/ui-foundation/contracts/components/feedback-state.json",
|
|
12208
|
+
"stateAliases": {
|
|
12209
|
+
"idle": "rest"
|
|
12210
|
+
},
|
|
12005
12211
|
"states": [
|
|
12006
|
-
"
|
|
12212
|
+
"rest",
|
|
12007
12213
|
"busy",
|
|
12008
12214
|
"actionable"
|
|
12009
12215
|
],
|
|
@@ -12033,7 +12239,7 @@
|
|
|
12033
12239
|
],
|
|
12034
12240
|
"importPath": "@atom63/ui-react",
|
|
12035
12241
|
"label": "Feedback State",
|
|
12036
|
-
"markdown": "# Feedback State\n\nFeedback State packages common empty, error, and no-results messages with actions.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Choose the kind that matches the recovery path and keep technical detail secondary.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { FeedbackState } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `FeedbackState`\n\n**Types:** `FeedbackStateAction`, `FeedbackStateIcon`, `FeedbackStateIconName`, `FeedbackStateKind`, `FeedbackStateProps`, `FeedbackStateSize`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/feedback-state.json` (`feedbackStateContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `kinds` | `empty`, `error`, `loading`, `not-found`, `no-results`, `offline`, `stale` | `empty` |\n| `sizes` | `inline`, `panel`, `page`, `widget` | `panel` |\n\n**Slots:** `feedback-state`, `feedback-state-header`, `feedback-state-media`, `feedback-state-title`, `feedback-state-description`, `feedback-state-content`\n\n**States:** `
|
|
12242
|
+
"markdown": "# Feedback State\n\nFeedback State packages common empty, error, and no-results messages with actions.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Choose the kind that matches the recovery path and keep technical detail secondary.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { FeedbackState } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `FeedbackState`\n\n**Types:** `FeedbackStateAction`, `FeedbackStateIcon`, `FeedbackStateIconName`, `FeedbackStateKind`, `FeedbackStateProps`, `FeedbackStateSize`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/feedback-state.json` (`feedbackStateContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `kinds` | `empty`, `error`, `loading`, `not-found`, `no-results`, `offline`, `stale` | `empty` |\n| `sizes` | `inline`, `panel`, `page`, `widget` | `panel` |\n\n**Deprecated aliases:** `idle` → `rest` (states)\n\n**Slots:** `feedback-state`, `feedback-state-header`, `feedback-state-media`, `feedback-state-title`, `feedback-state-description`, `feedback-state-content`\n\n**States:** `rest`, `busy`, `actionable`\n\n**Visual archetype:** Action controls — Momentary controls that perform an action now.\n\n## Related components\n\n- [Empty](/components/component-empty)\n- [Alert](/components/component-alert)\n- [Toaster](/components/component-toaster)\n",
|
|
12037
12243
|
"related": [
|
|
12038
12244
|
"empty",
|
|
12039
12245
|
"alert",
|
|
@@ -12117,8 +12323,11 @@
|
|
|
12117
12323
|
"frame-panel-footer"
|
|
12118
12324
|
],
|
|
12119
12325
|
"source": "packages/ui-foundation/contracts/components/frame.json",
|
|
12326
|
+
"stateAliases": {
|
|
12327
|
+
"default": "rest"
|
|
12328
|
+
},
|
|
12120
12329
|
"states": [
|
|
12121
|
-
"
|
|
12330
|
+
"rest",
|
|
12122
12331
|
"border-off",
|
|
12123
12332
|
"border-subtle",
|
|
12124
12333
|
"border-strong"
|
|
@@ -12150,7 +12359,7 @@
|
|
|
12150
12359
|
],
|
|
12151
12360
|
"importPath": "@atom63/ui-react",
|
|
12152
12361
|
"label": "Frame",
|
|
12153
|
-
"markdown": "# Frame\n\nFrame composes header, panel, description, and footer regions into a chrome-aware surface.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it for application chrome with distinct regions; use Card for content-first composition.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { Frame, FrameHeader, FrameTitle, FramePanel } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Frame`, `FrameDescription`, `FrameFooter`, `FrameHeader`, `FramePanel`, `FrameTitle`\n\n**Types:** `FramePanelProps`, `FrameProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/frame.json` (`frameContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `muted-background`, `muted-card` | `muted-background` |\n| `trays` | `muted`, `card`, `background` | — |\n| `panelSurfaces` | `background`, `card`, `muted` | — |\n| `borders` | `off`, `subtle`, `strong` | `strong` |\n\n**Slots:** `frame`, `frame-panel`, `frame-panel-header`, `frame-panel-title`, `frame-panel-description`, `frame-panel-footer`\n\n**States:** `
|
|
12362
|
+
"markdown": "# Frame\n\nFrame composes header, panel, description, and footer regions into a chrome-aware surface.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use it for application chrome with distinct regions; use Card for content-first composition.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { Frame, FrameHeader, FrameTitle, FramePanel } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Frame`, `FrameDescription`, `FrameFooter`, `FrameHeader`, `FramePanel`, `FrameTitle`\n\n**Types:** `FramePanelProps`, `FrameProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/frame.json` (`frameContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `muted-background`, `muted-card` | `muted-background` |\n| `trays` | `muted`, `card`, `background` | — |\n| `panelSurfaces` | `background`, `card`, `muted` | — |\n| `borders` | `off`, `subtle`, `strong` | `strong` |\n\n**Deprecated aliases:** `default` → `rest` (states)\n\n**Slots:** `frame`, `frame-panel`, `frame-panel-header`, `frame-panel-title`, `frame-panel-description`, `frame-panel-footer`\n\n**States:** `rest`, `border-off`, `border-subtle`, `border-strong`\n\n**Visual archetype:** Static content surfaces — In-flow containers and content surfaces that do not inherently manipulate state.\n\n## Related components\n\n- [Card](/components/component-card)\n- [Connected Panel](/components/component-connected-panel)\n",
|
|
12154
12363
|
"related": [
|
|
12155
12364
|
"card",
|
|
12156
12365
|
"connected-panel"
|
|
@@ -12202,11 +12411,14 @@
|
|
|
12202
12411
|
{
|
|
12203
12412
|
"name": "sizes",
|
|
12204
12413
|
"values": [
|
|
12205
|
-
"
|
|
12414
|
+
"md",
|
|
12206
12415
|
"sm",
|
|
12207
12416
|
"xs"
|
|
12208
12417
|
],
|
|
12209
|
-
"
|
|
12418
|
+
"deprecatedAliases": {
|
|
12419
|
+
"default": "md"
|
|
12420
|
+
},
|
|
12421
|
+
"default": "md"
|
|
12210
12422
|
},
|
|
12211
12423
|
{
|
|
12212
12424
|
"name": "mediaVariants",
|
|
@@ -12287,10 +12499,13 @@
|
|
|
12287
12499
|
"item-separator"
|
|
12288
12500
|
],
|
|
12289
12501
|
"source": "packages/ui-foundation/contracts/components/item.json",
|
|
12502
|
+
"stateAliases": {
|
|
12503
|
+
"focus": "focus-visible"
|
|
12504
|
+
},
|
|
12290
12505
|
"states": [
|
|
12291
12506
|
"rest",
|
|
12292
12507
|
"hover",
|
|
12293
|
-
"focus",
|
|
12508
|
+
"focus-visible",
|
|
12294
12509
|
"selected",
|
|
12295
12510
|
"current"
|
|
12296
12511
|
],
|
|
@@ -12327,7 +12542,7 @@
|
|
|
12327
12542
|
],
|
|
12328
12543
|
"importPath": "@atom63/ui-react",
|
|
12329
12544
|
"label": "Item",
|
|
12330
|
-
"markdown": "# Item\n\nItem provides structured row regions for media, content, actions, and supporting detail.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Keep the row hierarchy predictable and avoid nesting unrelated actions inside a row-level link. For a dense list (an inbox, a message list), pass size=\"sm\" (12px block padding) or size=\"xs\" (8px); the default is 16px.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { Item, ItemContent, ItemTitle, ItemActions } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Item`, `ItemActions`, `ItemContent`, `ItemDescription`, `ItemFooter`, `ItemGroup`, `ItemHeader`, `ItemMedia`, `ItemSeparator`, `ItemTitle`\n\n**Types:** `ItemGroupProps`, `ItemMediaProps`, `ItemProps`, `ItemSeparatorProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/item.json` (`itemContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `default`, `outline`, `muted` | `default` |\n| `sizes` | `
|
|
12545
|
+
"markdown": "# Item\n\nItem provides structured row regions for media, content, actions, and supporting detail.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Keep the row hierarchy predictable and avoid nesting unrelated actions inside a row-level link. For a dense list (an inbox, a message list), pass size=\"sm\" (12px block padding) or size=\"xs\" (8px); the default is 16px.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { Item, ItemContent, ItemTitle, ItemActions } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Item`, `ItemActions`, `ItemContent`, `ItemDescription`, `ItemFooter`, `ItemGroup`, `ItemHeader`, `ItemMedia`, `ItemSeparator`, `ItemTitle`\n\n**Types:** `ItemGroupProps`, `ItemMediaProps`, `ItemProps`, `ItemSeparatorProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/item.json` (`itemContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `default`, `outline`, `muted` | `default` |\n| `sizes` | `md`, `sm`, `xs` | `md` |\n| `mediaVariants` | `default`, `icon`, `image` | `default` |\n| `groupVariants` | `default`, `inset` | `default` |\n| `groupSurfaces` | `card`, `muted` | `card` |\n| `tones` | `neutral`, `accent` | `neutral` |\n\n**Deprecated aliases:** `default` → `md` (sizes), `focus` → `focus-visible` (states)\n\n**Slots:** `item-group`, `item`, `item-media`, `item-content`, `item-title`, `item-description`, `item-actions`, `item-header`, `item-footer`, `item-separator`\n\n**States:** `rest`, `hover`, `focus-visible`, `selected`, `current`\n\n**Visual archetype:** Static content surfaces — In-flow containers and content surfaces that do not inherently manipulate state.\n\n### Web and iOS\n\nGroup related rows on one inset surface with a divider between rows, as in a grouped settings list. Rendered by `AtomListSection` in SwiftUI, with `platform-adaptive` parity.\n\n**Required states:** `rest`\n\n**Shared outcomes:**\n\n- Rows keep reading order\n- Dividers are decorative\n\n**Accessibility outcomes:**\n\n- Preserves row order\n- Hides dividers from assistive technology\n\n**Platform adaptations:**\n\n- React: ItemGroup variant=\"inset\" draws the group; a heading above it and a note below it belong to the page.\n- React: ItemGroup surface=\"muted\" fills the inset group with the muted grey, for a white page (bg-card); the default card fill sits on the grey page.\n- React: A row that navigates is an Item rendered as a link, with its value in bold and a chevron in ItemActions.\n- React: In the phone form factor an inset group's default and sm rows are at least 52px tall (--a63-inset-row-min-size) and the card has the 2xl corner (--a63-inset-group-radius); elsewhere they keep the control-height floor and --radius-lg.\n- SwiftUI: AtomListSection draws the group inside a ScrollView and takes an optional header and footer; inside a List or Form, the native Section draws it.\n- SwiftUI: AtomListSection(surface: .muted) fills the section with surfaceMuted for a surfacePanel page; the default .card fill sits on surfacePage.\n- SwiftUI: AtomListSection rows are at least 52pt tall, scaled with Dynamic Type, and the section has an 18pt continuous corner.\n- SwiftUI: AtomValueRow(_:value:emphasizesValue:showsDisclosure:) is the label, value and chevron row.\n- SwiftUI: Rows pad themselves with atomListRowInsets() inside their tap area, so a NavigationLink or Button row is tappable edge to edge; Atom63 rows do it already, and a custom row takes the modifier inside its label.\n\n## Related components\n\n- [Card](/components/component-card)\n- [Separator](/components/component-separator)\n- [Avatar](/components/component-avatar)\n",
|
|
12331
12546
|
"related": [
|
|
12332
12547
|
"card",
|
|
12333
12548
|
"separator",
|
|
@@ -12352,7 +12567,7 @@
|
|
|
12352
12567
|
"Endpoints",
|
|
12353
12568
|
"ContractMetadata"
|
|
12354
12569
|
],
|
|
12355
|
-
"source": "import { itemContract, itemTones, themes } from '@atom63/ui-foundation'\nimport { Bookmark, ChevronRight } from 'lucide-react'\nimport {\n Button,\n Item,\n ItemActions,\n ItemContent,\n ItemDescription,\n ItemGroup,\n ItemMedia,\n ItemSeparator,\n ItemTitle,\n Switch,\n UIProvider,\n} from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\nconst meta = {\n title: 'UI React/Item',\n component: Item,\n} satisfies Meta<typeof Item>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nexport const Playground: Story = {\n render: () => (\n <div style={{ width: 'min(360px, 100%)' }}>\n <Item variant=\"outline\">\n <ItemMedia variant=\"icon\">\n <Bookmark aria-hidden />\n </ItemMedia>\n <ItemContent>\n <ItemTitle>Starred project</ItemTitle>\n <ItemDescription>Last edited 2 hours ago by you.</ItemDescription>\n </ItemContent>\n <ItemActions>\n <Button size=\"sm\" type=\"button\" variant=\"secondary\">\n Open\n </Button>\n </ItemActions>\n </Item>\n </div>\n ),\n}\n\nexport const Variants: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12, width: 360 }}>\n {(['default', 'outline', 'muted'] as const).map(variant => (\n <Item key={variant} variant={variant}>\n <ItemContent>\n <ItemTitle>{variant}</ItemTitle>\n <ItemDescription>The {variant} chrome.</ItemDescription>\n </ItemContent>\n </Item>\n ))}\n </div>\n ),\n}\n\n/* A grouped list with separators; sizes tighten the row density. */\nexport const Group: Story = {\n render: () => (\n <div style={{ width: 360 }}>\n <ItemGroup>\n <Item size=\"sm\" variant=\"outline\">\n <ItemContent>\n <ItemTitle>First</ItemTitle>\n </ItemContent>\n </Item>\n <ItemSeparator />\n <Item size=\"sm\" variant=\"outline\">\n <ItemContent>\n <ItemTitle>Second</ItemTitle>\n </ItemContent>\n </Item>\n </ItemGroup>\n </div>\n ),\n}\n\n/* A clickable row via the render prop (renders an <a>, gets a muted hover). */\nexport const AsLink: Story = {\n render: () => (\n <div style={{ width: 360 }}>\n <Item\n render={\n <a href=\"#item-link\">\n <ItemContent>\n <ItemTitle>Clickable row</ItemTitle>\n <ItemDescription>Renders as an anchor.</ItemDescription>\n </ItemContent>\n </a>\n }\n variant=\"outline\"\n />\n </div>\n ),\n}\n\n/* aria-current marks the row for the page the user is on; data-selected marks\n a picked row that is not a link. Both take the selected surface. */\nexport const SelectedAndCurrent: Story = {\n render: () => (\n <ItemGroup style={{ width: 360 }}>\n {['Inbox', 'My issues', 'Projects'].map(label => (\n <Item\n key={label}\n render={\n <a aria-current={label === 'My issues' ? 'page' : undefined} href={`#${label}`}>\n <ItemContent>\n <ItemTitle>{label}</ItemTitle>\n </ItemContent>\n </a>\n }\n size=\"xs\"\n />\n ))}\n <Item data-selected=\"\" size=\"xs\" variant=\"muted\">\n <ItemContent>\n <ItemTitle>Selected row</ItemTitle>\n <ItemDescription>Not a link: data-selected.</ItemDescription>\n </ItemContent>\n </Item>\n </ItemGroup>\n ),\n}\n\n/* tone sets how a selected or current row is coloured: neutral (the default)\n is a muted fill with primary text, accent is the opt-in primary wash. */\nexport const Tones: Story = {\n render: () => (\n <div style={{ display: 'flex', flexWrap: 'wrap', gap: 24 }}>\n {itemTones.map(tone => (\n <ItemGroup key={tone} style={{ width: 240 }}>\n {['Inbox', 'My issues', 'Projects'].map(label => (\n <Item\n key={label}\n render={\n <a aria-current={label === 'My issues' ? 'page' : undefined} href={`#${label}`}>\n <ItemContent>\n <ItemTitle>{label}</ItemTitle>\n </ItemContent>\n </a>\n }\n size=\"xs\"\n tone={tone}\n />\n ))}\n <Item data-selected=\"\" size=\"xs\" tone={tone}>\n <ItemContent>\n <ItemTitle>Selected row</ItemTitle>\n <ItemDescription>tone="{tone}"</ItemDescription>\n </ItemContent>\n </Item>\n </ItemGroup>\n ))}\n </div>\n ),\n}\n\n/* variant=\"inset\": the grouped settings list, each row a label with its value\n in bold and a chevron (the web side of iOS AtomValueRow). */\nexport const InsetGroup: Story = {\n render: () => (\n <div style={{ background: 'var(--a63-surface-page)', padding: 16, width: 360 }}>\n <ItemGroup variant=\"inset\">\n {[\n ['Units of measure', 'Imperial'],\n ['Active energy', 'kcal'],\n ['Start week on', 'Sunday'],\n ].map(([label, value]) => (\n <Item\n key={label}\n render={\n <a href={`#${label}`}>\n <ItemContent>\n <ItemTitle>{label}</ItemTitle>\n </ItemContent>\n <ItemActions>\n <strong>{value}</strong>\n <ChevronRight aria-hidden />\n </ItemActions>\n </a>\n }\n size=\"sm\"\n />\n ))}\n </ItemGroup>\n </div>\n ),\n}\n\n/* surface=\"muted\": grey cards on a white page (bg-card), the other common\n grouped-settings look. Inside the phone form factor, as AppView layout=\"phone\"\n draws it, the switch takes the iOS 26 shape, rows are 52px tall and the card\n has an 18px corner. */\nexport const InsetGroupMuted: Story = {\n render: () => (\n <div\n data-a63-form-factor=\"phone\"\n style={{\n background: 'var(--a63-surface-panel)',\n display: 'grid',\n gap: 24,\n padding: 16,\n width: 'min(390px, 100%)',\n }}\n >\n <ItemGroup surface=\"muted\" variant=\"inset\">\n {[\n ['Units of measure', 'Imperial'],\n ['Start week on', 'Sunday'],\n ].map(([label, value]) => (\n <Item\n key={label}\n render={\n <a href={`#${label}`}>\n <ItemContent>\n <ItemTitle>{label}</ItemTitle>\n </ItemContent>\n <ItemActions>\n <strong>{value}</strong>\n <ChevronRight aria-hidden />\n </ItemActions>\n </a>\n }\n size=\"sm\"\n />\n ))}\n </ItemGroup>\n <ItemGroup surface=\"muted\" variant=\"inset\">\n {(\n [\n ['Include steps', true],\n ['Sync with Health', false],\n ] as const\n ).map(([label, checked]) => (\n <Item key={label} size=\"sm\">\n <ItemContent>\n <ItemTitle>{label}</ItemTitle>\n </ItemContent>\n <ItemActions>\n <Switch aria-label={label} defaultChecked={checked} />\n </ItemActions>\n </Item>\n ))}\n </ItemGroup>\n </div>\n ),\n}\n\n/* Every size tightens the row density (default · sm · xs). */\nexport const Sizes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12, width: 360 }}>\n {(['default', 'sm', 'xs'] as const).map(size => (\n <Item key={size} size={size} variant=\"outline\">\n <ItemMedia variant=\"icon\">\n <Bookmark aria-hidden />\n </ItemMedia>\n <ItemContent>\n <ItemTitle>{size}</ItemTitle>\n <ItemDescription>The {size} row density.</ItemDescription>\n </ItemContent>\n </Item>\n ))}\n </div>\n ),\n}\n\n/* Renders a representative Item across all 4 DS themes × light/dark. */\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={`${theme}-${mode}`} mode={mode} theme={theme}>\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 12,\n padding: '0.75rem',\n background: 'var(--a63-surface-panel)',\n color: 'var(--a63-text-primary)',\n borderRadius: 'var(--a63-surface-radius, var(--radius-lg))',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 96 }}>\n {theme} / {mode}\n </span>\n <div style={{ width: 320 }}>\n <Item variant=\"outline\">\n <ItemMedia variant=\"icon\">\n <Bookmark aria-hidden />\n </ItemMedia>\n <ItemContent>\n <ItemTitle>Starred project</ItemTitle>\n <ItemDescription>Last edited 2 hours ago.</ItemDescription>\n </ItemContent>\n <ItemActions>\n <Button size=\"sm\" type=\"button\" variant=\"secondary\">\n Open\n </Button>\n </ItemActions>\n </Item>\n </div>\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\nexport const Endpoints: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n <UIProvider designLanguage=\"web\" input=\"pointer\">\n <EndpointItem label=\"Web\" />\n </UIProvider>\n <UIProvider designLanguage=\"ios\" input=\"touch\">\n <EndpointItem label=\"iOS touch\" />\n </UIProvider>\n <UIProvider density=\"compact\" designLanguage=\"web\" input=\"pointer\">\n <EndpointItem label=\"Compact extension\" />\n </UIProvider>\n </div>\n ),\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(itemContract, null, 2)}\n </pre>\n ),\n}\n\nfunction EndpointItem({ label }: { label: string }) {\n return (\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: 12,\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 112 }}>{label}</span>\n <div style={{ width: 320 }}>\n <Item variant=\"outline\">\n <ItemMedia variant=\"icon\">\n <Bookmark aria-hidden />\n </ItemMedia>\n <ItemContent>\n <ItemTitle>Starred project</ItemTitle>\n <ItemDescription>Last edited 2 hours ago.</ItemDescription>\n </ItemContent>\n <ItemActions>\n <Button size=\"sm\" type=\"button\" variant=\"secondary\">\n Open\n </Button>\n </ItemActions>\n </Item>\n </div>\n </div>\n )\n}\n"
|
|
12570
|
+
"source": "import { itemContract, itemTones, themes } from '@atom63/ui-foundation'\nimport { Bookmark, ChevronRight } from 'lucide-react'\nimport {\n Button,\n Item,\n ItemActions,\n ItemContent,\n ItemDescription,\n ItemGroup,\n ItemMedia,\n ItemSeparator,\n ItemTitle,\n Switch,\n UIProvider,\n} from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\nconst meta = {\n title: 'UI React/Item',\n component: Item,\n} satisfies Meta<typeof Item>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nexport const Playground: Story = {\n render: () => (\n <div style={{ width: 'min(360px, 100%)' }}>\n <Item variant=\"outline\">\n <ItemMedia variant=\"icon\">\n <Bookmark aria-hidden />\n </ItemMedia>\n <ItemContent>\n <ItemTitle>Starred project</ItemTitle>\n <ItemDescription>Last edited 2 hours ago by you.</ItemDescription>\n </ItemContent>\n <ItemActions>\n <Button size=\"sm\" type=\"button\" variant=\"secondary\">\n Open\n </Button>\n </ItemActions>\n </Item>\n </div>\n ),\n}\n\nexport const Variants: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12, width: 360 }}>\n {(['default', 'outline', 'muted'] as const).map(variant => (\n <Item key={variant} variant={variant}>\n <ItemContent>\n <ItemTitle>{variant}</ItemTitle>\n <ItemDescription>The {variant} chrome.</ItemDescription>\n </ItemContent>\n </Item>\n ))}\n </div>\n ),\n}\n\n/* A grouped list with separators; sizes tighten the row density. */\nexport const Group: Story = {\n render: () => (\n <div style={{ width: 360 }}>\n <ItemGroup>\n <Item size=\"sm\" variant=\"outline\">\n <ItemContent>\n <ItemTitle>First</ItemTitle>\n </ItemContent>\n </Item>\n <ItemSeparator />\n <Item size=\"sm\" variant=\"outline\">\n <ItemContent>\n <ItemTitle>Second</ItemTitle>\n </ItemContent>\n </Item>\n </ItemGroup>\n </div>\n ),\n}\n\n/* A clickable row via the render prop (renders an <a>, gets a muted hover). */\nexport const AsLink: Story = {\n render: () => (\n <div style={{ width: 360 }}>\n <Item\n render={\n <a href=\"#item-link\">\n <ItemContent>\n <ItemTitle>Clickable row</ItemTitle>\n <ItemDescription>Renders as an anchor.</ItemDescription>\n </ItemContent>\n </a>\n }\n variant=\"outline\"\n />\n </div>\n ),\n}\n\n/* aria-current marks the row for the page the user is on; data-selected marks\n a picked row that is not a link. Both take the selected surface. */\nexport const SelectedAndCurrent: Story = {\n render: () => (\n <ItemGroup style={{ width: 360 }}>\n {['Inbox', 'My issues', 'Projects'].map(label => (\n <Item\n key={label}\n render={\n <a aria-current={label === 'My issues' ? 'page' : undefined} href={`#${label}`}>\n <ItemContent>\n <ItemTitle>{label}</ItemTitle>\n </ItemContent>\n </a>\n }\n size=\"xs\"\n />\n ))}\n <Item data-selected=\"\" size=\"xs\" variant=\"muted\">\n <ItemContent>\n <ItemTitle>Selected row</ItemTitle>\n <ItemDescription>Not a link: data-selected.</ItemDescription>\n </ItemContent>\n </Item>\n </ItemGroup>\n ),\n}\n\n/* tone sets how a selected or current row is coloured: neutral (the default)\n is a muted fill with primary text, accent is the opt-in primary wash. */\nexport const Tones: Story = {\n render: () => (\n <div style={{ display: 'flex', flexWrap: 'wrap', gap: 24 }}>\n {itemTones.map(tone => (\n <ItemGroup key={tone} style={{ width: 240 }}>\n {['Inbox', 'My issues', 'Projects'].map(label => (\n <Item\n key={label}\n render={\n <a aria-current={label === 'My issues' ? 'page' : undefined} href={`#${label}`}>\n <ItemContent>\n <ItemTitle>{label}</ItemTitle>\n </ItemContent>\n </a>\n }\n size=\"xs\"\n tone={tone}\n />\n ))}\n <Item data-selected=\"\" size=\"xs\" tone={tone}>\n <ItemContent>\n <ItemTitle>Selected row</ItemTitle>\n <ItemDescription>tone="{tone}"</ItemDescription>\n </ItemContent>\n </Item>\n </ItemGroup>\n ))}\n </div>\n ),\n}\n\n/* variant=\"inset\": the grouped settings list, each row a label with its value\n in bold and a chevron (the web side of iOS AtomValueRow). */\nexport const InsetGroup: Story = {\n render: () => (\n <div style={{ background: 'var(--a63-surface-page)', padding: 16, width: 360 }}>\n <ItemGroup variant=\"inset\">\n {[\n ['Units of measure', 'Imperial'],\n ['Active energy', 'kcal'],\n ['Start week on', 'Sunday'],\n ].map(([label, value]) => (\n <Item\n key={label}\n render={\n <a href={`#${label}`}>\n <ItemContent>\n <ItemTitle>{label}</ItemTitle>\n </ItemContent>\n <ItemActions>\n <strong>{value}</strong>\n <ChevronRight aria-hidden />\n </ItemActions>\n </a>\n }\n size=\"sm\"\n />\n ))}\n </ItemGroup>\n </div>\n ),\n}\n\n/* surface=\"muted\": grey cards on a white page (bg-card), the other common\n grouped-settings look. Inside the phone form factor, as AppView layout=\"phone\"\n draws it, the switch takes the iOS 26 shape, rows are 52px tall and the card\n has an 18px corner. */\nexport const InsetGroupMuted: Story = {\n render: () => (\n <div\n data-a63-form-factor=\"phone\"\n style={{\n background: 'var(--a63-surface-panel)',\n display: 'grid',\n gap: 24,\n padding: 16,\n width: 'min(390px, 100%)',\n }}\n >\n <ItemGroup surface=\"muted\" variant=\"inset\">\n {[\n ['Units of measure', 'Imperial'],\n ['Start week on', 'Sunday'],\n ].map(([label, value]) => (\n <Item\n key={label}\n render={\n <a href={`#${label}`}>\n <ItemContent>\n <ItemTitle>{label}</ItemTitle>\n </ItemContent>\n <ItemActions>\n <strong>{value}</strong>\n <ChevronRight aria-hidden />\n </ItemActions>\n </a>\n }\n size=\"sm\"\n />\n ))}\n </ItemGroup>\n <ItemGroup surface=\"muted\" variant=\"inset\">\n {(\n [\n ['Include steps', true],\n ['Sync with Health', false],\n ] as const\n ).map(([label, checked]) => (\n <Item key={label} size=\"sm\">\n <ItemContent>\n <ItemTitle>{label}</ItemTitle>\n </ItemContent>\n <ItemActions>\n <Switch aria-label={label} defaultChecked={checked} />\n </ItemActions>\n </Item>\n ))}\n </ItemGroup>\n </div>\n ),\n}\n\n/* Every size tightens the row density (md · sm · xs). */\nexport const Sizes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12, width: 360 }}>\n {(['md', 'sm', 'xs'] as const).map(size => (\n <Item key={size} size={size} variant=\"outline\">\n <ItemMedia variant=\"icon\">\n <Bookmark aria-hidden />\n </ItemMedia>\n <ItemContent>\n <ItemTitle>{size}</ItemTitle>\n <ItemDescription>The {size} row density.</ItemDescription>\n </ItemContent>\n </Item>\n ))}\n </div>\n ),\n}\n\n/* Renders a representative Item across all 4 DS themes × light/dark. */\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={`${theme}-${mode}`} mode={mode} theme={theme}>\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 12,\n padding: '0.75rem',\n background: 'var(--a63-surface-panel)',\n color: 'var(--a63-text-primary)',\n borderRadius: 'var(--a63-surface-radius, var(--radius-lg))',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 96 }}>\n {theme} / {mode}\n </span>\n <div style={{ width: 320 }}>\n <Item variant=\"outline\">\n <ItemMedia variant=\"icon\">\n <Bookmark aria-hidden />\n </ItemMedia>\n <ItemContent>\n <ItemTitle>Starred project</ItemTitle>\n <ItemDescription>Last edited 2 hours ago.</ItemDescription>\n </ItemContent>\n <ItemActions>\n <Button size=\"sm\" type=\"button\" variant=\"secondary\">\n Open\n </Button>\n </ItemActions>\n </Item>\n </div>\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\nexport const Endpoints: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n <UIProvider designLanguage=\"web\" input=\"pointer\">\n <EndpointItem label=\"Web\" />\n </UIProvider>\n <UIProvider designLanguage=\"ios\" input=\"touch\">\n <EndpointItem label=\"iOS touch\" />\n </UIProvider>\n <UIProvider density=\"compact\" designLanguage=\"web\" input=\"pointer\">\n <EndpointItem label=\"Compact extension\" />\n </UIProvider>\n </div>\n ),\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(itemContract, null, 2)}\n </pre>\n ),\n}\n\nfunction EndpointItem({ label }: { label: string }) {\n return (\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: 12,\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 112 }}>{label}</span>\n <div style={{ width: 320 }}>\n <Item variant=\"outline\">\n <ItemMedia variant=\"icon\">\n <Bookmark aria-hidden />\n </ItemMedia>\n <ItemContent>\n <ItemTitle>Starred project</ItemTitle>\n <ItemDescription>Last edited 2 hours ago.</ItemDescription>\n </ItemContent>\n <ItemActions>\n <Button size=\"sm\" type=\"button\" variant=\"secondary\">\n Open\n </Button>\n </ItemActions>\n </Item>\n </div>\n </div>\n )\n}\n"
|
|
12356
12571
|
},
|
|
12357
12572
|
"summary": "Item provides structured row regions for media, content, actions, and supporting detail.",
|
|
12358
12573
|
"usage": "Keep the row hierarchy predictable and avoid nesting unrelated actions inside a row-level link. For a dense list (an inbox, a message list), pass size=\"sm\" (12px block padding) or size=\"xs\" (8px); the default is 16px.",
|
|
@@ -12363,6 +12578,101 @@
|
|
|
12363
12578
|
"ItemActions"
|
|
12364
12579
|
]
|
|
12365
12580
|
},
|
|
12581
|
+
{
|
|
12582
|
+
"axisGuidance": null,
|
|
12583
|
+
"contract": {
|
|
12584
|
+
"archetypes": [
|
|
12585
|
+
{
|
|
12586
|
+
"description": "In-flow containers and content surfaces that do not inherently manipulate state.",
|
|
12587
|
+
"id": "surface",
|
|
12588
|
+
"label": "Static content surfaces"
|
|
12589
|
+
}
|
|
12590
|
+
],
|
|
12591
|
+
"axes": [
|
|
12592
|
+
{
|
|
12593
|
+
"name": "placements",
|
|
12594
|
+
"values": [
|
|
12595
|
+
"center-bottom",
|
|
12596
|
+
"end-bottom",
|
|
12597
|
+
"start-bottom"
|
|
12598
|
+
],
|
|
12599
|
+
"default": "center-bottom"
|
|
12600
|
+
},
|
|
12601
|
+
{
|
|
12602
|
+
"name": "widths",
|
|
12603
|
+
"values": [
|
|
12604
|
+
"wide",
|
|
12605
|
+
"half"
|
|
12606
|
+
],
|
|
12607
|
+
"default": "wide"
|
|
12608
|
+
}
|
|
12609
|
+
],
|
|
12610
|
+
"exportName": "layeredSceneContract",
|
|
12611
|
+
"slots": [
|
|
12612
|
+
"layered-scene",
|
|
12613
|
+
"layered-scene-content",
|
|
12614
|
+
"layered-scene-stage",
|
|
12615
|
+
"layered-scene-foreground"
|
|
12616
|
+
],
|
|
12617
|
+
"source": "packages/ui-foundation/contracts/components/layered-scene.json",
|
|
12618
|
+
"states": [
|
|
12619
|
+
"rest"
|
|
12620
|
+
],
|
|
12621
|
+
"tokenSlots": []
|
|
12622
|
+
},
|
|
12623
|
+
"exports": {
|
|
12624
|
+
"types": [
|
|
12625
|
+
"LayeredSceneForegroundProps",
|
|
12626
|
+
"LayeredScenePlateProps",
|
|
12627
|
+
"LayeredSceneProps"
|
|
12628
|
+
],
|
|
12629
|
+
"values": [
|
|
12630
|
+
"LayeredScene",
|
|
12631
|
+
"LayeredSceneContent",
|
|
12632
|
+
"LayeredSceneForeground",
|
|
12633
|
+
"LayeredScenePlate",
|
|
12634
|
+
"LayeredSceneStage"
|
|
12635
|
+
]
|
|
12636
|
+
},
|
|
12637
|
+
"group": {
|
|
12638
|
+
"id": "content-and-surfaces",
|
|
12639
|
+
"title": "Content and surfaces"
|
|
12640
|
+
},
|
|
12641
|
+
"guidance": [
|
|
12642
|
+
"Use Layered Scene for a landing or portfolio hero where live product UI floats on an ArtPlate and a cut-out of the scene passes in front of it.",
|
|
12643
|
+
"Keep product data and fetching outside the presentational component.",
|
|
12644
|
+
"Test long, empty, and narrow content before adding local layout overrides."
|
|
12645
|
+
],
|
|
12646
|
+
"importPath": "@atom63/ui-react",
|
|
12647
|
+
"label": "Layered Scene",
|
|
12648
|
+
"markdown": "# Layered Scene\n\nLayered Scene stacks a plate, a stage of product UI and an inert foreground cut-out so the interface sits inside the picture.\n\n**Status:** Preview\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Use Layered Scene for a landing or portfolio hero where live product UI floats on an ArtPlate and a cut-out of the scene passes in front of it.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { LayeredScene, LayeredScenePlate, LayeredSceneContent, LayeredSceneStage, LayeredSceneForeground } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `LayeredScene`, `LayeredSceneContent`, `LayeredSceneForeground`, `LayeredScenePlate`, `LayeredSceneStage`\n\n**Types:** `LayeredSceneForegroundProps`, `LayeredScenePlateProps`, `LayeredSceneProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/layered-scene.json` (`layeredSceneContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `placements` | `center-bottom`, `end-bottom`, `start-bottom` | `center-bottom` |\n| `widths` | `wide`, `half` | `wide` |\n\n**Slots:** `layered-scene`, `layered-scene-content`, `layered-scene-stage`, `layered-scene-foreground`\n\n**States:** `rest`\n\n**Visual archetype:** Static content surfaces — In-flow containers and content surfaces that do not inherently manipulate state.\n\n## Related components\n\n- [Art Plate](/components/component-art-plate)\n- [Frame](/components/component-frame)\n- [Card](/components/component-card)\n",
|
|
12649
|
+
"related": [
|
|
12650
|
+
"art-plate",
|
|
12651
|
+
"frame",
|
|
12652
|
+
"card"
|
|
12653
|
+
],
|
|
12654
|
+
"route": "/components/component-layered-scene",
|
|
12655
|
+
"slug": "layered-scene",
|
|
12656
|
+
"status": "preview",
|
|
12657
|
+
"stories": {
|
|
12658
|
+
"file": "packages/ui-react/src/components/layered-scene/layered-scene.stories.tsx",
|
|
12659
|
+
"names": [
|
|
12660
|
+
"Playground",
|
|
12661
|
+
"EndPlacement",
|
|
12662
|
+
"WithoutForeground"
|
|
12663
|
+
],
|
|
12664
|
+
"source": "import { layeredScenePlacements, layeredSceneWidths } from '@atom63/ui-foundation'\nimport {\n Badge,\n Button,\n Frame,\n FrameDescription,\n FrameHeader,\n FramePanel,\n FrameTitle,\n LayeredScene,\n LayeredSceneContent,\n LayeredSceneForeground,\n LayeredScenePlate,\n LayeredSceneStage,\n} from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\n// Remote pictures are pinned to one placeholder in the visual and craft runs.\nconst PLATE = 'https://picsum.photos/id/1018/1920/1080'\nconst FOCUS = { x: 0.5, y: 0.7 }\n\n// A stand-in cut-out: a ridge across the bottom eighth of the plate, transparent\n// above it. A real scene uses a cut-out of its own plate.\nconst RIDGE =\n 'data:image/svg+xml,' +\n encodeURIComponent(\n '<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 1920 1080\" preserveAspectRatio=\"xMidYMid slice\"><path fill-opacity=\"0.9\" d=\"M0 1000 L180 960 L360 990 L560 945 L760 985 L980 950 L1180 990 L1400 955 L1620 985 L1920 960 L1920 1080 L0 1080 Z\"/></svg>'\n )\n\nconst meta = {\n title: 'UI React/LayeredScene',\n component: LayeredScene,\n parameters: { layout: 'fullscreen' },\n argTypes: {\n placement: { control: 'inline-radio', options: layeredScenePlacements },\n width: { control: 'inline-radio', options: layeredSceneWidths },\n },\n args: { placement: 'center-bottom', width: 'wide' },\n} satisfies Meta<typeof LayeredScene>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nfunction ProductWindow() {\n return (\n <Frame>\n <FrameHeader>\n <FrameTitle>Render queue</FrameTitle>\n <FrameDescription>3 jobs running on 4 workers</FrameDescription>\n </FrameHeader>\n <FramePanel>\n <div style={{ display: 'grid', gap: 'var(--a63-space-2)' }}>\n <span>title-sequence.mov · 72%</span>\n <span>logo-sting.mov · 40%</span>\n <span>lower-thirds.mov · queued</span>\n </div>\n {/* Empty room at the bottom of the window: the only part the cut-out may cover. */}\n <div style={{ blockSize: 'var(--spacing-24)' }} />\n </FramePanel>\n </Frame>\n )\n}\n\nfunction Copy() {\n return (\n <>\n <Badge variant=\"secondary\">Browser-native rendering</Badge>\n <h1\n style={{\n margin: 0,\n fontSize: 'var(--a63-type-display-large-font-size)',\n lineHeight: 'var(--a63-type-display-large-line-height)',\n maxInlineSize: '18ch',\n }}\n >\n Render at the speed of thought\n </h1>\n <p style={{ margin: 0 }}>A motion timeline that renders in the browser.</p>\n <div style={{ display: 'flex', gap: 'var(--a63-space-2)' }}>\n <Button>Start free</Button>\n <Button variant=\"outline\">Take a tour</Button>\n </div>\n </>\n )\n}\n\nexport const Playground: Story = {\n render: args => (\n <LayeredScene {...args}>\n <LayeredScenePlate alt=\"\" focus={FOCUS} priority src={PLATE} />\n <LayeredSceneContent>\n <Copy />\n </LayeredSceneContent>\n <LayeredSceneStage>\n <ProductWindow />\n </LayeredSceneStage>\n <LayeredSceneForeground focus={FOCUS} priority src={RIDGE} />\n </LayeredScene>\n ),\n}\n\nexport const EndPlacement: Story = {\n args: { placement: 'end-bottom', width: 'half' },\n render: Playground.render,\n}\n\nexport const WithoutForeground: Story = {\n render: args => (\n <LayeredScene {...args}>\n <LayeredScenePlate alt=\"\" focus={FOCUS} src={PLATE} />\n <LayeredSceneContent>\n <Copy />\n </LayeredSceneContent>\n <LayeredSceneStage>\n <ProductWindow />\n </LayeredSceneStage>\n </LayeredScene>\n ),\n}\n"
|
|
12665
|
+
},
|
|
12666
|
+
"summary": "Layered Scene stacks a plate, a stage of product UI and an inert foreground cut-out so the interface sits inside the picture.",
|
|
12667
|
+
"usage": "Use Layered Scene for a landing or portfolio hero where live product UI floats on an ArtPlate and a cut-out of the scene passes in front of it.",
|
|
12668
|
+
"usageExports": [
|
|
12669
|
+
"LayeredScene",
|
|
12670
|
+
"LayeredScenePlate",
|
|
12671
|
+
"LayeredSceneContent",
|
|
12672
|
+
"LayeredSceneStage",
|
|
12673
|
+
"LayeredSceneForeground"
|
|
12674
|
+
]
|
|
12675
|
+
},
|
|
12366
12676
|
{
|
|
12367
12677
|
"axisGuidance": null,
|
|
12368
12678
|
"contract": {
|
|
@@ -12537,9 +12847,13 @@
|
|
|
12537
12847
|
"scroll-area-corner"
|
|
12538
12848
|
],
|
|
12539
12849
|
"source": "packages/ui-foundation/contracts/components/scroll-area.json",
|
|
12850
|
+
"stateAliases": {
|
|
12851
|
+
"hovering": "hover",
|
|
12852
|
+
"idle": "rest"
|
|
12853
|
+
},
|
|
12540
12854
|
"states": [
|
|
12541
|
-
"
|
|
12542
|
-
"
|
|
12855
|
+
"rest",
|
|
12856
|
+
"hover",
|
|
12543
12857
|
"scrolling",
|
|
12544
12858
|
"focus-visible"
|
|
12545
12859
|
],
|
|
@@ -12565,7 +12879,7 @@
|
|
|
12565
12879
|
],
|
|
12566
12880
|
"importPath": "@atom63/ui-react",
|
|
12567
12881
|
"label": "Scroll Area",
|
|
12568
|
-
"markdown": "# Scroll Area\n\nScroll Area supplies themed scrollbars while preserving native scrolling behavior.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Constrain its viewport explicitly and avoid hiding overflow that users still need to reach.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { ScrollArea, ScrollBar } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `ScrollArea`, `ScrollBar`\n\n**Types:** `ScrollAreaViewportProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/scroll-area.json` (`scrollAreaContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `orientations` | `vertical`, `horizontal`, `both` | `both` |\n| `options` | `scroll-fade`, `scrollbar-gutter`, `show-on-hover` | — |\n\n**Slots:** `scroll-area`, `scroll-area-viewport`, `scroll-area-scrollbar`, `scroll-area-thumb`, `scroll-area-corner`\n\n**States:** `
|
|
12882
|
+
"markdown": "# Scroll Area\n\nScroll Area supplies themed scrollbars while preserving native scrolling behavior.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Constrain its viewport explicitly and avoid hiding overflow that users still need to reach.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { ScrollArea, ScrollBar } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `ScrollArea`, `ScrollBar`\n\n**Types:** `ScrollAreaViewportProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/scroll-area.json` (`scrollAreaContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `orientations` | `vertical`, `horizontal`, `both` | `both` |\n| `options` | `scroll-fade`, `scrollbar-gutter`, `show-on-hover` | — |\n\n**Deprecated aliases:** `hovering` → `hover` (states), `idle` → `rest` (states)\n\n**Slots:** `scroll-area`, `scroll-area-viewport`, `scroll-area-scrollbar`, `scroll-area-thumb`, `scroll-area-corner`\n\n**States:** `rest`, `hover`, `scrolling`, `focus-visible`\n\n**Visual archetype:** Range and track controls — Controls or indicators that represent a value along a rail.\n\n## Related components\n\n- [Scrollable List](/components/component-scrollable-list)\n- [Carousel](/components/component-carousel)\n",
|
|
12569
12883
|
"related": [
|
|
12570
12884
|
"scrollable-list",
|
|
12571
12885
|
"carousel"
|
|
@@ -12634,8 +12948,11 @@
|
|
|
12634
12948
|
"scrollable-list-control"
|
|
12635
12949
|
],
|
|
12636
12950
|
"source": "packages/ui-foundation/contracts/components/scrollable-list.json",
|
|
12951
|
+
"stateAliases": {
|
|
12952
|
+
"idle": "rest"
|
|
12953
|
+
},
|
|
12637
12954
|
"states": [
|
|
12638
|
-
"
|
|
12955
|
+
"rest",
|
|
12639
12956
|
"can-scroll-start",
|
|
12640
12957
|
"can-scroll-end",
|
|
12641
12958
|
"dragging",
|
|
@@ -12663,7 +12980,7 @@
|
|
|
12663
12980
|
],
|
|
12664
12981
|
"importPath": "@atom63/ui-react",
|
|
12665
12982
|
"label": "Scrollable List",
|
|
12666
|
-
"markdown": "# Scrollable List\n\nScrollable List adds edge masks and optional controls to overflowing row or column content.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Keep native scrolling available and use controls as an additional path, not the only one.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { ScrollableList } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `ScrollableList`, `scrollableListControlClassNames`\n\n**Types:** `ScrollableListProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/scrollable-list.json` (`scrollableListContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `layouts` | `scroll`, `wrap` | `scroll` |\n| `options` | `mask`, `chevrons`, `draggable`, `column-aligned` | — |\n\n**Slots:** `scrollable-list`, `scrollable-list-frame`, `scrollable-list-content`, `scrollable-list-control`\n\n**States:** `
|
|
12983
|
+
"markdown": "# Scrollable List\n\nScrollable List adds edge masks and optional controls to overflowing row or column content.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Keep native scrolling available and use controls as an additional path, not the only one.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { ScrollableList } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `ScrollableList`, `scrollableListControlClassNames`\n\n**Types:** `ScrollableListProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/scrollable-list.json` (`scrollableListContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `layouts` | `scroll`, `wrap` | `scroll` |\n| `options` | `mask`, `chevrons`, `draggable`, `column-aligned` | — |\n\n**Deprecated aliases:** `idle` → `rest` (states)\n\n**Slots:** `scrollable-list`, `scrollable-list-frame`, `scrollable-list-content`, `scrollable-list-control`\n\n**States:** `rest`, `can-scroll-start`, `can-scroll-end`, `dragging`, `disabled`\n\n**Visual archetype:** Action controls — Momentary controls that perform an action now.; Range and track controls — Controls or indicators that represent a value along a rail.\n\n## Related components\n\n- [Scroll Area](/components/component-scroll-area)\n- [Load More Trigger](/components/component-load-more-trigger)\n- [Carousel](/components/component-carousel)\n",
|
|
12667
12984
|
"related": [
|
|
12668
12985
|
"scroll-area",
|
|
12669
12986
|
"load-more-trigger",
|
|
@@ -12801,10 +13118,13 @@
|
|
|
12801
13118
|
{
|
|
12802
13119
|
"name": "sizes",
|
|
12803
13120
|
"values": [
|
|
12804
|
-
"
|
|
13121
|
+
"md",
|
|
12805
13122
|
"sm"
|
|
12806
13123
|
],
|
|
12807
|
-
"
|
|
13124
|
+
"deprecatedAliases": {
|
|
13125
|
+
"default": "md"
|
|
13126
|
+
},
|
|
13127
|
+
"default": "md"
|
|
12808
13128
|
},
|
|
12809
13129
|
{
|
|
12810
13130
|
"name": "stickyEdges",
|
|
@@ -12875,7 +13195,7 @@
|
|
|
12875
13195
|
],
|
|
12876
13196
|
"importPath": "@atom63/ui-react",
|
|
12877
13197
|
"label": "Table",
|
|
12878
|
-
"markdown": "# Table\n\nTable provides semantic table regions with shared typography, spacing, and states.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Keep header relationships intact and add horizontal containment for genuinely wide data. For a dense table (admin, payments, issues), pass size=\"sm\": rows are 33px, and a row checkbox or a 24px row menu (size=\"icon-xs\") keeps its hit area without making the row taller.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { Table, TableHeader, TableBody, TableRow, TableHead, TableCell } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Table`, `TableBody`, `TableCaption`, `TableCell`, `TableFooter`, `TableHead`, `TableHeader`, `TableRow`\n\n**Types:** `TableBodyProps`, `TableCaptionProps`, `TableCellProps`, `TableFooterProps`, `TableHeadProps`, `TableHeaderProps`, `TableProps`, `TableRowProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/table.json` (`tableContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `default`, `plain` | `default` |\n| `sizes` | `
|
|
13198
|
+
"markdown": "# Table\n\nTable provides semantic table regions with shared typography, spacing, and states.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Playground` story maintained with the component.\n\n## Guidance\n\n- Keep header relationships intact and add horizontal containment for genuinely wide data. For a dense table (admin, payments, issues), pass size=\"sm\": rows are 33px, and a row checkbox or a 24px row menu (size=\"icon-xs\") keeps its hit area without making the row taller.\n- Keep product data and fetching outside the presentational component.\n- Test long, empty, and narrow content before adding local layout overrides.\n\n## Usage\n\n```tsx\nimport { Table, TableHeader, TableBody, TableRow, TableHead, TableCell } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Table`, `TableBody`, `TableCaption`, `TableCell`, `TableFooter`, `TableHead`, `TableHeader`, `TableRow`\n\n**Types:** `TableBodyProps`, `TableCaptionProps`, `TableCellProps`, `TableFooterProps`, `TableHeadProps`, `TableHeaderProps`, `TableProps`, `TableRowProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/table.json` (`tableContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `default`, `plain` | `default` |\n| `sizes` | `md`, `sm` | `md` |\n| `stickyEdges` | `start`, `end` | — |\n| `tones` | `neutral`, `accent` | `neutral` |\n\n**Deprecated aliases:** `default` → `md` (sizes)\n\n**Slots:** `table-container`, `table`, `table-header`, `table-body`, `table-footer`, `table-row`, `table-head`, `table-cell`, `table-caption`\n\n**States:** `rest`, `row-hover`, `row-selected`\n\n**Visual archetype:** Static content surfaces — In-flow containers and content surfaces that do not inherently manipulate state.\n\n## Related components\n\n- [Pagination](/components/component-pagination)\n- [Scroll Area](/components/component-scroll-area)\n",
|
|
12879
13199
|
"related": [
|
|
12880
13200
|
"pagination",
|
|
12881
13201
|
"scroll-area"
|
|
@@ -13241,10 +13561,11 @@
|
|
|
13241
13561
|
"FailedTouch",
|
|
13242
13562
|
"CustomChildren",
|
|
13243
13563
|
"Themes",
|
|
13564
|
+
"FailedThemes",
|
|
13244
13565
|
"Endpoints",
|
|
13245
13566
|
"ContractMetadata"
|
|
13246
13567
|
],
|
|
13247
|
-
"source": "import { loadMoreTriggerContract, loadMoreTriggerVariants, themes } from '@atom63/ui-foundation'\nimport { Button, LoadMoreTrigger, UIProvider } from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\nconst meta = {\n title: 'UI React/LoadMoreTrigger',\n component: LoadMoreTrigger,\n argTypes: {\n variant: { control: 'inline-radio', options: loadMoreTriggerVariants },\n state: {\n control: 'select',\n options: loadMoreTriggerContract.states.filter(state => state !== 'custom'),\n },\n hasMore: { control: 'boolean' },\n isLoading: { control: 'boolean' },\n },\n args: { hasMore: true, isLoading: false, variant: 'default' },\n} satisfies Meta<typeof LoadMoreTrigger>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nexport const Playground: Story = {}\n\n/* Explicit state API uses the shared state-tone contract. */\nexport const States: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n <LoadMoreTrigger state=\"idle\" />\n <LoadMoreTrigger state=\"loading\" />\n <LoadMoreTrigger onRetry={() => {}} state=\"failed\" />\n <LoadMoreTrigger state=\"exhausted\" />\n </div>\n ),\n}\n\nexport const Variants: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {loadMoreTriggerVariants.map(variant => (\n <LoadMoreTrigger hasMore isLoading key={variant} variant={variant} />\n ))}\n </div>\n ),\n}\n\nexport const Exhausted: Story = {\n args: { state: 'exhausted' },\n}\n\nexport const Failed: Story = {\n args: { onRetry: () => {}, state: 'failed' },\n}\n\n/* On a touch screen the Retry text keeps its size, and its hit area grows to the\n 44px touch target (--a63-control-min-target) around it. */\nexport const FailedTouch: Story = {\n play: ({ canvasElement }) => {\n const retry = canvasElement.querySelector<HTMLElement>('[data-slot=\"load-more-trigger-action\"]')\n if (!retry) throw new Error('Expected a Retry action')\n const hitArea = getComputedStyle(retry, '::before')\n const [width, height] = [parseFloat(hitArea.width), parseFloat(hitArea.height)]\n if (!(width >= 44 && height >= 44)) {\n throw new Error(`Retry hit area is ${width}×${height}px, expected at least 44×44`)\n }\n },\n render: () => (\n <UIProvider input=\"touch\">\n <LoadMoreTrigger onRetry={() => {}} state=\"failed\" />\n </UIProvider>\n ),\n}\n\n/* Custom children take over the row entirely (e.g. a manual \"Load more\" button). */\nexport const CustomChildren: Story = {\n render: () => (\n <LoadMoreTrigger hasMore isLoading={false}>\n <Button type=\"button\" variant=\"secondary\">\n Load more\n </Button>\n </LoadMoreTrigger>\n ),\n}\n\n/* The loading row (spinner + message) across all 4 DS themes × light/dark. */\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={`${theme}-${mode}`} mode={mode} theme={theme}>\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--a63-surface-radius, var(--radius-lg))',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 96 }}>\n {theme} / {mode}\n </span>\n <LoadMoreTrigger hasMore isLoading />\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\nexport const Endpoints: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n <UIProvider designLanguage=\"web\" input=\"pointer\">\n <EndpointTrigger label=\"Web\" />\n </UIProvider>\n <UIProvider designLanguage=\"ios\" input=\"touch\">\n <EndpointTrigger label=\"iOS touch\" />\n </UIProvider>\n <UIProvider density=\"compact\" designLanguage=\"web\" input=\"pointer\">\n <EndpointTrigger label=\"Compact extension\" />\n </UIProvider>\n </div>\n ),\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(loadMoreTriggerContract, null, 2)}\n </pre>\n ),\n}\n\nfunction EndpointTrigger({ label }: { label: string }) {\n return (\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n paddingInline: 12,\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 112 }}>{label}</span>\n <LoadMoreTrigger hasMore isLoading variant=\"prominent\" />\n </div>\n )\n}\n"
|
|
13568
|
+
"source": "import { loadMoreTriggerContract, loadMoreTriggerVariants, themes } from '@atom63/ui-foundation'\nimport { Button, LoadMoreTrigger, UIProvider } from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\nconst meta = {\n title: 'UI React/LoadMoreTrigger',\n component: LoadMoreTrigger,\n argTypes: {\n variant: { control: 'inline-radio', options: loadMoreTriggerVariants },\n state: {\n control: 'select',\n options: loadMoreTriggerContract.states.filter(state => state !== 'custom'),\n },\n hasMore: { control: 'boolean' },\n isLoading: { control: 'boolean' },\n },\n args: { hasMore: true, isLoading: false, variant: 'default' },\n} satisfies Meta<typeof LoadMoreTrigger>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nexport const Playground: Story = {}\n\n/* Explicit state API uses the shared state-tone contract. */\nexport const States: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n <LoadMoreTrigger state=\"idle\" />\n <LoadMoreTrigger state=\"loading\" />\n <LoadMoreTrigger onRetry={() => {}} state=\"failed\" />\n <LoadMoreTrigger state=\"exhausted\" />\n </div>\n ),\n}\n\nexport const Variants: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {loadMoreTriggerVariants.map(variant => (\n <LoadMoreTrigger hasMore isLoading key={variant} variant={variant} />\n ))}\n </div>\n ),\n}\n\nexport const Exhausted: Story = {\n args: { state: 'exhausted' },\n}\n\nexport const Failed: Story = {\n args: { onRetry: () => {}, state: 'failed' },\n}\n\n/* On a touch screen the Retry text keeps its size, and its hit area grows to the\n 44px touch target (--a63-control-min-target) around it. */\nexport const FailedTouch: Story = {\n play: ({ canvasElement }) => {\n const retry = canvasElement.querySelector<HTMLElement>('[data-slot=\"load-more-trigger-action\"]')\n if (!retry) throw new Error('Expected a Retry action')\n const hitArea = getComputedStyle(retry, '::before')\n const [width, height] = [parseFloat(hitArea.width), parseFloat(hitArea.height)]\n if (!(width >= 44 && height >= 44)) {\n throw new Error(`Retry hit area is ${width}×${height}px, expected at least 44×44`)\n }\n },\n render: () => (\n <UIProvider input=\"touch\">\n <LoadMoreTrigger onRetry={() => {}} state=\"failed\" />\n </UIProvider>\n ),\n}\n\n/* Custom children take over the row entirely (e.g. a manual \"Load more\" button). */\nexport const CustomChildren: Story = {\n render: () => (\n <LoadMoreTrigger hasMore isLoading={false}>\n <Button type=\"button\" variant=\"secondary\">\n Load more\n </Button>\n </LoadMoreTrigger>\n ),\n}\n\n/* The loading row (spinner + message) across all 4 DS themes × light/dark. */\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={`${theme}-${mode}`} mode={mode} theme={theme}>\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--a63-surface-radius, var(--radius-lg))',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 96 }}>\n {theme} / {mode}\n </span>\n <LoadMoreTrigger hasMore isLoading />\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\n/* The sRGBA channels of a computed CSS colour, read back through a canvas so any\n colour syntax (oklch, color-mix) resolves the way the browser paints it. */\nfunction paintedRgba(color: string): [number, number, number, number] {\n const context = document.createElement('canvas').getContext('2d')\n if (!context) throw new Error('Expected a 2D canvas context')\n context.fillStyle = color\n context.fillRect(0, 0, 1, 1)\n const [r = 0, g = 0, b = 0, a = 0] = context.getImageData(0, 0, 1, 1).data\n return [r, g, b, a / 255]\n}\n\nfunction over(\n top: [number, number, number, number],\n base: [number, number, number]\n): [number, number, number] {\n const [r, g, b, a] = top\n return [r * a + base[0] * (1 - a), g * a + base[1] * (1 - a), b * a + base[2] * (1 - a)]\n}\n\n/* The colour an element sits on: its own and its ancestors' fills, composited\n from the first opaque one up. */\nfunction backdrop(element: HTMLElement): [number, number, number] {\n const layers: [number, number, number, number][] = []\n for (let node: HTMLElement | null = element; node; node = node.parentElement) {\n const fill = paintedRgba(getComputedStyle(node).backgroundColor)\n if (fill[3] > 0) layers.push(fill)\n if (fill[3] >= 0.99) break\n }\n return layers.reduceRight<[number, number, number]>(\n (base, layer) => over(layer, base),\n [255, 255, 255]\n )\n}\n\nfunction contrast(a: [number, number, number], b: [number, number, number]): number {\n const luminance = (rgb: [number, number, number]) => {\n const [r = 0, g = 0, b = 0] = rgb.map(channel => {\n const c = channel / 255\n return c <= 0.04045 ? c / 12.92 : ((c + 0.055) / 1.055) ** 2.4\n })\n return 0.2126 * r + 0.7152 * g + 0.0722 * b\n }\n const [hi = 0, lo = 0] = [luminance(a), luminance(b)].sort((x, y) => y - x)\n return (hi + 0.05) / (lo + 0.05)\n}\n\n/* The failed row across all 4 DS themes × light/dark. The Retry label is text\n (WCAG 1.4.3, 4.5:1) and the error icon a graphic (1.4.11, 3:1). */\nexport const FailedThemes: Story = {\n play: ({ canvasElement }) => {\n const rows = canvasElement.querySelectorAll<HTMLElement>('[data-failed-row]')\n if (rows.length !== themes.length * 2)\n throw new Error('Expected a failed row per theme and mode')\n for (const row of rows) {\n const checks = [\n ['Retry label', row.querySelector<HTMLElement>('.a63-LoadMoreTrigger-action'), 4.5],\n ['error icon', row.querySelector<HTMLElement>('.a63-LoadMoreTrigger-icon'), 3],\n ] as const\n for (const [name, element, min] of checks) {\n if (!element) throw new Error(`${row.dataset.failedRow}: no ${name}`)\n const base = backdrop(element)\n const ratio = contrast(over(paintedRgba(getComputedStyle(element).color), base), base)\n if (ratio < min) {\n throw new Error(`${row.dataset.failedRow}: ${name} is ${ratio.toFixed(2)}:1 < ${min}:1`)\n }\n }\n }\n },\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={`${theme}-${mode}`} mode={mode} theme={theme}>\n <div\n data-failed-row={`${theme}/${mode}`}\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--a63-surface-radius, var(--radius-lg))',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 96 }}>\n {theme} / {mode}\n </span>\n <LoadMoreTrigger onRetry={() => {}} state=\"failed\" />\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\nexport const Endpoints: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n <UIProvider designLanguage=\"web\" input=\"pointer\">\n <EndpointTrigger label=\"Web\" />\n </UIProvider>\n <UIProvider designLanguage=\"ios\" input=\"touch\">\n <EndpointTrigger label=\"iOS touch\" />\n </UIProvider>\n <UIProvider density=\"compact\" designLanguage=\"web\" input=\"pointer\">\n <EndpointTrigger label=\"Compact extension\" />\n </UIProvider>\n </div>\n ),\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(loadMoreTriggerContract, null, 2)}\n </pre>\n ),\n}\n\nfunction EndpointTrigger({ label }: { label: string }) {\n return (\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n paddingInline: 12,\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 112 }}>{label}</span>\n <LoadMoreTrigger hasMore isLoading variant=\"prominent\" />\n </div>\n )\n}\n"
|
|
13248
13569
|
},
|
|
13249
13570
|
"summary": "Load More Trigger is an observable sentinel row for incremental collection loading.",
|
|
13250
13571
|
"usage": "Attach fetching to the forwarded ref and announce loading without turning the sentinel into a button.",
|
|
@@ -13561,8 +13882,11 @@
|
|
|
13561
13882
|
"resizable-handle-grip"
|
|
13562
13883
|
],
|
|
13563
13884
|
"source": "packages/ui-foundation/contracts/components/resizable.json",
|
|
13885
|
+
"stateAliases": {
|
|
13886
|
+
"idle": "rest"
|
|
13887
|
+
},
|
|
13564
13888
|
"states": [
|
|
13565
|
-
"
|
|
13889
|
+
"rest",
|
|
13566
13890
|
"hover",
|
|
13567
13891
|
"focus-visible",
|
|
13568
13892
|
"dragging",
|
|
@@ -13594,7 +13918,7 @@
|
|
|
13594
13918
|
],
|
|
13595
13919
|
"importPath": "@atom63/ui-react",
|
|
13596
13920
|
"label": "Resizable",
|
|
13597
|
-
"markdown": "# Resizable\n\nResizable composes keyboard-operable panel groups, panels, and drag handles.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Horizontal` story maintained with the component.\n\n## Guidance\n\n- Give each panel usable minimums and make the handle visible when resizing is not otherwise obvious.\n- Keep the utility’s semantic purpose explicit instead of relying on visual treatment alone.\n- For animated or transient members, preserve reduced-motion behavior and surrounding layout.\n\n## Usage\n\n```tsx\nimport { ResizablePanelGroup, ResizablePanel, ResizableHandle } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `ResizableHandle`, `ResizablePanel`, `ResizablePanelGroup`\n\n**Types:** `ResizableHandleProps`, `ResizableOrientation`, `ResizablePanelGroupProps`, `ResizablePanelProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/resizable.json` (`resizableContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `orientations` | `horizontal`, `vertical` | `horizontal` |\n| `variants` | `line`, `grip` | — |\n\n**Slots:** `resizable-panel-group`, `resizable-panel`, `resizable-handle`, `resizable-handle-grip`\n\n**States:** `
|
|
13921
|
+
"markdown": "# Resizable\n\nResizable composes keyboard-operable panel groups, panels, and drag handles.\n\n**Status:** Stable\n\n## Preview\n\nThe live documentation page renders the `Horizontal` story maintained with the component.\n\n## Guidance\n\n- Give each panel usable minimums and make the handle visible when resizing is not otherwise obvious.\n- Keep the utility’s semantic purpose explicit instead of relying on visual treatment alone.\n- For animated or transient members, preserve reduced-motion behavior and surrounding layout.\n\n## Usage\n\n```tsx\nimport { ResizablePanelGroup, ResizablePanel, ResizableHandle } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `ResizableHandle`, `ResizablePanel`, `ResizablePanelGroup`\n\n**Types:** `ResizableHandleProps`, `ResizableOrientation`, `ResizablePanelGroupProps`, `ResizablePanelProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/resizable.json` (`resizableContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `orientations` | `horizontal`, `vertical` | `horizontal` |\n| `variants` | `line`, `grip` | — |\n\n**Deprecated aliases:** `idle` → `rest` (states)\n\n**Slots:** `resizable-panel-group`, `resizable-panel`, `resizable-handle`, `resizable-handle-grip`\n\n**States:** `rest`, `hover`, `focus-visible`, `dragging`, `disabled`\n\n## Related components\n\n- [Separator](/components/component-separator)\n- [Sidebar](/components/component-sidebar)\n",
|
|
13598
13922
|
"related": [
|
|
13599
13923
|
"separator",
|
|
13600
13924
|
"sidebar"
|
|
@@ -13834,7 +14158,7 @@
|
|
|
13834
14158
|
"Endpoints",
|
|
13835
14159
|
"ContractMetadata"
|
|
13836
14160
|
],
|
|
13837
|
-
"source": "import { textTickerContract, themes } from '@atom63/ui-foundation'\nimport { TextTicker, UIProvider } from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\nconst meta = {\n title: 'UI React/TextTicker',\n component: TextTicker,\n args: {\n children: 'Now playing — A very long track title that will overflow its container',\n variant: 'marquee',\n autoPlay: false,\n marqueeSpeed: 24,\n marqueeDelay: 0,\n },\n argTypes: {\n variant: { control: 'inline-radio', options: ['truncate', 'marquee'] },\n autoPlay: { control: 'boolean' },\n marqueeSpeed: { control: { type: 'number', min: 4, max: 60 } },\n marqueeDelay: { control: { type: 'number', min: 0, max: 2000, step: 100 } },\n },\n} satisfies Meta<typeof TextTicker>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nconst frame = (child: React.ReactNode) => (\n <div\n style={{\n width: 220,\n padding: '0.5rem 0.75rem',\n border: '1px solid var(--a63-border-control)',\n borderRadius: 'var(--a63-control-radius)',\n background: 'var(--a63-surface-panel)',\n color: 'var(--a63-text-primary)',\n fontFamily: 'var(--a63-control-font-family)',\n fontSize: 14,\n }}\n >\n {child}\n </div>\n)\n\n/* Hover (or focus) the constrained frame to reveal the scrolling marquee. */\nexport const Playground: Story = {\n render: args => (\n <div style={{ display: 'grid', gap: 8 }}>\n {frame(<TextTicker {...args} tabIndex={0} />)}\n <span style={{ color: 'var(--a63-text-secondary)', fontSize: 12 }}>\n Hover or focus the title to reveal the full text\n </span>\n </div>\n ),\n}\n\n/* No overflow — the ticker simply renders the text (marquee never engages). */\nexport const FitsInContainer: Story = {\n args: { children: 'Short title' },\n render: args => frame(<TextTicker {...args} />),\n}\n\n/* autoPlay scrolls continuously once the content overflows, no hover needed. */\nexport const AutoPlay: Story = {\n args: { autoPlay: true },\n render: args => frame(<TextTicker {...args} />),\n}\n\n/* The default truncate variant is a plain truncating line. */\nexport const StaticTruncate: Story = {\n args: { variant: 'truncate' },\n render: args => frame(<TextTicker {...args} />),\n}\n\n/* The ticker across all 4 DS themes × light/dark. autoPlay so the marquee is\n visible without hover in the static grid. */\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={`${theme}-${mode}`} mode={mode} theme={theme}>\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 96 }}>\n {theme} / {mode}\n </span>\n {frame(\n <TextTicker variant=\"marquee\" autoPlay marqueeSpeed={24}>\n Now playing — A very long track title that will overflow its container\n </TextTicker>\n )}\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\n/* Compare the same overflow behavior at the supported endpoint densities. */\nexport const Endpoints: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n <UIProvider designLanguage=\"web\" input=\"pointer\">\n {frame(\n <TextTicker variant=\"marquee\" autoPlay>\n Web — a long overflowing title for review\n </TextTicker>\n )}\n </UIProvider>\n <UIProvider designLanguage=\"ios\" input=\"touch\">\n {frame(\n <TextTicker variant=\"marquee\" autoPlay>\n iOS touch — a long overflowing title for review\n </TextTicker>\n )}\n </UIProvider>\n <UIProvider density=\"compact\">\n {frame(\n <TextTicker variant=\"marquee\" autoPlay>\n Compact extension — a long overflowing title\n </TextTicker>\n )}\n </UIProvider>\n </div>\n ),\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(textTickerContract, null, 2)}\n </pre>\n ),\n}\n"
|
|
14161
|
+
"source": "import { textTickerContract, themes } from '@atom63/ui-foundation'\nimport { TextTicker, UIProvider } from '@atom63/ui-react'\nimport '@atom63/ui-react/styles.css'\nimport type { Meta, StoryObj } from '@storybook/react-vite'\n\nconst meta = {\n title: 'UI React/TextTicker',\n component: TextTicker,\n args: {\n children: 'Now playing — A very long track title that will overflow its container',\n variant: 'marquee',\n autoPlay: false,\n marqueeSpeed: 24,\n marqueeDelay: 0,\n },\n argTypes: {\n variant: { control: 'inline-radio', options: ['truncate', 'marquee'] },\n autoPlay: { control: 'boolean' },\n marqueeSpeed: { control: { type: 'number', min: 4, max: 60 } },\n marqueeDelay: { control: { type: 'number', min: 0, max: 2000, step: 100 } },\n },\n} satisfies Meta<typeof TextTicker>\n\nexport default meta\ntype Story = StoryObj<typeof meta>\n\nconst frame = (child: React.ReactNode) => (\n <div\n style={{\n width: 220,\n padding: '0.5rem 0.75rem',\n border: '1px solid var(--a63-border-control)',\n borderRadius: 'var(--a63-control-radius)',\n background: 'var(--a63-surface-panel)',\n color: 'var(--a63-text-primary)',\n fontFamily: 'var(--a63-control-font-family)',\n fontSize: 14,\n }}\n >\n {child}\n </div>\n)\n\n/* Hover (or focus) the constrained frame to reveal the scrolling marquee. */\nexport const Playground: Story = {\n render: args => (\n <div style={{ display: 'grid', gap: 8 }}>\n {frame(<TextTicker {...args} tabIndex={0} />)}\n <span style={{ color: 'var(--a63-text-secondary)', fontSize: 12 }}>\n Hover or focus the title to reveal the full text\n </span>\n </div>\n ),\n}\n\n/* No overflow — the ticker simply renders the text (marquee never engages). */\nexport const FitsInContainer: Story = {\n args: { children: 'Short title' },\n render: args => frame(<TextTicker {...args} />),\n}\n\n/* autoPlay scrolls continuously once the content overflows, no hover needed.\n It pauses on hover and focus and shows a pause toggle (WCAG 2.2.2). */\nexport const AutoPlay: Story = {\n args: { autoPlay: true },\n render: args => frame(<TextTicker {...args} />),\n play: async ({ canvasElement }) => {\n await new Promise(resolve => setTimeout(resolve, 50))\n const toggle = canvasElement.querySelector<HTMLButtonElement>('button[aria-label=\"Pause\"]')\n // Under reduced motion (the visual run sets it) the ticker stands still and shows no toggle.\n if (window.matchMedia('(prefers-reduced-motion: reduce)').matches) {\n if (toggle) throw new Error('Expected no pause toggle under reduced motion')\n return\n }\n if (!toggle) throw new Error('Expected the built-in pause toggle')\n toggle.click()\n await new Promise(resolve => setTimeout(resolve, 50))\n if (toggle.getAttribute('aria-pressed') !== 'true') {\n throw new Error('Expected the pause toggle to be pressed')\n }\n const track = canvasElement.querySelector('.a63-TextTicker-marqueeTrack')\n if (!track || getComputedStyle(track).animationPlayState !== 'paused') {\n throw new Error('Expected the marquee track to be paused')\n }\n toggle.click()\n await new Promise(resolve => setTimeout(resolve, 50))\n if (getComputedStyle(track).animationPlayState !== 'running') {\n throw new Error('Expected the marquee track to run again after resuming')\n }\n },\n}\n\n/* The default truncate variant is a plain truncating line. */\nexport const StaticTruncate: Story = {\n args: { variant: 'truncate' },\n render: args => frame(<TextTicker {...args} />),\n}\n\n/* The ticker across all 4 DS themes × light/dark. autoPlay so the marquee is\n visible without hover in the static grid. */\nexport const Themes: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n {themes.map(theme =>\n (['light', 'dark'] as const).map(mode => (\n <UIProvider key={`${theme}-${mode}`} mode={mode} theme={theme}>\n <div\n style={{\n alignItems: 'center',\n background: 'var(--a63-surface-panel)',\n borderRadius: 'var(--radius-lg)',\n color: 'var(--a63-text-primary)',\n display: 'flex',\n gap: 12,\n padding: '0.75rem',\n }}\n >\n <span style={{ fontSize: 12, color: 'var(--a63-text-secondary)', width: 96 }}>\n {theme} / {mode}\n </span>\n {frame(\n <TextTicker variant=\"marquee\" autoPlay marqueeSpeed={24}>\n Now playing — A very long track title that will overflow its container\n </TextTicker>\n )}\n </div>\n </UIProvider>\n ))\n )}\n </div>\n ),\n}\n\n/* Compare the same overflow behavior at the supported endpoint densities. */\nexport const Endpoints: Story = {\n render: () => (\n <div style={{ display: 'grid', gap: 12 }}>\n <UIProvider designLanguage=\"web\" input=\"pointer\">\n {frame(\n <TextTicker variant=\"marquee\" autoPlay>\n Web — a long overflowing title for review\n </TextTicker>\n )}\n </UIProvider>\n <UIProvider designLanguage=\"ios\" input=\"touch\">\n {frame(\n <TextTicker variant=\"marquee\" autoPlay>\n iOS touch — a long overflowing title for review\n </TextTicker>\n )}\n </UIProvider>\n <UIProvider density=\"compact\">\n {frame(\n <TextTicker variant=\"marquee\" autoPlay>\n Compact extension — a long overflowing title\n </TextTicker>\n )}\n </UIProvider>\n </div>\n ),\n}\n\nexport const ContractMetadata: Story = {\n render: () => (\n <pre style={{ fontSize: 12, margin: 0, whiteSpace: 'pre-wrap' }}>\n {JSON.stringify(textTickerContract, null, 2)}\n </pre>\n ),\n}\n"
|
|
13838
14162
|
},
|
|
13839
14163
|
"summary": "Text Ticker truncates text and can reveal overflow with a measured marquee.",
|
|
13840
14164
|
"usage": "Keep the full text accessible elsewhere and avoid autoplay for essential reading.",
|
|
@@ -13992,14 +14316,14 @@
|
|
|
13992
14316
|
{
|
|
13993
14317
|
"area": "components",
|
|
13994
14318
|
"label": "Button",
|
|
13995
|
-
"markdown": "# Button\n\nButton is the reference action primitive for the current system: typed variants from `@atom63/ui-foundation`, Base UI-compatible rendering in `@atom63/ui-react`, and material values from the `control` and `action` contracts.\n\n```tsx\nimport { Button } from '@atom63/ui-react'\n\n<Button variant=\"primary\">Save changes</Button>\n<Button>Cancel</Button>\n<Button variant=\"outline\">Duplicate</Button>\n<Button variant=\"ghost\">Dismiss</Button>\n<Button variant=\"destructive\">Delete</Button>\n```\n\n## When to use\n\nUse it for an in-place action such as submitting, saving, confirming or changing state; use a link when the outcome is navigation. Choose emphasis from the action hierarchy rather than making every action primary, and give icon-only buttons an accessible name. Draw secondary actions in toolbars, rows and card headers as variant=\"ghost\" with tone=\"muted\". shape=\"round\" makes icon buttons circles (a play button) and labelled buttons pills.\n\n## Why it exists\n\nRaw buttons are easy until they need to survive themes, density, loading, icon-only sizing, pressed states, and form safety. The shared Button exists so every product surface gets those decisions once.\n\n## Contract shape\n\nThe root always renders `data-slot=\"button\"` and carries `data-variant` and `data-size`. Trigger-specific composition can mirror a different slot through `data-trigger-slot`, while the anatomy stays a button.\n\n| Layer | Examples |\n|-------|----------|\n| Public API | `variant`, `size`, `tone`, `shape`, `loading`, `disabled`, `render`, `type`. |\n| Stable metadata | `data-slot=\"button\"`, `data-size`, `data-variant`, `data-tone`, `data-loading`, `data-disabled`. |\n| Local recipe vars | `--button-background`, `--button-foreground`, `--button-shadow`, `--button-radius`. |\n| System vars | `--a63-action-*`, `--a63-control-*`, `--a63-density-scale`, `--a63-focus-ring`. |\n\n## Variants, sizes and states\n\n| Axis | Value | Guidance |\n| --- | --- | --- |\n| Variant | `primary` | The one primary action per view, when the product's main action is in its brand colour. |\n| Variant | `default` | Neutral solid: high emphasis without the brand colour (a white play button on dark, a black Pay button). |\n| Variant | `secondary` | Muted neutral action for supporting tasks. |\n| Variant | `raised` | Light fill, soft shadow, no border; with shape=\"round\", the floating button over a map or a light photo. |\n| Variant | `outline` | Lower-emphasis alternative (Duplicate). |\n| Variant | `dashed` | Add or filter affordance drawn as a dashed pill (+ Status). |\n| Variant | `ghost` | Lowest emphasis; toolbars and dismissals, with tone=\"muted\" for quiet secondary actions. |\n| Variant | `link` | Inline action styled as text; navigation should use a real link. |\n| Variant | `destructive` | Only when the outcome destroys data. |\n| Variant | `destructive-outline` | Quieter destructive action, beside a safe default. |\n| Variant | `overlay` | Forced contrast over media and imagery; the floating button over dark media. |\n| Variant | `glass` | Compatibility alias of overlay; new work uses overlay. |\n| Size | `xs` | Dense UI. |\n| Size | `sm` | Compact rows and toolbars. |\n| Size | `md` | Default. |\n| Size | `lg` | Prominent calls to action. |\n| Size | `xl` | Hero and marketing surfaces. |\n| State | `rest` | Resting appearance. |\n| State | `hover` | Pointer over an enabled button. |\n| State | `pressed` | While pressed, or held with data-pressed. |\n| State | `
|
|
14319
|
+
"markdown": "# Button\n\nButton is the reference action primitive for the current system: typed variants from `@atom63/ui-foundation`, Base UI-compatible rendering in `@atom63/ui-react`, and material values from the `control` and `action` contracts.\n\n```tsx\nimport { Button } from '@atom63/ui-react'\n\n<Button variant=\"primary\">Save changes</Button>\n<Button>Cancel</Button>\n<Button variant=\"outline\">Duplicate</Button>\n<Button variant=\"ghost\">Dismiss</Button>\n<Button variant=\"destructive\">Delete</Button>\n```\n\n## When to use\n\nUse it for an in-place action such as submitting, saving, confirming or changing state; use a link when the outcome is navigation. Choose emphasis from the action hierarchy rather than making every action primary, and give icon-only buttons an accessible name. Draw secondary actions in toolbars, rows and card headers as variant=\"ghost\" with tone=\"muted\". shape=\"round\" makes icon buttons circles (a play button) and labelled buttons pills.\n\n## Why it exists\n\nRaw buttons are easy until they need to survive themes, density, loading, icon-only sizing, pressed states, and form safety. The shared Button exists so every product surface gets those decisions once.\n\n## Contract shape\n\nThe root always renders `data-slot=\"button\"` and carries `data-variant` and `data-size`. Trigger-specific composition can mirror a different slot through `data-trigger-slot`, while the anatomy stays a button.\n\n| Layer | Examples |\n|-------|----------|\n| Public API | `variant`, `size`, `tone`, `shape`, `loading`, `disabled`, `render`, `type`. |\n| Stable metadata | `data-slot=\"button\"`, `data-size`, `data-variant`, `data-tone`, `data-loading`, `data-disabled`. |\n| Local recipe vars | `--button-background`, `--button-foreground`, `--button-shadow`, `--button-radius`. |\n| System vars | `--a63-action-*`, `--a63-control-*`, `--a63-density-scale`, `--a63-focus-ring`. |\n\n## Variants, sizes and states\n\n| Axis | Value | Guidance |\n| --- | --- | --- |\n| Variant | `primary` | The one primary action per view, when the product's main action is in its brand colour. |\n| Variant | `default` | Neutral solid: high emphasis without the brand colour (a white play button on dark, a black Pay button). |\n| Variant | `secondary` | Muted neutral action for supporting tasks. |\n| Variant | `raised` | Light fill, soft shadow, no border; with shape=\"round\", the floating button over a map or a light photo. |\n| Variant | `outline` | Lower-emphasis alternative (Duplicate). |\n| Variant | `dashed` | Add or filter affordance drawn as a dashed pill (+ Status). |\n| Variant | `ghost` | Lowest emphasis; toolbars and dismissals, with tone=\"muted\" for quiet secondary actions. |\n| Variant | `link` | Inline action styled as text; navigation should use a real link. |\n| Variant | `destructive` | Only when the outcome destroys data. |\n| Variant | `destructive-outline` | Quieter destructive action, beside a safe default. |\n| Variant | `overlay` | Forced contrast over media and imagery; the floating button over dark media. |\n| Variant | `glass` | Compatibility alias of overlay; new work uses overlay. |\n| Size | `xs` | Dense UI. |\n| Size | `sm` | Compact rows and toolbars. |\n| Size | `md` | Default. |\n| Size | `lg` | Prominent calls to action. |\n| Size | `xl` | Hero and marketing surfaces. |\n| State | `rest` | Resting appearance. |\n| State | `hover` | Pointer over an enabled button. |\n| State | `pressed` | While pressed, or held with data-pressed. |\n| State | `focus-visible` | Keyboard focus only; drawn as an outline. |\n| State | `disabled` | A neutral grey fill and muted label; ghost, link, overlay and glass fade only the label. |\n| State | `loading` | Label keeps its width; the spinner overlays it. |\n\n## Sizes and icons\n\nEach size step sets height, inline padding, gap and icon size together. Height, padding and gap are built on `--a63-space-unit`, so density scales them once (compact `md` is 28px, rounded to whole pixels); icon sizes stay the same. Icon-only buttons use the `icon-*` steps so the control stays square, and draw their glyph from `--a63-control-icon-only-size-*`, about 0.56 of the box (24/14, 28/16, 32/18). An icon beside a label stays on the smaller `--a63-control-icon-size-*` ramp. Button owns the icon gap — never add `mr-`/`ml-` margins to an icon inside one.\n\nHide decorative icons from assistive technology when the visible label already names the action.\n\n```tsx\n<Button size=\"xs\">Extra small</Button>\n<Button size=\"sm\">Small</Button>\n<Button size=\"md\">Medium</Button>\n<Button size=\"lg\">Large</Button>\n\n<Button variant=\"primary\">\n Continue\n <ArrowRight />\n</Button>\n<Button aria-label=\"Delete\" size=\"icon\" variant=\"destructive\">\n <Trash2 />\n</Button>\n```\n\n## Emphasis without the accent\n\n`default` is the neutral solid: high emphasis without the brand colour, such as a white play button on dark or a black Pay button. `primary` is the main action when the product's main action is in its brand colour. Use the accent for one or two cues per view; the main action may be neutral.\n\n## Quiet secondary actions\n\nSecondary actions in toolbars, list rows and card headers are ghost buttons with `tone=\"muted\"`. The glyph and label rest in the secondary text colour and go to full contrast on hover, keyboard focus and press, so the row reads calm and the action still answers the pointer. Only `ghost` reads the tone; keep the main action at full contrast.\n\n```tsx\n<Button aria-label=\"Notifications\" size=\"icon-sm\" tone=\"muted\" variant=\"ghost\">\n <Bell />\n</Button>\n<Button aria-label=\"More\" size=\"icon-sm\" tone=\"muted\" variant=\"ghost\">\n <Ellipsis />\n</Button>\n<Button size=\"sm\" tone=\"muted\" variant=\"ghost\">\n <Share />\n Share\n</Button>\n```\n\n## Floating buttons\n\n`raised` is a light button lifted off its ground: the panel fill, primary text and a soft shadow, with no border. With `shape=\"round\"` at an icon size it is the floating button maps and light heroes use for back, locate and layers. Over a dark photo or video use `overlay` instead.\n\n```tsx\n<Button aria-label=\"Back\" shape=\"round\" size=\"icon-lg\" variant=\"raised\">\n <ChevronLeft />\n</Button>\n<Button aria-label=\"Show my location\" shape=\"round\" size=\"icon-lg\" variant=\"raised\">\n <LocateFixed />\n</Button>\n<Button shape=\"round\" variant=\"raised\">Search this area</Button>\n```\n\n## Decisions worth knowing\n\n### Button sets `type=\"button\"`\n\nI make the safe form behavior explicit. A shared Button should not accidentally submit a form because it was mounted inside one.\n\n### Loading preserves layout\n\nLoading hides the label visually and overlays a spinner rather than swapping content. That keeps button width stable and avoids a small but very noticeable layout jump.\n\n```tsx\n<Button loading variant=\"primary\">Save changes</Button>\n<Button loading>Save changes</Button>\n<Button disabled variant=\"primary\">Save changes</Button>\n```\n\nCompare the loading and resting buttons above: the label reserves its width, so the row never reflows when a request starts.\n\n### Themes change material, not intent\n\nAqua adds gloss and tint through `--a63-control-gloss`, `--a63-control-highlight`, and `--a63-control-shadow`. Terminal can flatten those values. The Button recipe does not branch on `theme`; it consumes the same variables in every theme.\n\n## Usage\n\n```tsx\nimport { Button } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Button`\n\n**Types:** `ButtonProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/button.json` (`buttonContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `shapes` | `default`, `round` | `default` |\n| `tones` | `neutral`, `muted` | `neutral` |\n| `variants` | `default`, `primary`, `secondary`, `raised`, `destructive`, `destructive-outline`, `outline`, `dashed`, `ghost`, `link`, `overlay`, `glass` | `default` |\n| `sizes` | `xs`, `sm`, `md`, `lg`, `xl`, `tile`, `icon-xs`, `icon-sm`, `icon`, `icon-lg`, `icon-xl` | `md` |\n\n**Deprecated aliases:** `focusVisible` → `focus-visible` (states)\n\n**Slots:** `button`, `button-label`, `button-spinner`, `button-indicator`\n\n**States:** `rest`, `hover`, `pressed`, `focus-visible`, `disabled`, `loading`\n\n**Token slots:** `button.background`, `button.foreground`, `button.border.color`, `button.border.width`, `button.radius`, `button.shadow`, `button.focusRing`, `button.height`, `button.paddingInline`, `button.gap`, `button.iconSize`, `button.motion.press`\n\n**Visual archetype:** Action controls — Momentary controls that perform an action now.\n\n### Web and iOS\n\nTrigger a user-initiated action with explicit hierarchy and feedback. Rendered by `AtomButton` in SwiftUI, with `recipe` parity.\n\n**Required states:** `rest`, `pressed`, `disabled`, `loading`\n\n**Shared outcomes:**\n\n- Action fires once\n- Loading blocks repeat activation\n- Disabled prevents activation\n\n**Accessibility outcomes:**\n\n- Exposes label\n- Announces loading\n- Disabled while loading\n\n**Platform adaptations:**\n\n- React: Uses HTML button semantics with pointer and focus-visible feedback.\n- SwiftUI: Uses SwiftUI Button with native touch and keyboard activation.\n- SwiftUI: The round shape is a capsule: a circle at the icon size, a pill with a label.\n- SwiftUI: The raised emphasis uses the panel fill and a soft shadow with no border; muted tone only quiets ghost labels.\n\n## Related components\n\n- [Button Group](/components/component-button-group)\n- [Toggle](/components/component-toggle)\n- [Copy Button](/components/component-copy-button)",
|
|
13996
14320
|
"route": "/components/component-button",
|
|
13997
14321
|
"slug": "component-button"
|
|
13998
14322
|
},
|
|
13999
14323
|
{
|
|
14000
14324
|
"area": "components",
|
|
14001
14325
|
"label": "Button group",
|
|
14002
|
-
"markdown": "# Button Group\n\nButton Group turns adjacent controls into one welded segment. It is not a row with smaller gaps; it is a composition contract for shared edges, seams, radius, and selected state.\n\n```tsx\nimport { Button, ButtonGroup, ButtonGroupSeparator, ButtonGroupText } from '@atom63/ui-react'\n\n<ButtonGroup aria-label=\"Time range\">\n <Button variant=\"outline\">Day</Button>\n <Button variant=\"outline\">Week</Button>\n <Button variant=\"outline\">Month</Button>\n</ButtonGroup>\n\n<ButtonGroup aria-label=\"Text alignment\" size=\"icon\">\n <Button aria-label=\"Align left\" variant=\"outline\"><AlignLeft /></Button>\n <Button aria-label=\"Align center\" variant=\"outline\"><AlignCenter /></Button>\n <Button aria-label=\"Align right\" variant=\"outline\"><AlignRight /></Button>\n</ButtonGroup>\n\n<ButtonGroup aria-label=\"Branch actions\">\n <ButtonGroupText>Branch</ButtonGroupText>\n <ButtonGroupSeparator />\n <Button variant=\"outline\">main <ChevronDown /></Button>\n</ButtonGroup>\n```\n\n## When to use\n\nUse Button Group for related adjacent actions that should read as one visual run. Use Toggle Group or Segmented Control when the group represents persistent selection instead of independent commands.\n\nThe group supplies `role=\"group\"` but cannot infer its name. Add `aria-label` or `aria-labelledby` when the surrounding context does not already identify the grouped controls.\n\n## How it works\n\nThe group owns adjacency. Child Buttons keep their semantic API, but inside the group they flatten standalone elevation and read the `segment` contract.\n\n| Concern | Owner |\n|---------|-------|\n| Orientation, member sizing, edge radius, seams | Button Group recipe. |\n| Button label, loading, variant, disabled state | Button. |\n| Welded material | `--a63-segment-*`. |\n| Control height, font, padding | `--a63-control-*` plus density. |\n\n## Key tokens\n\n| Token | Purpose |\n|-------|---------|\n| `--a63-segment-track-border` | Shared outer and seam border. |\n| `--a63-segment-background` | Resting member fill. |\n| `--a63-segment-gloss` | Optional member material sheen. |\n| `--a63-segment-selected-background` | Pressed or selected member fill. |\n| `--a63-segment-selected-foreground` | Text/icon color on selected member. |\n| `--a63-segment-selected-shadow` | Pressed-in or raised selected treatment. |\n| `--a63-segment-primary-background` | Brand selected state for primary emphasis. |\n\n## Design decision\n\nGrouped buttons deliberately suppress the standalone Button shadow and highlight. If every child kept its own button chrome, the group would read as several objects colliding. The segment contract makes the group one object with internal choices.\n\n```tsx\n{/* One object: shared edges, no member elevation. */}\n<ButtonGroup aria-label=\"Time range\">\n <Button variant=\"outline\">Day</Button>\n <Button variant=\"outline\">Week</Button>\n</ButtonGroup>\n\n{/* Several objects: each keeps its own chrome. */}\n<div className=\"flex gap-2\">\n <Button variant=\"outline\">Day</Button>\n <Button variant=\"outline\">Week</Button>\n</div>\n```\n\nThat is why Button Group shares material vocabulary with Segmented Control and Toggle Group instead of inventing `--button-group-theme-*` variables.\n\n## Usage\n\n```tsx\nimport { ButtonGroup, ButtonGroupText, ButtonGroupSeparator } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `ButtonGroup`, `ButtonGroupProvider`, `ButtonGroupSeparator`, `ButtonGroupText`, `useButtonGroupContext`\n\n**Types:** `ButtonGroupProps`, `ButtonGroupSeparatorProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/button-group.json` (`buttonGroupContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `orientations` | `horizontal`, `vertical` | `horizontal` |\n| `sizes` | `xs`, `sm`, `
|
|
14326
|
+
"markdown": "# Button Group\n\nButton Group turns adjacent controls into one welded segment. It is not a row with smaller gaps; it is a composition contract for shared edges, seams, radius, and selected state.\n\n```tsx\nimport { Button, ButtonGroup, ButtonGroupSeparator, ButtonGroupText } from '@atom63/ui-react'\n\n<ButtonGroup aria-label=\"Time range\">\n <Button variant=\"outline\">Day</Button>\n <Button variant=\"outline\">Week</Button>\n <Button variant=\"outline\">Month</Button>\n</ButtonGroup>\n\n<ButtonGroup aria-label=\"Text alignment\" size=\"icon\">\n <Button aria-label=\"Align left\" variant=\"outline\"><AlignLeft /></Button>\n <Button aria-label=\"Align center\" variant=\"outline\"><AlignCenter /></Button>\n <Button aria-label=\"Align right\" variant=\"outline\"><AlignRight /></Button>\n</ButtonGroup>\n\n<ButtonGroup aria-label=\"Branch actions\">\n <ButtonGroupText>Branch</ButtonGroupText>\n <ButtonGroupSeparator />\n <Button variant=\"outline\">main <ChevronDown /></Button>\n</ButtonGroup>\n```\n\n## When to use\n\nUse Button Group for related adjacent actions that should read as one visual run. Use Toggle Group or Segmented Control when the group represents persistent selection instead of independent commands.\n\nThe group supplies `role=\"group\"` but cannot infer its name. Add `aria-label` or `aria-labelledby` when the surrounding context does not already identify the grouped controls.\n\n## How it works\n\nThe group owns adjacency. Child Buttons keep their semantic API, but inside the group they flatten standalone elevation and read the `segment` contract.\n\n| Concern | Owner |\n|---------|-------|\n| Orientation, member sizing, edge radius, seams | Button Group recipe. |\n| Button label, loading, variant, disabled state | Button. |\n| Welded material | `--a63-segment-*`. |\n| Control height, font, padding | `--a63-control-*` plus density. |\n\n## Key tokens\n\n| Token | Purpose |\n|-------|---------|\n| `--a63-segment-track-border` | Shared outer and seam border. |\n| `--a63-segment-background` | Resting member fill. |\n| `--a63-segment-gloss` | Optional member material sheen. |\n| `--a63-segment-selected-background` | Pressed or selected member fill. |\n| `--a63-segment-selected-foreground` | Text/icon color on selected member. |\n| `--a63-segment-selected-shadow` | Pressed-in or raised selected treatment. |\n| `--a63-segment-primary-background` | Brand selected state for primary emphasis. |\n\n## Design decision\n\nGrouped buttons deliberately suppress the standalone Button shadow and highlight. If every child kept its own button chrome, the group would read as several objects colliding. The segment contract makes the group one object with internal choices.\n\n```tsx\n{/* One object: shared edges, no member elevation. */}\n<ButtonGroup aria-label=\"Time range\">\n <Button variant=\"outline\">Day</Button>\n <Button variant=\"outline\">Week</Button>\n</ButtonGroup>\n\n{/* Several objects: each keeps its own chrome. */}\n<div className=\"flex gap-2\">\n <Button variant=\"outline\">Day</Button>\n <Button variant=\"outline\">Week</Button>\n</div>\n```\n\nThat is why Button Group shares material vocabulary with Segmented Control and Toggle Group instead of inventing `--button-group-theme-*` variables.\n\n## Usage\n\n```tsx\nimport { ButtonGroup, ButtonGroupText, ButtonGroupSeparator } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `ButtonGroup`, `ButtonGroupProvider`, `ButtonGroupSeparator`, `ButtonGroupText`, `useButtonGroupContext`\n\n**Types:** `ButtonGroupProps`, `ButtonGroupSeparatorProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/button-group.json` (`buttonGroupContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `orientations` | `horizontal`, `vertical` | `horizontal` |\n| `sizes` | `xs`, `sm`, `md`, `lg`, `xl`, `icon-xs`, `icon-sm`, `icon`, `icon-lg`, `icon-xl` | `md` |\n\n**Deprecated aliases:** `default` → `md` (sizes)\n\n**Slots:** `button-group`, `button-group-text`, `button-group-separator`\n\n**States:** `rest`, `focus-within`\n\n**Visual archetype:** Action controls — Momentary controls that perform an action now.; Segmented selection — One-of-many peer selections presented as a shared track or grouped row.\n\n## Related components\n\n- [Button](/components/component-button)\n- [Toggle Group](/components/component-toggle-group)\n- [Segmented Control](/components/component-segmented-control)",
|
|
14003
14327
|
"route": "/components/component-button-group",
|
|
14004
14328
|
"slug": "component-button-group"
|
|
14005
14329
|
},
|
|
@@ -14034,14 +14358,14 @@
|
|
|
14034
14358
|
{
|
|
14035
14359
|
"area": "components",
|
|
14036
14360
|
"label": "Segmented control",
|
|
14037
|
-
"markdown": "# Segmented Control\n\nSegmented Control is a compact choice surface with one active value. It shares the segment archetype with Toggle Group and Button Group, but keeps its own moving indicator behavior.\n\n```tsx\nimport { SegmentedControl } from '@atom63/ui-react'\nimport { useState } from 'react'\n\n export function ThemeModeControl() {\n const [value, setValue] = useState('dark')\n\n return (\n <SegmentedControl\n items={[\n { label: 'Light', value: 'light' },\n { label: 'Dark', value: 'dark' },\n { label: 'Auto', value: 'auto' },\n ]}\n onValueChange={setValue}\n value={value}\n />\n )\n }\n```\n\nClick between segments to watch the backplate travel. `tone=\"accent\"` is the second row.\n\n## When to use\n\nUse Segmented Control for a small set of peer choices with one active value. In constrained containers, the default track stays on one line and scrolls horizontally while each item preserves its minimum target width. Set `fullWidth` when the track should fill its container and divide space equally; labels may then truncate. Use Tabs when the choices switch content panels.\n\
|
|
14361
|
+
"markdown": "# Segmented Control\n\nSegmented Control is a compact choice surface with one active value. It shares the segment archetype with Toggle Group and Button Group, but keeps its own moving indicator behavior.\n\n```tsx\nimport { SegmentedControl } from '@atom63/ui-react'\nimport { useState } from 'react'\n\n export function ThemeModeControl() {\n const [value, setValue] = useState('dark')\n\n return (\n <SegmentedControl\n aria-label=\"Appearance\"\n items={[\n { label: 'Light', value: 'light' },\n { label: 'Dark', value: 'dark' },\n { label: 'Auto', value: 'auto' },\n ]}\n onValueChange={setValue}\n value={value}\n />\n )\n }\n```\n\nClick between segments to watch the backplate travel. `tone=\"accent\"` is the second row.\n\n## When to use\n\nUse Segmented Control for a small set of peer choices with one active value. In constrained containers, the default track stays on one line and scrolls horizontally while each item preserves its minimum target width. Set `fullWidth` when the track should fill its container and divide space equally; labels may then truncate. Use Tabs when the choices switch content panels.\n\nSegmented Control is a radio group: the root has `role=\"radiogroup\"` and each segment is a `radio` named by its label. Name the group with `aria-label`, or with `aria-labelledby` pointing at a visible label. Tab moves focus to the selected segment, and the arrow keys move between segments and select as they go, as in the [APG Radio Group pattern](https://www.w3.org/WAI/ARIA/apg/patterns/radio/). It has no tab panels; when the choices switch content panels, use Tabs.\n\n## Contract shape\n\nSegmented Control is built on Base UI's radio group. The component owns selection, indicator positioning, and item anatomy. The theme owns the track and selected material through `--a63-segment-*`.\n\n| Concern | Owner |\n|---------|-------|\n| Active value and keyboard behavior | Component / Base UI radio group behavior. |\n| Track geometry and item sizing | Segmented Control recipe. |\n| Material treatment | Segment contract tokens. |\n| Brand emphasis | `tone=\"accent\"` mapping to `--a63-segment-primary-*`. |\n\n## Key tokens\n\n| Token | Purpose |\n|-------|---------|\n| `--a63-segment-track-background` | Recessed shell fill. |\n| `--a63-segment-track-border` | Track border. |\n| `--a63-segment-track-shadow` | Recessed well treatment. |\n| `--a63-segment-foreground` | Resting item label color. |\n| `--a63-segment-hover-foreground` | Hover item label color. |\n| `--a63-segment-selected-background` | Neutral active plate. |\n| `--a63-segment-selected-foreground` | Text/icon on neutral active plate. |\n| `--a63-segment-primary-background` | Brand active plate. |\n| `--a63-segment-primary-foreground` | Text/icon on brand active plate. |\n\n## Design decisions\n\n### Active state can be neutral or accent\n\nMost settings controls should use a neutral active plate. A product-level mode switch or high-emphasis choice can use `tone=\"accent\"`. That choice is semantic; the theme only decides how the plate feels.\n\n### Track and plate are separate materials\n\nThe track should read as a seated well; the active plate should read as the chosen item. If both are equally loud, the control becomes a row of decorations instead of a selector.\n\n### Motion is behavior, not a theme\n\nThe moving backplate communicates spatial continuity between selected items. Themes do not control whether the indicator animates; consumers set `animateBackplate={false}` when a context needs a snap.\n\n## Usage\n\n```tsx\nimport { SegmentedControl } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `SegmentedControl`\n\n**Types:** `SegmentedControlItem`, `SegmentedControlProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/segmented-control.json` (`segmentedControlContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `sizes` | `sm`, `md`, `lg` | `md` |\n| `tones` | `neutral`, `accent` | `neutral` |\n| `variants` | `icon`, `label` | `label` |\n\n**Slots:** `segmented-control`, `segmented-control-track`, `segmented-control-item`, `segmented-control-icon`, `segmented-control-label`, `segmented-control-indicator`\n\n**States:** `rest`, `hover`, `selected`, `disabled`, `focus-visible`\n\n**Visual archetype:** Segmented selection — One-of-many peer selections presented as a shared track or grouped row.\n\n### Web and iOS\n\nSwitch a compact local mode or view between a small set of mutually exclusive options. Rendered by `Picker(.segmented)` in SwiftUI, with `platform-adaptive` parity.\n\n**Required states:** `rest`, `selected`, `disabled`\n\n**Shared outcomes:**\n\n- One segment is selected at a time\n- Activation updates the selection once\n- Disabled segment prevents selection\n\n**Accessibility outcomes:**\n\n- Exposes each segment label\n- Exposes selected state\n- Preserves single selection semantics\n\n**Platform adaptations:**\n\n- React: Uses radiogroup and radio semantics on a segmented track, named by aria-label or aria-labelledby, with arrow-key selection, focus-visible feedback and an optional animated selection backplate.\n- SwiftUI: Uses Picker with segmented style so geometry, typography, and selection feedback remain platform-native.\n\n## Related components\n\n- [Toggle Group](/components/component-toggle-group)\n- [Tabs](/components/component-tabs)\n- [Radio](/components/component-radio)",
|
|
14038
14362
|
"route": "/components/component-segmented-control",
|
|
14039
14363
|
"slug": "component-segmented-control"
|
|
14040
14364
|
},
|
|
14041
14365
|
{
|
|
14042
14366
|
"area": "components",
|
|
14043
14367
|
"label": "Tabs",
|
|
14044
|
-
"markdown": "# Tabs\n\nTabs organize related panels without leaving the current task. The component owns orientation, keyboard behavior, indicator placement, and panel relationships; the theme owns the material values behind those states.\n\n## When to use\n\nUse Tabs for peer panels inside one task or surface. Use navigation links when each destination has its own URL, should appear in browser history, or needs to remain directly addressable.\n\nGive each `TabsList` an accessible name with `aria-label` or `aria-labelledby`; otherwise assistive technology announces an unnamed tab list. Base UI supplies keyboard movement and tab-panel relationships, but it cannot infer the group's purpose.\n\n## Variants\n\n| Variant | Intent |\n|---------|--------|\n| `default` | Contained switcher with a moving active plate. |\n| `underline` | Navigation-like tabs where active state is an edge marker. |\n| `attached` | Tabs and panel form one connected surface. |\n\n```tsx\nimport { Tabs, TabsList, TabsPanel, TabsTab } from '@atom63/ui-react'\n\n<Tabs defaultValue=\"tokens\">\n <TabsList aria-label=\"Implementation layer\" variant=\"default\">\n <TabsTab value=\"tokens\">Tokens</TabsTab>\n <TabsTab value=\"recipe\">Recipe</TabsTab>\n <TabsTab value=\"usage\">Usage</TabsTab>\n </TabsList>\n <TabsPanel value=\"tokens\">Semantic roles resolve here.</TabsPanel>\n <TabsPanel value=\"recipe\">The component recipe consumes them.</TabsPanel>\n <TabsPanel value=\"usage\">Product code sees only the API.</TabsPanel>\n</Tabs>\n```\n\n## Contract shape\n\nTabs combine several archetypes instead of inventing a theme namespace.\n\n| Part | Contract |\n|------|----------|\n| Default tab track | `--a63-surface-muted` plus `--a63-track-shadow`. |\n| Active plate | `--a63-surface-overlay`, `--a63-action-primary`, and `--a63-control-shadow`. |\n| Attached panel | `--a63-surface-*` and the surface contract. |\n| Text and focus | `--a63-text-*`, `--a63-control-focus-ring-*`. |\n\n## Design decisions\n\n### Attached tabs are one object\n\nAttached tabs are not a tab row sitting above a card. The selected tab and the panel need to visually merge, while inactive tabs remain lower-emphasis. The recipe handles that connection through panel surface tokens and active overlap.\n\n### Underline is intentionally restrained\n\nUnderline tabs are for content navigation. A full plate would compete with the page; an edge marker gives enough orientation without turning the control into a toolbar.\n\n### Orientation is component behavior\n\nHorizontal and vertical tabs use the same semantic contract. A theme should not patch orientation with bespoke spacing fixes; the recipe's size and indicator variables should keep the active marker aligned.\n\n## Review cues\n\nWhen reviewing Tabs, check that the active state is obvious in light and dark mode, the panel connection does not double its border, disabled tabs stay readable, and the active indicator remains aligned across density and radius axes.\n\n## Usage\n\n```tsx\nimport { Tabs, TabsList, TabsTab, TabsPanel } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Tabs`, `TabsContent`, `TabsList`, `TabsPanel`, `TabsTab`, `TabsTrigger`\n\n**Types:** `TabsListProps`, `TabsPanelProps`, `TabsTabProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/tabs.json` (`tabsContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `default`, `underline`, `attached` | `default` |\n| `sizes` | `xs`, `sm`, `
|
|
14368
|
+
"markdown": "# Tabs\n\nTabs organize related panels without leaving the current task. The component owns orientation, keyboard behavior, indicator placement, and panel relationships; the theme owns the material values behind those states.\n\n## When to use\n\nUse Tabs for peer panels inside one task or surface. Use navigation links when each destination has its own URL, should appear in browser history, or needs to remain directly addressable.\n\nGive each `TabsList` an accessible name with `aria-label` or `aria-labelledby`; otherwise assistive technology announces an unnamed tab list. Base UI supplies keyboard movement and tab-panel relationships, but it cannot infer the group's purpose.\n\n## Variants\n\n| Variant | Intent |\n|---------|--------|\n| `default` | Contained switcher with a moving active plate. |\n| `underline` | Navigation-like tabs where active state is an edge marker. |\n| `attached` | Tabs and panel form one connected surface. |\n\n```tsx\nimport { Tabs, TabsList, TabsPanel, TabsTab } from '@atom63/ui-react'\n\n<Tabs defaultValue=\"tokens\">\n <TabsList aria-label=\"Implementation layer\" variant=\"default\">\n <TabsTab value=\"tokens\">Tokens</TabsTab>\n <TabsTab value=\"recipe\">Recipe</TabsTab>\n <TabsTab value=\"usage\">Usage</TabsTab>\n </TabsList>\n <TabsPanel value=\"tokens\">Semantic roles resolve here.</TabsPanel>\n <TabsPanel value=\"recipe\">The component recipe consumes them.</TabsPanel>\n <TabsPanel value=\"usage\">Product code sees only the API.</TabsPanel>\n</Tabs>\n```\n\n## Contract shape\n\nTabs combine several archetypes instead of inventing a theme namespace.\n\n| Part | Contract |\n|------|----------|\n| Default tab track | `--a63-surface-muted` plus `--a63-track-shadow`. |\n| Active plate | `--a63-surface-overlay`, `--a63-action-primary`, and `--a63-control-shadow`. |\n| Attached panel | `--a63-surface-*` and the surface contract. |\n| Text and focus | `--a63-text-*`, `--a63-control-focus-ring-*`. |\n\n## Design decisions\n\n### Attached tabs are one object\n\nAttached tabs are not a tab row sitting above a card. The selected tab and the panel need to visually merge, while inactive tabs remain lower-emphasis. The recipe handles that connection through panel surface tokens and active overlap.\n\n### Underline is intentionally restrained\n\nUnderline tabs are for content navigation. A full plate would compete with the page; an edge marker gives enough orientation without turning the control into a toolbar.\n\n### Orientation is component behavior\n\nHorizontal and vertical tabs use the same semantic contract. A theme should not patch orientation with bespoke spacing fixes; the recipe's size and indicator variables should keep the active marker aligned.\n\n## Review cues\n\nWhen reviewing Tabs, check that the active state is obvious in light and dark mode, the panel connection does not double its border, disabled tabs stay readable, and the active indicator remains aligned across density and radius axes.\n\n## Usage\n\n```tsx\nimport { Tabs, TabsList, TabsTab, TabsPanel } from '@atom63/ui-react'\n```\n\n## API surface\n\n**Values:** `Tabs`, `TabsContent`, `TabsList`, `TabsPanel`, `TabsTab`, `TabsTrigger`\n\n**Types:** `TabsListProps`, `TabsPanelProps`, `TabsTabProps`\n\nTypeScript remains the source of truth for complete prop contracts.\n\n## Contract\n\nSource: `packages/ui-foundation/contracts/components/tabs.json` (`tabsContract` in `@atom63/ui-foundation`).\n\n| Axis | Values | Default |\n| --- | --- | --- |\n| `variants` | `default`, `underline`, `attached` | `default` |\n| `sizes` | `xs`, `sm`, `md`, `lg` | `md` |\n| `orientations` | `horizontal`, `vertical` | — |\n\n**Deprecated aliases:** `default` → `md` (sizes)\n\n**Slots:** `tabs`, `tabs-list`, `tabs-tab`, `tab-indicator`, `tabs-content`\n\n**States:** `rest`, `hover`, `selected`, `focus-visible`, `disabled`\n\n**Visual archetype:** Segmented selection — One-of-many peer selections presented as a shared track or grouped row.; Static content surfaces — In-flow containers and content surfaces that do not inherently manipulate state.\n\n**Accessibility pattern:** [Tabs](https://www.w3.org/WAI/ARIA/apg/patterns/tabs/) (activation: manual)\n\n### Web and iOS\n\nSwitch between peer destinations or content views while keeping one selection active. Rendered by `Picker(.segmented) / AtomTabRow` in SwiftUI, with `platform-adaptive` parity.\n\n**SwiftUI renderer per variant:**\n\n- `default`: `Picker(.segmented)`\n- `underline`: `AtomTabRow`\n- `attached`: `AtomTabRow`\n\n**Required states:** `rest`, `selected`\n\n**Shared outcomes:**\n\n- One tab is selected at a time\n- Selection reveals the associated content\n- Selected tab remains visually distinguishable\n\n**Accessibility outcomes:**\n\n- Exposes tab labels\n- Exposes selected state\n- Associates selection with visible content\n\n**Platform adaptations:**\n\n- React: Uses tablist, tab, and tabpanel semantics with keyboard navigation and a visual indicator.\n- SwiftUI: The default variant is a segmented Picker above the content it selects, for a short second-level filter of two to four options.\n- SwiftUI: The underline variant is AtomTabRow, a row of text tabs over the content it selects: the selected tab reads text-primary over an accent bar, the others text-secondary. The row scrolls sideways when the tabs do not fit and keeps the selected tab in view. Each tab can show an SF Symbol over its label. The bar slides to the new tab, and jumps under Reduce Motion. Each tab is a named button with the selected trait inside a tab-bar container, and the row mirrors in right-to-left languages.\n- SwiftUI: The attached variant also renders as AtomTabRow: folder tabs are a pointer idiom with no iOS counterpart, and the underline row already sits flush on the content it selects.\n- SwiftUI: TabView stays the renderer for app-level sections such as a tab bar or sidebar.\n- SwiftUI: In a TabView, each tab's root is its ScrollView or List. From iOS 26 the glass tab bar floats over it: content scrolls under the bar at rest, and TabView insets the scroll content so the last row ends above the bar. Do not pad for the bar, draw content in a ZStack or overlay over the TabView, or apply ignoresSafeArea to the bottom edge; extra bottom chrome goes in safeAreaInset(edge: .bottom) on the tab's root.\n\n## Related components\n\n- [Segmented Control](/components/component-segmented-control)\n- [Collapsible](/components/component-collapsible)\n- [Navigation Menu](/components/component-navigation-menu)",
|
|
14045
14369
|
"route": "/components/component-tabs",
|
|
14046
14370
|
"slug": "component-tabs"
|
|
14047
14371
|
},
|
|
@@ -14090,7 +14414,7 @@
|
|
|
14090
14414
|
{
|
|
14091
14415
|
"area": "foundations",
|
|
14092
14416
|
"label": "Personalization",
|
|
14093
|
-
"markdown": "# Personalization\n\nPersonalization is not a theme picker bolted onto the UI. It is the shape of the foundation: independent axes stamped as `data-a63-*` attributes (plus one scalar tint token), resolving through one semantic `--a63-*` layer.\n\n## Axes, not presets\n\nPresets demo well and compose badly. The moment someone wants Aqua material with a different neutral family and sharper radius, a preset model becomes a matrix of one-offs.\n\nATOM63 uses axes instead. Each axis owns a distinct slice of the system. CSS-backed component recipes inherit the resolved tokens instead of branching on axis values; `iconTheme` is the explicit React-consumed exception.\n\nThe live registry lives in `@atom63/ui-foundation` → `personalizationAxes`. The table below mirrors it:\n\n| Axis | Values | Applied as | Owns |\n|------|--------|------------|------|\n| Design language | `web` · `ios` | `data-a63-design-language` | Control proportions and interaction feedback. |\n| Mode | `light` · `dark` · `system` | `.light` / `.dark` + `data-a63-mode` | Light/dark semantic color resolution. |\n| Theme | `modern` · `aqua` · `retro` · `terminal` | `data-a63-theme` | Material values: gloss, shadow, bevel, texture, blur. |\n| Brand | `auto` · `b1`–`b6` | `data-a63-brand` | Primary tonal ramp and focus color. |\n| Surface | `n1`–`n6` | `data-a63-surface` | Neutral surface palette. |\n| Surface tint | `0%`–`100%` | `--a63-surface-tint` | Continuous brand bend on semantic surfaces. |\n| Type scale | `compact` · `normal` · `comfortable` · `large` | `data-a63-type-scale` | Global typographic scale. |\n| Radius | `none` · `subtle` · `default` · `round` | `data-a63-radius` | Corner multiplier across the radius ramp. |\n| Font | `sans` · `serif` · `mono` · `pixel` | `data-a63-font` | Active type personality. |\n| Input | `touch` · `pointer` · `keyboard` | `data-a63-input` | Hit target ergonomics. |\n| Density | `compact` · `comfortable` | `data-a63-density` | Spacing rhythm and proportional control sizing. |\n| OS | `macos` · `windows` | `data-a63-os` | Shell chrome and platform framing. |\n| Icon theme | `realistic` · `color` · `neutral` · `primary` | `data-a63-icon-theme` | Icon rendering style (React-consumed). |\n\n`UIProvider` stamps design language, mode, theme, brand, input, density, and surface when those props are supplied. `applyPersonalization` / `PersonalizationController` stamps mode, theme, brand, surface, tint, type scale, radius, font, OS, and icon theme. Together they cover every live axis; neither stamper resets dimensions it does not own. The contract is attributes (or one scalar) in, tokens out.\n\nRuntime availability and implementation completeness answer different questions: an axis can be stampable while one of its owned token groups is still expanding. The live registry in `packages/ui-foundation/src/axes.ts` is the source of truth for that implementation metadata; public documentation describes the stable contract rather than duplicating the internal backlog.\n\n## Density\n\nDensity sets one number, the space unit (`--a63-space-unit`): 4px when comfortable, 3.5px when compact. The space steps, gaps, paddings, row padding and control heights are all built on it, so compact scales them once, by 0.875: a 32px control becomes 28px and a 16px gap 14px. Control heights and row padding round to whole pixels, so a 36px control becomes 32px rather than 31.5px. Text keeps its size; the type scale axis owns that.\n\nIt works the same on `<html>` and on a nested scope. Every token built on the unit is declared again on `[data-a63-density]`, so `<UIProvider density=\"compact\">` around one region recomputes them there, and a design-language or phone scope keeps its own height ramp at the compact unit.\n\nDensity is also a product choice, not only a user preference. Use compact for dense product screens, where rows of data are scanned and acted on: tables, inboxes, issue trackers, admin dashboards and file lists.\n\n```tsx\nimport { UIProvider } from '@atom63/ui-react'\n\n<UIProvider density=\"compact\">\n {/* the table, inbox or list */}\n</UIProvider>\n```\n\nFor a whole app, set `data-a63-density=\"compact\"` on `<html>`. `atom63 build` suggests it for these screens.\n\n## One semantic layer\n\nThe rule is deliberately small:\n\n> Axes set attributes. The cascade resolves `--a63-*`. Components read `--a63-*`.\n\nThat means no component writes `--primary`, `--background`, or raw `--surface-*` values inline to express personalization. Those names are either compatibility aliases or palette primitives; writing them directly freezes a value at the wrong layer.\n\n## Why surface tint is continuous\n\nBrand and surface are separate axes because color personality has two jobs: accent and neutrality. `data-a63-brand` chooses the accent ramp. `data-a63-surface` chooses the neutral family. `--a63-surface-tint` bends the semantic surfaces toward the brand hue without generating a bespoke palette for every tint value.\n\nThe implementation mixes a small set of semantic surface and border roles rather than every raw ramp stop. That is the practical tradeoff: fewer computed colors, more predictable UI, and enough expressiveness for product-level personalization.\n\n## OS is not a theme\n\nTheme is material character. OS is platform structure. I split them because \"Windows\" should not imply one permanent visual skin, and \"Terminal\" should not dictate where caption controls live.\n\nThis lets OS63 compose coordinates such as `theme=terminal` with `os=macos`, or `theme=aqua` with `os=windows`, without inventing new theme names.\n\nRadius, type scale, and font are also **not** theme — they are independent appearance axes so you can keep Aqua material while sharpening corners or enlarging type.\n\n## What this enables\n\n- A subtree can override one axis without resetting the others.\n- Theme work can happen in CSS without React conditionals.\n- Agents can reason from the axis table instead of guessing local conventions.\n- Public docs can explain the architecture at the same level the code enforces it.",
|
|
14417
|
+
"markdown": "# Personalization\n\nPersonalization is not a theme picker bolted onto the UI. It is the shape of the foundation: independent axes stamped as `data-a63-*` attributes (plus one scalar tint token), resolving through one semantic `--a63-*` layer.\n\n## Axes, not presets\n\nPresets demo well and compose badly. The moment someone wants Aqua material with a different neutral family and sharper radius, a preset model becomes a matrix of one-offs.\n\nATOM63 uses axes instead. Each axis owns a distinct slice of the system. CSS-backed component recipes inherit the resolved tokens instead of branching on axis values; `iconTheme` is the explicit React-consumed exception.\n\nThe live registry lives in `@atom63/ui-foundation` → `personalizationAxes`. The table below mirrors it:\n\n| Axis | Values | Applied as | Owns |\n|------|--------|------------|------|\n| Design language | `web` · `ios` | `data-a63-design-language` | Control proportions and interaction feedback. |\n| Mode | `light` · `dark` · `system` | `.light` / `.dark` + `data-a63-mode` | Light/dark semantic color resolution. |\n| Theme | `modern` · `aqua` · `retro` · `terminal` | `data-a63-theme` | Material values: gloss, shadow, bevel, texture, blur. |\n| Brand | `auto` · `b1`–`b6` | `data-a63-brand` | Primary tonal ramp and focus color. |\n| Surface | `n1`–`n6` | `data-a63-surface` | Neutral surface palette. |\n| Surface tint | `0%`–`100%` | `--a63-surface-tint` | Continuous brand bend on semantic surfaces. |\n| Type scale | `compact` · `normal` · `comfortable` · `large` | `data-a63-type-scale` | Global typographic scale. |\n| Radius | `none` · `subtle` · `default` · `round` | `data-a63-radius` | Corner multiplier across the radius ramp. |\n| Font | `sans` · `serif` · `mono` · `pixel` | `data-a63-font` | Active type personality. |\n| Input | `touch` · `pointer` · `keyboard` | `data-a63-input` | Hit target ergonomics. |\n| Density | `compact` · `comfortable` | `data-a63-density` | Spacing rhythm and proportional control sizing. |\n| OS | `macos` · `windows` | `data-a63-os` | Shell chrome and platform framing. |\n| Icon theme | `realistic` · `color` · `neutral` · `primary` | `data-a63-icon-theme` | Icon rendering style (React-consumed). |\n\n`UIProvider` stamps design language, mode, theme, brand, input, density, and surface when those props are supplied. `applyPersonalization` / `PersonalizationController` stamps mode, theme, brand, surface, tint, type scale, radius, font, OS, and icon theme. Together they cover every live axis; neither stamper resets dimensions it does not own. The contract is attributes (or one scalar) in, tokens out.\n\nRuntime availability and implementation completeness answer different questions: an axis can be stampable while one of its owned token groups is still expanding. The live registry in `packages/ui-foundation/src/axes.ts` is the source of truth for that implementation metadata; public documentation describes the stable contract rather than duplicating the internal backlog.\n\n## Density\n\nDensity sets one number, the space unit (`--a63-space-unit`): 4px when comfortable, 3.5px when compact. The space steps, gaps, paddings, row padding and control heights are all built on it, so compact scales them once, by 0.875: a 32px control becomes 28px and a 16px gap 14px. Control heights and row padding round to whole pixels, so a 36px control becomes 32px rather than 31.5px. Text keeps its size; the type scale axis owns that.\n\nIt works the same on `<html>` and on a nested scope. Every token built on the unit is declared again on `[data-a63-density]`, so `<UIProvider density=\"compact\">` around one region recomputes them there, and a design-language or phone scope keeps its own height ramp at the compact unit.\n\nDensity is also a product choice, not only a user preference. Use compact for dense product screens, where rows of data are scanned and acted on: tables, inboxes, issue trackers, admin dashboards and file lists.\n\n```tsx\nimport { UIProvider } from '@atom63/ui-react'\n\n<UIProvider density=\"compact\">\n {/* the table, inbox or list */}\n</UIProvider>\n```\n\nFor a whole app, set `data-a63-density=\"compact\"` on `<html>`. `atom63 build` suggests it for these screens.\n\n## One semantic layer\n\nThe rule is deliberately small:\n\n> Axes set attributes. The cascade resolves `--a63-*`. Components read `--a63-*`.\n\nThat means no component writes `--primary`, `--background`, or raw `--surface-*` values inline to express personalization. Those names are either compatibility aliases or palette primitives; writing them directly freezes a value at the wrong layer.\n\n## Why surface tint is continuous\n\nBrand and surface are separate axes because color personality has two jobs: accent and neutrality. `data-a63-brand` chooses the accent ramp. `data-a63-surface` chooses the neutral family. `--a63-surface-tint` bends the semantic surfaces toward the brand hue without generating a bespoke palette for every tint value.\n\nThe implementation mixes a small set of semantic surface and border roles rather than every raw ramp stop. That is the practical tradeoff: fewer computed colors, more predictable UI, and enough expressiveness for product-level personalization.\n\n## Plate scopes: a palette from a picture\n\nAn art landing page or a portfolio project takes its palette from its main picture, the plate. `pnpm plate:palette <image> --id <plate-id> --out <file.css>` reads the plate in headless Chromium, picks three roles (the page tone from the calm area where the headline sits, `--safe-area top` by default; the deep ink on the far side of it; the most chromatic cluster as the accent), checks WCAG AA, and writes one stylesheet for `[data-a63-plate='<plate-id>']`. It moves the ink and the secondary text along lightness until they pass, and refuses, writing nothing, when the primary action on the page tone or the text on that action fails.\n\n```html\n<link rel=\"stylesheet\" href=\"/plates/plate-01.css\" />\n<main data-a63-plate=\"plate-01\" data-a63-brand=\"auto\">\n …\n <section data-a63-mode=\"dark\">the dark band: page tone and ink swap</section>\n</main>\n```\n\nThe stylesheet stays inside the semantic layer. It writes the accent's ramp to `--color-auto-50…950`, which `data-a63-brand=\"auto\"` maps onto the brand ramp, so the primary action and every role derived from the ramp recompute on the scope like any nested `[data-a63-brand]`. It overrides only `--a63-surface-page`, `--a63-text-primary` and `--a63-text-secondary`, keyed to the `--a63-if-light` / `--a63-if-dark` switch of the nearest mode scope, so a nested `[data-a63-mode=\"dark\"]` section takes the ink as its surface and the page tone as its text. Everything else (panels, borders, status colours) stays on the theme's neutrals. Set the mode the script suggests on the scope or an ancestor. A plate with no chromatic cluster keeps the theme brand; drop `data-a63-brand=\"auto\"` then.\n\n## OS is not a theme\n\nTheme is material character. OS is platform structure. I split them because \"Windows\" should not imply one permanent visual skin, and \"Terminal\" should not dictate where caption controls live.\n\nThis lets OS63 compose coordinates such as `theme=terminal` with `os=macos`, or `theme=aqua` with `os=windows`, without inventing new theme names.\n\nRadius, type scale, and font are also **not** theme — they are independent appearance axes so you can keep Aqua material while sharpening corners or enlarging type.\n\n## What this enables\n\n- A subtree can override one axis without resetting the others.\n- Theme work can happen in CSS without React conditionals.\n- Agents can reason from the axis table instead of guessing local conventions.\n- Public docs can explain the architecture at the same level the code enforces it.",
|
|
14094
14418
|
"route": "/foundations/foundation-personalization",
|
|
14095
14419
|
"slug": "foundation-personalization"
|
|
14096
14420
|
},
|
|
@@ -14111,7 +14435,7 @@
|
|
|
14111
14435
|
{
|
|
14112
14436
|
"area": "foundations",
|
|
14113
14437
|
"label": "Typography",
|
|
14114
|
-
"markdown": "# Typography\n\nThe type system targets dense information interfaces rather than marketing pages. Body text starts at 15px—between compact 14px UI conventions and the browser's 16px default—to balance information density with sustained reading.\n\n## Design intent\n\nI wanted a scale that serves three very different surfaces from the same tokens: portfolio pages with expressive display type, documentation with dense readable prose, and app panels with compact controls. The solution is one responsive scale plus an independent `--typography-scale` multiplier that any subtree can adjust.\n\nThe shipped scale is deliberately not fluid. It uses viewport breakpoints for pages and `data-window-size` overrides for OS windows, so a constrained window can use its own size band even on a wide viewport. The separate `data-a63-type-scale` axis adjusts the whole ramp for user preference.\n\n## Font families\n\n| CSS variable | Tailwind | Stack |\n|--------------|----------|-------|\n| `--font-family-sans` | `font-sans` | Geist, system UI |\n| `--font-family-serif` | `font-serif` | Brawler, Georgia |\n| `--font-family-mono` | `font-mono` | Geist Mono, monospace |\n\nI chose Geist because it's optimized for interfaces — generous x-height, clear at small sizes, and a mono companion that shares the same metrics. Brawler is reserved for rare editorial moments in the portfolio; the system defaults to sans everywhere.\n\n## How the scale works\n\nSixteen steps from `2xs` (11px) to `11xl` (56px). Up to `9xl` (39px at mobile, 49px at `768px+`) the scale grows at `640px` and `768px`, and `[data-window-size='xs'|'sm'|'md'|'lg'|'xl']` applies the same bands inside OS windows; the two display steps, `10xl` (40px) and `11xl` (56px), stay the same at every width.\n\n## Mental model\n\nTypography has three separate jobs:\n\n| Job | What it controls | Examples |\n|-----|------------------|----------|\n| Reading | Long-form comfort | Prose, docs, descriptions |\n| Hierarchy | Relative importance | Page titles, section headers, labels |\n| Density | How much interface fits | Sidebars, tables, controls, OS windows |\n\nDo not solve all three with one heading scale. A docs page, a compact sidebar, and a portfolio hero need different hierarchy even when they share the same tokens.\n\n### Line-height strategy\n\nBody text (`xs` through `lg`) uses a ~1.5× ratio for comfortable reading. Display sizes (`xl` and above) compress to ~1.25× — tighter line-height at large sizes prevents headings from floating away from their content.\n\n### The scale multiplier\n\n`--typography-scale` defaults to `1`. The shipped `data-a63-type-scale` values map to `0.9` (`compact`), `1` (`normal`), `1.1` (`comfortable`), and `1.2` (`large`). OS window width is handled separately by `data-window-size`; the multiplier is a personalization control, not the window breakpoint mechanism.\n\n## Decisions worth knowing\n\n### 15px base, not 16px\n\nMost systems use 16px because browsers default to it. I chose 15px after testing information-dense layouts — docs tables, prop references, sidebar navigation. At 16px, content felt loose and wasted space. At 14px, extended reading got fatiguing. 15px is the sweet spot for my use cases: dense enough for tool interfaces, comfortable enough for documentation prose.\n\nText without a size class takes the body role too, not the browser's 16px. `@atom63/styles` sets `--a63-type-body-font-size` and `--a63-type-body-line-height` (15/23) on `body` and on a phone scope (17/22 there), and the `@atom63/ui-react` reset sets them on `Atom63Theme` and `UIProvider`. `html` keeps the browser size, so `1rem` stays 16px and every rem-based token is unchanged. Set a size class or a text role where text should be smaller, such as `text-sm` in a dense table.\n\n### Breakpoints over fluid\n\nFluid typography (`clamp()`) assumes the viewport is the right proxy for text size. In the OS metaphor, multiple windows have arbitrary widths on one screen. Breakpoint jumps plus `data-window-size` attributes let window content follow its container band instead of the outer viewport.\n\n### No heading-element-to-scale mapping in CSS\n\nI don't automatically map `h1` to `9xl` or `h2` to `8xl` in the base tokens. Different surfaces need different heading scales — a docs `h2` should be smaller than a portfolio `h2`. The MDX variants handle heading sizing per context, and the raw scale stays available for explicit use via `text-*` utilities.\n\n### Visual hierarchy and semantics are separate\n\nA semantic `h2` does not always need to look like the second-largest text on the page. The `SectionHeader` pattern follows this rule: `variant` controls visual scale, while `level` can control document outline. That keeps accessibility and visual rhythm from fighting each other.\n\n## Text roles\n\nText roles name what text is for, after the Apple HIG text styles, so one intent works on every platform. Each role picks a step of the scale on the web and a `Font.TextStyle` (with Dynamic Type) on iOS. The source is `packages/styles/src/tokens/type-roles.resolver.json`; each role has `--a63-type-<role>-font-size`, `-line-height`, `-font-weight` and `-font-weight-strong`, and the Tailwind utilities `text-<role>` and `text-<role>-strong` set all three at once.\n\n| Role | Web step | iOS text style |\n|------|----------|----------------|\n| `display-large` | `11xl`, weight 600 | 56pt, scaled like `largeTitle` |\n| `display` | `10xl`, weight 600 | 40pt, scaled like `largeTitle` |\n| `large-title` | `6xl` | `largeTitle` |\n| `title-1` | `5xl` | `title` |\n| `title-2` | `3xl` | `title2` |\n| `title-3` | `2xl` | `title3` |\n| `headline` | `base`, weight 600 | `headline` |\n| `body` | `base` | `body` |\n| `callout` | `base` | `callout` |\n| `subhead` | `sm` | `subheadline` |\n| `footnote` | `xs` | `footnote` |\n| `caption-1` | `xs` | `caption` |\n| `caption-2` | `2xs` | `caption2` |\n\n`-strong` is the emphasized weight: bold for the display roles, `large-title`, `title-1` and `title-2`, semibold for the rest. The display roles are for balances, prices and hero headlines; iOS has no larger text style, so `AtomDisplayRole` draws them at the web size and scales it with Dynamic Type like `largeTitle`. For an amount such as `$13.25`, use `Amount` from `@atom63/ui-react` (`<Amount value={13.25} currency=\"USD\" />`, `size=\"lg\"` for `display-large`): it formats the value for the locale with `Intl.NumberFormat`, draws the fraction at half size and raised with tabular figures, and reads as one label. `fraction=\"baseline\"` keeps the half-size fraction on the baseline of the integer digits instead, as some banking apps draw a balance; `raised` is the default. Without the component, put the whole number in one `text-display tabular-nums` span and wrap the fraction in `amount-fraction`, which sets it at half size and raises it, or in `amount-fraction-baseline`, which sets it at half size on the baseline. On iOS, `AtomAmountText(13.25, currencyCode: \"USD\", role: .display)` formats the amount for the locale, draws the fraction the same way with monospaced digits and reads as one VoiceOver label, and `fraction: .baseline` keeps it on the baseline; `.atomDisplayFont()` sets a display role on any other text. Web sizes follow web conventions (body is 15px; iOS body is 17pt); the role is what stays the same. Size steps are fine while exploring; settled UI should use roles.\n\n## Phone screens\n\nThe web scale is set for pages and desktop apps: body is 15px and compact control labels are 12–13px. A phone app screen reads at the iOS sizes instead, so `[data-a63-form-factor=\"phone\"]` gives a subtree the type steps and control sizing of a phone. `AppView layout=\"phone\"` (from `@atom63/ui-react/layout`) stamps it on the screen; stamp it yourself on the root of a phone-only web app. Viewport width does not apply it, so a docs page or a marketing page on a phone keeps the web sizes.\n\n| Role | Web, under 640px | Phone (`data-a63-form-factor=\"phone\"`) | iOS text style |\n|------|------------------|-----------------------------------------|----------------|\n| `body`, `headline`, `callout` | 15px | 17px | `body` 17pt |\n| `subhead` | 13px | 15px | `subheadline` 15pt |\n| `footnote`, `caption-1` | 12px | 13px | `footnote` 13pt |\n| `caption-2` | 11px | 11px | `caption2` 11pt |\n| `title-3` | 19px | 20px | `title3` 20pt |\n| `title-2` | 21px | 22px | `title2` 22pt |\n| `title-1` | 26px | 28px | `title` 28pt |\n| `large-title` | 28px | 34px | `largeTitle` 34pt |\n| `display`, `display-large` | 40px, 56px | 40px, 56px | `AtomDisplayRole` |\n\nThe scope sets the steps themselves (`text-sm` is 15px and `text-base` 17px inside it), redeclares the text roles, and sizes controls the iOS way: heights of 36, 40, 44, 48 and 52px, and every standard control label (buttons, rows, fields, menus) at body size, with `xs` at footnote size for badges, shortcuts and initials. A Switch takes the iOS 26 shape: a pill knob 1.6 times as wide as it is tall (`--a63-switch-thumb-aspect`) on a track of about 63 by 28px. A grouped list (`ItemGroup variant=\"inset\"`) takes the iOS 26 Settings rows: its default and `sm` rows, static or interactive, are at least 52px tall (`--a63-inset-row-min-size`), so a 17px label sits in about 15px of space above and below, and the card has the `2xl` corner, 18px at defaults (`--a63-inset-group-radius`). Outside the phone scope neither variable is declared, and the group keeps its control-height rows and `--radius-lg` corner. The secondary line under a title or label (an Item, Field or Form description, a Frame or ConnectedPanel description) reads `--a63-control-font-size-secondary`, which the phone scope sets to subhead size (15px) so it stays below its 17px title; elsewhere it falls back to the control `sm` size. The type scale preference still multiplies the phone steps. Inside a phone screen, keep rows and labels on the component defaults or the text roles; shrinking them with `text-sm` or `text-xs` brings back the desktop sizes.\n\n## Usage guidance\n\n| Surface | Typical range | Scale multiplier |\n|---------|---------------|------------------|\n| Portfolio hero | `4xl`–`9xl` | Usually `normal`; user preference still applies |\n| Documentation prose | `sm`–`xl` | `1` |\n| App panels / OS windows | `xs`–`lg` | Window-size band + active type-scale axis |\n| Code blocks | `sm` mono | `1` |\n\n## Anti-patterns\n\n```tsx\n// Avoid: viewport-sized type inside a constrained panel.\n<aside className=\"w-80\">\n <h2 className=\"text-5xl\">Settings</h2>\n</aside>\n```\n\nThe panel is narrow even if the viewport is wide. The text should respond to the container's role, not the browser width.\n\n```tsx\n// Prefer: choose a scale for the surface.\n<aside className=\"w-80\">\n <h2 className=\"text-lg font-semibold\">Settings</h2>\n</aside>\n```\n\n## Review checklist\n\nWhen reviewing typography, ask:\n\n1. Is this text sized for its container, not only the viewport?\n2. Does the hierarchy still work if the content wraps?\n3. Is the line-height comfortable for the amount of reading?\n4. Are semantic heading levels valid independent of visual size?\n5. Is display type reserved for display moments?",
|
|
14438
|
+
"markdown": "# Typography\n\nThe type system targets dense information interfaces rather than marketing pages. Body text starts at 15px—between compact 14px UI conventions and the browser's 16px default—to balance information density with sustained reading.\n\n## Design intent\n\nI wanted a scale that serves three very different surfaces from the same tokens: portfolio pages with expressive display type, documentation with dense readable prose, and app panels with compact controls. The solution is one responsive scale plus an independent `--typography-scale` multiplier that any subtree can adjust.\n\nThe shipped scale is deliberately not fluid. It uses viewport breakpoints for pages and `data-window-size` overrides for OS windows, so a constrained window can use its own size band even on a wide viewport. The separate `data-a63-type-scale` axis adjusts the whole ramp for user preference.\n\n## Font families\n\n| CSS variable | Tailwind | Stack |\n|--------------|----------|-------|\n| `--font-family-sans` | `font-sans` | Geist, system UI |\n| `--font-family-serif` | `font-serif` | Brawler, Georgia |\n| `--font-family-mono` | `font-mono` | Geist Mono, monospace |\n\nI chose Geist because it's optimized for interfaces — generous x-height, clear at small sizes, and a mono companion that shares the same metrics. Brawler is reserved for rare editorial moments in the portfolio; the system defaults to sans everywhere.\n\n## How the scale works\n\nSixteen steps from `2xs` (11px) to `11xl` (56px). Up to `9xl` (39px at mobile, 49px at `768px+`) the scale grows at `640px` and `768px`, and `[data-window-size='xs'|'sm'|'md'|'lg'|'xl']` applies the same bands inside OS windows; the two display steps, `10xl` (40px) and `11xl` (56px), stay the same at every width.\n\n## Mental model\n\nTypography has three separate jobs:\n\n| Job | What it controls | Examples |\n|-----|------------------|----------|\n| Reading | Long-form comfort | Prose, docs, descriptions |\n| Hierarchy | Relative importance | Page titles, section headers, labels |\n| Density | How much interface fits | Sidebars, tables, controls, OS windows |\n\nDo not solve all three with one heading scale. A docs page, a compact sidebar, and a portfolio hero need different hierarchy even when they share the same tokens.\n\n### Line-height strategy\n\nBody text (`xs` through `lg`) uses a ~1.5× ratio for comfortable reading. Display sizes (`xl` and above) compress to ~1.25× — tighter line-height at large sizes prevents headings from floating away from their content.\n\n### The scale multiplier\n\n`--typography-scale` defaults to `1`. The shipped `data-a63-type-scale` values map to `0.9` (`compact`), `1` (`normal`), `1.1` (`comfortable`), and `1.2` (`large`). OS window width is handled separately by `data-window-size`; the multiplier is a personalization control, not the window breakpoint mechanism.\n\n## Decisions worth knowing\n\n### 15px base, not 16px\n\nMost systems use 16px because browsers default to it. I chose 15px after testing information-dense layouts — docs tables, prop references, sidebar navigation. At 16px, content felt loose and wasted space. At 14px, extended reading got fatiguing. 15px is the sweet spot for my use cases: dense enough for tool interfaces, comfortable enough for documentation prose.\n\nText without a size class takes the body role too, not the browser's 16px. `@atom63/styles` sets `--a63-type-body-font-size` and `--a63-type-body-line-height` (15/23) on `body` and on a phone scope (17/22 there), and the `@atom63/ui-react` reset sets them on `Atom63Theme` and `UIProvider`. `html` keeps the browser size, so `1rem` stays 16px and every rem-based token is unchanged. Set a size class or a text role where text should be smaller, such as `text-sm` in a dense table.\n\n### Breakpoints over fluid\n\nFluid typography (`clamp()`) assumes the viewport is the right proxy for text size. In the OS metaphor, multiple windows have arbitrary widths on one screen. Breakpoint jumps plus `data-window-size` attributes let window content follow its container band instead of the outer viewport.\n\n### No heading-element-to-scale mapping in CSS\n\nI don't automatically map `h1` to `9xl` or `h2` to `8xl` in the base tokens. Different surfaces need different heading scales — a docs `h2` should be smaller than a portfolio `h2`. The MDX variants handle heading sizing per context, and the raw scale stays available for explicit use via `text-*` utilities.\n\n### Visual hierarchy and semantics are separate\n\nA semantic `h2` does not always need to look like the second-largest text on the page. The `SectionHeader` pattern follows this rule: `variant` controls visual scale, while `level` can control document outline. That keeps accessibility and visual rhythm from fighting each other.\n\n## Text roles\n\nText roles name what text is for, after the Apple HIG text styles, so one intent works on every platform. Each role picks a step of the scale on the web and a `Font.TextStyle` (with Dynamic Type) on iOS. The source is `packages/styles/src/tokens/type-roles.resolver.json`; each role has `--a63-type-<role>-font-size`, `-line-height`, `-font-weight` and `-font-weight-strong`, and the Tailwind utilities `text-<role>` and `text-<role>-strong` set all three at once.\n\n| Role | Web step | iOS text style |\n|------|----------|----------------|\n| `display-hero` | fluid, `10xl` (40px) to 72px, weight 600 | none (web only; iOS uses `display-large`) |\n| `display-large` | `11xl`, weight 600 | 56pt, scaled like `largeTitle` |\n| `display` | `10xl`, weight 600 | 40pt, scaled like `largeTitle` |\n| `large-title` | `6xl` | `largeTitle` |\n| `title-1` | `5xl` | `title` |\n| `title-2` | `3xl` | `title2` |\n| `title-3` | `2xl` | `title3` |\n| `headline` | `base`, weight 600 | `headline` |\n| `body` | `base` | `body` |\n| `callout` | `base` | `callout` |\n| `subhead` | `sm` | `subheadline` |\n| `footnote` | `xs` | `footnote` |\n| `caption-1` | `xs` | `caption` |\n| `caption-2` | `2xs` | `caption2` |\n\n`-strong` is the emphasized weight: bold for the display roles, `large-title`, `title-1` and `title-2`, semibold for the rest. The display roles are for balances, prices and hero headlines; iOS has no larger text style, so `AtomDisplayRole` draws them at the web size and scales it with Dynamic Type like `largeTitle`. For an amount such as `$13.25`, use `Amount` from `@atom63/ui-react` (`<Amount value={13.25} currency=\"USD\" />`, `size=\"lg\"` for `display-large`): it formats the value for the locale with `Intl.NumberFormat`, draws the fraction at half size and raised with tabular figures, and reads as one label. `fraction=\"baseline\"` keeps the half-size fraction on the baseline of the integer digits instead, as some banking apps draw a balance; `raised` is the default. Without the component, put the whole number in one `text-display tabular-nums` span and wrap the fraction in `amount-fraction`, which sets it at half size and raises it, or in `amount-fraction-baseline`, which sets it at half size on the baseline. On iOS, `AtomAmountText(13.25, currencyCode: \"USD\", role: .display)` formats the amount for the locale, draws the fraction the same way with monospaced digits and reads as one VoiceOver label, and `fraction: .baseline` keeps it on the baseline; `.atomDisplayFont()` sets a display role on any other text. Web sizes follow web conventions (body is 15px; iOS body is 17pt); the role is what stays the same. Size steps are fine while exploring; settled UI should use roles.\n\n`display-hero` is for one marketing headline per page, such as a landing hero over an `ArtPlate`. It grows with the viewport from the `10xl` step on phones to 72px on wide screens (`clamp()`), with a line height of 1.05 times its size. The three display roles also carry `--a63-type-<role>-letter-spacing` (−0.03em for `display`, −0.04em for `display-large`, −0.045em for `display-hero`); set it with `letter-spacing` where the role is used, since the `text-<role>` utilities do not include it. Headlines take their face from `--a63-font-display`, which defaults to `--a63-font-app`; set it to `var(--font-family-serif)` on a page or a section for serif headlines over sans UI, and loosen the tracking towards −0.025em for the serif.\n\n## Phone screens\n\nThe web scale is set for pages and desktop apps: body is 15px and compact control labels are 12–13px. A phone app screen reads at the iOS sizes instead, so `[data-a63-form-factor=\"phone\"]` gives a subtree the type steps and control sizing of a phone. `AppView layout=\"phone\"` (from `@atom63/ui-react/layout`) stamps it on the screen; stamp it yourself on the root of a phone-only web app. Viewport width does not apply it, so a docs page or a marketing page on a phone keeps the web sizes.\n\n| Role | Web, under 640px | Phone (`data-a63-form-factor=\"phone\"`) | iOS text style |\n|------|------------------|-----------------------------------------|----------------|\n| `body`, `headline`, `callout` | 15px | 17px | `body` 17pt |\n| `subhead` | 13px | 15px | `subheadline` 15pt |\n| `footnote`, `caption-1` | 12px | 13px | `footnote` 13pt |\n| `caption-2` | 11px | 11px | `caption2` 11pt |\n| `title-3` | 19px | 20px | `title3` 20pt |\n| `title-2` | 21px | 22px | `title2` 22pt |\n| `title-1` | 26px | 28px | `title` 28pt |\n| `large-title` | 28px | 34px | `largeTitle` 34pt |\n| `display`, `display-large` | 40px, 56px | 40px, 56px | `AtomDisplayRole` |\n\nThe scope sets the steps themselves (`text-sm` is 15px and `text-base` 17px inside it), redeclares the text roles, and sizes controls the iOS way: heights of 36, 40, 44, 48 and 52px, and every standard control label (buttons, rows, fields, menus) at body size, with `xs` at footnote size for badges, shortcuts and initials. A Switch takes the iOS 26 shape: a pill knob 1.6 times as wide as it is tall (`--a63-switch-thumb-aspect`) on a track of about 63 by 28px. A grouped list (`ItemGroup variant=\"inset\"`) takes the iOS 26 Settings rows: its default and `sm` rows, static or interactive, are at least 52px tall (`--a63-inset-row-min-size`), so a 17px label sits in about 15px of space above and below, and the card has the `2xl` corner, 18px at defaults (`--a63-inset-group-radius`). Outside the phone scope neither variable is declared, and the group keeps its control-height rows and `--radius-lg` corner. The secondary line under a title or label (an Item, Field or Form description, a Frame or ConnectedPanel description) reads `--a63-control-font-size-secondary`, which the phone scope sets to subhead size (15px) so it stays below its 17px title; elsewhere it falls back to the control `sm` size. The type scale preference still multiplies the phone steps. Inside a phone screen, keep rows and labels on the component defaults or the text roles; shrinking them with `text-sm` or `text-xs` brings back the desktop sizes.\n\n## Usage guidance\n\n| Surface | Typical range | Scale multiplier |\n|---------|---------------|------------------|\n| Portfolio hero | `4xl`–`9xl` | Usually `normal`; user preference still applies |\n| Documentation prose | `sm`–`xl` | `1` |\n| App panels / OS windows | `xs`–`lg` | Window-size band + active type-scale axis |\n| Code blocks | `sm` mono | `1` |\n\n## Anti-patterns\n\n```tsx\n// Avoid: viewport-sized type inside a constrained panel.\n<aside className=\"w-80\">\n <h2 className=\"text-5xl\">Settings</h2>\n</aside>\n```\n\nThe panel is narrow even if the viewport is wide. The text should respond to the container's role, not the browser width.\n\n```tsx\n// Prefer: choose a scale for the surface.\n<aside className=\"w-80\">\n <h2 className=\"text-lg font-semibold\">Settings</h2>\n</aside>\n```\n\n## Review checklist\n\nWhen reviewing typography, ask:\n\n1. Is this text sized for its container, not only the viewport?\n2. Does the hierarchy still work if the content wraps?\n3. Is the line-height comfortable for the amount of reading?\n4. Are semantic heading levels valid independent of visual size?\n5. Is display type reserved for display moments?",
|
|
14115
14439
|
"route": "/foundations/foundation-typography",
|
|
14116
14440
|
"slug": "foundation-typography"
|
|
14117
14441
|
},
|
|
@@ -14174,7 +14498,7 @@
|
|
|
14174
14498
|
{
|
|
14175
14499
|
"area": "patterns",
|
|
14176
14500
|
"label": "MDX blocks",
|
|
14177
|
-
"markdown": "# MDX blocks\n\nEvery block `@atom63/mdx/blocks` exports, with what it is for, a working example and its props. The props tables are read from each block's TypeScript types. For setup and the providers, see [MDX content](/patterns/pattern-mdx).\n\nInside a provider (`MDXContentProvider`, `DocsMDXContentProvider` or `ArticleMDXContentProvider`), most blocks need no import: the provider's component map registers them. `KeyIdea`, `Compare`, `ImageCompare`, `LayerStack`, `DocExample`, `DocExampleCode` and `DemoConfigPanel` are not in the map; import them from `@atom63/mdx/blocks`. In React, import any block from there.\n\nLook a block up from the terminal with `atom63 api <Block>`, for example `atom63 api KeyIdea`.\n\n## Notices\n\n### Callout\n\nA notice beside the text: a tip, a caveat, an error to avoid or a success state. Pick `type` by what the reader should feel; one callout per point.\n\n```tsx\n<Callout type=\"warning\">Releases need approval before they publish.</Callout>\n```\n\nProps of `Callout`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `type`: `'info' | 'warning' | 'error' | 'success'` (default `'info'`)\n\nSlots, each taking `children`: `Callout.Actions`, `Callout.Body`, `Callout.Icon`, `Callout.Title`.\n\n### KeyIdea\n\nThe one takeaway of a section, set apart with a label and an optional title. Use it once or twice per page; a page of key ideas has none.\n\n```tsx\n<KeyIdea title=\"One token architecture\">\n Every renderer reads the same tokens, so a theme change reaches web, iOS and Figma at once.\n</KeyIdea>\n```\n\nProps of `KeyIdea`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `label`: `ReactNode` (default `'Key idea'`)\n- `title`: `ReactNode`\n\n## Comparison\n\n### Compare\n\nTwo or more options side by side, each with an eyebrow, a title and a tone. Use it to explain a difference in words or code; for pictures use `ImageCompare`.\n\n```tsx\n<Compare title=\"Patch CSS vs system CSS\">\n <Compare.Item eyebrow=\"Before\" title=\"Local patch\" tone=\"negative\">\n Values are invented for the screen at hand.\n </Compare.Item>\n <Compare.Item eyebrow=\"After\" title=\"System contract\" tone=\"positive\">\n Values come from tokens that change together.\n </Compare.Item>\n</Compare>\n```\n\nProps of `Compare`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `description`: `ReactNode`\n- `title`: `ReactNode`\n\nProps of `Compare.Item`:\n\n- `children`: `ReactNode` (required)\n- `title`: `ReactNode` (required)\n- `className`: `string`\n- `eyebrow`: `ReactNode`\n- `tone`: `'warning' | 'neutral' | 'negative' | 'positive'` (default `'neutral'`)\n\nSlots, each taking `children`: `Compare.Description`, `Compare.Title`.\n\n### ComparisonPair\n\nTwo live panels, before and after, that the reader toggles between. Use it for interaction or motion differences; `speedControl` adds a slow-motion switch.\n\n```tsx\n<ComparisonPair label=\"Spacing\">\n <ComparisonPair.Before label=\"Before\">Cramped 4px gaps</ComparisonPair.Before>\n <ComparisonPair.After label=\"After\">Comfortable 16px gaps</ComparisonPair.After>\n</ComparisonPair>\n```\n\nProps of `ComparisonPair`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `label`: `string`\n- `slowMotionLabel`: `string` (default `'Slow motion'`)\n- `speedControl`: `boolean` (default `false`)\n\nProps of `ComparisonPair.After`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `label`: `string`\n\nProps of `ComparisonPair.Before`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `label`: `string`\n\n### ImageCompare\n\nTwo images in one frame with a draggable divider. Use it when the visual difference is the point; give both images real `alt` text. The slider loads on demand.\n\n```mdx\n<ImageCompare\n title=\"Ad hoc layout vs system layout\"\n before={{ src: '/images/before.webp', alt: 'Form with uneven spacing', label: 'Before' }}\n after={{ src: '/images/after.webp', alt: 'Form on the spacing scale', label: 'After' }}\n caption=\"Drag the divider to compare.\"\n/>\n```\n\nProps of `ImageCompare`:\n\n- `after`: `ImageCompareImage` (required)\n- `before`: `ImageCompareImage` (required)\n- `aspectRatio`: `string` (default `'16/9'`)\n- `bordered`: `boolean` (default `true`)\n- `caption`: `string`\n- `changePositionOnHover`: `boolean` (default `false`)\n- `description`: `string`\n- `handle`: `ReactNode`\n- `idleResetMs`: `number` (default `2500`). Idle ms before restoring to center when `resetAfterIdle` is on.\n- `objectFit`: `'none' | 'contain' | 'cover' | 'fill' | 'scale-down'` (default `'cover'`)\n- `onPositionChange`: `(position: number) => void`\n- `position`: `number` (default `50`). Initial slider position (0-100).\n- `resetAfterIdle`: `boolean` (default `false`). Restore to center after the user stops interacting.\n- `resetDelay`: `number` (default `500`)\n- `resetOnLeave`: `boolean` (default `false`)\n- `title`: `ReactNode`\n- `transition`: `string` (default `'0.25s cubic-bezier(.17,.67,.83,.67)'`)\n- `vertical`: `boolean` (default `false`)\n\n## Media\n\n### FigureBlock\n\nAn image with a caption. Clicking it opens the page's `MediaLightbox` gallery, which the provider hosts; set `enableLightbox={false}` to turn that off. Put rich captions in `FigureBlock.Caption` and a source line in `FigureBlock.Aside`.\n\n```tsx\n<FigureBlock\n alt=\"The Atom63 design system social card\"\n aspectRatio=\"16/9\"\n caption=\"Figure 1. The social card for this site.\"\n src=\"/og.png\"\n/>\n```\n\nProps of `FigureBlock`:\n\n- `alt`: `string` (required)\n- `src`: `string` (required)\n- `aspectRatio`: `'1/1' | '4/3' | '3/4' | '16/9' | '9/16'`\n- `bordered`: `boolean` (default `true`)\n- `caption`: `string`\n- `children`: `ReactNode`\n- `className`: `string`\n- `enableLightbox`: `boolean` (default `true`). Click-to-zoom; multiple figures on a page share one connected gallery.\n- `lightboxGalleryId`: `string` (default `MDX_FIGURE_LIGHTBOX_GALLERY_ID`). Gallery id for connected lightbox (default: all FigureBlocks on the page).\n- `loading`: `'eager' | 'lazy'` (default `'lazy'`)\n- `spacing`: `'none' | 'sm' | 'default' | 'lg'` (default `'default'`)\n\nSlots, each taking `children`: `FigureBlock.Aside`, `FigureBlock.Caption`.\n\n### VideoBlock\n\nA video figure with native controls and an optional caption. A video with speech needs a caption track (`trackSrc`); mark a purely visual loop `captionPolicy=\"decorative\"` instead. With `autoPlay` and no `controls`, it draws its own pause button and stays still under reduced motion.\n\n```mdx\n<VideoBlock src=\"/media/talk.mp4\" title=\"Design tokens talk\" trackSrc=\"/media/talk.en.vtt\" />\n\n<VideoBlock\n autoPlay\n captionPolicy=\"decorative\"\n controls={false}\n loop\n muted\n src=\"/media/loop.mp4\"\n title=\"Theme switching loop\"\n/>\n```\n\nProps of `VideoBlock`:\n\n- `src`: `string` (required)\n- `title`: `string` (required)\n- `autoPlay`: `boolean` (default `false`). Start playing, muted, on load. Ignored when the reader prefers reduced motion. Without `controls`, a pause and play toggle sits over the video.\n- `caption`: `string`\n- `captionPolicy`: `'required' | 'decorative'`. Video has spoken or meaningful audio and must provide captions. Video is decorative or purely visual; no caption track is required.\n- `className`: `string`\n- `controls`: `boolean` (default `true`)\n- `fit`: `'contain' | 'cover'` (default `'contain'`)\n- `loop`: `boolean` (default `false`)\n- `muted`: `boolean` (default `false`)\n- `pauseLabel`: `string` (default `'Pause video'`). Name of the toggle while the video plays. Defaults to \"Pause video\".\n- `playLabel`: `string` (default `'Play video'`). Name of the toggle while the video is paused. Defaults to \"Play video\".\n- `showCaption`: `boolean` (default `false`)\n- `spacing`: `'none' | 'sm' | 'default' | 'lg'` (default `'default'`)\n- `trackLabel`: `string`. Name of the caption track in the player's caption menu. Defaults to the track language's own name, such as \"English\" or \"Deutsch\".\n- `trackLang`: `string` (default `'en'`). BCP 47 language of the caption track (`srclang`). Defaults to `en`.\n- `trackSrc`: `string`\n\n### MediaCaption\n\nThe caption line the media blocks use, on its own: for a custom figure, an embed or a chart.\n\n```tsx\n<MediaCaption>Figure 2. Token layers, from primitive to product.</MediaCaption>\n```\n\nProps of `MediaCaption`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n\n### MediaPlaceholder\n\nA labelled frame that stands in for an image, video or diagram that is not made yet. The label says what the real asset should show.\n\n```tsx\n<MediaPlaceholder kind=\"diagram\" label=\"Token flow from DTCG source to each renderer\" />\n```\n\nProps of `MediaPlaceholder`:\n\n- `aspectRatio`: `string` (default `'16 / 9'`). CSS aspect-ratio for the frame (e.g. `16 / 9`, `4 / 3`, `1 / 1`).\n- `className`: `string`\n- `kind`: `'video' | 'image' | 'diagram'` (default `'image'`). Picks the icon + kind tag. Defaults to `image`.\n- `label`: `string`. What the real asset should show — surfaced as the frame's caption.\n\n## Demos\n\n### DocExample\n\nA live example with Preview and Code tabs and a copy button. Every example on this page is one. Pass the source as `code` and render the same thing as children.\n\n```mdx\n<DocExample title=\"Primary button\" code={`<Button variant=\"primary\">Save</Button>`}>\n <Button variant=\"primary\">Save</Button>\n</DocExample>\n```\n\nProps of `DocExample`:\n\n- `children`: `ReactNode` (required)\n- `code`: `string` (required)\n- `align`: `'center' | 'left'` (default `'center'`)\n- `className`: `string`\n- `codeLabel`: `string` (default `'Code'`). Label for the code tab (default: \"Code\").\n- `copiedAnnouncement`: `string` (default `'Example code copied'`). Visually-hidden live-region text announced after copying (default: \"Example code copied\").\n- `copiedLabel`: `string` (default `'Copied to clipboard'`). aria-label for the copy control right after copying (default: \"Copied to clipboard\").\n- `copyCodeLabel`: `string` (default `'Copy example code'`). aria-label for the copy control when idle (default: \"Copy example code\").\n- `lang`: `string`\n- `previewLabel`: `string` (default `'Preview'`). Label for the preview tab (default: \"Preview\").\n- `title`: `string`\n- `wide`: `boolean` (default `false`)\n\nSlots, each taking `children`: `DocExample.Code`, `DocExample.Preview`, `DocExample.Title`.\n\n### DocExampleCode\n\nThe highlighted code panel of `DocExample`, on its own, for showing code that has no preview.\n\n```tsx\nimport { DocExampleCode } from '@atom63/mdx/blocks'\n\n<DocExampleCode code={`pnpm add @atom63/mdx`} lang=\"bash\" />\n```\n\nProps of `DocExampleCode`:\n\n- `code`: `string` (required)\n- `lang`: `string` (default `'tsx'`)\n\n### ExampleContainer\n\nA plain demo frame on a dot grid, with an optional title, description and spec line. Use it for a preview without a code tab.\n\n```mdx\n<ExampleContainer description=\"The main action of a view.\" title=\"Primary variant\">\n <Button variant=\"primary\">Save</Button>\n</ExampleContainer>\n```\n\nProps of `ExampleContainer`:\n\n- `children`: `React.ReactNode` (required)\n- `align`: `'center' | 'left'` (default `'center'`)\n- `className`: `string`\n- `description`: `string`\n- `embedded`: `boolean` (default `false`). Nested inside DocExample — drops outer margin and border (parent supplies chrome).\n- `spec`: `React.ReactNode`\n- `title`: `string`\n- `wide`: `boolean` (default `false`). Use wide layout to break out of narrow prose constraints\n\n### DemoStage\n\nA framed stage for a centrepiece demo or visual, with header slots for a title (`headerStart`) and controls (`headerEnd`).\n\n```tsx\n<DemoStage headerStart=\"Live demo\">\n <Button>Try me</Button>\n</DemoStage>\n```\n\nProps of `DemoStage`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `headerEnd`: `ReactNode`\n- `headerStart`: `ReactNode`\n- `panelClassName`: `string`\n\n### DemoConfigPanel\n\nThe controls panel for a `DemoStage`: a popover beside the stage, a sheet on small screens. Put it in `headerEnd` and pass the stage's ref.\n\n```tsx\nimport { DemoConfigPanel, DemoStage } from '@atom63/mdx/blocks'\nimport { Switch } from '@atom63/ui-react'\nimport { useRef, useState } from 'react'\n\nfunction TunableDemo() {\n const stageRef = useRef<HTMLElement>(null)\n const [dense, setDense] = useState(false)\n\n return (\n <DemoStage\n ref={stageRef}\n headerEnd={\n <DemoConfigPanel stageRef={stageRef} title=\"Demo controls\">\n <label>\n <Switch checked={dense} onCheckedChange={setDense} /> Dense\n </label>\n </DemoConfigPanel>\n }\n >\n <p>{dense ? 'Dense' : 'Comfortable'}</p>\n </DemoStage>\n )\n}\n```\n\nProps of `DemoConfigPanel`:\n\n- `children`: `ReactNode` (required)\n- `stageRef`: `RefObject<HTMLElement | null>` (required)\n- `defaultOpen`: `boolean`\n- `label`: `ReactNode` (default `'Tune'`)\n- `mobileQuery`: `string` (default `'(max-width: 767px)'`)\n- `onOpenChange`: `(open: boolean) => void`\n- `open`: `boolean`\n- `panelClassName`: `string`\n- `panelInset`: `number` (default `16`)\n- `panelWidth`: `number` (default `320`)\n- `sheetClassName`: `string`\n- `sheetPanelClassName`: `string`\n- `title`: `string` (default `'Demo controls'`)\n\n## Sequences\n\n### Steps\n\nNumbered steps for a procedure. Numbers and the connecting line come from document order; do not number titles by hand.\n\n```tsx\n<Steps>\n <Steps.Step title=\"Install the package\">Run pnpm add @atom63/mdx.</Steps.Step>\n <Steps.Step title=\"Load the styles\">Import @atom63/mdx/styles/a63.css once.</Steps.Step>\n <Steps.Step title=\"Wrap the page\">Render it inside MDXContentProvider.</Steps.Step>\n</Steps>\n```\n\nProps of `Steps`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n\nProps of `Steps.Step`:\n\n- `children`: `ReactNode` (required)\n- `title`: `ReactNode` (required). Bold heading for the step.\n- `className`: `string`\n- `index`: `number` (default `1`). Injected by `Steps` — the 1-indexed position in document order.\n\n### Timeline\n\nDated events in order: a release history, a project log. Each item has a date, a title and a short body.\n\n```tsx\n<Timeline>\n <Timeline.Item date=\"2025\" title=\"Primitive layer\">Colour ramps, type scale, spacing.</Timeline.Item>\n <Timeline.Item date=\"2026\" title=\"Semantic layer\">Tokens map primitives to intent.</Timeline.Item>\n</Timeline>\n```\n\nProps of `Timeline`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n\nProps of `Timeline.Item`:\n\n- `children`: `ReactNode` (required)\n- `date`: `ReactNode` (required). Date or label shown in the left column (e.g. a year).\n- `title`: `ReactNode` (required). Bold heading for the event.\n- `className`: `string`\n\n### ScrollStage\n\nScroll-driven storytelling: text steps scroll past while each step's `media` stays pinned beside them, and the media changes with the step in view. On narrow screens the media sits above its text.\n\n```mdx\n<ScrollStage>\n <ScrollStage.Step media={<img alt=\"Primitive tokens\" src=\"/images/primitives.webp\" />}>\n ### Primitive layer\n\n Raw values: colour ramps, the type scale, spacing and radius.\n </ScrollStage.Step>\n <ScrollStage.Step media={<img alt=\"Semantic tokens\" src=\"/images/semantic.webp\" />}>\n ### Semantic layer\n\n Tokens that name intent, so one theme change restyles everything.\n </ScrollStage.Step>\n</ScrollStage>\n```\n\nProps of `ScrollStage`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n\nProps of `ScrollStage.Step`:\n\n- `children`: `ReactNode` (required)\n- `media`: `ReactNode` (required). The visual (image, diagram, JSX) shown for this step. Keep it cheap — in the pinned path it re-renders whenever the active step changes, so prefer static images/JSX over heavy live components. Avoid putting anchor `id`s inside `media` or the prose: both the pinned (`lg+`) and stacked (below `lg`) copies render into the DOM, so an `id` would be duplicated.\n- `className`: `string`\n\n## Figures and links\n\n### StatCard\n\nOne metric with a label and an optional change. `trend` colours the change: `up` and `down` use status colours, `neutral` stays muted.\n\n```tsx\n<StatCard change=\"+1 this quarter\" label=\"Themes\" trend=\"up\" value=\"4\" />\n```\n\nProps of `StatCard`:\n\n- `label`: `string` (required). Small muted caption above the value.\n- `value`: `ReactNode` (required). The prominent metric.\n- `change`: `ReactNode`. Optional secondary change indicator, colored by `trend`.\n- `className`: `string`\n- `trend`: `'neutral' | 'up' | 'down'` (default `'neutral'`). Semantic direction of `change`; drives the token color.\n\n### StatGrid\n\nA responsive grid of `StatCard`s.\n\n```tsx\n<StatGrid>\n <StatCard label=\"Blocks\" value=\"30\" />\n <StatCard change=\"-5\" label=\"Open issues\" trend=\"down\" value=\"3\" />\n <StatCard label=\"Themes\" value=\"4\" />\n</StatGrid>\n```\n\nProps of `StatGrid`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n\n### ResourceList\n\nA list of outside links, each with a name and an optional note. Links open in a new tab.\n\n```tsx\n<ResourceList\n items={[\n { name: 'DTCG format', url: 'https://www.designtokens.org', note: 'The token file format' },\n { name: 'WCAG 2.2', url: 'https://www.w3.org/TR/WCAG22/', note: 'Accessibility criteria' },\n ]}\n/>\n```\n\nProps of `ResourceList`:\n\n- `items`: `ResourceItem[]` (required)\n- `className`: `string`\n\n## Diagrams\n\n### MermaidDiagram\n\nA Mermaid chart drawn in the theme's colours, with zoom controls. A fenced `mermaid` code block in MDX renders as one too.\n\n```tsx\n<MermaidDiagram\n chart=\"flowchart LR\n Tokens --> Contracts --> Components\"\n title=\"Build order\"\n/>\n```\n\nProps of `MermaidDiagram`:\n\n- `chart`: `string` (required)\n- `animated`: `boolean` (default `false`). When true, animate the diagram's paths with a stroke draw-on-reveal. Off by default.\n- `labels`: `Partial<MermaidDiagramLabels>`\n- `title`: `string`\n\n### LayerStack\n\nA layered model, top to bottom, with a label, title and optional metaphor, description and constraint per layer. Use it to explain an architecture in layers.\n\n```tsx\n<LayerStack\n title=\"Primitive / Procedure / Product\"\n layers={[\n { label: 'Primitive', title: 'Stable materials', description: 'Raw tokens and scales.' },\n { label: 'Procedure', title: 'Semantic rules', description: 'Semantic tokens and states.' },\n { label: 'Product', title: 'Rendered experience', description: 'Pages and flows.' },\n ]}\n/>\n```\n\nProps of `LayerStack`:\n\n- `layers`: `LayerStackItem[]` (required)\n- `className`: `string`\n- `description`: `ReactNode`\n- `labels`: `Partial<LayerStackLabels>`\n- `title`: `ReactNode`\n\n### ColorSwatchItem\n\nA colour swatch for a CSS variable, with its name and variable. Use it on token and theme pages.\n\n```tsx\n<ColorSwatchItem name=\"Page surface\" variable=\"--a63-surface-page\" />\n<ColorSwatchItem name=\"Primary text\" variable=\"--a63-text-primary\" />\n```\n\nProps of `ColorSwatchItem`:\n\n- `name`: `string` (required)\n- `variable`: `string` (required)\n\n## Code\n\n### CodeBlock\n\nHighlighted code with a copy button and a language label. A fenced code block in MDX renders as one; use the component for code held in a variable.\n\n```tsx\n<CodeBlock code=\"pnpm add @atom63/mdx\" lang=\"bash\" />\n```\n\nProps of `CodeBlock`:\n\n- `code`: `string` (required)\n- `children`: `ReactNode`\n- `className`: `string`\n- `copyLabel`: `string`\n- `fallbackLangLabel`: `string`. Label shown in place of an unknown language in the article header.\n- `lang`: `string` (default `'tsx'`)\n- `loadingLabel`: `string` (default `'Highlighting code'`). Visually-hidden status text announced while syntax highlighting runs.\n- `maxHeight`: `string`\n- `showCopyButton`: `boolean`\n- `showLineNumbers`: `boolean`. Show a numbered gutter. Defaults to a smart heuristic: on for `article` blocks longer than 6 lines, off for short snippets and embedded blocks.\n- `spacing`: `'component' | 'none'`\n- `variant`: `'article' | 'embedded'`\n\n### Tabs\n\nTabbed panels in prose, such as the same step for npm and pnpm. It is the `Tabs` component of `@atom63/ui-react` with MDX spacing, and takes its props: `atom63 component tabs`.\n\n```tsx\n<Tabs defaultValue=\"pnpm\">\n <Tabs.List>\n <Tabs.Tab value=\"pnpm\">pnpm</Tabs.Tab>\n <Tabs.Tab value=\"npm\">npm</Tabs.Tab>\n </Tabs.List>\n <Tabs.Panel value=\"pnpm\">pnpm add @atom63/mdx</Tabs.Panel>\n <Tabs.Panel value=\"npm\">npm install @atom63/mdx</Tabs.Panel>\n</Tabs>\n```\n\n`Tabs` adds no props of its own.\n\nProps of `Tabs.List`:\n\n- `size`: `'sm' | 'default' | 'lg' | 'xs'` (default `tabsContract.defaultSize`)\n- `variant`: `'default' | 'underline' | 'attached'` (default `tabsContract.defaultVariant`)\n\nProps of `Tabs.Panel`:\n\n- `animated`: `boolean` (default `false`)\n\nProps of `Tabs.Tab`:\n\n- `size`: `'sm' | 'default' | 'lg' | 'xs'`\n\n## Page furniture\n\n### Accordion\n\nCollapsible questions and answers, such as an FAQ. It is the `Accordion` component of `@atom63/ui-react` with MDX spacing, and takes its props: `atom63 component accordion`.\n\n```tsx\n<Accordion collapsible type=\"single\">\n <Accordion.Item value=\"token\">\n <Accordion.Trigger>What is a design token?</Accordion.Trigger>\n <Accordion.Content>A named value that components read instead of a literal.</Accordion.Content>\n </Accordion.Item>\n</Accordion>\n```\n\nProps of `Accordion`:\n\n- `collapsible`: `boolean`\n- `defaultValue`: `string | string[]`\n- `onValueChange`: `(value: string | string[]) => void`\n- `type`: `'multiple' | 'single'`\n- `value`: `string | string[]`\n\nProps of `Accordion.Trigger`:\n\n- `icon`: `'chevron' | 'plus-minus'` (default `'chevron'`)\n\n### PageMeta\n\nThe header of an article or lesson: eyebrow, title, description and a meta line such as the reading time.\n\n```tsx\n<PageMeta\n description=\"How semantic tokens keep colour and spacing consistent.\"\n eyebrow=\"Guide\"\n meta=\"8 min read\"\n title=\"Designing with tokens\"\n/>\n```\n\nProps of `PageMeta`:\n\n- `title`: `ReactNode` (required)\n- `children`: `ReactNode`\n- `className`: `string`\n- `description`: `ReactNode`\n- `eyebrow`: `ReactNode`\n- `meta`: `ReactNode`\n\n### PageTableOfContents\n\nThe page's table of contents, built from its `h2` and `h3` headings, with the current section highlighted. `rail` sits beside the text; `inline`, `menu` and `embedded` fit narrow layouts.\n\n```tsx\nimport { PageTableOfContents } from '@atom63/mdx/blocks'\n\n<aside>\n <PageTableOfContents label=\"On this page\" variant=\"rail\" />\n</aside>\n```\n\nProps of `PageTableOfContents`:\n\n- `activeOffset`: `number` (default `120`)\n- `className`: `string`\n- `containerSelector`: `string` (default `'[data-mdx-scroll-root], #learn-main, main'`)\n- `headingSelector`: `string` (default `'[data-mdx-content] h2, [data-mdx-content] h3, article h2, article h3'`)\n- `inlinePositionClassName`: `string` (default `'fixed top-[calc(--spacing(14)+--spacing(3))] right-4 z-30 xl:hidden'`)\n- `label`: `string` (default `'On this page'`)\n- `onActiveLabelChange`: `(label: string) => void`\n- `onNavigate`: `() => void`\n- `scrollOffset`: `number` (default `96`)\n- `showProgress`: `boolean` (default `true`)\n- `smoothScrollDuration`: `number` (default `420`)\n- `variant`: `'menu' | 'embedded' | 'inline' | 'rail'` (default `'rail'`)\n\n### MdxPageSkeleton\n\nThe loading state of an MDX page while its content loads, in the `docs` or `lesson` layout.\n\n```tsx\n<MdxPageSkeleton showRail={false} variant=\"docs\" />\n```\n\nProps of `MdxPageSkeleton`:\n\n- `className`: `string`\n- `showInlineToc`: `boolean` (default `true`)\n- `showRail`: `boolean` (default `true`)\n- `variant`: `'docs' | 'lesson'` (default `'docs'`)\n\n### CreditsBlock\n\nA collapsible list of credits, one role per row, at the end of an article or project page.\n\n```tsx\n<CreditsBlock\n credits={[\n { role: 'Design', credits: 'ATOM63' },\n { role: 'Photography', credits: 'Unsplash contributors' },\n ]}\n/>\n```\n\nProps of `CreditsBlock`:\n\n- `credits`: `CreditEntry[]` (required)\n- `className`: `string`\n- `label`: `string` (default `'Credits'`)\n\n## Prose elements\n\nThe provider's component map also styles plain Markdown, so most of a page needs no blocks:\n\n| Markdown | Renders as |\n|----------|------------|\n| `#` to `######` | Headings on the type scale; `h2` and `h3` feed `PageTableOfContents` |\n| Paragraphs, `**strong**`, `*em*`, `<kbd>` | Body text at prose measure |\n| `[link](url)` | A link; an external one opens in a new tab |\n| `` `code` `` | Inline code |\n| Fenced code | `CodeBlock`; a `mermaid` fence renders `MermaidDiagram` |\n| Lists, `>` quotes, `---` | Lists, a quote, a rule |\n| Tables | The `Table` of `@atom63/ui-react`, scrolling when wide |",
|
|
14501
|
+
"markdown": "# MDX blocks\n\nEvery block `@atom63/mdx/blocks` exports, with what it is for, a working example and its props. The props tables are read from each block's TypeScript types. For setup and the providers, see [MDX content](/patterns/pattern-mdx).\n\nInside a provider (`MDXContentProvider`, `DocsMDXContentProvider` or `ArticleMDXContentProvider`), most blocks need no import: the provider's component map registers them. `KeyIdea`, `Compare`, `ImageCompare`, `LayerStack`, `DocExample`, `DocExampleCode` and `DemoConfigPanel` are not in the map; import them from `@atom63/mdx/blocks`. In React, import any block from there.\n\nLook a block up from the terminal with `atom63 api <Block>`, for example `atom63 api KeyIdea`.\n\n## Notices\n\n### Callout\n\nA notice beside the text: a tip, a caveat, an error to avoid or a success state. Pick `type` by what the reader should feel; one callout per point.\n\n```tsx\n<Callout type=\"warning\">Releases need approval before they publish.</Callout>\n```\n\nProps of `Callout`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `type`: `'info' | 'warning' | 'error' | 'success'` (default `'info'`)\n\nSlots, each taking `children`: `Callout.Actions`, `Callout.Body`, `Callout.Icon`, `Callout.Title`.\n\n### KeyIdea\n\nThe one takeaway of a section, set apart with a label and an optional title. Use it once or twice per page; a page of key ideas has none.\n\n```tsx\n<KeyIdea title=\"One token architecture\">\n Every renderer reads the same tokens, so a theme change reaches web, iOS and Figma at once.\n</KeyIdea>\n```\n\nProps of `KeyIdea`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `label`: `ReactNode` (default `'Key idea'`)\n- `title`: `ReactNode`\n\n## Comparison\n\n### Compare\n\nTwo or more options side by side, each with an eyebrow, a title and a tone. Use it to explain a difference in words or code; for pictures use `ImageCompare`.\n\n```tsx\n<Compare title=\"Patch CSS vs system CSS\">\n <Compare.Item eyebrow=\"Before\" title=\"Local patch\" tone=\"negative\">\n Values are invented for the screen at hand.\n </Compare.Item>\n <Compare.Item eyebrow=\"After\" title=\"System contract\" tone=\"positive\">\n Values come from tokens that change together.\n </Compare.Item>\n</Compare>\n```\n\nProps of `Compare`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `description`: `ReactNode`\n- `title`: `ReactNode`\n\nProps of `Compare.Item`:\n\n- `children`: `ReactNode` (required)\n- `title`: `ReactNode` (required)\n- `className`: `string`\n- `eyebrow`: `ReactNode`\n- `tone`: `'warning' | 'neutral' | 'negative' | 'positive'` (default `'neutral'`)\n\nSlots, each taking `children`: `Compare.Description`, `Compare.Title`.\n\n### ComparisonPair\n\nTwo live panels, before and after, that the reader toggles between. Use it for interaction or motion differences; `speedControl` adds a slow-motion switch.\n\n```tsx\n<ComparisonPair label=\"Spacing\">\n <ComparisonPair.Before label=\"Before\">Cramped 4px gaps</ComparisonPair.Before>\n <ComparisonPair.After label=\"After\">Comfortable 16px gaps</ComparisonPair.After>\n</ComparisonPair>\n```\n\nProps of `ComparisonPair`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `label`: `string`\n- `slowMotionLabel`: `string` (default `'Slow motion'`)\n- `speedControl`: `boolean` (default `false`)\n\nProps of `ComparisonPair.After`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `label`: `string`\n\nProps of `ComparisonPair.Before`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `label`: `string`\n\n### ImageCompare\n\nTwo images in one frame with a draggable divider. Use it when the visual difference is the point; give both images real `alt` text. The slider loads on demand.\n\n```mdx\n<ImageCompare\n title=\"Ad hoc layout vs system layout\"\n before={{ src: '/images/before.webp', alt: 'Form with uneven spacing', label: 'Before' }}\n after={{ src: '/images/after.webp', alt: 'Form on the spacing scale', label: 'After' }}\n caption=\"Drag the divider to compare.\"\n/>\n```\n\nProps of `ImageCompare`:\n\n- `after`: `ImageCompareImage` (required)\n- `before`: `ImageCompareImage` (required)\n- `aspectRatio`: `string` (default `'16/9'`)\n- `bordered`: `boolean` (default `true`)\n- `caption`: `string`\n- `changePositionOnHover`: `boolean` (default `false`)\n- `description`: `string`\n- `handle`: `ReactNode`\n- `idleResetMs`: `number` (default `2500`). Idle ms before restoring to center when `resetAfterIdle` is on.\n- `objectFit`: `'none' | 'contain' | 'cover' | 'fill' | 'scale-down'` (default `'cover'`)\n- `onPositionChange`: `(position: number) => void`\n- `position`: `number` (default `50`). Initial slider position (0-100).\n- `resetAfterIdle`: `boolean` (default `false`). Restore to center after the user stops interacting.\n- `resetDelay`: `number` (default `500`)\n- `resetOnLeave`: `boolean` (default `false`)\n- `title`: `ReactNode`\n- `transition`: `string` (default `'0.25s cubic-bezier(.17,.67,.83,.67)'`)\n- `vertical`: `boolean` (default `false`)\n\n## Media\n\n### FigureBlock\n\nAn image with a caption. Clicking it opens the page's `MediaLightbox` gallery, which the provider hosts; set `enableLightbox={false}` to turn that off. Put rich captions in `FigureBlock.Caption` and a source line in `FigureBlock.Aside`.\n\n```tsx\n<FigureBlock\n alt=\"The Atom63 design system social card\"\n aspectRatio=\"16/9\"\n caption=\"Figure 1. The social card for this site.\"\n src=\"/og.png\"\n/>\n```\n\nProps of `FigureBlock`:\n\n- `alt`: `string` (required)\n- `src`: `string` (required)\n- `aspectRatio`: `'1/1' | '4/3' | '3/4' | '16/9' | '9/16'`\n- `bordered`: `boolean` (default `true`)\n- `caption`: `string`\n- `children`: `ReactNode`\n- `className`: `string`\n- `enableLightbox`: `boolean` (default `true`). Click-to-zoom; multiple figures on a page share one connected gallery.\n- `lightboxGalleryId`: `string` (default `MDX_FIGURE_LIGHTBOX_GALLERY_ID`). Gallery id for connected lightbox (default: all FigureBlocks on the page).\n- `loading`: `'eager' | 'lazy'` (default `'lazy'`)\n- `spacing`: `'none' | 'sm' | 'default' | 'lg'` (default `'default'`)\n\nSlots, each taking `children`: `FigureBlock.Aside`, `FigureBlock.Caption`.\n\n### VideoBlock\n\nA video figure with native controls and an optional caption. A video with speech needs a caption track (`trackSrc`); mark a purely visual loop `captionPolicy=\"decorative\"` instead. With `autoPlay` and no `controls`, it draws its own pause button and stays still under reduced motion.\n\n```mdx\n<VideoBlock src=\"/media/talk.mp4\" title=\"Design tokens talk\" trackSrc=\"/media/talk.en.vtt\" />\n\n<VideoBlock\n autoPlay\n captionPolicy=\"decorative\"\n controls={false}\n loop\n muted\n src=\"/media/loop.mp4\"\n title=\"Theme switching loop\"\n/>\n```\n\nProps of `VideoBlock`:\n\n- `src`: `string` (required)\n- `title`: `string` (required)\n- `autoPlay`: `boolean` (default `false`). Start playing, muted, on load. Ignored when the reader prefers reduced motion. Without `controls`, a pause and play toggle sits over the video.\n- `caption`: `string`\n- `captionPolicy`: `'required' | 'decorative'`. Video has spoken or meaningful audio and must provide captions. Video is decorative or purely visual; no caption track is required.\n- `className`: `string`\n- `controls`: `boolean` (default `true`)\n- `fit`: `'contain' | 'cover'` (default `'contain'`)\n- `loop`: `boolean` (default `false`)\n- `muted`: `boolean` (default `false`)\n- `pauseLabel`: `string` (default `'Pause video'`). Name of the toggle while the video plays. Defaults to \"Pause video\".\n- `playLabel`: `string` (default `'Play video'`). Name of the toggle while the video is paused. Defaults to \"Play video\".\n- `showCaption`: `boolean` (default `false`)\n- `spacing`: `'none' | 'sm' | 'default' | 'lg'` (default `'default'`)\n- `trackLabel`: `string`. Name of the caption track in the player's caption menu. Defaults to the track language's own name, such as \"English\" or \"Deutsch\".\n- `trackLang`: `string` (default `'en'`). BCP 47 language of the caption track (`srclang`). Defaults to `en`.\n- `trackSrc`: `string`\n\n### MediaCaption\n\nThe caption line the media blocks use, on its own: for a custom figure, an embed or a chart.\n\n```tsx\n<MediaCaption>Figure 2. Token layers, from primitive to product.</MediaCaption>\n```\n\nProps of `MediaCaption`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n\n### MediaPlaceholder\n\nA labelled frame that stands in for an image, video or diagram that is not made yet. The label says what the real asset should show.\n\n```tsx\n<MediaPlaceholder kind=\"diagram\" label=\"Token flow from DTCG source to each renderer\" />\n```\n\nProps of `MediaPlaceholder`:\n\n- `aspectRatio`: `string` (default `'16 / 9'`). CSS aspect-ratio for the frame (e.g. `16 / 9`, `4 / 3`, `1 / 1`).\n- `className`: `string`\n- `kind`: `'video' | 'image' | 'diagram'` (default `'image'`). Picks the icon + kind tag. Defaults to `image`.\n- `label`: `string`. What the real asset should show — surfaced as the frame's caption.\n\n## Demos\n\n### DocExample\n\nA live example with Preview and Code tabs and a copy button. Every example on this page is one. Pass the source as `code` and render the same thing as children.\n\n```mdx\n<DocExample title=\"Primary button\" code={`<Button variant=\"primary\">Save</Button>`}>\n <Button variant=\"primary\">Save</Button>\n</DocExample>\n```\n\nProps of `DocExample`:\n\n- `children`: `ReactNode` (required)\n- `code`: `string` (required)\n- `align`: `'center' | 'left'` (default `'center'`)\n- `className`: `string`\n- `codeLabel`: `string` (default `'Code'`). Label for the code tab (default: \"Code\").\n- `copiedAnnouncement`: `string` (default `'Example code copied'`). Visually-hidden live-region text announced after copying (default: \"Example code copied\").\n- `copiedLabel`: `string` (default `'Copied to clipboard'`). aria-label for the copy control right after copying (default: \"Copied to clipboard\").\n- `copyCodeLabel`: `string` (default `'Copy example code'`). aria-label for the copy control when idle (default: \"Copy example code\").\n- `lang`: `string`\n- `previewLabel`: `string` (default `'Preview'`). Label for the preview tab (default: \"Preview\").\n- `title`: `string`\n- `wide`: `boolean` (default `false`)\n\nSlots, each taking `children`: `DocExample.Code`, `DocExample.Preview`, `DocExample.Title`.\n\n### DocExampleCode\n\nThe highlighted code panel of `DocExample`, on its own, for showing code that has no preview.\n\n```tsx\nimport { DocExampleCode } from '@atom63/mdx/blocks'\n\n<DocExampleCode code={`pnpm add @atom63/mdx`} lang=\"bash\" />\n```\n\nProps of `DocExampleCode`:\n\n- `code`: `string` (required)\n- `lang`: `string` (default `'tsx'`)\n\n### ExampleContainer\n\nA plain demo frame on a dot grid, with an optional title, description and spec line. Use it for a preview without a code tab.\n\n```mdx\n<ExampleContainer description=\"The main action of a view.\" title=\"Primary variant\">\n <Button variant=\"primary\">Save</Button>\n</ExampleContainer>\n```\n\nProps of `ExampleContainer`:\n\n- `children`: `React.ReactNode` (required)\n- `align`: `'center' | 'left'` (default `'center'`)\n- `className`: `string`\n- `description`: `string`\n- `embedded`: `boolean` (default `false`). Nested inside DocExample — drops outer margin and border (parent supplies chrome).\n- `spec`: `React.ReactNode`\n- `title`: `string`\n- `wide`: `boolean` (default `false`). Use wide layout to break out of narrow prose constraints\n\n### DemoStage\n\nA framed stage for a centrepiece demo or visual, with header slots for a title (`headerStart`) and controls (`headerEnd`).\n\n```tsx\n<DemoStage headerStart=\"Live demo\">\n <Button>Try me</Button>\n</DemoStage>\n```\n\nProps of `DemoStage`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n- `headerEnd`: `ReactNode`\n- `headerStart`: `ReactNode`\n- `panelClassName`: `string`\n\n### DemoConfigPanel\n\nThe controls panel for a `DemoStage`: a popover beside the stage, a sheet on small screens. Put it in `headerEnd` and pass the stage's ref.\n\n```tsx\nimport { DemoConfigPanel, DemoStage } from '@atom63/mdx/blocks'\nimport { Switch } from '@atom63/ui-react'\nimport { useRef, useState } from 'react'\n\nfunction TunableDemo() {\n const stageRef = useRef<HTMLElement>(null)\n const [dense, setDense] = useState(false)\n\n return (\n <DemoStage\n ref={stageRef}\n headerEnd={\n <DemoConfigPanel stageRef={stageRef} title=\"Demo controls\">\n <label>\n <Switch checked={dense} onCheckedChange={setDense} /> Dense\n </label>\n </DemoConfigPanel>\n }\n >\n <p>{dense ? 'Dense' : 'Comfortable'}</p>\n </DemoStage>\n )\n}\n```\n\nProps of `DemoConfigPanel`:\n\n- `children`: `ReactNode` (required)\n- `stageRef`: `RefObject<HTMLElement | null>` (required)\n- `defaultOpen`: `boolean`\n- `label`: `ReactNode` (default `'Tune'`)\n- `mobileQuery`: `string` (default `'(max-width: 767px)'`)\n- `onOpenChange`: `(open: boolean) => void`\n- `open`: `boolean`\n- `panelClassName`: `string`\n- `panelInset`: `number` (default `16`)\n- `panelWidth`: `number` (default `320`)\n- `sheetClassName`: `string`\n- `sheetPanelClassName`: `string`\n- `title`: `string` (default `'Demo controls'`)\n\n## Sequences\n\n### Steps\n\nNumbered steps for a procedure. Numbers and the connecting line come from document order; do not number titles by hand.\n\n```tsx\n<Steps>\n <Steps.Step title=\"Install the package\">Run pnpm add @atom63/mdx.</Steps.Step>\n <Steps.Step title=\"Load the styles\">Import @atom63/mdx/styles/a63.css once.</Steps.Step>\n <Steps.Step title=\"Wrap the page\">Render it inside MDXContentProvider.</Steps.Step>\n</Steps>\n```\n\nProps of `Steps`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n\nProps of `Steps.Step`:\n\n- `children`: `ReactNode` (required)\n- `title`: `ReactNode` (required). Bold heading for the step.\n- `className`: `string`\n- `index`: `number` (default `1`). Injected by `Steps` — the 1-indexed position in document order.\n\n### Timeline\n\nDated events in order: a release history, a project log. Each item has a date, a title and a short body.\n\n```tsx\n<Timeline>\n <Timeline.Item date=\"2025\" title=\"Primitive layer\">Colour ramps, type scale, spacing.</Timeline.Item>\n <Timeline.Item date=\"2026\" title=\"Semantic layer\">Tokens map primitives to intent.</Timeline.Item>\n</Timeline>\n```\n\nProps of `Timeline`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n\nProps of `Timeline.Item`:\n\n- `children`: `ReactNode` (required)\n- `date`: `ReactNode` (required). Date or label shown in the left column (e.g. a year).\n- `title`: `ReactNode` (required). Bold heading for the event.\n- `className`: `string`\n\n### ScrollStage\n\nScroll-driven storytelling: text steps scroll past while each step's `media` stays pinned beside them, and the media changes with the step in view. On narrow screens the media sits above its text.\n\n```mdx\n<ScrollStage>\n <ScrollStage.Step media={<img alt=\"Primitive tokens\" src=\"/images/primitives.webp\" />}>\n ### Primitive layer\n\n Raw values: colour ramps, the type scale, spacing and radius.\n </ScrollStage.Step>\n <ScrollStage.Step media={<img alt=\"Semantic tokens\" src=\"/images/semantic.webp\" />}>\n ### Semantic layer\n\n Tokens that name intent, so one theme change restyles everything.\n </ScrollStage.Step>\n</ScrollStage>\n```\n\nProps of `ScrollStage`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n\nProps of `ScrollStage.Step`:\n\n- `children`: `ReactNode` (required)\n- `media`: `ReactNode` (required). The visual (image, diagram, JSX) shown for this step. Keep it cheap — in the pinned path it re-renders whenever the active step changes, so prefer static images/JSX over heavy live components. Avoid putting anchor `id`s inside `media` or the prose: both the pinned (`lg+`) and stacked (below `lg`) copies render into the DOM, so an `id` would be duplicated.\n- `className`: `string`\n\n## Figures and links\n\n### StatCard\n\nOne metric with a label and an optional change. `trend` colours the change: `up` and `down` use status colours, `neutral` stays muted.\n\n```tsx\n<StatCard change=\"+1 this quarter\" label=\"Themes\" trend=\"up\" value=\"4\" />\n```\n\nProps of `StatCard`:\n\n- `label`: `string` (required). Small muted caption above the value.\n- `value`: `ReactNode` (required). The prominent metric.\n- `change`: `ReactNode`. Optional secondary change indicator, colored by `trend`.\n- `className`: `string`\n- `trend`: `'neutral' | 'up' | 'down'` (default `'neutral'`). Semantic direction of `change`; drives the token color.\n\n### StatGrid\n\nA responsive grid of `StatCard`s.\n\n```tsx\n<StatGrid>\n <StatCard label=\"Blocks\" value=\"30\" />\n <StatCard change=\"-5\" label=\"Open issues\" trend=\"down\" value=\"3\" />\n <StatCard label=\"Themes\" value=\"4\" />\n</StatGrid>\n```\n\nProps of `StatGrid`:\n\n- `children`: `ReactNode` (required)\n- `className`: `string`\n\n### ResourceList\n\nA list of outside links, each with a name and an optional note. Links open in a new tab.\n\n```tsx\n<ResourceList\n items={[\n { name: 'DTCG format', url: 'https://www.designtokens.org', note: 'The token file format' },\n { name: 'WCAG 2.2', url: 'https://www.w3.org/TR/WCAG22/', note: 'Accessibility criteria' },\n ]}\n/>\n```\n\nProps of `ResourceList`:\n\n- `items`: `ResourceItem[]` (required)\n- `className`: `string`\n\n## Diagrams\n\n### MermaidDiagram\n\nA Mermaid chart drawn in the theme's colours, with zoom controls. A fenced `mermaid` code block in MDX renders as one too.\n\n```tsx\n<MermaidDiagram\n chart=\"flowchart LR\n Tokens --> Contracts --> Components\"\n title=\"Build order\"\n/>\n```\n\nProps of `MermaidDiagram`:\n\n- `chart`: `string` (required)\n- `animated`: `boolean` (default `false`). When true, animate the diagram's paths with a stroke draw-on-reveal. Off by default.\n- `labels`: `Partial<MermaidDiagramLabels>`\n- `title`: `string`\n\n### LayerStack\n\nA layered model, top to bottom, with a label, title and optional metaphor, description and constraint per layer. Use it to explain an architecture in layers.\n\n```tsx\n<LayerStack\n title=\"Primitive / Procedure / Product\"\n layers={[\n { label: 'Primitive', title: 'Stable materials', description: 'Raw tokens and scales.' },\n { label: 'Procedure', title: 'Semantic rules', description: 'Semantic tokens and states.' },\n { label: 'Product', title: 'Rendered experience', description: 'Pages and flows.' },\n ]}\n/>\n```\n\nProps of `LayerStack`:\n\n- `layers`: `LayerStackItem[]` (required)\n- `className`: `string`\n- `description`: `ReactNode`\n- `labels`: `Partial<LayerStackLabels>`\n- `title`: `ReactNode`\n\n### ColorSwatchItem\n\nA colour swatch for a CSS variable, with its name and variable. Use it on token and theme pages.\n\n```tsx\n<ColorSwatchItem name=\"Page surface\" variable=\"--a63-surface-page\" />\n<ColorSwatchItem name=\"Primary text\" variable=\"--a63-text-primary\" />\n```\n\nProps of `ColorSwatchItem`:\n\n- `name`: `string` (required)\n- `variable`: `string` (required)\n\n## Code\n\n### CodeBlock\n\nHighlighted code with a copy button and a language label. A fenced code block in MDX renders as one; use the component for code held in a variable.\n\n```tsx\n<CodeBlock code=\"pnpm add @atom63/mdx\" lang=\"bash\" />\n```\n\nProps of `CodeBlock`:\n\n- `code`: `string` (required)\n- `children`: `ReactNode`\n- `className`: `string`\n- `copyLabel`: `string`\n- `fallbackLangLabel`: `string`. Label shown in place of an unknown language in the article header.\n- `lang`: `string` (default `'tsx'`)\n- `loadingLabel`: `string` (default `'Highlighting code'`). Visually-hidden status text announced while syntax highlighting runs.\n- `maxHeight`: `string`\n- `showCopyButton`: `boolean`\n- `showLineNumbers`: `boolean`. Show a numbered gutter. Defaults to a smart heuristic: on for `article` blocks longer than 6 lines, off for short snippets and embedded blocks.\n- `spacing`: `'component' | 'none'`\n- `variant`: `'article' | 'embedded'`\n\n### Tabs\n\nTabbed panels in prose, such as the same step for npm and pnpm. It is the `Tabs` component of `@atom63/ui-react` with MDX spacing, and takes its props: `atom63 component tabs`.\n\n```tsx\n<Tabs defaultValue=\"pnpm\">\n <Tabs.List>\n <Tabs.Tab value=\"pnpm\">pnpm</Tabs.Tab>\n <Tabs.Tab value=\"npm\">npm</Tabs.Tab>\n </Tabs.List>\n <Tabs.Panel value=\"pnpm\">pnpm add @atom63/mdx</Tabs.Panel>\n <Tabs.Panel value=\"npm\">npm install @atom63/mdx</Tabs.Panel>\n</Tabs>\n```\n\n`Tabs` adds no props of its own.\n\nProps of `Tabs.List`:\n\n- `size`: `'sm' | 'default' | 'lg' | 'xs' | 'md'` (default `tabsContract.defaultSize`). `'default'` is a deprecated alias of `'md'`.\n- `variant`: `'default' | 'underline' | 'attached'` (default `tabsContract.defaultVariant`)\n\nProps of `Tabs.Panel`:\n\n- `animated`: `boolean` (default `false`)\n\nProps of `Tabs.Tab`:\n\n- `size`: `'sm' | 'default' | 'lg' | 'xs' | 'md'`. `'default'` is a deprecated alias of `'md'`.\n\n## Page furniture\n\n### Accordion\n\nCollapsible questions and answers, such as an FAQ. It is the `Accordion` component of `@atom63/ui-react` with MDX spacing, and takes its props: `atom63 component accordion`.\n\n```tsx\n<Accordion collapsible type=\"single\">\n <Accordion.Item value=\"token\">\n <Accordion.Trigger>What is a design token?</Accordion.Trigger>\n <Accordion.Content>A named value that components read instead of a literal.</Accordion.Content>\n </Accordion.Item>\n</Accordion>\n```\n\nProps of `Accordion`:\n\n- `collapsible`: `boolean`\n- `defaultValue`: `string | string[]`\n- `onValueChange`: `(value: string | string[]) => void`\n- `type`: `'multiple' | 'single'`\n- `value`: `string | string[]`\n\nProps of `Accordion.Trigger`:\n\n- `icon`: `'chevron' | 'plus-minus'` (default `'chevron'`)\n\n### PageMeta\n\nThe header of an article or lesson: eyebrow, title, description and a meta line such as the reading time.\n\n```tsx\n<PageMeta\n description=\"How semantic tokens keep colour and spacing consistent.\"\n eyebrow=\"Guide\"\n meta=\"8 min read\"\n title=\"Designing with tokens\"\n/>\n```\n\nProps of `PageMeta`:\n\n- `title`: `ReactNode` (required)\n- `children`: `ReactNode`\n- `className`: `string`\n- `description`: `ReactNode`\n- `eyebrow`: `ReactNode`\n- `meta`: `ReactNode`\n\n### PageTableOfContents\n\nThe page's table of contents, built from its `h2` and `h3` headings, with the current section highlighted. `rail` sits beside the text; `inline`, `menu` and `embedded` fit narrow layouts.\n\n```tsx\nimport { PageTableOfContents } from '@atom63/mdx/blocks'\n\n<aside>\n <PageTableOfContents label=\"On this page\" variant=\"rail\" />\n</aside>\n```\n\nProps of `PageTableOfContents`:\n\n- `activeOffset`: `number` (default `120`)\n- `className`: `string`\n- `containerSelector`: `string` (default `'[data-mdx-scroll-root], #learn-main, main'`)\n- `headingSelector`: `string` (default `'[data-mdx-content] h2, [data-mdx-content] h3, article h2, article h3'`)\n- `inlinePositionClassName`: `string` (default `'fixed top-[calc(--spacing(14)+--spacing(3))] right-4 z-30 xl:hidden'`)\n- `label`: `string` (default `'On this page'`)\n- `onActiveLabelChange`: `(label: string) => void`\n- `onNavigate`: `() => void`\n- `scrollOffset`: `number` (default `96`)\n- `showProgress`: `boolean` (default `true`)\n- `smoothScrollDuration`: `number` (default `420`)\n- `variant`: `'menu' | 'embedded' | 'inline' | 'rail'` (default `'rail'`)\n\n### MdxPageSkeleton\n\nThe loading state of an MDX page while its content loads, in the `docs` or `lesson` layout.\n\n```tsx\n<MdxPageSkeleton showRail={false} variant=\"docs\" />\n```\n\nProps of `MdxPageSkeleton`:\n\n- `className`: `string`\n- `showInlineToc`: `boolean` (default `true`)\n- `showRail`: `boolean` (default `true`)\n- `variant`: `'docs' | 'lesson'` (default `'docs'`)\n\n### CreditsBlock\n\nA collapsible list of credits, one role per row, at the end of an article or project page.\n\n```tsx\n<CreditsBlock\n credits={[\n { role: 'Design', credits: 'ATOM63' },\n { role: 'Photography', credits: 'Unsplash contributors' },\n ]}\n/>\n```\n\nProps of `CreditsBlock`:\n\n- `credits`: `CreditEntry[]` (required)\n- `className`: `string`\n- `label`: `string` (default `'Credits'`)\n\n## Prose elements\n\nThe provider's component map also styles plain Markdown, so most of a page needs no blocks:\n\n| Markdown | Renders as |\n|----------|------------|\n| `#` to `######` | Headings on the type scale; `h2` and `h3` feed `PageTableOfContents` |\n| Paragraphs, `**strong**`, `*em*`, `<kbd>` | Body text at prose measure |\n| `[link](url)` | A link; an external one opens in a new tab |\n| `` `code` `` | Inline code |\n| Fenced code | `CodeBlock`; a `mermaid` fence renders `MermaidDiagram` |\n| Lists, `>` quotes, `---` | Lists, a quote, a rule |\n| Tables | The `Table` of `@atom63/ui-react`, scrolling when wide |",
|
|
14178
14502
|
"route": "/patterns/pattern-mdx-blocks",
|
|
14179
14503
|
"slug": "pattern-mdx-blocks"
|
|
14180
14504
|
},
|
|
@@ -15129,6 +15453,10 @@
|
|
|
15129
15453
|
{
|
|
15130
15454
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15131
15455
|
"value": "var(--color-danger-600)"
|
|
15456
|
+
},
|
|
15457
|
+
{
|
|
15458
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15459
|
+
"value": "var(--color-danger-600)"
|
|
15132
15460
|
}
|
|
15133
15461
|
]
|
|
15134
15462
|
},
|
|
@@ -15145,6 +15473,10 @@
|
|
|
15145
15473
|
{
|
|
15146
15474
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15147
15475
|
"value": "white"
|
|
15476
|
+
},
|
|
15477
|
+
{
|
|
15478
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15479
|
+
"value": "white"
|
|
15148
15480
|
}
|
|
15149
15481
|
]
|
|
15150
15482
|
},
|
|
@@ -15165,6 +15497,10 @@
|
|
|
15165
15497
|
{
|
|
15166
15498
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15167
15499
|
"value": "color-mix(in oklch, var(--a63-action-danger) 90%, transparent)"
|
|
15500
|
+
},
|
|
15501
|
+
{
|
|
15502
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15503
|
+
"value": "var( --a63-if-light, color-mix(in oklch, var(--a63-action-danger) 90%, transparent) ) var(--a63-if-dark, color-mix(in oklch, var(--a63-action-danger) 82%, white 8%))"
|
|
15168
15504
|
}
|
|
15169
15505
|
]
|
|
15170
15506
|
},
|
|
@@ -15185,6 +15521,10 @@
|
|
|
15185
15521
|
{
|
|
15186
15522
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15187
15523
|
"value": "color-mix(in oklab, var(--a63-action-danger) 14%, transparent)"
|
|
15524
|
+
},
|
|
15525
|
+
{
|
|
15526
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15527
|
+
"value": "color-mix(in oklab, var(--a63-action-danger) 14%, transparent)"
|
|
15188
15528
|
}
|
|
15189
15529
|
]
|
|
15190
15530
|
},
|
|
@@ -15205,6 +15545,10 @@
|
|
|
15205
15545
|
{
|
|
15206
15546
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15207
15547
|
"value": "var(--color-danger-700)"
|
|
15548
|
+
},
|
|
15549
|
+
{
|
|
15550
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15551
|
+
"value": "var(--a63-if-light, var(--color-danger-700)) var(--a63-if-dark, var(--color-danger-400))"
|
|
15208
15552
|
}
|
|
15209
15553
|
]
|
|
15210
15554
|
},
|
|
@@ -15225,6 +15569,10 @@
|
|
|
15225
15569
|
{
|
|
15226
15570
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15227
15571
|
"value": "var(--a63-surface-muted)"
|
|
15572
|
+
},
|
|
15573
|
+
{
|
|
15574
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15575
|
+
"value": "var(--a63-surface-muted)"
|
|
15228
15576
|
}
|
|
15229
15577
|
]
|
|
15230
15578
|
},
|
|
@@ -15245,6 +15593,10 @@
|
|
|
15245
15593
|
{
|
|
15246
15594
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15247
15595
|
"value": "var(--a63-border-subtle)"
|
|
15596
|
+
},
|
|
15597
|
+
{
|
|
15598
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15599
|
+
"value": "var(--a63-border-subtle)"
|
|
15248
15600
|
}
|
|
15249
15601
|
]
|
|
15250
15602
|
},
|
|
@@ -15265,6 +15617,10 @@
|
|
|
15265
15617
|
{
|
|
15266
15618
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15267
15619
|
"value": "var(--surface-light-9)"
|
|
15620
|
+
},
|
|
15621
|
+
{
|
|
15622
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15623
|
+
"value": "var(--a63-if-light, var(--surface-light-9)) var(--a63-if-dark, var(--surface-dark-9))"
|
|
15268
15624
|
}
|
|
15269
15625
|
]
|
|
15270
15626
|
},
|
|
@@ -15302,6 +15658,10 @@
|
|
|
15302
15658
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
15303
15659
|
"value": "color-mix( in oklab, var(--surface-dark-3) 86%, var(--a63-action-primary) 14% )"
|
|
15304
15660
|
},
|
|
15661
|
+
{
|
|
15662
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
15663
|
+
"value": "var(--a63-if-light, color-mix(in oklab, var(--surface-light-3) 60%, white)) var( --a63-if-dark, color-mix(in oklab, var(--surface-dark-3) 86%, var(--a63-action-primary) 14%) )"
|
|
15664
|
+
},
|
|
15305
15665
|
{
|
|
15306
15666
|
"scope": ":is(.dark, [data-a63-mode='dark'])",
|
|
15307
15667
|
"value": "var(--surface-dark-12)"
|
|
@@ -15309,6 +15669,10 @@
|
|
|
15309
15669
|
{
|
|
15310
15670
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15311
15671
|
"value": "var(--surface-light-12)"
|
|
15672
|
+
},
|
|
15673
|
+
{
|
|
15674
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15675
|
+
"value": "var(--a63-if-light, var(--surface-light-12)) var(--a63-if-dark, var(--surface-dark-12))"
|
|
15312
15676
|
}
|
|
15313
15677
|
]
|
|
15314
15678
|
},
|
|
@@ -15330,6 +15694,10 @@
|
|
|
15330
15694
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
15331
15695
|
"value": "var(--a63-text-accent)"
|
|
15332
15696
|
},
|
|
15697
|
+
{
|
|
15698
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
15699
|
+
"value": "var( --a63-if-light, color-mix(in oklab, var(--a63-action-primary) 80%, var(--surface-light-12)) ) var(--a63-if-dark, var(--a63-text-accent))"
|
|
15700
|
+
},
|
|
15333
15701
|
{
|
|
15334
15702
|
"scope": ":is(.dark, [data-a63-mode='dark'])",
|
|
15335
15703
|
"value": "var(--surface-dark-1)"
|
|
@@ -15337,6 +15705,10 @@
|
|
|
15337
15705
|
{
|
|
15338
15706
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15339
15707
|
"value": "var(--surface-light-2)"
|
|
15708
|
+
},
|
|
15709
|
+
{
|
|
15710
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15711
|
+
"value": "var(--a63-if-light, var(--surface-light-2)) var(--a63-if-dark, var(--surface-dark-1))"
|
|
15340
15712
|
}
|
|
15341
15713
|
]
|
|
15342
15714
|
},
|
|
@@ -15429,6 +15801,10 @@
|
|
|
15429
15801
|
{
|
|
15430
15802
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15431
15803
|
"value": "transparent"
|
|
15804
|
+
},
|
|
15805
|
+
{
|
|
15806
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15807
|
+
"value": "var(--a63-if-light, transparent) var(--a63-if-dark, color-mix(in oklab, var(--a63-surface-control) 32%, transparent))"
|
|
15432
15808
|
}
|
|
15433
15809
|
]
|
|
15434
15810
|
},
|
|
@@ -15481,6 +15857,10 @@
|
|
|
15481
15857
|
{
|
|
15482
15858
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15483
15859
|
"value": "var(--a63-category-amber)"
|
|
15860
|
+
},
|
|
15861
|
+
{
|
|
15862
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15863
|
+
"value": "var(--a63-category-amber)"
|
|
15484
15864
|
}
|
|
15485
15865
|
]
|
|
15486
15866
|
},
|
|
@@ -15501,6 +15881,10 @@
|
|
|
15501
15881
|
{
|
|
15502
15882
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15503
15883
|
"value": "var(--a63-category-amber-subtle-foreground)"
|
|
15884
|
+
},
|
|
15885
|
+
{
|
|
15886
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15887
|
+
"value": "var(--a63-category-amber-subtle-foreground)"
|
|
15504
15888
|
}
|
|
15505
15889
|
]
|
|
15506
15890
|
},
|
|
@@ -15521,6 +15905,10 @@
|
|
|
15521
15905
|
{
|
|
15522
15906
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15523
15907
|
"value": "var(--a63-category-blue)"
|
|
15908
|
+
},
|
|
15909
|
+
{
|
|
15910
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15911
|
+
"value": "var(--a63-category-blue)"
|
|
15524
15912
|
}
|
|
15525
15913
|
]
|
|
15526
15914
|
},
|
|
@@ -15541,6 +15929,10 @@
|
|
|
15541
15929
|
{
|
|
15542
15930
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15543
15931
|
"value": "var(--a63-category-blue-subtle-foreground)"
|
|
15932
|
+
},
|
|
15933
|
+
{
|
|
15934
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15935
|
+
"value": "var(--a63-category-blue-subtle-foreground)"
|
|
15544
15936
|
}
|
|
15545
15937
|
]
|
|
15546
15938
|
},
|
|
@@ -15561,6 +15953,10 @@
|
|
|
15561
15953
|
{
|
|
15562
15954
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15563
15955
|
"value": "var(--a63-category-cyan)"
|
|
15956
|
+
},
|
|
15957
|
+
{
|
|
15958
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15959
|
+
"value": "var(--a63-category-cyan)"
|
|
15564
15960
|
}
|
|
15565
15961
|
]
|
|
15566
15962
|
},
|
|
@@ -15581,6 +15977,10 @@
|
|
|
15581
15977
|
{
|
|
15582
15978
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15583
15979
|
"value": "var(--a63-category-cyan-subtle-foreground)"
|
|
15980
|
+
},
|
|
15981
|
+
{
|
|
15982
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
15983
|
+
"value": "var(--a63-category-cyan-subtle-foreground)"
|
|
15584
15984
|
}
|
|
15585
15985
|
]
|
|
15586
15986
|
},
|
|
@@ -15601,6 +16001,10 @@
|
|
|
15601
16001
|
{
|
|
15602
16002
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15603
16003
|
"value": "var(--a63-category-emerald)"
|
|
16004
|
+
},
|
|
16005
|
+
{
|
|
16006
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16007
|
+
"value": "var(--a63-category-emerald)"
|
|
15604
16008
|
}
|
|
15605
16009
|
]
|
|
15606
16010
|
},
|
|
@@ -15621,6 +16025,10 @@
|
|
|
15621
16025
|
{
|
|
15622
16026
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15623
16027
|
"value": "var(--a63-category-emerald-subtle-foreground)"
|
|
16028
|
+
},
|
|
16029
|
+
{
|
|
16030
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16031
|
+
"value": "var(--a63-category-emerald-subtle-foreground)"
|
|
15624
16032
|
}
|
|
15625
16033
|
]
|
|
15626
16034
|
},
|
|
@@ -15641,6 +16049,10 @@
|
|
|
15641
16049
|
{
|
|
15642
16050
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15643
16051
|
"value": "var(--a63-action-danger-subtle-foreground)"
|
|
16052
|
+
},
|
|
16053
|
+
{
|
|
16054
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16055
|
+
"value": "var(--a63-action-danger-subtle-foreground)"
|
|
15644
16056
|
}
|
|
15645
16057
|
]
|
|
15646
16058
|
},
|
|
@@ -15661,6 +16073,10 @@
|
|
|
15661
16073
|
{
|
|
15662
16074
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15663
16075
|
"value": "var(--a63-category-fuchsia)"
|
|
16076
|
+
},
|
|
16077
|
+
{
|
|
16078
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16079
|
+
"value": "var(--a63-category-fuchsia)"
|
|
15664
16080
|
}
|
|
15665
16081
|
]
|
|
15666
16082
|
},
|
|
@@ -15681,6 +16097,10 @@
|
|
|
15681
16097
|
{
|
|
15682
16098
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15683
16099
|
"value": "var(--a63-category-fuchsia-subtle-foreground)"
|
|
16100
|
+
},
|
|
16101
|
+
{
|
|
16102
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16103
|
+
"value": "var(--a63-category-fuchsia-subtle-foreground)"
|
|
15684
16104
|
}
|
|
15685
16105
|
]
|
|
15686
16106
|
},
|
|
@@ -15701,6 +16121,10 @@
|
|
|
15701
16121
|
{
|
|
15702
16122
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15703
16123
|
"value": "var(--a63-category-green)"
|
|
16124
|
+
},
|
|
16125
|
+
{
|
|
16126
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16127
|
+
"value": "var(--a63-category-green)"
|
|
15704
16128
|
}
|
|
15705
16129
|
]
|
|
15706
16130
|
},
|
|
@@ -15721,6 +16145,10 @@
|
|
|
15721
16145
|
{
|
|
15722
16146
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15723
16147
|
"value": "var(--a63-category-green-subtle-foreground)"
|
|
16148
|
+
},
|
|
16149
|
+
{
|
|
16150
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16151
|
+
"value": "var(--a63-category-green-subtle-foreground)"
|
|
15724
16152
|
}
|
|
15725
16153
|
]
|
|
15726
16154
|
},
|
|
@@ -15741,6 +16169,10 @@
|
|
|
15741
16169
|
{
|
|
15742
16170
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15743
16171
|
"value": "var(--a63-category-indigo)"
|
|
16172
|
+
},
|
|
16173
|
+
{
|
|
16174
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16175
|
+
"value": "var(--a63-category-indigo)"
|
|
15744
16176
|
}
|
|
15745
16177
|
]
|
|
15746
16178
|
},
|
|
@@ -15761,6 +16193,10 @@
|
|
|
15761
16193
|
{
|
|
15762
16194
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15763
16195
|
"value": "var(--a63-category-indigo-subtle-foreground)"
|
|
16196
|
+
},
|
|
16197
|
+
{
|
|
16198
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16199
|
+
"value": "var(--a63-category-indigo-subtle-foreground)"
|
|
15764
16200
|
}
|
|
15765
16201
|
]
|
|
15766
16202
|
},
|
|
@@ -15781,6 +16217,10 @@
|
|
|
15781
16217
|
{
|
|
15782
16218
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15783
16219
|
"value": "var(--a63-status-info-subtle-foreground)"
|
|
16220
|
+
},
|
|
16221
|
+
{
|
|
16222
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16223
|
+
"value": "var(--a63-status-info-subtle-foreground)"
|
|
15784
16224
|
}
|
|
15785
16225
|
]
|
|
15786
16226
|
},
|
|
@@ -15801,6 +16241,10 @@
|
|
|
15801
16241
|
{
|
|
15802
16242
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15803
16243
|
"value": "var(--a63-category-lime)"
|
|
16244
|
+
},
|
|
16245
|
+
{
|
|
16246
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16247
|
+
"value": "var(--a63-category-lime)"
|
|
15804
16248
|
}
|
|
15805
16249
|
]
|
|
15806
16250
|
},
|
|
@@ -15821,6 +16265,10 @@
|
|
|
15821
16265
|
{
|
|
15822
16266
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15823
16267
|
"value": "var(--a63-category-lime-subtle-foreground)"
|
|
16268
|
+
},
|
|
16269
|
+
{
|
|
16270
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16271
|
+
"value": "var(--a63-category-lime-subtle-foreground)"
|
|
15824
16272
|
}
|
|
15825
16273
|
]
|
|
15826
16274
|
},
|
|
@@ -15841,6 +16289,10 @@
|
|
|
15841
16289
|
{
|
|
15842
16290
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15843
16291
|
"value": "var(--a63-category-neutral)"
|
|
16292
|
+
},
|
|
16293
|
+
{
|
|
16294
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16295
|
+
"value": "var(--a63-category-neutral)"
|
|
15844
16296
|
}
|
|
15845
16297
|
]
|
|
15846
16298
|
},
|
|
@@ -15861,6 +16313,10 @@
|
|
|
15861
16313
|
{
|
|
15862
16314
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15863
16315
|
"value": "var(--a63-category-neutral-subtle-foreground)"
|
|
16316
|
+
},
|
|
16317
|
+
{
|
|
16318
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16319
|
+
"value": "var(--a63-category-neutral-subtle-foreground)"
|
|
15864
16320
|
}
|
|
15865
16321
|
]
|
|
15866
16322
|
},
|
|
@@ -15881,6 +16337,10 @@
|
|
|
15881
16337
|
{
|
|
15882
16338
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15883
16339
|
"value": "var(--a63-category-orange)"
|
|
16340
|
+
},
|
|
16341
|
+
{
|
|
16342
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16343
|
+
"value": "var(--a63-category-orange)"
|
|
15884
16344
|
}
|
|
15885
16345
|
]
|
|
15886
16346
|
},
|
|
@@ -15901,6 +16361,10 @@
|
|
|
15901
16361
|
{
|
|
15902
16362
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15903
16363
|
"value": "var(--a63-category-orange-subtle-foreground)"
|
|
16364
|
+
},
|
|
16365
|
+
{
|
|
16366
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16367
|
+
"value": "var(--a63-category-orange-subtle-foreground)"
|
|
15904
16368
|
}
|
|
15905
16369
|
]
|
|
15906
16370
|
},
|
|
@@ -15921,6 +16385,10 @@
|
|
|
15921
16385
|
{
|
|
15922
16386
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15923
16387
|
"value": "var(--a63-category-pink)"
|
|
16388
|
+
},
|
|
16389
|
+
{
|
|
16390
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16391
|
+
"value": "var(--a63-category-pink)"
|
|
15924
16392
|
}
|
|
15925
16393
|
]
|
|
15926
16394
|
},
|
|
@@ -15941,6 +16409,10 @@
|
|
|
15941
16409
|
{
|
|
15942
16410
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15943
16411
|
"value": "var(--a63-category-pink-subtle-foreground)"
|
|
16412
|
+
},
|
|
16413
|
+
{
|
|
16414
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16415
|
+
"value": "var(--a63-category-pink-subtle-foreground)"
|
|
15944
16416
|
}
|
|
15945
16417
|
]
|
|
15946
16418
|
},
|
|
@@ -15961,6 +16433,10 @@
|
|
|
15961
16433
|
{
|
|
15962
16434
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15963
16435
|
"value": "var(--a63-category-purple)"
|
|
16436
|
+
},
|
|
16437
|
+
{
|
|
16438
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16439
|
+
"value": "var(--a63-category-purple)"
|
|
15964
16440
|
}
|
|
15965
16441
|
]
|
|
15966
16442
|
},
|
|
@@ -15981,6 +16457,10 @@
|
|
|
15981
16457
|
{
|
|
15982
16458
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
15983
16459
|
"value": "var(--a63-category-purple-subtle-foreground)"
|
|
16460
|
+
},
|
|
16461
|
+
{
|
|
16462
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16463
|
+
"value": "var(--a63-category-purple-subtle-foreground)"
|
|
15984
16464
|
}
|
|
15985
16465
|
]
|
|
15986
16466
|
},
|
|
@@ -16001,6 +16481,10 @@
|
|
|
16001
16481
|
{
|
|
16002
16482
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16003
16483
|
"value": "var(--a63-category-red)"
|
|
16484
|
+
},
|
|
16485
|
+
{
|
|
16486
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16487
|
+
"value": "var(--a63-category-red)"
|
|
16004
16488
|
}
|
|
16005
16489
|
]
|
|
16006
16490
|
},
|
|
@@ -16021,6 +16505,10 @@
|
|
|
16021
16505
|
{
|
|
16022
16506
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16023
16507
|
"value": "var(--a63-category-red-subtle-foreground)"
|
|
16508
|
+
},
|
|
16509
|
+
{
|
|
16510
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16511
|
+
"value": "var(--a63-category-red-subtle-foreground)"
|
|
16024
16512
|
}
|
|
16025
16513
|
]
|
|
16026
16514
|
},
|
|
@@ -16041,6 +16529,10 @@
|
|
|
16041
16529
|
{
|
|
16042
16530
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16043
16531
|
"value": "var(--a63-category-rose)"
|
|
16532
|
+
},
|
|
16533
|
+
{
|
|
16534
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16535
|
+
"value": "var(--a63-category-rose)"
|
|
16044
16536
|
}
|
|
16045
16537
|
]
|
|
16046
16538
|
},
|
|
@@ -16061,6 +16553,10 @@
|
|
|
16061
16553
|
{
|
|
16062
16554
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16063
16555
|
"value": "var(--a63-category-rose-subtle-foreground)"
|
|
16556
|
+
},
|
|
16557
|
+
{
|
|
16558
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16559
|
+
"value": "var(--a63-category-rose-subtle-foreground)"
|
|
16064
16560
|
}
|
|
16065
16561
|
]
|
|
16066
16562
|
},
|
|
@@ -16081,6 +16577,10 @@
|
|
|
16081
16577
|
{
|
|
16082
16578
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16083
16579
|
"value": "var(--a63-category-sky)"
|
|
16580
|
+
},
|
|
16581
|
+
{
|
|
16582
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16583
|
+
"value": "var(--a63-category-sky)"
|
|
16084
16584
|
}
|
|
16085
16585
|
]
|
|
16086
16586
|
},
|
|
@@ -16101,6 +16601,10 @@
|
|
|
16101
16601
|
{
|
|
16102
16602
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16103
16603
|
"value": "var(--a63-category-sky-subtle-foreground)"
|
|
16604
|
+
},
|
|
16605
|
+
{
|
|
16606
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16607
|
+
"value": "var(--a63-category-sky-subtle-foreground)"
|
|
16104
16608
|
}
|
|
16105
16609
|
]
|
|
16106
16610
|
},
|
|
@@ -16121,6 +16625,10 @@
|
|
|
16121
16625
|
{
|
|
16122
16626
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16123
16627
|
"value": "var(--a63-status-success-subtle-foreground)"
|
|
16628
|
+
},
|
|
16629
|
+
{
|
|
16630
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16631
|
+
"value": "var(--a63-status-success-subtle-foreground)"
|
|
16124
16632
|
}
|
|
16125
16633
|
]
|
|
16126
16634
|
},
|
|
@@ -16141,6 +16649,10 @@
|
|
|
16141
16649
|
{
|
|
16142
16650
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16143
16651
|
"value": "var(--a63-category-teal)"
|
|
16652
|
+
},
|
|
16653
|
+
{
|
|
16654
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16655
|
+
"value": "var(--a63-category-teal)"
|
|
16144
16656
|
}
|
|
16145
16657
|
]
|
|
16146
16658
|
},
|
|
@@ -16161,6 +16673,10 @@
|
|
|
16161
16673
|
{
|
|
16162
16674
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16163
16675
|
"value": "var(--a63-category-teal-subtle-foreground)"
|
|
16676
|
+
},
|
|
16677
|
+
{
|
|
16678
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16679
|
+
"value": "var(--a63-category-teal-subtle-foreground)"
|
|
16164
16680
|
}
|
|
16165
16681
|
]
|
|
16166
16682
|
},
|
|
@@ -16181,6 +16697,10 @@
|
|
|
16181
16697
|
{
|
|
16182
16698
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16183
16699
|
"value": "var(--a63-category-violet)"
|
|
16700
|
+
},
|
|
16701
|
+
{
|
|
16702
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16703
|
+
"value": "var(--a63-category-violet)"
|
|
16184
16704
|
}
|
|
16185
16705
|
]
|
|
16186
16706
|
},
|
|
@@ -16201,6 +16721,10 @@
|
|
|
16201
16721
|
{
|
|
16202
16722
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16203
16723
|
"value": "var(--a63-category-violet-subtle-foreground)"
|
|
16724
|
+
},
|
|
16725
|
+
{
|
|
16726
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16727
|
+
"value": "var(--a63-category-violet-subtle-foreground)"
|
|
16204
16728
|
}
|
|
16205
16729
|
]
|
|
16206
16730
|
},
|
|
@@ -16221,6 +16745,10 @@
|
|
|
16221
16745
|
{
|
|
16222
16746
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16223
16747
|
"value": "var(--a63-status-warning-subtle-foreground)"
|
|
16748
|
+
},
|
|
16749
|
+
{
|
|
16750
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16751
|
+
"value": "var(--a63-status-warning-subtle-foreground)"
|
|
16224
16752
|
}
|
|
16225
16753
|
]
|
|
16226
16754
|
},
|
|
@@ -16241,6 +16769,10 @@
|
|
|
16241
16769
|
{
|
|
16242
16770
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16243
16771
|
"value": "var(--a63-category-yellow)"
|
|
16772
|
+
},
|
|
16773
|
+
{
|
|
16774
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16775
|
+
"value": "var(--a63-category-yellow)"
|
|
16244
16776
|
}
|
|
16245
16777
|
]
|
|
16246
16778
|
},
|
|
@@ -16261,6 +16793,10 @@
|
|
|
16261
16793
|
{
|
|
16262
16794
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16263
16795
|
"value": "var(--a63-category-yellow-subtle-foreground)"
|
|
16796
|
+
},
|
|
16797
|
+
{
|
|
16798
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16799
|
+
"value": "var(--a63-category-yellow-subtle-foreground)"
|
|
16264
16800
|
}
|
|
16265
16801
|
]
|
|
16266
16802
|
},
|
|
@@ -16282,6 +16818,10 @@
|
|
|
16282
16818
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
16283
16819
|
"value": "color-mix(in oklch, var(--a63-action-primary) 42%, transparent)"
|
|
16284
16820
|
},
|
|
16821
|
+
{
|
|
16822
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
16823
|
+
"value": "var( --a63-if-light, color-mix( in oklab, var(--a63-action-primary) 26%, color-mix(in oklab, var(--surface-light-5) 60%, white) ) ) var(--a63-if-dark, color-mix(in oklch, var(--a63-action-primary) 42%, transparent))"
|
|
16824
|
+
},
|
|
16285
16825
|
{
|
|
16286
16826
|
"scope": ":is(.dark, [data-a63-mode='dark'])",
|
|
16287
16827
|
"value": "color-mix( in oklab, var(--surface-dark-7) calc(100% - var(--a63-surface-tint)), var(--a63-brand-500) var(--a63-surface-tint) )"
|
|
@@ -16289,6 +16829,34 @@
|
|
|
16289
16829
|
{
|
|
16290
16830
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16291
16831
|
"value": "color-mix( in oklab, var(--surface-light-5) calc(100% - var(--a63-surface-tint)), var(--a63-brand-400) var(--a63-surface-tint) )"
|
|
16832
|
+
},
|
|
16833
|
+
{
|
|
16834
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16835
|
+
"value": "var( --a63-if-light, color-mix( in oklab, var(--surface-light-5) calc(100% - var(--a63-surface-tint)), var(--a63-brand-400) var(--a63-surface-tint) ) ) var( --a63-if-dark, color-mix( in oklab, var(--surface-dark-7) calc(100% - var(--a63-surface-tint)), var(--a63-brand-500) var(--a63-surface-tint) ) )"
|
|
16836
|
+
}
|
|
16837
|
+
]
|
|
16838
|
+
},
|
|
16839
|
+
{
|
|
16840
|
+
"cssVar": "--a63-border-danger",
|
|
16841
|
+
"figma": {
|
|
16842
|
+
"collection": "Semantic",
|
|
16843
|
+
"path": "border/danger"
|
|
16844
|
+
},
|
|
16845
|
+
"layer": "semantic",
|
|
16846
|
+
"swift": null,
|
|
16847
|
+
"type": "color",
|
|
16848
|
+
"values": [
|
|
16849
|
+
{
|
|
16850
|
+
"scope": ":is(.dark, [data-a63-mode='dark'])",
|
|
16851
|
+
"value": "var(--color-danger-500)"
|
|
16852
|
+
},
|
|
16853
|
+
{
|
|
16854
|
+
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16855
|
+
"value": "color-mix(in oklch, var(--color-danger-600) 62%, transparent)"
|
|
16856
|
+
},
|
|
16857
|
+
{
|
|
16858
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16859
|
+
"value": "var( --a63-if-light, color-mix(in oklch, var(--color-danger-600) 62%, transparent) ) var(--a63-if-dark, var(--color-danger-500))"
|
|
16292
16860
|
}
|
|
16293
16861
|
]
|
|
16294
16862
|
},
|
|
@@ -16310,6 +16878,10 @@
|
|
|
16310
16878
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
16311
16879
|
"value": "color-mix(in oklch, var(--a63-text-accent) 60%, transparent)"
|
|
16312
16880
|
},
|
|
16881
|
+
{
|
|
16882
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
16883
|
+
"value": "var( --a63-if-light, color-mix(in oklab, var(--a63-action-primary) 70%, var(--surface-light-10)) ) var(--a63-if-dark, color-mix(in oklch, var(--a63-text-accent) 60%, transparent))"
|
|
16884
|
+
},
|
|
16313
16885
|
{
|
|
16314
16886
|
"scope": ":is(.dark, [data-a63-mode='dark'])",
|
|
16315
16887
|
"value": "color-mix( in oklab, var(--surface-dark-9) calc(100% - var(--a63-surface-tint)), var(--a63-brand-500) var(--a63-surface-tint) )"
|
|
@@ -16317,6 +16889,10 @@
|
|
|
16317
16889
|
{
|
|
16318
16890
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16319
16891
|
"value": "color-mix( in oklab, var(--surface-light-10) calc(100% - var(--a63-surface-tint)), var(--a63-brand-500) var(--a63-surface-tint) )"
|
|
16892
|
+
},
|
|
16893
|
+
{
|
|
16894
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16895
|
+
"value": "var( --a63-if-light, color-mix( in oklab, var(--surface-light-10) calc(100% - var(--a63-surface-tint)), var(--a63-brand-500) var(--a63-surface-tint) ) ) var( --a63-if-dark, color-mix( in oklab, var(--surface-dark-9) calc(100% - var(--a63-surface-tint)), var(--a63-brand-500) var(--a63-surface-tint) ) )"
|
|
16320
16896
|
}
|
|
16321
16897
|
]
|
|
16322
16898
|
},
|
|
@@ -16338,6 +16914,10 @@
|
|
|
16338
16914
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
16339
16915
|
"value": "color-mix(in oklch, var(--a63-action-primary) 22%, transparent)"
|
|
16340
16916
|
},
|
|
16917
|
+
{
|
|
16918
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
16919
|
+
"value": "var( --a63-if-light, color-mix( in oklab, var(--a63-action-primary) 16%, color-mix(in oklab, var(--surface-light-6) 50%, white) ) ) var(--a63-if-dark, color-mix(in oklch, var(--a63-action-primary) 22%, transparent))"
|
|
16920
|
+
},
|
|
16341
16921
|
{
|
|
16342
16922
|
"scope": ":is(.dark, [data-a63-mode='dark'])",
|
|
16343
16923
|
"value": "color-mix( in oklab, var(--surface-dark-6) calc(100% - var(--a63-surface-tint)), var(--a63-brand-600) var(--a63-surface-tint) )"
|
|
@@ -16345,6 +16925,10 @@
|
|
|
16345
16925
|
{
|
|
16346
16926
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16347
16927
|
"value": "color-mix( in oklab, var(--surface-light-4) calc(100% - var(--a63-surface-tint)), var(--a63-brand-300) var(--a63-surface-tint) )"
|
|
16928
|
+
},
|
|
16929
|
+
{
|
|
16930
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
16931
|
+
"value": "var( --a63-if-light, color-mix( in oklab, var(--surface-light-4) calc(100% - var(--a63-surface-tint)), var(--a63-brand-300) var(--a63-surface-tint) ) ) var( --a63-if-dark, color-mix( in oklab, var(--surface-dark-6) calc(100% - var(--a63-surface-tint)), var(--a63-brand-600) var(--a63-surface-tint) ) )"
|
|
16348
16932
|
}
|
|
16349
16933
|
]
|
|
16350
16934
|
},
|
|
@@ -16869,6 +17453,10 @@
|
|
|
16869
17453
|
{
|
|
16870
17454
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16871
17455
|
"value": "var(--color-warning-800)"
|
|
17456
|
+
},
|
|
17457
|
+
{
|
|
17458
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
17459
|
+
"value": "var(--a63-if-light, var(--color-warning-800)) var(--a63-if-dark, var(--color-warning-400))"
|
|
16872
17460
|
}
|
|
16873
17461
|
]
|
|
16874
17462
|
},
|
|
@@ -16921,6 +17509,10 @@
|
|
|
16921
17509
|
{
|
|
16922
17510
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16923
17511
|
"value": "var(--color-blue-700)"
|
|
17512
|
+
},
|
|
17513
|
+
{
|
|
17514
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
17515
|
+
"value": "var(--a63-if-light, var(--color-blue-700)) var(--a63-if-dark, var(--color-blue-400))"
|
|
16924
17516
|
}
|
|
16925
17517
|
]
|
|
16926
17518
|
},
|
|
@@ -16973,6 +17565,10 @@
|
|
|
16973
17565
|
{
|
|
16974
17566
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
16975
17567
|
"value": "var(--color-cyan-800)"
|
|
17568
|
+
},
|
|
17569
|
+
{
|
|
17570
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
17571
|
+
"value": "var(--a63-if-light, var(--color-cyan-800)) var(--a63-if-dark, var(--color-cyan-400))"
|
|
16976
17572
|
}
|
|
16977
17573
|
]
|
|
16978
17574
|
},
|
|
@@ -17025,6 +17621,10 @@
|
|
|
17025
17621
|
{
|
|
17026
17622
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17027
17623
|
"value": "var(--color-emerald-800)"
|
|
17624
|
+
},
|
|
17625
|
+
{
|
|
17626
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
17627
|
+
"value": "var(--a63-if-light, var(--color-emerald-800)) var(--a63-if-dark, var(--color-emerald-400))"
|
|
17028
17628
|
}
|
|
17029
17629
|
]
|
|
17030
17630
|
},
|
|
@@ -17077,6 +17677,10 @@
|
|
|
17077
17677
|
{
|
|
17078
17678
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17079
17679
|
"value": "var(--color-fuchsia-700)"
|
|
17680
|
+
},
|
|
17681
|
+
{
|
|
17682
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
17683
|
+
"value": "var(--a63-if-light, var(--color-fuchsia-700)) var(--a63-if-dark, var(--color-fuchsia-400))"
|
|
17080
17684
|
}
|
|
17081
17685
|
]
|
|
17082
17686
|
},
|
|
@@ -17129,6 +17733,10 @@
|
|
|
17129
17733
|
{
|
|
17130
17734
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17131
17735
|
"value": "var(--color-gray-700)"
|
|
17736
|
+
},
|
|
17737
|
+
{
|
|
17738
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
17739
|
+
"value": "var(--a63-if-light, var(--color-gray-700)) var(--a63-if-dark, var(--color-gray-400))"
|
|
17132
17740
|
}
|
|
17133
17741
|
]
|
|
17134
17742
|
},
|
|
@@ -17181,6 +17789,10 @@
|
|
|
17181
17789
|
{
|
|
17182
17790
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17183
17791
|
"value": "var(--color-green-800)"
|
|
17792
|
+
},
|
|
17793
|
+
{
|
|
17794
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
17795
|
+
"value": "var(--a63-if-light, var(--color-green-800)) var(--a63-if-dark, var(--color-green-400))"
|
|
17184
17796
|
}
|
|
17185
17797
|
]
|
|
17186
17798
|
},
|
|
@@ -17233,6 +17845,10 @@
|
|
|
17233
17845
|
{
|
|
17234
17846
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17235
17847
|
"value": "var(--color-indigo-700)"
|
|
17848
|
+
},
|
|
17849
|
+
{
|
|
17850
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
17851
|
+
"value": "var(--a63-if-light, var(--color-indigo-700)) var(--a63-if-dark, var(--color-indigo-400))"
|
|
17236
17852
|
}
|
|
17237
17853
|
]
|
|
17238
17854
|
},
|
|
@@ -17285,6 +17901,10 @@
|
|
|
17285
17901
|
{
|
|
17286
17902
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17287
17903
|
"value": "var(--color-lime-800)"
|
|
17904
|
+
},
|
|
17905
|
+
{
|
|
17906
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
17907
|
+
"value": "var(--a63-if-light, var(--color-lime-800)) var(--a63-if-dark, var(--color-lime-400))"
|
|
17288
17908
|
}
|
|
17289
17909
|
]
|
|
17290
17910
|
},
|
|
@@ -17337,6 +17957,10 @@
|
|
|
17337
17957
|
{
|
|
17338
17958
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17339
17959
|
"value": "var(--color-neutral-700)"
|
|
17960
|
+
},
|
|
17961
|
+
{
|
|
17962
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
17963
|
+
"value": "var(--a63-if-light, var(--color-neutral-700)) var(--a63-if-dark, var(--color-neutral-400))"
|
|
17340
17964
|
}
|
|
17341
17965
|
]
|
|
17342
17966
|
},
|
|
@@ -17389,6 +18013,10 @@
|
|
|
17389
18013
|
{
|
|
17390
18014
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17391
18015
|
"value": "var(--color-orange-800)"
|
|
18016
|
+
},
|
|
18017
|
+
{
|
|
18018
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18019
|
+
"value": "var(--a63-if-light, var(--color-orange-800)) var(--a63-if-dark, var(--color-orange-400))"
|
|
17392
18020
|
}
|
|
17393
18021
|
]
|
|
17394
18022
|
},
|
|
@@ -17441,6 +18069,10 @@
|
|
|
17441
18069
|
{
|
|
17442
18070
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17443
18071
|
"value": "var(--color-pink-700)"
|
|
18072
|
+
},
|
|
18073
|
+
{
|
|
18074
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18075
|
+
"value": "var(--a63-if-light, var(--color-pink-700)) var(--a63-if-dark, var(--color-pink-400))"
|
|
17444
18076
|
}
|
|
17445
18077
|
]
|
|
17446
18078
|
},
|
|
@@ -17493,6 +18125,10 @@
|
|
|
17493
18125
|
{
|
|
17494
18126
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17495
18127
|
"value": "var(--color-purple-700)"
|
|
18128
|
+
},
|
|
18129
|
+
{
|
|
18130
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18131
|
+
"value": "var(--a63-if-light, var(--color-purple-700)) var(--a63-if-dark, var(--color-purple-400))"
|
|
17496
18132
|
}
|
|
17497
18133
|
]
|
|
17498
18134
|
},
|
|
@@ -17545,6 +18181,10 @@
|
|
|
17545
18181
|
{
|
|
17546
18182
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17547
18183
|
"value": "var(--color-red-700)"
|
|
18184
|
+
},
|
|
18185
|
+
{
|
|
18186
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18187
|
+
"value": "var(--a63-if-light, var(--color-red-700)) var(--a63-if-dark, var(--color-red-400))"
|
|
17548
18188
|
}
|
|
17549
18189
|
]
|
|
17550
18190
|
},
|
|
@@ -17597,6 +18237,10 @@
|
|
|
17597
18237
|
{
|
|
17598
18238
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17599
18239
|
"value": "var(--color-rose-700)"
|
|
18240
|
+
},
|
|
18241
|
+
{
|
|
18242
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18243
|
+
"value": "var(--a63-if-light, var(--color-rose-700)) var(--a63-if-dark, var(--color-rose-400))"
|
|
17600
18244
|
}
|
|
17601
18245
|
]
|
|
17602
18246
|
},
|
|
@@ -17649,6 +18293,10 @@
|
|
|
17649
18293
|
{
|
|
17650
18294
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17651
18295
|
"value": "var(--color-sky-700)"
|
|
18296
|
+
},
|
|
18297
|
+
{
|
|
18298
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18299
|
+
"value": "var(--a63-if-light, var(--color-sky-700)) var(--a63-if-dark, var(--color-sky-400))"
|
|
17652
18300
|
}
|
|
17653
18301
|
]
|
|
17654
18302
|
},
|
|
@@ -17701,6 +18349,10 @@
|
|
|
17701
18349
|
{
|
|
17702
18350
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17703
18351
|
"value": "var(--color-slate-700)"
|
|
18352
|
+
},
|
|
18353
|
+
{
|
|
18354
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18355
|
+
"value": "var(--a63-if-light, var(--color-slate-700)) var(--a63-if-dark, var(--color-slate-400))"
|
|
17704
18356
|
}
|
|
17705
18357
|
]
|
|
17706
18358
|
},
|
|
@@ -17753,6 +18405,10 @@
|
|
|
17753
18405
|
{
|
|
17754
18406
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17755
18407
|
"value": "var(--color-stone-700)"
|
|
18408
|
+
},
|
|
18409
|
+
{
|
|
18410
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18411
|
+
"value": "var(--a63-if-light, var(--color-stone-700)) var(--a63-if-dark, var(--color-stone-400))"
|
|
17756
18412
|
}
|
|
17757
18413
|
]
|
|
17758
18414
|
},
|
|
@@ -17805,6 +18461,10 @@
|
|
|
17805
18461
|
{
|
|
17806
18462
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17807
18463
|
"value": "var(--color-teal-800)"
|
|
18464
|
+
},
|
|
18465
|
+
{
|
|
18466
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18467
|
+
"value": "var(--a63-if-light, var(--color-teal-800)) var(--a63-if-dark, var(--color-teal-400))"
|
|
17808
18468
|
}
|
|
17809
18469
|
]
|
|
17810
18470
|
},
|
|
@@ -17857,6 +18517,10 @@
|
|
|
17857
18517
|
{
|
|
17858
18518
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17859
18519
|
"value": "var(--color-violet-700)"
|
|
18520
|
+
},
|
|
18521
|
+
{
|
|
18522
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18523
|
+
"value": "var(--a63-if-light, var(--color-violet-700)) var(--a63-if-dark, var(--color-violet-400))"
|
|
17860
18524
|
}
|
|
17861
18525
|
]
|
|
17862
18526
|
},
|
|
@@ -17909,6 +18573,10 @@
|
|
|
17909
18573
|
{
|
|
17910
18574
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17911
18575
|
"value": "var(--color-yellow-800)"
|
|
18576
|
+
},
|
|
18577
|
+
{
|
|
18578
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18579
|
+
"value": "var(--a63-if-light, var(--color-yellow-800)) var(--a63-if-dark, var(--color-yellow-400))"
|
|
17912
18580
|
}
|
|
17913
18581
|
]
|
|
17914
18582
|
},
|
|
@@ -17961,6 +18629,10 @@
|
|
|
17961
18629
|
{
|
|
17962
18630
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17963
18631
|
"value": "var(--color-zinc-700)"
|
|
18632
|
+
},
|
|
18633
|
+
{
|
|
18634
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18635
|
+
"value": "var(--a63-if-light, var(--color-zinc-700)) var(--a63-if-dark, var(--color-zinc-400))"
|
|
17964
18636
|
}
|
|
17965
18637
|
]
|
|
17966
18638
|
},
|
|
@@ -17981,6 +18653,10 @@
|
|
|
17981
18653
|
{
|
|
17982
18654
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
17983
18655
|
"value": "var(--a63-action-primary)"
|
|
18656
|
+
},
|
|
18657
|
+
{
|
|
18658
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18659
|
+
"value": "var(--a63-action-primary)"
|
|
17984
18660
|
}
|
|
17985
18661
|
]
|
|
17986
18662
|
},
|
|
@@ -18001,6 +18677,10 @@
|
|
|
18001
18677
|
{
|
|
18002
18678
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
18003
18679
|
"value": "var(--color-teal-500)"
|
|
18680
|
+
},
|
|
18681
|
+
{
|
|
18682
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18683
|
+
"value": "var(--a63-if-light, var(--color-teal-500)) var(--a63-if-dark, var(--color-teal-400))"
|
|
18004
18684
|
}
|
|
18005
18685
|
]
|
|
18006
18686
|
},
|
|
@@ -18021,6 +18701,10 @@
|
|
|
18021
18701
|
{
|
|
18022
18702
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
18023
18703
|
"value": "var(--color-amber-500)"
|
|
18704
|
+
},
|
|
18705
|
+
{
|
|
18706
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18707
|
+
"value": "var(--a63-if-light, var(--color-amber-500)) var(--a63-if-dark, var(--color-amber-400))"
|
|
18024
18708
|
}
|
|
18025
18709
|
]
|
|
18026
18710
|
},
|
|
@@ -18041,6 +18725,10 @@
|
|
|
18041
18725
|
{
|
|
18042
18726
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
18043
18727
|
"value": "var(--color-violet-500)"
|
|
18728
|
+
},
|
|
18729
|
+
{
|
|
18730
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18731
|
+
"value": "var(--a63-if-light, var(--color-violet-500)) var(--a63-if-dark, var(--color-violet-400))"
|
|
18044
18732
|
}
|
|
18045
18733
|
]
|
|
18046
18734
|
},
|
|
@@ -18061,6 +18749,10 @@
|
|
|
18061
18749
|
{
|
|
18062
18750
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
18063
18751
|
"value": "var(--color-rose-500)"
|
|
18752
|
+
},
|
|
18753
|
+
{
|
|
18754
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18755
|
+
"value": "var(--a63-if-light, var(--color-rose-500)) var(--a63-if-dark, var(--color-rose-400))"
|
|
18064
18756
|
}
|
|
18065
18757
|
]
|
|
18066
18758
|
},
|
|
@@ -18153,6 +18845,10 @@
|
|
|
18153
18845
|
{
|
|
18154
18846
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
18155
18847
|
"value": "color-mix( in oklch, var(--a63-action-primary) 5%, transparent )"
|
|
18848
|
+
},
|
|
18849
|
+
{
|
|
18850
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18851
|
+
"value": "var( --a63-if-light, color-mix(in oklch, var(--a63-action-primary) 5%, transparent) ) var(--a63-if-dark, color-mix(in oklch, var(--a63-action-primary) 10%, transparent))"
|
|
18156
18852
|
}
|
|
18157
18853
|
]
|
|
18158
18854
|
},
|
|
@@ -18173,6 +18869,10 @@
|
|
|
18173
18869
|
{
|
|
18174
18870
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
18175
18871
|
"value": "color-mix(in oklch, var(--a63-action-primary) 30%, transparent)"
|
|
18872
|
+
},
|
|
18873
|
+
{
|
|
18874
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
18875
|
+
"value": "var( --a63-if-light, color-mix(in oklch, var(--a63-action-primary) 30%, transparent) ) var(--a63-if-dark, color-mix(in oklch, var(--a63-action-primary) 20%, transparent))"
|
|
18176
18876
|
}
|
|
18177
18877
|
]
|
|
18178
18878
|
},
|
|
@@ -19156,6 +19856,10 @@
|
|
|
19156
19856
|
{
|
|
19157
19857
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
19158
19858
|
"value": "var(--a63-surface-panel)"
|
|
19859
|
+
},
|
|
19860
|
+
{
|
|
19861
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
19862
|
+
"value": "var(--a63-if-light, var(--a63-surface-panel)) var(--a63-if-dark, color-mix(in oklab, var(--a63-border-control) 32%, transparent))"
|
|
19159
19863
|
}
|
|
19160
19864
|
]
|
|
19161
19865
|
},
|
|
@@ -19176,6 +19880,10 @@
|
|
|
19176
19880
|
{
|
|
19177
19881
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
19178
19882
|
"value": "color-mix( in oklab, var(--a63-surface-control-hover) 50%, transparent )"
|
|
19883
|
+
},
|
|
19884
|
+
{
|
|
19885
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
19886
|
+
"value": "var( --a63-if-light, color-mix(in oklab, var(--a63-surface-control-hover) 50%, transparent) ) var(--a63-if-dark, color-mix(in oklab, var(--a63-border-control) 64%, transparent))"
|
|
19179
19887
|
}
|
|
19180
19888
|
]
|
|
19181
19889
|
},
|
|
@@ -19196,6 +19904,10 @@
|
|
|
19196
19904
|
{
|
|
19197
19905
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
19198
19906
|
"value": "var(--a63-border-subtle)"
|
|
19907
|
+
},
|
|
19908
|
+
{
|
|
19909
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
19910
|
+
"value": "var(--a63-if-light, var(--a63-border-subtle)) var(--a63-if-dark, var(--a63-border-control))"
|
|
19199
19911
|
}
|
|
19200
19912
|
]
|
|
19201
19913
|
},
|
|
@@ -19569,6 +20281,10 @@
|
|
|
19569
20281
|
{
|
|
19570
20282
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
19571
20283
|
"value": "color-mix(in oklab, var(--surface-dark-1) 90%, var(--a63-action-primary))"
|
|
20284
|
+
},
|
|
20285
|
+
{
|
|
20286
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
20287
|
+
"value": "var( --a63-if-light, color-mix(in oklab, var(--surface-light-2) 86%, var(--a63-action-primary)) ) var(--a63-if-dark, color-mix(in oklab, var(--surface-dark-1) 90%, var(--a63-action-primary)))"
|
|
19572
20288
|
}
|
|
19573
20289
|
]
|
|
19574
20290
|
},
|
|
@@ -19621,6 +20337,10 @@
|
|
|
19621
20337
|
{
|
|
19622
20338
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
19623
20339
|
"value": "var(--a63-brand-600)"
|
|
20340
|
+
},
|
|
20341
|
+
{
|
|
20342
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
20343
|
+
"value": "var(--a63-if-light, var(--a63-brand-600)) var(--a63-if-dark, var(--a63-brand-400))"
|
|
19624
20344
|
}
|
|
19625
20345
|
]
|
|
19626
20346
|
},
|
|
@@ -19656,6 +20376,38 @@
|
|
|
19656
20376
|
}
|
|
19657
20377
|
]
|
|
19658
20378
|
},
|
|
20379
|
+
{
|
|
20380
|
+
"cssVar": "--a63-font-display",
|
|
20381
|
+
"figma": {
|
|
20382
|
+
"collection": "Semantic",
|
|
20383
|
+
"path": "font/display"
|
|
20384
|
+
},
|
|
20385
|
+
"layer": "semantic",
|
|
20386
|
+
"swift": null,
|
|
20387
|
+
"type": "typography",
|
|
20388
|
+
"values": [
|
|
20389
|
+
{
|
|
20390
|
+
"scope": ":root",
|
|
20391
|
+
"value": "var(--a63-font-app)"
|
|
20392
|
+
},
|
|
20393
|
+
{
|
|
20394
|
+
"scope": "[data-a63-font='mono']",
|
|
20395
|
+
"value": "var(--a63-font-app)"
|
|
20396
|
+
},
|
|
20397
|
+
{
|
|
20398
|
+
"scope": "[data-a63-font='pixel']",
|
|
20399
|
+
"value": "var(--a63-font-app)"
|
|
20400
|
+
},
|
|
20401
|
+
{
|
|
20402
|
+
"scope": "[data-a63-font='sans']",
|
|
20403
|
+
"value": "var(--a63-font-app)"
|
|
20404
|
+
},
|
|
20405
|
+
{
|
|
20406
|
+
"scope": "[data-a63-font='serif']",
|
|
20407
|
+
"value": "var(--a63-font-app)"
|
|
20408
|
+
}
|
|
20409
|
+
]
|
|
20410
|
+
},
|
|
19659
20411
|
{
|
|
19660
20412
|
"cssVar": "--a63-gradient-brand",
|
|
19661
20413
|
"figma": {
|
|
@@ -19689,6 +20441,10 @@
|
|
|
19689
20441
|
{
|
|
19690
20442
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
19691
20443
|
"value": "linear-gradient( to bottom, var(--a63-brand-800), var(--a63-brand-700) var(--a63-gradient-brand-fade-dark-zone), var(--a63-surface-page) )"
|
|
20444
|
+
},
|
|
20445
|
+
{
|
|
20446
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
20447
|
+
"value": "linear-gradient( to bottom, var(--a63-brand-800), var(--a63-brand-700) var(--a63-gradient-brand-fade-dark-zone), var(--a63-surface-page) )"
|
|
19692
20448
|
}
|
|
19693
20449
|
]
|
|
19694
20450
|
},
|
|
@@ -19737,6 +20493,40 @@
|
|
|
19737
20493
|
}
|
|
19738
20494
|
]
|
|
19739
20495
|
},
|
|
20496
|
+
{
|
|
20497
|
+
"cssVar": "--a63-if-dark",
|
|
20498
|
+
"figma": null,
|
|
20499
|
+
"layer": "semantic",
|
|
20500
|
+
"swift": null,
|
|
20501
|
+
"type": "string",
|
|
20502
|
+
"values": [
|
|
20503
|
+
{
|
|
20504
|
+
"scope": ":is(.dark, [data-a63-mode='dark'])",
|
|
20505
|
+
"value": "initial"
|
|
20506
|
+
},
|
|
20507
|
+
{
|
|
20508
|
+
"scope": ":root, .light, [data-a63-mode='light']",
|
|
20509
|
+
"value": ""
|
|
20510
|
+
}
|
|
20511
|
+
]
|
|
20512
|
+
},
|
|
20513
|
+
{
|
|
20514
|
+
"cssVar": "--a63-if-light",
|
|
20515
|
+
"figma": null,
|
|
20516
|
+
"layer": "semantic",
|
|
20517
|
+
"swift": null,
|
|
20518
|
+
"type": "string",
|
|
20519
|
+
"values": [
|
|
20520
|
+
{
|
|
20521
|
+
"scope": ":is(.dark, [data-a63-mode='dark'])",
|
|
20522
|
+
"value": ""
|
|
20523
|
+
},
|
|
20524
|
+
{
|
|
20525
|
+
"scope": ":root, .light, [data-a63-mode='light']",
|
|
20526
|
+
"value": "initial"
|
|
20527
|
+
}
|
|
20528
|
+
]
|
|
20529
|
+
},
|
|
19740
20530
|
{
|
|
19741
20531
|
"cssVar": "--a63-inset-group-radius",
|
|
19742
20532
|
"figma": {
|
|
@@ -20923,6 +21713,10 @@
|
|
|
20923
21713
|
"scope": "[data-a63-theme='aqua']:is(.dark, [data-a63-mode='dark'])",
|
|
20924
21714
|
"value": "linear-gradient( 180deg, color-mix(in oklch, white 8%, transparent) 0%, color-mix(in oklch, white 2%, transparent) 48%, color-mix(in oklch, black 14%, transparent) 100% ), linear-gradient( 180deg, color-mix(in oklch, var(--a63-surface-panel) 88%, white) 0%, var(--a63-surface-muted) 100% )"
|
|
20925
21715
|
},
|
|
21716
|
+
{
|
|
21717
|
+
"scope": "[data-a63-theme='aqua']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='aqua'] :is([data-a63-brand], [data-a63-surface])",
|
|
21718
|
+
"value": "var( --a63-if-light, linear-gradient( 180deg, color-mix(in oklch, white 10%, transparent) 0%, color-mix(in oklch, white 4%, transparent) 46%, color-mix(in oklch, black 6%, transparent) 54%, color-mix(in oklch, white 2%, transparent) 100% ), linear-gradient(180deg, var(--a63-surface-panel) 0%, var(--a63-surface-muted) 100%) ) var( --a63-if-dark, linear-gradient( 180deg, color-mix(in oklch, white 8%, transparent) 0%, color-mix(in oklch, white 2%, transparent) 48%, color-mix(in oklch, black 14%, transparent) 100% ), linear-gradient( 180deg, color-mix(in oklch, var(--a63-surface-panel) 88%, white) 0%, var(--a63-surface-muted) 100% ) )"
|
|
21719
|
+
},
|
|
20926
21720
|
{
|
|
20927
21721
|
"scope": "[data-a63-theme='modern']",
|
|
20928
21722
|
"value": "none"
|
|
@@ -21027,6 +21821,10 @@
|
|
|
21027
21821
|
"scope": "[data-a63-theme='aqua']:is(.dark, [data-a63-mode='dark'])",
|
|
21028
21822
|
"value": "inset 0 1px 0 color-mix(in oklch, white 22%, transparent), inset 0 3px 10px color-mix(in oklch, black 42%, transparent)"
|
|
21029
21823
|
},
|
|
21824
|
+
{
|
|
21825
|
+
"scope": "[data-a63-theme='aqua']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='aqua'] :is([data-a63-brand], [data-a63-surface])",
|
|
21826
|
+
"value": "var( --a63-if-light, inset 0 1px 0 color-mix(in oklch, white 28%, transparent), inset 0 2px 8px color-mix(in oklch, black 36%, transparent) ) var( --a63-if-dark, inset 0 1px 0 color-mix(in oklch, white 22%, transparent), inset 0 3px 10px color-mix(in oklch, black 42%, transparent) )"
|
|
21827
|
+
},
|
|
21030
21828
|
{
|
|
21031
21829
|
"scope": "[data-a63-theme='modern']",
|
|
21032
21830
|
"value": "inset 0 1px 0 color-mix(in oklch, white 30%, transparent), 0 1px 2px color-mix(in oklch, black 16%, transparent)"
|
|
@@ -21144,6 +21942,10 @@
|
|
|
21144
21942
|
"scope": "[data-a63-theme='aqua']:is(.dark, [data-a63-mode='dark'])",
|
|
21145
21943
|
"value": "inset 0 1px 0 color-mix(in oklch, white 22%, transparent), inset 0 3px 8px color-mix(in oklch, black 28%, transparent)"
|
|
21146
21944
|
},
|
|
21945
|
+
{
|
|
21946
|
+
"scope": "[data-a63-theme='aqua']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='aqua'] :is([data-a63-brand], [data-a63-surface])",
|
|
21947
|
+
"value": "var( --a63-if-light, inset 0 1px 0 color-mix(in oklch, white 35%, transparent), inset 0 2px 6px color-mix(in oklch, black 14%, transparent) ) var( --a63-if-dark, inset 0 1px 0 color-mix(in oklch, white 22%, transparent), inset 0 3px 8px color-mix(in oklch, black 28%, transparent) )"
|
|
21948
|
+
},
|
|
21147
21949
|
{
|
|
21148
21950
|
"scope": "[data-a63-theme='modern']",
|
|
21149
21951
|
"value": "inset 0 1px 0 color-mix(in oklch, white 70%, transparent), 0 1px 2px color-mix(in oklch, black 12%, transparent), 0 1px 1px color-mix(in oklch, black 6%, transparent)"
|
|
@@ -21260,6 +22062,10 @@
|
|
|
21260
22062
|
{
|
|
21261
22063
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21262
22064
|
"value": "color-mix(in oklch, var(--a63-action-primary) 12%, transparent)"
|
|
22065
|
+
},
|
|
22066
|
+
{
|
|
22067
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22068
|
+
"value": "color-mix(in oklch, var(--a63-action-primary) 12%, transparent)"
|
|
21263
22069
|
}
|
|
21264
22070
|
]
|
|
21265
22071
|
},
|
|
@@ -21280,6 +22086,10 @@
|
|
|
21280
22086
|
{
|
|
21281
22087
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21282
22088
|
"value": "var(--a63-text-accent)"
|
|
22089
|
+
},
|
|
22090
|
+
{
|
|
22091
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22092
|
+
"value": "var(--a63-text-accent)"
|
|
21283
22093
|
}
|
|
21284
22094
|
]
|
|
21285
22095
|
},
|
|
@@ -21300,6 +22110,10 @@
|
|
|
21300
22110
|
{
|
|
21301
22111
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21302
22112
|
"value": "var(--a63-surface-muted)"
|
|
22113
|
+
},
|
|
22114
|
+
{
|
|
22115
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22116
|
+
"value": "var(--a63-surface-muted)"
|
|
21303
22117
|
}
|
|
21304
22118
|
]
|
|
21305
22119
|
},
|
|
@@ -21320,6 +22134,10 @@
|
|
|
21320
22134
|
{
|
|
21321
22135
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21322
22136
|
"value": "var(--a63-text-primary)"
|
|
22137
|
+
},
|
|
22138
|
+
{
|
|
22139
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22140
|
+
"value": "var(--a63-text-primary)"
|
|
21323
22141
|
}
|
|
21324
22142
|
]
|
|
21325
22143
|
},
|
|
@@ -21388,6 +22206,10 @@
|
|
|
21388
22206
|
{
|
|
21389
22207
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21390
22208
|
"value": "var(--a63-surface-muted)"
|
|
22209
|
+
},
|
|
22210
|
+
{
|
|
22211
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22212
|
+
"value": "var(--a63-surface-muted)"
|
|
21391
22213
|
}
|
|
21392
22214
|
]
|
|
21393
22215
|
},
|
|
@@ -21408,6 +22230,10 @@
|
|
|
21408
22230
|
{
|
|
21409
22231
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21410
22232
|
"value": "var(--color-white-60)"
|
|
22233
|
+
},
|
|
22234
|
+
{
|
|
22235
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22236
|
+
"value": "var(--a63-if-light, var(--color-white-60)) var(--a63-if-dark, var(--color-white-10))"
|
|
21411
22237
|
}
|
|
21412
22238
|
]
|
|
21413
22239
|
},
|
|
@@ -21652,6 +22478,10 @@
|
|
|
21652
22478
|
{
|
|
21653
22479
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21654
22480
|
"value": "var(--color-danger-600)"
|
|
22481
|
+
},
|
|
22482
|
+
{
|
|
22483
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22484
|
+
"value": "var(--a63-if-light, var(--color-danger-600)) var(--a63-if-dark, var(--color-danger-500))"
|
|
21655
22485
|
}
|
|
21656
22486
|
]
|
|
21657
22487
|
},
|
|
@@ -21668,6 +22498,10 @@
|
|
|
21668
22498
|
{
|
|
21669
22499
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21670
22500
|
"value": "oklch( from var(--a63-status-danger) clamp(0.15, (0.57 - l) * 1000, 0.985) calc(c * 0.06) h )"
|
|
22501
|
+
},
|
|
22502
|
+
{
|
|
22503
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22504
|
+
"value": "oklch( from var(--a63-status-danger) clamp(0.15, (0.57 - l) * 1000, 0.985) calc(c * 0.06) h )"
|
|
21671
22505
|
}
|
|
21672
22506
|
]
|
|
21673
22507
|
},
|
|
@@ -21688,6 +22522,10 @@
|
|
|
21688
22522
|
{
|
|
21689
22523
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21690
22524
|
"value": "color-mix(in oklab, var(--a63-status-danger) 14%, transparent)"
|
|
22525
|
+
},
|
|
22526
|
+
{
|
|
22527
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22528
|
+
"value": "color-mix(in oklab, var(--a63-status-danger) 14%, transparent)"
|
|
21691
22529
|
}
|
|
21692
22530
|
]
|
|
21693
22531
|
},
|
|
@@ -21708,6 +22546,10 @@
|
|
|
21708
22546
|
{
|
|
21709
22547
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21710
22548
|
"value": "var(--color-danger-700)"
|
|
22549
|
+
},
|
|
22550
|
+
{
|
|
22551
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22552
|
+
"value": "var(--a63-if-light, var(--color-danger-700)) var(--a63-if-dark, var(--color-danger-400))"
|
|
21711
22553
|
}
|
|
21712
22554
|
]
|
|
21713
22555
|
},
|
|
@@ -21728,6 +22570,10 @@
|
|
|
21728
22570
|
{
|
|
21729
22571
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21730
22572
|
"value": "var(--color-info-600)"
|
|
22573
|
+
},
|
|
22574
|
+
{
|
|
22575
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22576
|
+
"value": "var(--a63-if-light, var(--color-info-600)) var(--a63-if-dark, var(--color-info-500))"
|
|
21731
22577
|
}
|
|
21732
22578
|
]
|
|
21733
22579
|
},
|
|
@@ -21744,6 +22590,10 @@
|
|
|
21744
22590
|
{
|
|
21745
22591
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21746
22592
|
"value": "oklch( from var(--a63-status-info) clamp(0.15, (0.57 - l) * 1000, 0.985) calc(c * 0.06) h )"
|
|
22593
|
+
},
|
|
22594
|
+
{
|
|
22595
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22596
|
+
"value": "oklch( from var(--a63-status-info) clamp(0.15, (0.57 - l) * 1000, 0.985) calc(c * 0.06) h )"
|
|
21747
22597
|
}
|
|
21748
22598
|
]
|
|
21749
22599
|
},
|
|
@@ -21764,6 +22614,10 @@
|
|
|
21764
22614
|
{
|
|
21765
22615
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21766
22616
|
"value": "color-mix(in oklab, var(--a63-status-info) 14%, transparent)"
|
|
22617
|
+
},
|
|
22618
|
+
{
|
|
22619
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22620
|
+
"value": "color-mix(in oklab, var(--a63-status-info) 14%, transparent)"
|
|
21767
22621
|
}
|
|
21768
22622
|
]
|
|
21769
22623
|
},
|
|
@@ -21784,6 +22638,10 @@
|
|
|
21784
22638
|
{
|
|
21785
22639
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21786
22640
|
"value": "var(--color-info-700)"
|
|
22641
|
+
},
|
|
22642
|
+
{
|
|
22643
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22644
|
+
"value": "var(--a63-if-light, var(--color-info-700)) var(--a63-if-dark, var(--color-info-400))"
|
|
21787
22645
|
}
|
|
21788
22646
|
]
|
|
21789
22647
|
},
|
|
@@ -21804,6 +22662,10 @@
|
|
|
21804
22662
|
{
|
|
21805
22663
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21806
22664
|
"value": "var(--color-success-600)"
|
|
22665
|
+
},
|
|
22666
|
+
{
|
|
22667
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22668
|
+
"value": "var(--a63-if-light, var(--color-success-600)) var(--a63-if-dark, var(--color-success-500))"
|
|
21807
22669
|
}
|
|
21808
22670
|
]
|
|
21809
22671
|
},
|
|
@@ -21820,6 +22682,10 @@
|
|
|
21820
22682
|
{
|
|
21821
22683
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21822
22684
|
"value": "oklch( from var(--a63-status-success) clamp(0.15, (0.57 - l) * 1000, 0.985) calc(c * 0.06) h )"
|
|
22685
|
+
},
|
|
22686
|
+
{
|
|
22687
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22688
|
+
"value": "oklch( from var(--a63-status-success) clamp(0.15, (0.57 - l) * 1000, 0.985) calc(c * 0.06) h )"
|
|
21823
22689
|
}
|
|
21824
22690
|
]
|
|
21825
22691
|
},
|
|
@@ -21840,6 +22706,10 @@
|
|
|
21840
22706
|
{
|
|
21841
22707
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21842
22708
|
"value": "color-mix(in oklab, var(--a63-status-success) 14%, transparent)"
|
|
22709
|
+
},
|
|
22710
|
+
{
|
|
22711
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22712
|
+
"value": "color-mix(in oklab, var(--a63-status-success) 14%, transparent)"
|
|
21843
22713
|
}
|
|
21844
22714
|
]
|
|
21845
22715
|
},
|
|
@@ -21860,6 +22730,10 @@
|
|
|
21860
22730
|
{
|
|
21861
22731
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21862
22732
|
"value": "var(--color-success-700)"
|
|
22733
|
+
},
|
|
22734
|
+
{
|
|
22735
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22736
|
+
"value": "var(--a63-if-light, var(--color-success-700)) var(--a63-if-dark, var(--color-success-400))"
|
|
21863
22737
|
}
|
|
21864
22738
|
]
|
|
21865
22739
|
},
|
|
@@ -21880,6 +22754,10 @@
|
|
|
21880
22754
|
{
|
|
21881
22755
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21882
22756
|
"value": "var(--color-warning-600)"
|
|
22757
|
+
},
|
|
22758
|
+
{
|
|
22759
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22760
|
+
"value": "var(--a63-if-light, var(--color-warning-600)) var(--a63-if-dark, var(--color-warning-500))"
|
|
21883
22761
|
}
|
|
21884
22762
|
]
|
|
21885
22763
|
},
|
|
@@ -21896,6 +22774,10 @@
|
|
|
21896
22774
|
{
|
|
21897
22775
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21898
22776
|
"value": "oklch( from var(--a63-status-warning) clamp(0.15, (0.57 - l) * 1000, 0.985) calc(c * 0.06) h )"
|
|
22777
|
+
},
|
|
22778
|
+
{
|
|
22779
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22780
|
+
"value": "oklch( from var(--a63-status-warning) clamp(0.15, (0.57 - l) * 1000, 0.985) calc(c * 0.06) h )"
|
|
21899
22781
|
}
|
|
21900
22782
|
]
|
|
21901
22783
|
},
|
|
@@ -21916,6 +22798,10 @@
|
|
|
21916
22798
|
{
|
|
21917
22799
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21918
22800
|
"value": "color-mix(in oklab, var(--a63-status-warning) 14%, transparent)"
|
|
22801
|
+
},
|
|
22802
|
+
{
|
|
22803
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22804
|
+
"value": "color-mix(in oklab, var(--a63-status-warning) 14%, transparent)"
|
|
21919
22805
|
}
|
|
21920
22806
|
]
|
|
21921
22807
|
},
|
|
@@ -21936,6 +22822,10 @@
|
|
|
21936
22822
|
{
|
|
21937
22823
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
21938
22824
|
"value": "var(--color-warning-800)"
|
|
22825
|
+
},
|
|
22826
|
+
{
|
|
22827
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22828
|
+
"value": "var(--a63-if-light, var(--color-warning-800)) var(--a63-if-dark, var(--color-warning-400))"
|
|
21939
22829
|
}
|
|
21940
22830
|
]
|
|
21941
22831
|
},
|
|
@@ -22016,6 +22906,10 @@
|
|
|
22016
22906
|
{
|
|
22017
22907
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22018
22908
|
"value": "color-mix( in oklab, var(--surface-light-1) calc(100% - var(--a63-surface-tint)), var(--a63-brand-50) var(--a63-surface-tint) )"
|
|
22909
|
+
},
|
|
22910
|
+
{
|
|
22911
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22912
|
+
"value": "var( --a63-if-light, color-mix( in oklab, var(--surface-light-1) calc(100% - var(--a63-surface-tint)), var(--a63-brand-50) var(--a63-surface-tint) ) ) var( --a63-if-dark, color-mix( in oklab, var(--surface-dark-1) calc(100% - var(--a63-surface-tint)), var(--a63-brand-950) var(--a63-surface-tint) ) )"
|
|
22019
22913
|
}
|
|
22020
22914
|
]
|
|
22021
22915
|
},
|
|
@@ -22036,6 +22930,10 @@
|
|
|
22036
22930
|
{
|
|
22037
22931
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22038
22932
|
"value": "color-mix( in srgb, color-mix( in oklab, var(--surface-light-4) calc(100% - var(--a63-surface-tint)), var(--a63-brand-300) var(--a63-surface-tint) ), transparent 20% )"
|
|
22933
|
+
},
|
|
22934
|
+
{
|
|
22935
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
22936
|
+
"value": "var( --a63-if-light, color-mix( in srgb, color-mix( in oklab, var(--surface-light-4) calc(100% - var(--a63-surface-tint)), var(--a63-brand-300) var(--a63-surface-tint) ), transparent 20% ) ) var( --a63-if-dark, color-mix( in srgb, color-mix( in oklab, var(--surface-dark-6) calc(100% - var(--a63-surface-tint)), var(--a63-brand-600) var(--a63-surface-tint) ), transparent 20% ) )"
|
|
22039
22937
|
}
|
|
22040
22938
|
]
|
|
22041
22939
|
},
|
|
@@ -22132,6 +23030,10 @@
|
|
|
22132
23030
|
{
|
|
22133
23031
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22134
23032
|
"value": "color-mix( in oklab, var(--surface-light-3) calc(100% - var(--a63-surface-tint)), var(--a63-brand-200) var(--a63-surface-tint) )"
|
|
23033
|
+
},
|
|
23034
|
+
{
|
|
23035
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
23036
|
+
"value": "var( --a63-if-light, color-mix( in oklab, var(--surface-light-3) calc(100% - var(--a63-surface-tint)), var(--a63-brand-200) var(--a63-surface-tint) ) ) var( --a63-if-dark, color-mix( in oklab, var(--surface-dark-3) calc(100% - var(--a63-surface-tint)), var(--a63-brand-800) var(--a63-surface-tint) ) )"
|
|
22135
23037
|
}
|
|
22136
23038
|
]
|
|
22137
23039
|
},
|
|
@@ -22152,6 +23054,10 @@
|
|
|
22152
23054
|
{
|
|
22153
23055
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22154
23056
|
"value": "color-mix( in oklab, var(--surface-light-1) calc(100% - var(--a63-surface-tint)), var(--a63-brand-50) var(--a63-surface-tint) )"
|
|
23057
|
+
},
|
|
23058
|
+
{
|
|
23059
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
23060
|
+
"value": "var( --a63-if-light, color-mix( in oklab, var(--surface-light-1) calc(100% - var(--a63-surface-tint)), var(--a63-brand-50) var(--a63-surface-tint) ) ) var( --a63-if-dark, color-mix( in oklab, var(--surface-dark-4) calc(100% - var(--a63-surface-tint)), var(--a63-brand-800) var(--a63-surface-tint) ) )"
|
|
22155
23061
|
}
|
|
22156
23062
|
]
|
|
22157
23063
|
},
|
|
@@ -22173,6 +23079,10 @@
|
|
|
22173
23079
|
"scope": "[data-a63-theme='aqua']:is(.dark, [data-a63-mode='dark'])",
|
|
22174
23080
|
"value": "color-mix(in oklab, var(--surface-dark-1) 94%, var(--color-b1-500))"
|
|
22175
23081
|
},
|
|
23082
|
+
{
|
|
23083
|
+
"scope": "[data-a63-theme='aqua']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='aqua'] :is([data-a63-brand], [data-a63-surface])",
|
|
23084
|
+
"value": "var( --a63-if-light, color-mix(in oklab, var(--surface-light-2) 95%, var(--color-b1-500)) ) var(--a63-if-dark, color-mix(in oklab, var(--surface-dark-1) 94%, var(--color-b1-500)))"
|
|
23085
|
+
},
|
|
22176
23086
|
{
|
|
22177
23087
|
"scope": "[data-a63-theme='terminal']:is(:root, .light, [data-a63-mode='light']), [data-a63-theme='terminal'] :is(.light, [data-a63-mode='light'])",
|
|
22178
23088
|
"value": "color-mix(in oklab, var(--surface-light-1) 60%, white)"
|
|
@@ -22181,6 +23091,10 @@
|
|
|
22181
23091
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
22182
23092
|
"value": "color-mix(in oklab, var(--surface-dark-1) 92%, var(--a63-action-primary))"
|
|
22183
23093
|
},
|
|
23094
|
+
{
|
|
23095
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
23096
|
+
"value": "var(--a63-if-light, color-mix(in oklab, var(--surface-light-1) 60%, white)) var(--a63-if-dark, color-mix(in oklab, var(--surface-dark-1) 92%, var(--a63-action-primary)))"
|
|
23097
|
+
},
|
|
22184
23098
|
{
|
|
22185
23099
|
"scope": ":is(.dark, [data-a63-mode='dark'])",
|
|
22186
23100
|
"value": "color-mix( in oklab, var(--surface-dark-1) calc(100% - var(--a63-surface-tint)), var(--a63-brand-950) var(--a63-surface-tint) )"
|
|
@@ -22188,6 +23102,10 @@
|
|
|
22188
23102
|
{
|
|
22189
23103
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22190
23104
|
"value": "color-mix( in oklab, var(--surface-light-2) calc(100% - var(--a63-surface-tint)), var(--a63-brand-100) var(--a63-surface-tint) )"
|
|
23105
|
+
},
|
|
23106
|
+
{
|
|
23107
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
23108
|
+
"value": "var( --a63-if-light, color-mix( in oklab, var(--surface-light-2) calc(100% - var(--a63-surface-tint)), var(--a63-brand-100) var(--a63-surface-tint) ) ) var( --a63-if-dark, color-mix( in oklab, var(--surface-dark-1) calc(100% - var(--a63-surface-tint)), var(--a63-brand-950) var(--a63-surface-tint) ) )"
|
|
22191
23109
|
}
|
|
22192
23110
|
]
|
|
22193
23111
|
},
|
|
@@ -22209,6 +23127,10 @@
|
|
|
22209
23127
|
"scope": "[data-a63-theme='aqua']:is(.dark, [data-a63-mode='dark'])",
|
|
22210
23128
|
"value": "color-mix(in oklab, var(--surface-dark-2) 94%, var(--color-b1-500))"
|
|
22211
23129
|
},
|
|
23130
|
+
{
|
|
23131
|
+
"scope": "[data-a63-theme='aqua']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='aqua'] :is([data-a63-brand], [data-a63-surface])",
|
|
23132
|
+
"value": "var( --a63-if-light, color-mix(in oklab, var(--surface-light-1) 96%, var(--color-b1-500)) ) var(--a63-if-dark, color-mix(in oklab, var(--surface-dark-2) 94%, var(--color-b1-500)))"
|
|
23133
|
+
},
|
|
22212
23134
|
{
|
|
22213
23135
|
"scope": "[data-a63-theme='terminal']:is(:root, .light, [data-a63-mode='light']), [data-a63-theme='terminal'] :is(.light, [data-a63-mode='light'])",
|
|
22214
23136
|
"value": "color-mix(in oklab, var(--surface-light-2) 60%, white)"
|
|
@@ -22217,6 +23139,10 @@
|
|
|
22217
23139
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
22218
23140
|
"value": "color-mix(in oklab, var(--surface-dark-2) 92%, var(--a63-action-primary))"
|
|
22219
23141
|
},
|
|
23142
|
+
{
|
|
23143
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
23144
|
+
"value": "var(--a63-if-light, color-mix(in oklab, var(--surface-light-2) 60%, white)) var(--a63-if-dark, color-mix(in oklab, var(--surface-dark-2) 92%, var(--a63-action-primary)))"
|
|
23145
|
+
},
|
|
22220
23146
|
{
|
|
22221
23147
|
"scope": ":is(.dark, [data-a63-mode='dark'])",
|
|
22222
23148
|
"value": "color-mix( in oklab, var(--surface-dark-2) calc(100% - var(--a63-surface-tint)), var(--a63-brand-900) var(--a63-surface-tint) )"
|
|
@@ -22224,6 +23150,10 @@
|
|
|
22224
23150
|
{
|
|
22225
23151
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22226
23152
|
"value": "color-mix( in oklab, var(--surface-light-1) calc(100% - var(--a63-surface-tint)), var(--a63-brand-50) var(--a63-surface-tint) )"
|
|
23153
|
+
},
|
|
23154
|
+
{
|
|
23155
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
23156
|
+
"value": "var( --a63-if-light, color-mix( in oklab, var(--surface-light-1) calc(100% - var(--a63-surface-tint)), var(--a63-brand-50) var(--a63-surface-tint) ) ) var( --a63-if-dark, color-mix( in oklab, var(--surface-dark-2) calc(100% - var(--a63-surface-tint)), var(--a63-brand-900) var(--a63-surface-tint) ) )"
|
|
22227
23157
|
}
|
|
22228
23158
|
]
|
|
22229
23159
|
},
|
|
@@ -22272,6 +23202,10 @@
|
|
|
22272
23202
|
{
|
|
22273
23203
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22274
23204
|
"value": "var(--a63-surface-muted)"
|
|
23205
|
+
},
|
|
23206
|
+
{
|
|
23207
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
23208
|
+
"value": "var(--a63-if-light, var(--a63-surface-muted)) var(--a63-if-dark, var(--a63-surface-page))"
|
|
22275
23209
|
}
|
|
22276
23210
|
]
|
|
22277
23211
|
},
|
|
@@ -22320,6 +23254,10 @@
|
|
|
22320
23254
|
{
|
|
22321
23255
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22322
23256
|
"value": "var(--a63-surface-muted)"
|
|
23257
|
+
},
|
|
23258
|
+
{
|
|
23259
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
23260
|
+
"value": "var(--a63-if-light, var(--a63-surface-muted)) var(--a63-if-dark, var(--a63-surface-page))"
|
|
22323
23261
|
}
|
|
22324
23262
|
]
|
|
22325
23263
|
},
|
|
@@ -22440,6 +23378,10 @@
|
|
|
22440
23378
|
{
|
|
22441
23379
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22442
23380
|
"value": "var(--a63-brand-text)"
|
|
23381
|
+
},
|
|
23382
|
+
{
|
|
23383
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
23384
|
+
"value": "var(--a63-if-light, var(--a63-brand-text)) var(--a63-if-dark, var(--a63-brand-400))"
|
|
22443
23385
|
}
|
|
22444
23386
|
]
|
|
22445
23387
|
},
|
|
@@ -22460,6 +23402,10 @@
|
|
|
22460
23402
|
{
|
|
22461
23403
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22462
23404
|
"value": "var(--color-danger-600)"
|
|
23405
|
+
},
|
|
23406
|
+
{
|
|
23407
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
23408
|
+
"value": "var(--a63-if-light, var(--color-danger-600)) var(--a63-if-dark, var(--color-danger-400))"
|
|
22463
23409
|
}
|
|
22464
23410
|
]
|
|
22465
23411
|
},
|
|
@@ -22481,6 +23427,10 @@
|
|
|
22481
23427
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
22482
23428
|
"value": "color-mix(in oklch, var(--a63-action-primary) 62%, white)"
|
|
22483
23429
|
},
|
|
23430
|
+
{
|
|
23431
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
23432
|
+
"value": "var(--a63-if-light, color-mix(in oklch, var(--a63-action-primary) 70%, black)) var(--a63-if-dark, color-mix(in oklch, var(--a63-action-primary) 62%, white))"
|
|
23433
|
+
},
|
|
22484
23434
|
{
|
|
22485
23435
|
"scope": ":is(.dark, [data-a63-mode='dark'])",
|
|
22486
23436
|
"value": "var(--surface-dark-12)"
|
|
@@ -22488,6 +23438,10 @@
|
|
|
22488
23438
|
{
|
|
22489
23439
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22490
23440
|
"value": "var(--surface-light-12)"
|
|
23441
|
+
},
|
|
23442
|
+
{
|
|
23443
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
23444
|
+
"value": "var(--a63-if-light, var(--surface-light-12)) var(--a63-if-dark, var(--surface-dark-12))"
|
|
22491
23445
|
}
|
|
22492
23446
|
]
|
|
22493
23447
|
},
|
|
@@ -22509,6 +23463,10 @@
|
|
|
22509
23463
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
22510
23464
|
"value": "color-mix(in oklab, var(--a63-text-accent) 48%, var(--surface-dark-11))"
|
|
22511
23465
|
},
|
|
23466
|
+
{
|
|
23467
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
23468
|
+
"value": "var( --a63-if-light, color-mix(in oklch, var(--a63-action-primary) 52%, black) ) var(--a63-if-dark, color-mix(in oklab, var(--a63-text-accent) 48%, var(--surface-dark-11)))"
|
|
23469
|
+
},
|
|
22512
23470
|
{
|
|
22513
23471
|
"scope": ":is(.dark, [data-a63-mode='dark'])",
|
|
22514
23472
|
"value": "var(--surface-dark-11)"
|
|
@@ -22516,6 +23474,10 @@
|
|
|
22516
23474
|
{
|
|
22517
23475
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22518
23476
|
"value": "var(--surface-light-11)"
|
|
23477
|
+
},
|
|
23478
|
+
{
|
|
23479
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
23480
|
+
"value": "var(--a63-if-light, var(--surface-light-11)) var(--a63-if-dark, var(--surface-dark-11))"
|
|
22519
23481
|
}
|
|
22520
23482
|
]
|
|
22521
23483
|
},
|
|
@@ -22537,6 +23499,10 @@
|
|
|
22537
23499
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
22538
23500
|
"value": "color-mix(in oklab, var(--a63-text-accent) 40%, var(--surface-dark-10))"
|
|
22539
23501
|
},
|
|
23502
|
+
{
|
|
23503
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
23504
|
+
"value": "var( --a63-if-light, color-mix(in oklch, var(--a63-action-primary) 80%, black) ) var(--a63-if-dark, color-mix(in oklab, var(--a63-text-accent) 40%, var(--surface-dark-10)))"
|
|
23505
|
+
},
|
|
22540
23506
|
{
|
|
22541
23507
|
"scope": ":is(.dark, [data-a63-mode='dark'])",
|
|
22542
23508
|
"value": "color-mix(in oklab, var(--surface-dark-11) 30%, var(--surface-dark-10))"
|
|
@@ -22544,6 +23510,10 @@
|
|
|
22544
23510
|
{
|
|
22545
23511
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22546
23512
|
"value": "color-mix(in oklab, var(--surface-light-11) 70%, var(--surface-light-10))"
|
|
23513
|
+
},
|
|
23514
|
+
{
|
|
23515
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
23516
|
+
"value": "var( --a63-if-light, color-mix(in oklab, var(--surface-light-11) 70%, var(--surface-light-10)) ) var(--a63-if-dark, color-mix(in oklab, var(--surface-dark-11) 30%, var(--surface-dark-10)))"
|
|
22547
23517
|
}
|
|
22548
23518
|
]
|
|
22549
23519
|
},
|
|
@@ -22633,6 +23603,10 @@
|
|
|
22633
23603
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22634
23604
|
"value": "var(--a63-action-neutral)"
|
|
22635
23605
|
},
|
|
23606
|
+
{
|
|
23607
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
23608
|
+
"value": "var(--a63-action-neutral)"
|
|
23609
|
+
},
|
|
22636
23610
|
{
|
|
22637
23611
|
"scope": "[data-a63-theme='terminal']:is(:root, .light, [data-a63-mode='light']), [data-a63-theme='terminal'] :is(.light, [data-a63-mode='light'])",
|
|
22638
23612
|
"value": "var(--a63-text-primary)"
|
|
@@ -22640,6 +23614,10 @@
|
|
|
22640
23614
|
{
|
|
22641
23615
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
22642
23616
|
"value": "var(--a63-text-primary)"
|
|
23617
|
+
},
|
|
23618
|
+
{
|
|
23619
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
23620
|
+
"value": "var(--a63-text-primary)"
|
|
22643
23621
|
}
|
|
22644
23622
|
]
|
|
22645
23623
|
},
|
|
@@ -22661,6 +23639,10 @@
|
|
|
22661
23639
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
22662
23640
|
"value": "var(--a63-action-neutral-foreground)"
|
|
22663
23641
|
},
|
|
23642
|
+
{
|
|
23643
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
23644
|
+
"value": "var(--a63-action-neutral-foreground)"
|
|
23645
|
+
},
|
|
22664
23646
|
{
|
|
22665
23647
|
"scope": "[data-a63-theme='terminal']:is(:root, .light, [data-a63-mode='light']), [data-a63-theme='terminal'] :is(.light, [data-a63-mode='light'])",
|
|
22666
23648
|
"value": "var(--a63-surface-page)"
|
|
@@ -22668,6 +23650,10 @@
|
|
|
22668
23650
|
{
|
|
22669
23651
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
22670
23652
|
"value": "var(--a63-surface-page)"
|
|
23653
|
+
},
|
|
23654
|
+
{
|
|
23655
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
23656
|
+
"value": "var(--a63-surface-page)"
|
|
22671
23657
|
}
|
|
22672
23658
|
]
|
|
22673
23659
|
},
|
|
@@ -23215,6 +24201,86 @@
|
|
|
23215
24201
|
}
|
|
23216
24202
|
]
|
|
23217
24203
|
},
|
|
24204
|
+
{
|
|
24205
|
+
"cssVar": "--a63-type-display-hero-font-size",
|
|
24206
|
+
"figma": {
|
|
24207
|
+
"collection": "Semantic",
|
|
24208
|
+
"path": "type/display/hero/font/size"
|
|
24209
|
+
},
|
|
24210
|
+
"layer": "semantic",
|
|
24211
|
+
"swift": null,
|
|
24212
|
+
"type": "typography",
|
|
24213
|
+
"values": [
|
|
24214
|
+
{
|
|
24215
|
+
"scope": ":root, [data-window-size], [data-a63-form-factor]",
|
|
24216
|
+
"value": "clamp( var(--typography-10xl-font-size), calc(1.5rem + 3.4vw), calc(72px * var(--typography-scale, 1)) )"
|
|
24217
|
+
}
|
|
24218
|
+
]
|
|
24219
|
+
},
|
|
24220
|
+
{
|
|
24221
|
+
"cssVar": "--a63-type-display-hero-font-weight",
|
|
24222
|
+
"figma": {
|
|
24223
|
+
"collection": "Semantic",
|
|
24224
|
+
"path": "type/display/hero/font/weight"
|
|
24225
|
+
},
|
|
24226
|
+
"layer": "semantic",
|
|
24227
|
+
"swift": null,
|
|
24228
|
+
"type": "typography",
|
|
24229
|
+
"values": [
|
|
24230
|
+
{
|
|
24231
|
+
"scope": ":root, [data-window-size], [data-a63-form-factor]",
|
|
24232
|
+
"value": "600"
|
|
24233
|
+
}
|
|
24234
|
+
]
|
|
24235
|
+
},
|
|
24236
|
+
{
|
|
24237
|
+
"cssVar": "--a63-type-display-hero-font-weight-strong",
|
|
24238
|
+
"figma": {
|
|
24239
|
+
"collection": "Semantic",
|
|
24240
|
+
"path": "type/display/hero/font/weight/strong"
|
|
24241
|
+
},
|
|
24242
|
+
"layer": "semantic",
|
|
24243
|
+
"swift": null,
|
|
24244
|
+
"type": "typography",
|
|
24245
|
+
"values": [
|
|
24246
|
+
{
|
|
24247
|
+
"scope": ":root, [data-window-size], [data-a63-form-factor]",
|
|
24248
|
+
"value": "700"
|
|
24249
|
+
}
|
|
24250
|
+
]
|
|
24251
|
+
},
|
|
24252
|
+
{
|
|
24253
|
+
"cssVar": "--a63-type-display-hero-letter-spacing",
|
|
24254
|
+
"figma": {
|
|
24255
|
+
"collection": "Semantic",
|
|
24256
|
+
"path": "type/display/hero/letter/spacing"
|
|
24257
|
+
},
|
|
24258
|
+
"layer": "semantic",
|
|
24259
|
+
"swift": null,
|
|
24260
|
+
"type": "typography",
|
|
24261
|
+
"values": [
|
|
24262
|
+
{
|
|
24263
|
+
"scope": ":root, [data-window-size], [data-a63-form-factor]",
|
|
24264
|
+
"value": "-0.045em"
|
|
24265
|
+
}
|
|
24266
|
+
]
|
|
24267
|
+
},
|
|
24268
|
+
{
|
|
24269
|
+
"cssVar": "--a63-type-display-hero-line-height",
|
|
24270
|
+
"figma": {
|
|
24271
|
+
"collection": "Semantic",
|
|
24272
|
+
"path": "type/display/hero/line/height"
|
|
24273
|
+
},
|
|
24274
|
+
"layer": "semantic",
|
|
24275
|
+
"swift": null,
|
|
24276
|
+
"type": "typography",
|
|
24277
|
+
"values": [
|
|
24278
|
+
{
|
|
24279
|
+
"scope": ":root, [data-window-size], [data-a63-form-factor]",
|
|
24280
|
+
"value": "calc(var(--a63-type-display-hero-font-size) * 1.05)"
|
|
24281
|
+
}
|
|
24282
|
+
]
|
|
24283
|
+
},
|
|
23218
24284
|
{
|
|
23219
24285
|
"cssVar": "--a63-type-display-large-font-size",
|
|
23220
24286
|
"figma": {
|
|
@@ -23263,6 +24329,22 @@
|
|
|
23263
24329
|
}
|
|
23264
24330
|
]
|
|
23265
24331
|
},
|
|
24332
|
+
{
|
|
24333
|
+
"cssVar": "--a63-type-display-large-letter-spacing",
|
|
24334
|
+
"figma": {
|
|
24335
|
+
"collection": "Semantic",
|
|
24336
|
+
"path": "type/display/large/letter/spacing"
|
|
24337
|
+
},
|
|
24338
|
+
"layer": "semantic",
|
|
24339
|
+
"swift": null,
|
|
24340
|
+
"type": "typography",
|
|
24341
|
+
"values": [
|
|
24342
|
+
{
|
|
24343
|
+
"scope": ":root, [data-window-size], [data-a63-form-factor]",
|
|
24344
|
+
"value": "-0.04em"
|
|
24345
|
+
}
|
|
24346
|
+
]
|
|
24347
|
+
},
|
|
23266
24348
|
{
|
|
23267
24349
|
"cssVar": "--a63-type-display-large-line-height",
|
|
23268
24350
|
"figma": {
|
|
@@ -23279,6 +24361,22 @@
|
|
|
23279
24361
|
}
|
|
23280
24362
|
]
|
|
23281
24363
|
},
|
|
24364
|
+
{
|
|
24365
|
+
"cssVar": "--a63-type-display-letter-spacing",
|
|
24366
|
+
"figma": {
|
|
24367
|
+
"collection": "Semantic",
|
|
24368
|
+
"path": "type/display/letter/spacing"
|
|
24369
|
+
},
|
|
24370
|
+
"layer": "semantic",
|
|
24371
|
+
"swift": null,
|
|
24372
|
+
"type": "typography",
|
|
24373
|
+
"values": [
|
|
24374
|
+
{
|
|
24375
|
+
"scope": ":root, [data-window-size], [data-a63-form-factor]",
|
|
24376
|
+
"value": "-0.03em"
|
|
24377
|
+
}
|
|
24378
|
+
]
|
|
24379
|
+
},
|
|
23282
24380
|
{
|
|
23283
24381
|
"cssVar": "--a63-type-display-line-height",
|
|
23284
24382
|
"figma": {
|
|
@@ -23833,6 +24931,10 @@
|
|
|
23833
24931
|
{
|
|
23834
24932
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
23835
24933
|
"value": "color-mix(in oklch, var(--a63-action-primary) 22%, black 78%)"
|
|
24934
|
+
},
|
|
24935
|
+
{
|
|
24936
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
24937
|
+
"value": "var( --a63-if-light, color-mix(in oklch, var(--a63-action-primary) 34%, white 66%) ) var(--a63-if-dark, color-mix(in oklch, var(--a63-action-primary) 22%, black 78%))"
|
|
23836
24938
|
}
|
|
23837
24939
|
]
|
|
23838
24940
|
},
|
|
@@ -23854,6 +24956,10 @@
|
|
|
23854
24956
|
"scope": "[data-a63-theme='aqua']:is(.dark, [data-a63-mode='dark'])",
|
|
23855
24957
|
"value": "radial-gradient( 120% 90% at 10% 0%, color-mix(in oklab, white 18%, transparent), transparent 48% ), radial-gradient( 88% 110% at 100% 0%, color-mix(in oklab, var(--a63-action-primary) 30%, transparent), transparent 58% ), linear-gradient( 135deg, color-mix(in oklab, var(--a63-action-primary) 58%, var(--surface-dark-6) 42%), color-mix(in oklab, var(--a63-action-primary) 36%, var(--surface-dark-3) 64%) )"
|
|
23856
24958
|
},
|
|
24959
|
+
{
|
|
24960
|
+
"scope": "[data-a63-theme='aqua']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='aqua'] :is([data-a63-brand], [data-a63-surface])",
|
|
24961
|
+
"value": "var( --a63-if-light, radial-gradient( 120% 90% at 10% 0%, color-mix(in oklch, white 28%, transparent), transparent 48% ), radial-gradient( 78% 100% at 100% 0%, color-mix(in oklch, var(--a63-action-primary) 32%, transparent), transparent 58% ), linear-gradient( 135deg, color-mix(in oklch, var(--a63-action-primary) 78%, white 10%), color-mix(in oklch, var(--a63-action-primary) 70%, var(--color-b1-900) 30%) ) ) var( --a63-if-dark, radial-gradient( 120% 90% at 10% 0%, color-mix(in oklab, white 18%, transparent), transparent 48% ), radial-gradient( 88% 110% at 100% 0%, color-mix(in oklab, var(--a63-action-primary) 30%, transparent), transparent 58% ), linear-gradient( 135deg, color-mix(in oklab, var(--a63-action-primary) 58%, var(--surface-dark-6) 42%), color-mix(in oklab, var(--a63-action-primary) 36%, var(--surface-dark-3) 64%) ) )"
|
|
24962
|
+
},
|
|
23857
24963
|
{
|
|
23858
24964
|
"scope": "[data-a63-theme='retro']",
|
|
23859
24965
|
"value": "linear-gradient(135deg, color-mix(in oklab, white 22%, transparent), transparent 44%), linear-gradient( 135deg, color-mix(in oklab, var(--a63-action-primary) 58%, var(--a63-surface-panel)), color-mix(in oklab, var(--a63-action-primary) 68%, var(--a63-text-primary)) )"
|
|
@@ -23865,6 +24971,10 @@
|
|
|
23865
24971
|
{
|
|
23866
24972
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
23867
24973
|
"value": "linear-gradient(color-mix(in oklch, var(--a63-action-primary) 12%, transparent), transparent), linear-gradient( 135deg, color-mix(in oklch, var(--a63-action-primary) 30%, black 70%), color-mix(in oklch, var(--a63-action-primary) 16%, black 84%) )"
|
|
24974
|
+
},
|
|
24975
|
+
{
|
|
24976
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
24977
|
+
"value": "var( --a63-if-light, linear-gradient(color-mix(in oklch, var(--a63-action-primary) 18%, transparent), transparent), linear-gradient( 135deg, color-mix(in oklch, var(--a63-action-primary) 48%, white 52%), color-mix(in oklch, var(--a63-action-primary) 36%, white 64%) ) ) var( --a63-if-dark, linear-gradient(color-mix(in oklch, var(--a63-action-primary) 12%, transparent), transparent), linear-gradient( 135deg, color-mix(in oklch, var(--a63-action-primary) 30%, black 70%), color-mix(in oklch, var(--a63-action-primary) 16%, black 84%) ) )"
|
|
23868
24978
|
}
|
|
23869
24979
|
]
|
|
23870
24980
|
},
|
|
@@ -23890,6 +25000,10 @@
|
|
|
23890
25000
|
"scope": "[data-a63-theme='aqua']:is(.dark, [data-a63-mode='dark'])",
|
|
23891
25001
|
"value": "color-mix(in oklch, white 14%, transparent)"
|
|
23892
25002
|
},
|
|
25003
|
+
{
|
|
25004
|
+
"scope": "[data-a63-theme='aqua']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='aqua'] :is([data-a63-brand], [data-a63-surface])",
|
|
25005
|
+
"value": "var( --a63-if-light, color-mix(in oklch, var(--a63-action-primary) 32%, transparent) ) var(--a63-if-dark, color-mix(in oklch, white 14%, transparent))"
|
|
25006
|
+
},
|
|
23893
25007
|
{
|
|
23894
25008
|
"scope": "[data-a63-theme='retro']",
|
|
23895
25009
|
"value": "color-mix( in oklab, var(--a63-action-primary) 44%, var(--a63-border-subtle) )"
|
|
@@ -24089,6 +25203,10 @@
|
|
|
24089
25203
|
{
|
|
24090
25204
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
24091
25205
|
"value": "color-mix(in oklch, var(--a63-action-primary) 36%, transparent)"
|
|
25206
|
+
},
|
|
25207
|
+
{
|
|
25208
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
25209
|
+
"value": "var( --a63-if-light, color-mix(in oklch, var(--a63-action-primary) 38%, transparent) ) var(--a63-if-dark, color-mix(in oklch, var(--a63-action-primary) 36%, transparent))"
|
|
24092
25210
|
}
|
|
24093
25211
|
]
|
|
24094
25212
|
},
|
|
@@ -24121,6 +25239,10 @@
|
|
|
24121
25239
|
{
|
|
24122
25240
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
24123
25241
|
"value": "color-mix(in oklch, var(--a63-action-primary) 26%, white 74%)"
|
|
25242
|
+
},
|
|
25243
|
+
{
|
|
25244
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
25245
|
+
"value": "var( --a63-if-light, color-mix(in oklab, var(--a63-action-primary) 82%, var(--surface-light-12)) ) var(--a63-if-dark, color-mix(in oklch, var(--a63-action-primary) 26%, white 74%))"
|
|
24124
25246
|
}
|
|
24125
25247
|
]
|
|
24126
25248
|
},
|
|
@@ -24153,6 +25275,10 @@
|
|
|
24153
25275
|
{
|
|
24154
25276
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
24155
25277
|
"value": "color-mix(in oklch, var(--a63-text-accent) 54%, white 46%)"
|
|
25278
|
+
},
|
|
25279
|
+
{
|
|
25280
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
25281
|
+
"value": "var( --a63-if-light, color-mix(in oklab, var(--a63-action-primary) 58%, var(--surface-light-10)) ) var(--a63-if-dark, color-mix(in oklch, var(--a63-text-accent) 54%, white 46%))"
|
|
24156
25282
|
}
|
|
24157
25283
|
]
|
|
24158
25284
|
},
|
|
@@ -24185,6 +25311,10 @@
|
|
|
24185
25311
|
{
|
|
24186
25312
|
"scope": "[data-a63-theme='terminal']:is(.dark, [data-a63-mode='dark']), [data-a63-theme='terminal'] :is(.dark, [data-a63-mode='dark'])",
|
|
24187
25313
|
"value": "0 0 8px color-mix(in oklch, var(--a63-action-primary) 38%, transparent)"
|
|
25314
|
+
},
|
|
25315
|
+
{
|
|
25316
|
+
"scope": "[data-a63-theme='terminal']:is([data-a63-brand], [data-a63-surface]), [data-a63-theme='terminal'] :is([data-a63-brand], [data-a63-surface])",
|
|
25317
|
+
"value": "var( --a63-if-light, 0 0 10px color-mix(in oklch, var(--a63-action-primary) 22%, transparent) ) var(--a63-if-dark, 0 0 8px color-mix(in oklch, var(--a63-action-primary) 38%, transparent))"
|
|
24188
25318
|
}
|
|
24189
25319
|
]
|
|
24190
25320
|
},
|
|
@@ -24355,6 +25485,10 @@
|
|
|
24355
25485
|
{
|
|
24356
25486
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
24357
25487
|
"value": "0 0 0 1px color-mix(in oklch, black 8%, transparent), 0 1px 0 color-mix(in oklch, white 45%, transparent) inset, 0 10px 16px -10px color-mix(in oklch, black 22%, transparent), 0 22px 34px -16px color-mix(in oklch, black 26%, transparent)"
|
|
25488
|
+
},
|
|
25489
|
+
{
|
|
25490
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
25491
|
+
"value": "var( --a63-if-light, 0 0 0 1px color-mix(in oklch, black 8%, transparent), 0 1px 0 color-mix(in oklch, white 45%, transparent) inset, 0 10px 16px -10px color-mix(in oklch, black 22%, transparent), 0 22px 34px -16px color-mix(in oklch, black 26%, transparent) ) var( --a63-if-dark, 0 0 0 1px color-mix(in oklch, white 10%, transparent), 0 1px 0 color-mix(in oklch, white 8%, transparent) inset, 0 10px 16px -10px color-mix(in oklch, black 50%, transparent), 0 22px 34px -16px color-mix(in oklch, black 62%, transparent) )"
|
|
24358
25492
|
}
|
|
24359
25493
|
]
|
|
24360
25494
|
},
|
|
@@ -24375,6 +25509,10 @@
|
|
|
24375
25509
|
{
|
|
24376
25510
|
"scope": ":root, .light, [data-a63-mode='light']",
|
|
24377
25511
|
"value": "0 0 0 1px color-mix(in oklch, black 12%, transparent), 0 1px 0 color-mix(in oklch, white 60%, transparent) inset, 0 1px 1px color-mix(in oklch, black 12%, transparent), 0 14px 22px -10px color-mix(in oklch, black 26%, transparent), 0 32px 48px -18px color-mix(in oklch, black 30%, transparent)"
|
|
25512
|
+
},
|
|
25513
|
+
{
|
|
25514
|
+
"scope": "[data-a63-brand], [data-a63-surface]",
|
|
25515
|
+
"value": "var( --a63-if-light, 0 0 0 1px color-mix(in oklch, black 12%, transparent), 0 1px 0 color-mix(in oklch, white 60%, transparent) inset, 0 1px 1px color-mix(in oklch, black 12%, transparent), 0 14px 22px -10px color-mix(in oklch, black 26%, transparent), 0 32px 48px -18px color-mix(in oklch, black 30%, transparent) ) var( --a63-if-dark, 0 0 0 1px color-mix(in oklch, white 16%, transparent), 0 1px 0 color-mix(in oklch, white 12%, transparent) inset, 0 1px 1px color-mix(in oklch, black 35%, transparent), 0 14px 22px -10px color-mix(in oklch, black 58%, transparent), 0 32px 48px -18px color-mix(in oklch, black 72%, transparent) )"
|
|
24378
25516
|
}
|
|
24379
25517
|
]
|
|
24380
25518
|
},
|