@zazz-ui/core 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +19 -0
- package/LICENSE +21 -0
- package/README.md +61 -0
- package/dist/sri.json +75 -0
- package/dist/zazz.css +1 -0
- package/dist/zazz.js +1 -0
- package/examples/about.html +590 -0
- package/examples/components.html +1040 -0
- package/examples/forms.html +511 -0
- package/examples/index.html +268 -0
- package/examples/layout.html +320 -0
- package/examples/products.html +846 -0
- package/examples/responsive.html +339 -0
- package/package.json +85 -0
- package/src/base/_layers.css +12 -0
- package/src/base/_layout.css +568 -0
- package/src/base/_reset.css +515 -0
- package/src/base/_typography.css +495 -0
- package/src/base/_utilities.css +6628 -0
- package/src/base/_variables.css +682 -0
- package/src/base/_view-transitions.css +103 -0
- package/src/base/command-score.d.ts +12 -0
- package/src/base/command-score.d.ts.map +1 -0
- package/src/base/command-score.js +151 -0
- package/src/base/command-score.ts +192 -0
- package/src/base/dialog-lifecycle.d.ts +11 -0
- package/src/base/dialog-lifecycle.d.ts.map +1 -0
- package/src/base/dialog-lifecycle.js +65 -0
- package/src/base/dialog-lifecycle.ts +80 -0
- package/src/base/embla.d.ts +90 -0
- package/src/base/embla.d.ts.map +1 -0
- package/src/base/embla.js +643 -0
- package/src/base/embla.ts +791 -0
- package/src/base/hotkeys.d.ts +82 -0
- package/src/base/hotkeys.d.ts.map +1 -0
- package/src/base/hotkeys.js +141 -0
- package/src/base/hotkeys.ts +195 -0
- package/src/base/navigation.d.ts +2 -0
- package/src/base/navigation.d.ts.map +1 -0
- package/src/base/navigation.js +136 -0
- package/src/base/navigation.ts +151 -0
- package/src/base/reveal.d.ts +80 -0
- package/src/base/reveal.d.ts.map +1 -0
- package/src/base/reveal.js +305 -0
- package/src/base/reveal.ts +379 -0
- package/src/base/signals.d.ts +89 -0
- package/src/base/signals.d.ts.map +1 -0
- package/src/base/signals.js +134 -0
- package/src/base/signals.ts +164 -0
- package/src/base/typeahead.d.ts +105 -0
- package/src/base/typeahead.d.ts.map +1 -0
- package/src/base/typeahead.js +411 -0
- package/src/base/typeahead.ts +500 -0
- package/src/base/utils.d.ts +56 -0
- package/src/base/utils.d.ts.map +1 -0
- package/src/base/utils.js +88 -0
- package/src/base/utils.ts +98 -0
- package/src/base/zazz-element.d.ts +44 -0
- package/src/base/zazz-element.d.ts.map +1 -0
- package/src/base/zazz-element.js +59 -0
- package/src/base/zazz-element.ts +73 -0
- package/src/globals.d.ts +148 -0
- package/src/head.d.ts +95 -0
- package/src/head.d.ts.map +1 -0
- package/src/head.js +311 -0
- package/src/head.ts +433 -0
- package/src/index.css +71 -0
- package/src/index.d.ts +36 -0
- package/src/index.d.ts.map +1 -0
- package/src/index.js +35 -0
- package/src/index.ts +36 -0
- package/src/manifest.d.ts +90 -0
- package/src/manifest.d.ts.map +1 -0
- package/src/manifest.js +614 -0
- package/src/manifest.ts +667 -0
- package/src/primitives/accordion/accordion.css +104 -0
- package/src/primitives/accordion/accordion.html +69 -0
- package/src/primitives/alert-dialog/alert-dialog.css +38 -0
- package/src/primitives/alert-dialog/alert-dialog.html +53 -0
- package/src/primitives/autocomplete/autocomplete-groups.html +77 -0
- package/src/primitives/autocomplete/autocomplete.css +114 -0
- package/src/primitives/autocomplete/autocomplete.d.ts +30 -0
- package/src/primitives/autocomplete/autocomplete.d.ts.map +1 -0
- package/src/primitives/autocomplete/autocomplete.html +66 -0
- package/src/primitives/autocomplete/autocomplete.js +41 -0
- package/src/primitives/autocomplete/autocomplete.ts +46 -0
- package/src/primitives/avatar/avatar.html +44 -0
- package/src/primitives/badge/badge-icon.html +36 -0
- package/src/primitives/badge/badge.css +251 -0
- package/src/primitives/badge/badge.html +7 -0
- package/src/primitives/breadcrumbs/breadcrumbs.html +9 -0
- package/src/primitives/button/button-icon-only.html +84 -0
- package/src/primitives/button/button-icon.html +82 -0
- package/src/primitives/button/button.css +319 -0
- package/src/primitives/button/button.html +8 -0
- package/src/primitives/button-group/button-group-vertical.html +6 -0
- package/src/primitives/button-group/button-group.css +94 -0
- package/src/primitives/button-group/button-group.html +64 -0
- package/src/primitives/card/card-subgrid.html +118 -0
- package/src/primitives/card/card.html +53 -0
- package/src/primitives/carousel/carousel.css +61 -0
- package/src/primitives/carousel/carousel.d.ts +16 -0
- package/src/primitives/carousel/carousel.d.ts.map +1 -0
- package/src/primitives/carousel/carousel.html +315 -0
- package/src/primitives/carousel/carousel.js +73 -0
- package/src/primitives/carousel/carousel.ts +84 -0
- package/src/primitives/checkbox/checkbox-tasklist.html +71 -0
- package/src/primitives/checkbox/checkbox.css +82 -0
- package/src/primitives/checkbox/checkbox.d.ts +21 -0
- package/src/primitives/checkbox/checkbox.d.ts.map +1 -0
- package/src/primitives/checkbox/checkbox.html +17 -0
- package/src/primitives/checkbox/checkbox.js +190 -0
- package/src/primitives/checkbox/checkbox.ts +219 -0
- package/src/primitives/combobox/combobox-multiselect.html +91 -0
- package/src/primitives/combobox/combobox.css +307 -0
- package/src/primitives/combobox/combobox.d.ts +100 -0
- package/src/primitives/combobox/combobox.d.ts.map +1 -0
- package/src/primitives/combobox/combobox.html +73 -0
- package/src/primitives/combobox/combobox.js +503 -0
- package/src/primitives/combobox/combobox.ts +559 -0
- package/src/primitives/command/command-actions.d.ts +31 -0
- package/src/primitives/command/command-actions.d.ts.map +1 -0
- package/src/primitives/command/command-actions.html +89 -0
- package/src/primitives/command/command-actions.js +70 -0
- package/src/primitives/command/command-actions.ts +77 -0
- package/src/primitives/command/command-dialog.html +77 -0
- package/src/primitives/command/command.css +151 -0
- package/src/primitives/command/command.d.ts +52 -0
- package/src/primitives/command/command.d.ts.map +1 -0
- package/src/primitives/command/command.html +119 -0
- package/src/primitives/command/command.js +146 -0
- package/src/primitives/command/command.ts +157 -0
- package/src/primitives/dialog/dialog-with-form.html +200 -0
- package/src/primitives/dialog/dialog.css +229 -0
- package/src/primitives/dialog/dialog.html +90 -0
- package/src/primitives/fields/fields.css +278 -0
- package/src/primitives/input/input-icon-leading.html +19 -0
- package/src/primitives/input/input-icon-trailing.html +18 -0
- package/src/primitives/input/input.css +114 -0
- package/src/primitives/input/input.html +61 -0
- package/src/primitives/input-group/input-group-password-group.html +108 -0
- package/src/primitives/input-group/input-group.css +215 -0
- package/src/primitives/input-group/input-group.html +132 -0
- package/src/primitives/kbd/kbd-group.html +18 -0
- package/src/primitives/kbd/kbd.css +87 -0
- package/src/primitives/kbd/kbd.html +7 -0
- package/src/primitives/lightbox/lightbox.css +459 -0
- package/src/primitives/lightbox/lightbox.d.ts +7 -0
- package/src/primitives/lightbox/lightbox.d.ts.map +1 -0
- package/src/primitives/lightbox/lightbox.html +665 -0
- package/src/primitives/lightbox/lightbox.js +96 -0
- package/src/primitives/lightbox/lightbox.ts +113 -0
- package/src/primitives/menu/menu-interest.html +52 -0
- package/src/primitives/menu/menu.css +55 -0
- package/src/primitives/menu/menu.d.ts +38 -0
- package/src/primitives/menu/menu.d.ts.map +1 -0
- package/src/primitives/menu/menu.html +70 -0
- package/src/primitives/menu/menu.js +117 -0
- package/src/primitives/menu/menu.ts +131 -0
- package/src/primitives/menubar/menubar-help-search.html +103 -0
- package/src/primitives/menubar/menubar.html +166 -0
- package/src/primitives/meter/meter.css +178 -0
- package/src/primitives/meter/meter.html +38 -0
- package/src/primitives/mobile-menu/mobile-menu.css +145 -0
- package/src/primitives/mobile-menu/mobile-menu.html +614 -0
- package/src/primitives/navigation-menu/navigation-menu-featured.html +76 -0
- package/src/primitives/navigation-menu/navigation-menu-icon-grid.html +158 -0
- package/src/primitives/navigation-menu/navigation-menu-interest.html +103 -0
- package/src/primitives/navigation-menu/navigation-menu-megamenu.html +141 -0
- package/src/primitives/navigation-menu/navigation-menu-simple.html +96 -0
- package/src/primitives/navigation-menu/navigation-menu.css +295 -0
- package/src/primitives/navigation-menu/navigation-menu.html +576 -0
- package/src/primitives/otp/otp.css +126 -0
- package/src/primitives/otp/otp.d.ts +89 -0
- package/src/primitives/otp/otp.d.ts.map +1 -0
- package/src/primitives/otp/otp.html +22 -0
- package/src/primitives/otp/otp.js +226 -0
- package/src/primitives/otp/otp.ts +279 -0
- package/src/primitives/password-group/password-group.css +238 -0
- package/src/primitives/password-group/password-group.d.ts +25 -0
- package/src/primitives/password-group/password-group.d.ts.map +1 -0
- package/src/primitives/password-group/password-group.html +109 -0
- package/src/primitives/password-group/password-group.js +76 -0
- package/src/primitives/password-group/password-group.ts +95 -0
- package/src/primitives/popover/popover.css +233 -0
- package/src/primitives/progress/progress-indeterminate.html +1 -0
- package/src/primitives/progress/progress.css +105 -0
- package/src/primitives/progress/progress.html +7 -0
- package/src/primitives/prose/prose.html +65 -0
- package/src/primitives/radio/radio.css +84 -0
- package/src/primitives/radio/radio.html +17 -0
- package/src/primitives/reveal/reveal.css +167 -0
- package/src/primitives/select/multiselect.d.ts +43 -0
- package/src/primitives/select/multiselect.d.ts.map +1 -0
- package/src/primitives/select/multiselect.js +147 -0
- package/src/primitives/select/multiselect.ts +188 -0
- package/src/primitives/select/select-align.html +49 -0
- package/src/primitives/select/select-multiple.html +12 -0
- package/src/primitives/select/select-sides.html +65 -0
- package/src/primitives/select/select.css +481 -0
- package/src/primitives/select/select.html +16 -0
- package/src/primitives/separator/separator.css +49 -0
- package/src/primitives/separator/separator.html +16 -0
- package/src/primitives/slider/slider.css +122 -0
- package/src/primitives/slider/slider.html +1 -0
- package/src/primitives/switch/switch.css +126 -0
- package/src/primitives/switch/switch.html +13 -0
- package/src/primitives/table/table-alternating.html +36 -0
- package/src/primitives/table/table-grid.html +30 -0
- package/src/primitives/table/table-size-sm.html +26 -0
- package/src/primitives/table/table.css +158 -0
- package/src/primitives/table/table.html +45 -0
- package/src/primitives/tabs/tabs.css +328 -0
- package/src/primitives/tabs/tabs.d.ts +35 -0
- package/src/primitives/tabs/tabs.d.ts.map +1 -0
- package/src/primitives/tabs/tabs.html +75 -0
- package/src/primitives/tabs/tabs.js +84 -0
- package/src/primitives/tabs/tabs.ts +93 -0
- package/src/primitives/textarea/textarea.css +78 -0
- package/src/primitives/textarea/textarea.html +10 -0
- package/src/primitives/toaster/toaster.css +309 -0
- package/src/primitives/toaster/toaster.d.ts +138 -0
- package/src/primitives/toaster/toaster.d.ts.map +1 -0
- package/src/primitives/toaster/toaster.html +77 -0
- package/src/primitives/toaster/toaster.js +736 -0
- package/src/primitives/toaster/toaster.ts +823 -0
- package/src/primitives/toggle/toggle.css +295 -0
- package/src/primitives/toggle/toggle.html +68 -0
- package/src/primitives/toggle-group/toggle-group-multiple.html +14 -0
- package/src/primitives/toggle-group/toggle-group-vertical.html +14 -0
- package/src/primitives/toggle-group/toggle-group.css +73 -0
- package/src/primitives/toggle-group/toggle-group.html +53 -0
- package/src/primitives/toolbar/toolbar.html +45 -0
- package/src/primitives/tooltip/tooltip-disabled.html +19 -0
- package/src/primitives/tooltip/tooltip-sides.html +57 -0
- package/src/primitives/tooltip/tooltip-with-kbd.html +31 -0
- package/src/primitives/tooltip/tooltip.css +235 -0
- package/src/primitives/tooltip/tooltip.html +12 -0
- package/src/primitives/utilities/aspect-ratio.html +17 -0
- package/src/primitives/utilities/basis.html +27 -0
- package/src/primitives/utilities/col-span.html +23 -0
- package/src/primitives/utilities/compose.html +19 -0
- package/src/primitives/utilities/flex-align.html +26 -0
- package/src/primitives/utilities/flex-direction.html +36 -0
- package/src/primitives/utilities/flex-grow.html +17 -0
- package/src/primitives/utilities/gap.html +62 -0
- package/src/primitives/utilities/grid-cols.html +20 -0
- package/src/primitives/utilities/grid-pile.html +5 -0
- package/src/primitives/utilities/grid-responsive.html +31 -0
- package/src/primitives/utilities/margin-auto.html +13 -0
- package/src/primitives/utilities/object-fit.html +41 -0
- package/src/primitives/utilities/order.html +17 -0
- package/src/primitives/utilities/overflow.html +26 -0
- package/src/primitives/utilities/padding-compose.html +23 -0
- package/src/primitives/utilities/padding.html +30 -0
- package/src/primitives/utilities/position.html +13 -0
- package/src/primitives/utilities/responsive-flex.html +22 -0
- package/src/primitives/utilities/responsive-grid.html +31 -0
- package/src/primitives/utilities/size.html +22 -0
- package/src/primitives/utilities/width.html +22 -0
|
@@ -0,0 +1,1040 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<!-- Page-specific tags stay above the generated block -->
|
|
5
|
+
<title>Zazz tests | Overview</title>
|
|
6
|
+
<link rel="prefetch" href="layout.html" />
|
|
7
|
+
|
|
8
|
+
<!-- Shared head, generated from @zazz-ui/core's head contract (src/head.ts). -->
|
|
9
|
+
<!-- Edit nothing between the markers; run `vp run heads` to regenerate. -->
|
|
10
|
+
<!-- zazz:head -->
|
|
11
|
+
<meta charset="utf-8" />
|
|
12
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
13
|
+
<!-- Paint the right theme (background, form controls, scrollbars) before CSS loads -->
|
|
14
|
+
<meta name="color-scheme" content="light dark" />
|
|
15
|
+
<!-- Google Fonts: Geist + Geist Mono (preconnect so the CSS request starts early) -->
|
|
16
|
+
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
|
17
|
+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
|
18
|
+
<link
|
|
19
|
+
rel="preload"
|
|
20
|
+
as="font"
|
|
21
|
+
type="font/woff2"
|
|
22
|
+
crossorigin
|
|
23
|
+
href="https://fonts.gstatic.com/s/geist/v5/gyByhwUxId8gMEwcGFWNOITd.woff2"
|
|
24
|
+
/>
|
|
25
|
+
<link
|
|
26
|
+
href="https://fonts.googleapis.com/css2?family=Geist+Mono:ital,wght@0,100..900;1,100..900&family=Geist:ital,wght@0,100..900;1,100..900&display=swap"
|
|
27
|
+
rel="stylesheet"
|
|
28
|
+
/>
|
|
29
|
+
<!-- Zazz styles: one bundle (index.css @imports every layer in cascade order) -->
|
|
30
|
+
<link rel="stylesheet" href="../src/index.css" />
|
|
31
|
+
<!-- Import map: bare specifiers in Zazz scripts resolve to pinned, SRI-checked files -->
|
|
32
|
+
<script type="importmap">
|
|
33
|
+
{
|
|
34
|
+
"imports": {
|
|
35
|
+
"signal-polyfill": "https://cdn.jsdelivr.net/npm/signal-polyfill@0.2.2/dist/index.js",
|
|
36
|
+
"embla-carousel": "https://cdn.jsdelivr.net/npm/embla-carousel@8.6.0/esm/embla-carousel.esm.js",
|
|
37
|
+
"embla-carousel-autoplay": "https://cdn.jsdelivr.net/npm/embla-carousel-autoplay@8.6.0/esm/embla-carousel-autoplay.esm.js",
|
|
38
|
+
"embla-carousel-auto-scroll": "https://cdn.jsdelivr.net/npm/embla-carousel-auto-scroll@8.6.0/esm/embla-carousel-auto-scroll.esm.js",
|
|
39
|
+
"embla-carousel-class-names": "https://cdn.jsdelivr.net/npm/embla-carousel-class-names@8.6.0/esm/embla-carousel-class-names.esm.js"
|
|
40
|
+
},
|
|
41
|
+
"integrity": {
|
|
42
|
+
"https://cdn.jsdelivr.net/npm/signal-polyfill@0.2.2/dist/index.js": "sha384-0OqM7OXGT6Oz1z98u/geiFn/FUyz4iWexkXHCvbIGXRRDXl6bp6IKc0j78AQ6DEK",
|
|
43
|
+
"https://cdn.jsdelivr.net/npm/embla-carousel@8.6.0/esm/embla-carousel.esm.js": "sha384-GXjfyU1fSHHeweoYd3rwo7OBKYtkq+JcsDoe8VDRc6znCty2ZTzyVvX1DwqCE+9t",
|
|
44
|
+
"https://cdn.jsdelivr.net/npm/embla-carousel-autoplay@8.6.0/esm/embla-carousel-autoplay.esm.js": "sha384-AX49yBc7zd/CT8ZqNMRiiqqVSV9xfxb27VwEGziPioT3wL4k4C5BW2qwefdWuN4J",
|
|
45
|
+
"https://cdn.jsdelivr.net/npm/embla-carousel-auto-scroll@8.6.0/esm/embla-carousel-auto-scroll.esm.js": "sha384-SPdnL1eic73WfM72zFEf0RJ5PdUC7TL3Yb5jOl1JC3/l4D7EsVxwO8wFnnezlMSu",
|
|
46
|
+
"https://cdn.jsdelivr.net/npm/embla-carousel-class-names@8.6.0/esm/embla-carousel-class-names.esm.js": "sha384-ZWno/FqzYeWE5Ils19GIhep1AZ5bMl0mp9wmm6baTJE4+pjMjOdTnE55SjUQAdVh"
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
</script>
|
|
50
|
+
<link rel="modulepreload" href="../src/index.js" />
|
|
51
|
+
<!-- Polyfills: Popover API + Invoker Commands (command/commandfor) -->
|
|
52
|
+
<script
|
|
53
|
+
src="https://cdn.jsdelivr.net/npm/@oddbird/popover-polyfill@0.7.2/dist/popover.min.js"
|
|
54
|
+
integrity="sha384-pOVHoXRgxuaWHCRM4KSyfyfRTmdxgjVo1Ux78ZKJ+GjUz4zIzXiTa8XXuDF1R1Sd"
|
|
55
|
+
crossorigin="anonymous"
|
|
56
|
+
defer
|
|
57
|
+
></script>
|
|
58
|
+
<script
|
|
59
|
+
type="module"
|
|
60
|
+
src="https://cdn.jsdelivr.net/npm/invokers@2.2.2/dist/esm/production/compatible.js"
|
|
61
|
+
integrity="sha384-7vRXDaS2mcW7LheGSA/rxBwIQNEqmWj0OLEOta/+mvw+9Uf5w1vplA5qg8kLQ99u"
|
|
62
|
+
crossorigin="anonymous"
|
|
63
|
+
defer
|
|
64
|
+
></script>
|
|
65
|
+
<!-- Zazz behavior: one ES module imports every component script in dependency order -->
|
|
66
|
+
<script type="module" src="../src/index.js"></script>
|
|
67
|
+
<!-- Theme: apply the persisted (or preferred) scheme before first paint -->
|
|
68
|
+
<script>
|
|
69
|
+
(() => {
|
|
70
|
+
try {
|
|
71
|
+
const storedTheme = localStorage.getItem("theme");
|
|
72
|
+
const prefersDark = matchMedia("(prefers-color-scheme: dark)").matches;
|
|
73
|
+
const theme = storedTheme ?? (prefersDark ? "dark" : "light");
|
|
74
|
+
document.documentElement.classList.toggle("dark", theme === "dark");
|
|
75
|
+
} catch {
|
|
76
|
+
document.documentElement.classList.toggle(
|
|
77
|
+
"dark",
|
|
78
|
+
matchMedia("(prefers-color-scheme: dark)").matches,
|
|
79
|
+
);
|
|
80
|
+
}
|
|
81
|
+
})();
|
|
82
|
+
</script>
|
|
83
|
+
<!-- /zazz:head -->
|
|
84
|
+
</head>
|
|
85
|
+
|
|
86
|
+
<body class="bg-background">
|
|
87
|
+
<header class="py-md border-b" data-transition-layer="global-header">
|
|
88
|
+
<div class="container">
|
|
89
|
+
<div class="flex items-center justify-between">
|
|
90
|
+
<a href="index.html" class="text-h6 font-black">Zazz tests</a>
|
|
91
|
+
<nav>
|
|
92
|
+
<menu class="flex gap-xs">
|
|
93
|
+
<li>
|
|
94
|
+
<a class="ui-button" data-variant="ghost" data-size="sm" href="index.html"
|
|
95
|
+
>Overview</a
|
|
96
|
+
>
|
|
97
|
+
</li>
|
|
98
|
+
<li>
|
|
99
|
+
<a class="ui-button" data-variant="ghost" data-size="sm" href="about.html">About</a>
|
|
100
|
+
</li>
|
|
101
|
+
<li>
|
|
102
|
+
<a class="ui-button" data-variant="ghost" data-size="sm" href="products.html"
|
|
103
|
+
>Products</a
|
|
104
|
+
>
|
|
105
|
+
</li>
|
|
106
|
+
<li>
|
|
107
|
+
<a class="ui-button" data-variant="ghost" data-size="sm" href="layout.html"
|
|
108
|
+
>Layout</a
|
|
109
|
+
>
|
|
110
|
+
</li>
|
|
111
|
+
<li>
|
|
112
|
+
<a class="ui-button" data-variant="ghost" data-size="sm" href="responsive.html"
|
|
113
|
+
>Responsive</a
|
|
114
|
+
>
|
|
115
|
+
</li>
|
|
116
|
+
<li>
|
|
117
|
+
<a class="ui-button" data-variant="ghost" data-size="sm" href="components.html"
|
|
118
|
+
>Components</a
|
|
119
|
+
>
|
|
120
|
+
</li>
|
|
121
|
+
<li>
|
|
122
|
+
<a class="ui-button" data-variant="ghost" data-size="sm" href="forms.html">Forms</a>
|
|
123
|
+
</li>
|
|
124
|
+
</menu>
|
|
125
|
+
</nav>
|
|
126
|
+
</div>
|
|
127
|
+
</div>
|
|
128
|
+
</header>
|
|
129
|
+
|
|
130
|
+
<main data-layout="main">
|
|
131
|
+
<section class="py-xl">
|
|
132
|
+
<div class="container">
|
|
133
|
+
<hgroup class="flex flex-col gap-sm">
|
|
134
|
+
<span class="text-eyebrow">Components</span>
|
|
135
|
+
<h1 class="text-h1">Component kitchen sink</h1>
|
|
136
|
+
<p class="text-lg text-muted-foreground max-w-screen-sm">
|
|
137
|
+
Each block is adapted from the component's single-source example. Tooltips, menus, and
|
|
138
|
+
the dialog use the native Popover and Invoker Commands APIs; tabs are a light-DOM
|
|
139
|
+
custom element. Try them with mouse and keyboard.
|
|
140
|
+
</p>
|
|
141
|
+
</hgroup>
|
|
142
|
+
</div>
|
|
143
|
+
</section>
|
|
144
|
+
|
|
145
|
+
<section class="pb-xl">
|
|
146
|
+
<div class="container">
|
|
147
|
+
<!-- Buttons -->
|
|
148
|
+
<div class="mb-lg">
|
|
149
|
+
<h2 class="text-h6 font-heading pb-sm">Buttons</h2>
|
|
150
|
+
<div class="flex items-center gap-xs pb-sm">
|
|
151
|
+
<button class="ui-button" type="button">Default</button>
|
|
152
|
+
<button class="ui-button" data-variant="primary" type="button">Primary</button>
|
|
153
|
+
<button class="ui-button" data-variant="muted" type="button">Muted</button>
|
|
154
|
+
<button class="ui-button" data-variant="ghost" type="button">Ghost</button>
|
|
155
|
+
<button class="ui-button" data-variant="destructive" type="button">
|
|
156
|
+
Destructive
|
|
157
|
+
</button>
|
|
158
|
+
<button class="ui-button" data-variant="link" type="button">Link</button>
|
|
159
|
+
</div>
|
|
160
|
+
<div class="flex items-center gap-xs">
|
|
161
|
+
<button class="ui-button" data-variant="primary" type="button">
|
|
162
|
+
Start free trial
|
|
163
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256">
|
|
164
|
+
<rect width="256" height="256" fill="none" />
|
|
165
|
+
<line
|
|
166
|
+
x1="40"
|
|
167
|
+
y1="128"
|
|
168
|
+
x2="216"
|
|
169
|
+
y2="128"
|
|
170
|
+
fill="none"
|
|
171
|
+
stroke="currentColor"
|
|
172
|
+
stroke-linecap="round"
|
|
173
|
+
stroke-linejoin="round"
|
|
174
|
+
stroke-width="16"
|
|
175
|
+
/>
|
|
176
|
+
<polyline
|
|
177
|
+
points="144 56 216 128 144 200"
|
|
178
|
+
fill="none"
|
|
179
|
+
stroke="currentColor"
|
|
180
|
+
stroke-linecap="round"
|
|
181
|
+
stroke-linejoin="round"
|
|
182
|
+
stroke-width="16"
|
|
183
|
+
/>
|
|
184
|
+
</svg>
|
|
185
|
+
</button>
|
|
186
|
+
<button class="ui-button" data-variant="primary" data-size="sm" type="button">
|
|
187
|
+
Small
|
|
188
|
+
</button>
|
|
189
|
+
<button
|
|
190
|
+
class="ui-button"
|
|
191
|
+
data-variant="primary"
|
|
192
|
+
data-size="icon"
|
|
193
|
+
type="button"
|
|
194
|
+
aria-label="Add"
|
|
195
|
+
>
|
|
196
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256">
|
|
197
|
+
<rect width="256" height="256" fill="none" />
|
|
198
|
+
<line
|
|
199
|
+
x1="40"
|
|
200
|
+
y1="128"
|
|
201
|
+
x2="216"
|
|
202
|
+
y2="128"
|
|
203
|
+
fill="none"
|
|
204
|
+
stroke="currentColor"
|
|
205
|
+
stroke-linecap="round"
|
|
206
|
+
stroke-linejoin="round"
|
|
207
|
+
stroke-width="16"
|
|
208
|
+
/>
|
|
209
|
+
<line
|
|
210
|
+
x1="128"
|
|
211
|
+
y1="40"
|
|
212
|
+
x2="128"
|
|
213
|
+
y2="216"
|
|
214
|
+
fill="none"
|
|
215
|
+
stroke="currentColor"
|
|
216
|
+
stroke-linecap="round"
|
|
217
|
+
stroke-linejoin="round"
|
|
218
|
+
stroke-width="16"
|
|
219
|
+
/>
|
|
220
|
+
</svg>
|
|
221
|
+
</button>
|
|
222
|
+
<button
|
|
223
|
+
class="ui-button"
|
|
224
|
+
data-variant="muted"
|
|
225
|
+
data-size="icon-sm"
|
|
226
|
+
type="button"
|
|
227
|
+
aria-label="Add"
|
|
228
|
+
>
|
|
229
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256">
|
|
230
|
+
<rect width="256" height="256" fill="none" />
|
|
231
|
+
<line
|
|
232
|
+
x1="40"
|
|
233
|
+
y1="128"
|
|
234
|
+
x2="216"
|
|
235
|
+
y2="128"
|
|
236
|
+
fill="none"
|
|
237
|
+
stroke="currentColor"
|
|
238
|
+
stroke-linecap="round"
|
|
239
|
+
stroke-linejoin="round"
|
|
240
|
+
stroke-width="16"
|
|
241
|
+
/>
|
|
242
|
+
<line
|
|
243
|
+
x1="128"
|
|
244
|
+
y1="40"
|
|
245
|
+
x2="128"
|
|
246
|
+
y2="216"
|
|
247
|
+
fill="none"
|
|
248
|
+
stroke="currentColor"
|
|
249
|
+
stroke-linecap="round"
|
|
250
|
+
stroke-linejoin="round"
|
|
251
|
+
stroke-width="16"
|
|
252
|
+
/>
|
|
253
|
+
</svg>
|
|
254
|
+
</button>
|
|
255
|
+
</div>
|
|
256
|
+
</div>
|
|
257
|
+
|
|
258
|
+
<!-- Button Group -->
|
|
259
|
+
<div class="mb-lg">
|
|
260
|
+
<div class="flex flex-col items-start gap-md">
|
|
261
|
+
<ui-button-group role="group" aria-label="Text alignment">
|
|
262
|
+
<button class="ui-button" type="button">Left</button>
|
|
263
|
+
<button class="ui-button" type="button">Center</button>
|
|
264
|
+
<button class="ui-button" type="button">Right</button>
|
|
265
|
+
</ui-button-group>
|
|
266
|
+
|
|
267
|
+
<ui-button-group role="group" aria-label="Pagination">
|
|
268
|
+
<button class="ui-button" data-variant="muted" type="button">Previous</button>
|
|
269
|
+
<button class="ui-button" data-variant="muted" data-size="icon" type="button">
|
|
270
|
+
1
|
|
271
|
+
</button>
|
|
272
|
+
<button class="ui-button" data-variant="muted" data-size="icon" type="button">
|
|
273
|
+
2
|
|
274
|
+
</button>
|
|
275
|
+
<button class="ui-button" data-variant="muted" data-size="icon" type="button">
|
|
276
|
+
3
|
|
277
|
+
</button>
|
|
278
|
+
<button class="ui-button" data-variant="muted" type="button">Next</button>
|
|
279
|
+
</ui-button-group>
|
|
280
|
+
</div>
|
|
281
|
+
</div>
|
|
282
|
+
|
|
283
|
+
<!-- Toggle Group -->
|
|
284
|
+
<div class="mb-lg">
|
|
285
|
+
<h2 class="text-h6 font-heading pb-sm">Toggle Group</h2>
|
|
286
|
+
<ui-toggle-group role="group" aria-label="Text formatting">
|
|
287
|
+
<label class="ui-toggle">
|
|
288
|
+
<input type="checkbox" name="format" value="bold" />
|
|
289
|
+
<span>Bold</span>
|
|
290
|
+
</label>
|
|
291
|
+
<label class="ui-toggle">
|
|
292
|
+
<input type="checkbox" name="format" value="italic" />
|
|
293
|
+
<span>Italic</span>
|
|
294
|
+
</label>
|
|
295
|
+
<label class="ui-toggle">
|
|
296
|
+
<input type="checkbox" name="format" value="underline" />
|
|
297
|
+
<span>Underline</span>
|
|
298
|
+
</label>
|
|
299
|
+
</ui-toggle-group>
|
|
300
|
+
</div>
|
|
301
|
+
|
|
302
|
+
<!-- Buttons -->
|
|
303
|
+
<div class="mb-lg">
|
|
304
|
+
<h2 class="text-h6 font-heading pb-sm">Buttons</h2>
|
|
305
|
+
<div class="flex items-center gap-xs pb-sm">
|
|
306
|
+
<button class="ui-button" type="button">Default</button>
|
|
307
|
+
<button class="ui-button" data-variant="primary" type="button">Primary</button>
|
|
308
|
+
<button class="ui-button" data-variant="muted" type="button">Muted</button>
|
|
309
|
+
<button class="ui-button" data-variant="ghost" type="button">Ghost</button>
|
|
310
|
+
<button class="ui-button" data-variant="destructive" type="button">
|
|
311
|
+
Destructive
|
|
312
|
+
</button>
|
|
313
|
+
<button class="ui-button" data-variant="link" type="button">Link</button>
|
|
314
|
+
</div>
|
|
315
|
+
<div class="flex items-center gap-xs">
|
|
316
|
+
<button class="ui-button" data-variant="primary" type="button">
|
|
317
|
+
Start free trial
|
|
318
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256">
|
|
319
|
+
<rect width="256" height="256" fill="none" />
|
|
320
|
+
<line
|
|
321
|
+
x1="40"
|
|
322
|
+
y1="128"
|
|
323
|
+
x2="216"
|
|
324
|
+
y2="128"
|
|
325
|
+
fill="none"
|
|
326
|
+
stroke="currentColor"
|
|
327
|
+
stroke-linecap="round"
|
|
328
|
+
stroke-linejoin="round"
|
|
329
|
+
stroke-width="16"
|
|
330
|
+
/>
|
|
331
|
+
<polyline
|
|
332
|
+
points="144 56 216 128 144 200"
|
|
333
|
+
fill="none"
|
|
334
|
+
stroke="currentColor"
|
|
335
|
+
stroke-linecap="round"
|
|
336
|
+
stroke-linejoin="round"
|
|
337
|
+
stroke-width="16"
|
|
338
|
+
/>
|
|
339
|
+
</svg>
|
|
340
|
+
</button>
|
|
341
|
+
<button class="ui-button" data-variant="primary" data-size="sm" type="button">
|
|
342
|
+
Small
|
|
343
|
+
</button>
|
|
344
|
+
<button
|
|
345
|
+
class="ui-button"
|
|
346
|
+
data-variant="primary"
|
|
347
|
+
data-size="icon"
|
|
348
|
+
type="button"
|
|
349
|
+
aria-label="Add"
|
|
350
|
+
>
|
|
351
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256">
|
|
352
|
+
<rect width="256" height="256" fill="none" />
|
|
353
|
+
<line
|
|
354
|
+
x1="40"
|
|
355
|
+
y1="128"
|
|
356
|
+
x2="216"
|
|
357
|
+
y2="128"
|
|
358
|
+
fill="none"
|
|
359
|
+
stroke="currentColor"
|
|
360
|
+
stroke-linecap="round"
|
|
361
|
+
stroke-linejoin="round"
|
|
362
|
+
stroke-width="16"
|
|
363
|
+
/>
|
|
364
|
+
<line
|
|
365
|
+
x1="128"
|
|
366
|
+
y1="40"
|
|
367
|
+
x2="128"
|
|
368
|
+
y2="216"
|
|
369
|
+
fill="none"
|
|
370
|
+
stroke="currentColor"
|
|
371
|
+
stroke-linecap="round"
|
|
372
|
+
stroke-linejoin="round"
|
|
373
|
+
stroke-width="16"
|
|
374
|
+
/>
|
|
375
|
+
</svg>
|
|
376
|
+
</button>
|
|
377
|
+
<button
|
|
378
|
+
class="ui-button"
|
|
379
|
+
data-variant="muted"
|
|
380
|
+
data-size="icon-sm"
|
|
381
|
+
type="button"
|
|
382
|
+
aria-label="Add"
|
|
383
|
+
>
|
|
384
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256">
|
|
385
|
+
<rect width="256" height="256" fill="none" />
|
|
386
|
+
<line
|
|
387
|
+
x1="40"
|
|
388
|
+
y1="128"
|
|
389
|
+
x2="216"
|
|
390
|
+
y2="128"
|
|
391
|
+
fill="none"
|
|
392
|
+
stroke="currentColor"
|
|
393
|
+
stroke-linecap="round"
|
|
394
|
+
stroke-linejoin="round"
|
|
395
|
+
stroke-width="16"
|
|
396
|
+
/>
|
|
397
|
+
<line
|
|
398
|
+
x1="128"
|
|
399
|
+
y1="40"
|
|
400
|
+
x2="128"
|
|
401
|
+
y2="216"
|
|
402
|
+
fill="none"
|
|
403
|
+
stroke="currentColor"
|
|
404
|
+
stroke-linecap="round"
|
|
405
|
+
stroke-linejoin="round"
|
|
406
|
+
stroke-width="16"
|
|
407
|
+
/>
|
|
408
|
+
</svg>
|
|
409
|
+
</button>
|
|
410
|
+
</div>
|
|
411
|
+
</div>
|
|
412
|
+
|
|
413
|
+
<!-- Badges -->
|
|
414
|
+
<div class="mb-lg">
|
|
415
|
+
<h2 class="text-h6 font-heading pb-sm">Badges</h2>
|
|
416
|
+
<div class="flex items-center gap-xs">
|
|
417
|
+
<button type="button" class="ui-badge">Category</button>
|
|
418
|
+
<button type="button" class="ui-badge" data-variant="primary">New</button>
|
|
419
|
+
<button type="button" class="ui-badge" data-variant="muted">Draft</button>
|
|
420
|
+
<button type="button" class="ui-badge" data-variant="ghost">Inline</button>
|
|
421
|
+
<button type="button" class="ui-badge" data-variant="link">Posts</button>
|
|
422
|
+
</div>
|
|
423
|
+
</div>
|
|
424
|
+
|
|
425
|
+
<!-- Breadcrumbs -->
|
|
426
|
+
<div class="mb-lg">
|
|
427
|
+
<h2 class="text-h6 font-heading pb-sm">Breadcrumbs</h2>
|
|
428
|
+
<nav class="flex items-center gap-xs">
|
|
429
|
+
<menu class="flex items-center gap-xs">
|
|
430
|
+
<li><a class="ui-button" data-variant="link" href="#">Home</a></li>
|
|
431
|
+
<li><span class="text-muted-foreground opacity-50">/</span></li>
|
|
432
|
+
<li><a class="ui-button" data-variant="link" href="#">Products</a></li>
|
|
433
|
+
<li><span class="text-muted-foreground opacity-50">/</span></li>
|
|
434
|
+
<li>
|
|
435
|
+
<div class="ui-button" data-variant="link" aria-disabled="true">Product name</div>
|
|
436
|
+
</li>
|
|
437
|
+
</menu>
|
|
438
|
+
</nav>
|
|
439
|
+
</div>
|
|
440
|
+
|
|
441
|
+
<!-- Tooltip and menu -->
|
|
442
|
+
<div class="mb-lg">
|
|
443
|
+
<h2 class="text-h6 font-heading pb-sm">Tooltip and menu</h2>
|
|
444
|
+
<div class="flex items-center gap-xs">
|
|
445
|
+
<ui-tooltip>
|
|
446
|
+
<button type="button" class="ui-button" interestfor="tooltip-components-1">
|
|
447
|
+
Hover or focus
|
|
448
|
+
</button>
|
|
449
|
+
<div
|
|
450
|
+
data-slot="tooltip-content"
|
|
451
|
+
id="tooltip-components-1"
|
|
452
|
+
popover="hint"
|
|
453
|
+
data-use-inverted-menu="false"
|
|
454
|
+
>
|
|
455
|
+
Add to library
|
|
456
|
+
<span data-slot="tooltip-arrow" aria-hidden="true"></span>
|
|
457
|
+
</div>
|
|
458
|
+
</ui-tooltip>
|
|
459
|
+
|
|
460
|
+
<ui-menu>
|
|
461
|
+
<button class="ui-button" type="button" popovertarget="menu-components-1">
|
|
462
|
+
Open menu
|
|
463
|
+
</button>
|
|
464
|
+
<div
|
|
465
|
+
id="menu-components-1"
|
|
466
|
+
data-slot="menu-popover"
|
|
467
|
+
data-side="bottom"
|
|
468
|
+
data-align="start"
|
|
469
|
+
popover="auto"
|
|
470
|
+
>
|
|
471
|
+
<menu>
|
|
472
|
+
<li class="font-strong text-eyebrow text-muted-foreground p-xs">Account</li>
|
|
473
|
+
<li>
|
|
474
|
+
<a href="#" class="ui-button justify-start" data-variant="ghost">Profile</a>
|
|
475
|
+
</li>
|
|
476
|
+
<li>
|
|
477
|
+
<a href="#" class="ui-button justify-start" data-variant="ghost">Billing</a>
|
|
478
|
+
</li>
|
|
479
|
+
<hr class="ui-separator my-xs" />
|
|
480
|
+
<li class="font-strong text-eyebrow text-muted-foreground p-xs">Session</li>
|
|
481
|
+
<li>
|
|
482
|
+
<a href="#" class="ui-button justify-start" data-variant="ghost">Sign out</a>
|
|
483
|
+
</li>
|
|
484
|
+
</menu>
|
|
485
|
+
</div>
|
|
486
|
+
</ui-menu>
|
|
487
|
+
</div>
|
|
488
|
+
</div>
|
|
489
|
+
|
|
490
|
+
<!-- Dialog -->
|
|
491
|
+
<div class="mb-lg">
|
|
492
|
+
<h2 class="text-h6 font-heading pb-sm">Dialog</h2>
|
|
493
|
+
<button
|
|
494
|
+
class="ui-button"
|
|
495
|
+
type="button"
|
|
496
|
+
command="show-modal"
|
|
497
|
+
commandfor="dialog-components-1"
|
|
498
|
+
>
|
|
499
|
+
Open dialog
|
|
500
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256">
|
|
501
|
+
<rect width="256" height="256" fill="none" />
|
|
502
|
+
<line
|
|
503
|
+
x1="64"
|
|
504
|
+
y1="192"
|
|
505
|
+
x2="192"
|
|
506
|
+
y2="64"
|
|
507
|
+
fill="none"
|
|
508
|
+
stroke="currentColor"
|
|
509
|
+
stroke-linecap="round"
|
|
510
|
+
stroke-linejoin="round"
|
|
511
|
+
stroke-width="16"
|
|
512
|
+
/>
|
|
513
|
+
<polyline
|
|
514
|
+
points="88 64 192 64 192 168"
|
|
515
|
+
fill="none"
|
|
516
|
+
stroke="currentColor"
|
|
517
|
+
stroke-linecap="round"
|
|
518
|
+
stroke-linejoin="round"
|
|
519
|
+
stroke-width="16"
|
|
520
|
+
/>
|
|
521
|
+
</svg>
|
|
522
|
+
</button>
|
|
523
|
+
<dialog id="dialog-components-1" class="ui-dialog" closedby="any">
|
|
524
|
+
<div data-slot="dialog-content">
|
|
525
|
+
<header data-slot="dialog-header">
|
|
526
|
+
<h2 class="text-lg font-heading font-strong">Dialog title</h2>
|
|
527
|
+
<p class="text-muted-foreground">
|
|
528
|
+
Opened with an invoker command. Closes on backdrop click, Escape, or either
|
|
529
|
+
button.
|
|
530
|
+
</p>
|
|
531
|
+
</header>
|
|
532
|
+
<div data-slot="dialog-body">
|
|
533
|
+
<p>Set the size of the dialog with the <code>data-size</code> attribute.</p>
|
|
534
|
+
</div>
|
|
535
|
+
<footer data-slot="dialog-footer">
|
|
536
|
+
<button
|
|
537
|
+
class="ui-button"
|
|
538
|
+
type="button"
|
|
539
|
+
commandfor="dialog-components-1"
|
|
540
|
+
command="close"
|
|
541
|
+
>
|
|
542
|
+
Cancel
|
|
543
|
+
</button>
|
|
544
|
+
<button
|
|
545
|
+
class="ui-button"
|
|
546
|
+
data-variant="primary"
|
|
547
|
+
commandfor="dialog-components-1"
|
|
548
|
+
command="close"
|
|
549
|
+
>
|
|
550
|
+
Accept
|
|
551
|
+
</button>
|
|
552
|
+
</footer>
|
|
553
|
+
</div>
|
|
554
|
+
<button
|
|
555
|
+
class="ui-button"
|
|
556
|
+
data-slot="dialog-close"
|
|
557
|
+
data-size="icon"
|
|
558
|
+
data-variant="ghost"
|
|
559
|
+
type="button"
|
|
560
|
+
commandfor="dialog-components-1"
|
|
561
|
+
command="close"
|
|
562
|
+
aria-label="Close dialog"
|
|
563
|
+
>
|
|
564
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256">
|
|
565
|
+
<rect width="256" height="256" fill="none" />
|
|
566
|
+
<line
|
|
567
|
+
x1="200"
|
|
568
|
+
y1="56"
|
|
569
|
+
x2="56"
|
|
570
|
+
y2="200"
|
|
571
|
+
stroke="currentColor"
|
|
572
|
+
stroke-linecap="round"
|
|
573
|
+
stroke-linejoin="round"
|
|
574
|
+
stroke-width="16"
|
|
575
|
+
/>
|
|
576
|
+
<line
|
|
577
|
+
x1="200"
|
|
578
|
+
y1="200"
|
|
579
|
+
x2="56"
|
|
580
|
+
y2="56"
|
|
581
|
+
stroke="currentColor"
|
|
582
|
+
stroke-linecap="round"
|
|
583
|
+
stroke-linejoin="round"
|
|
584
|
+
stroke-width="16"
|
|
585
|
+
/>
|
|
586
|
+
</svg>
|
|
587
|
+
</button>
|
|
588
|
+
</dialog>
|
|
589
|
+
</div>
|
|
590
|
+
|
|
591
|
+
<!-- Accordion -->
|
|
592
|
+
<div class="mb-lg">
|
|
593
|
+
<h2 class="text-h6 font-heading pb-sm">Accordion</h2>
|
|
594
|
+
<ui-accordion>
|
|
595
|
+
<details class="border-b">
|
|
596
|
+
<summary class="font-strong hover:text-muted-foreground">
|
|
597
|
+
What is an accordion?
|
|
598
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256">
|
|
599
|
+
<rect width="256" height="256" fill="none" />
|
|
600
|
+
<polyline
|
|
601
|
+
points="208 96 128 176 48 96"
|
|
602
|
+
fill="none"
|
|
603
|
+
stroke="currentColor"
|
|
604
|
+
stroke-linecap="round"
|
|
605
|
+
stroke-linejoin="round"
|
|
606
|
+
stroke-width="16"
|
|
607
|
+
/>
|
|
608
|
+
</svg>
|
|
609
|
+
</summary>
|
|
610
|
+
<div class="pb-sm">
|
|
611
|
+
<p>
|
|
612
|
+
A disclosure widget built from the native <code><details></code> and
|
|
613
|
+
<code><summary></code> elements. The open and close animation uses the
|
|
614
|
+
<code>::details-content</code> pseudo-element, with no JavaScript.
|
|
615
|
+
</p>
|
|
616
|
+
</div>
|
|
617
|
+
</details>
|
|
618
|
+
<details class="border-b">
|
|
619
|
+
<summary class="font-strong hover:text-muted-foreground">
|
|
620
|
+
How does it work?
|
|
621
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256">
|
|
622
|
+
<rect width="256" height="256" fill="none" />
|
|
623
|
+
<polyline
|
|
624
|
+
points="208 96 128 176 48 96"
|
|
625
|
+
fill="none"
|
|
626
|
+
stroke="currentColor"
|
|
627
|
+
stroke-linecap="round"
|
|
628
|
+
stroke-linejoin="round"
|
|
629
|
+
stroke-width="16"
|
|
630
|
+
/>
|
|
631
|
+
</svg>
|
|
632
|
+
</summary>
|
|
633
|
+
<div class="pb-sm">
|
|
634
|
+
<p>
|
|
635
|
+
Each item is a separate <code><details></code>, so several can stay open
|
|
636
|
+
at once. Click a summary or focus it and press Enter to toggle.
|
|
637
|
+
</p>
|
|
638
|
+
</div>
|
|
639
|
+
</details>
|
|
640
|
+
<details class="border-b">
|
|
641
|
+
<summary class="font-strong hover:text-muted-foreground">
|
|
642
|
+
Why use it?
|
|
643
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256">
|
|
644
|
+
<rect width="256" height="256" fill="none" />
|
|
645
|
+
<polyline
|
|
646
|
+
points="208 96 128 176 48 96"
|
|
647
|
+
fill="none"
|
|
648
|
+
stroke="currentColor"
|
|
649
|
+
stroke-linecap="round"
|
|
650
|
+
stroke-linejoin="round"
|
|
651
|
+
stroke-width="16"
|
|
652
|
+
/>
|
|
653
|
+
</svg>
|
|
654
|
+
</summary>
|
|
655
|
+
<div class="pb-sm">
|
|
656
|
+
<p>
|
|
657
|
+
Keyboard support, state, and accessibility come from the platform. Zazz only
|
|
658
|
+
styles the chrome through theme tokens.
|
|
659
|
+
</p>
|
|
660
|
+
</div>
|
|
661
|
+
</details>
|
|
662
|
+
</ui-accordion>
|
|
663
|
+
</div>
|
|
664
|
+
|
|
665
|
+
<!-- Tabs -->
|
|
666
|
+
<div class="mb-lg">
|
|
667
|
+
<h2 class="text-h6 font-heading pb-sm">Tabs</h2>
|
|
668
|
+
<ui-tabs class="w-full">
|
|
669
|
+
<div data-slot="tabs-list" role="tablist">
|
|
670
|
+
<div data-slot="tabs-indicator" aria-hidden="true"></div>
|
|
671
|
+
<input type="radio" role="tab" name="components-tabs" id="ctab-1" checked />
|
|
672
|
+
<label for="ctab-1" data-slot="tabs-label"
|
|
673
|
+
><span data-slot="tabs-label-text">Account</span></label
|
|
674
|
+
>
|
|
675
|
+
<input type="radio" role="tab" name="components-tabs" id="ctab-2" />
|
|
676
|
+
<label for="ctab-2" data-slot="tabs-label"
|
|
677
|
+
><span data-slot="tabs-label-text">Billing</span></label
|
|
678
|
+
>
|
|
679
|
+
<input type="radio" role="tab" name="components-tabs" id="ctab-3" />
|
|
680
|
+
<label for="ctab-3" data-slot="tabs-label"
|
|
681
|
+
><span data-slot="tabs-label-text">Notifications</span></label
|
|
682
|
+
>
|
|
683
|
+
</div>
|
|
684
|
+
<div class="border rounded-md p-md w-full" data-slot="tabs-panel" role="tabpanel">
|
|
685
|
+
<h3 class="text-lg font-strong">Account</h3>
|
|
686
|
+
<p class="text-muted-foreground mt-xs">Manage your profile, email, and password.</p>
|
|
687
|
+
</div>
|
|
688
|
+
<div class="border rounded-md p-md w-full" data-slot="tabs-panel" role="tabpanel">
|
|
689
|
+
<h3 class="text-lg font-strong">Billing</h3>
|
|
690
|
+
<p class="text-muted-foreground mt-xs">
|
|
691
|
+
Review invoices and update your payment method.
|
|
692
|
+
</p>
|
|
693
|
+
</div>
|
|
694
|
+
<div class="border rounded-md p-md w-full" data-slot="tabs-panel" role="tabpanel">
|
|
695
|
+
<h3 class="text-lg font-strong">Notifications</h3>
|
|
696
|
+
<p class="text-muted-foreground mt-xs">
|
|
697
|
+
Choose what we email you about and how often.
|
|
698
|
+
</p>
|
|
699
|
+
</div>
|
|
700
|
+
</ui-tabs>
|
|
701
|
+
</div>
|
|
702
|
+
|
|
703
|
+
<!-- Cards -->
|
|
704
|
+
<div class="mb-lg">
|
|
705
|
+
<h2 class="text-h6 font-heading pb-sm">Cards</h2>
|
|
706
|
+
<div class="grid grid-cols-1 @sm:grid-cols-2 @lg:grid-cols-3 gap-md">
|
|
707
|
+
<a class="grid cursor-pointer" href="#">
|
|
708
|
+
<div
|
|
709
|
+
class="grid gap-sm bg-card text-card-foreground rounded-md shadow-sm overflow-clip"
|
|
710
|
+
>
|
|
711
|
+
<figure class="grid aspect-landscape rounded-t-md overflow-clip">
|
|
712
|
+
<img
|
|
713
|
+
class="size-full object-cover hover:scale-102 hover:opacity-75 transition"
|
|
714
|
+
width="300"
|
|
715
|
+
height="200"
|
|
716
|
+
loading="lazy"
|
|
717
|
+
src="https://images.unsplash.com/photo-1500382017468-9049fed747ef?auto=format&fit=crop&w=300&h=200&q=60"
|
|
718
|
+
alt="Zebras grazing at dawn on the savanna"
|
|
719
|
+
/>
|
|
720
|
+
</figure>
|
|
721
|
+
<div class="grid gap-sm px-sm pb-sm">
|
|
722
|
+
<header class="grid gap-xs">
|
|
723
|
+
<div class="flex items-center gap-xs">
|
|
724
|
+
<span class="ui-badge" data-variant="muted">Field notes</span>
|
|
725
|
+
</div>
|
|
726
|
+
<hgroup class="grid gap-xs">
|
|
727
|
+
<h3 class="text-lg font-heading">How quickly zebras jump</h3>
|
|
728
|
+
<p class="text-sm text-muted-foreground line-clamp-2">
|
|
729
|
+
Striped coats and sudden bursts of speed help herds evade predators when
|
|
730
|
+
the grasslands go quiet at dusk.
|
|
731
|
+
</p>
|
|
732
|
+
</hgroup>
|
|
733
|
+
</header>
|
|
734
|
+
<footer class="grid justify-start gap-sm pt-sm border-t">
|
|
735
|
+
<div class="text-link">Read article</div>
|
|
736
|
+
</footer>
|
|
737
|
+
</div>
|
|
738
|
+
</div>
|
|
739
|
+
</a>
|
|
740
|
+
|
|
741
|
+
<a class="grid cursor-pointer" href="#">
|
|
742
|
+
<div
|
|
743
|
+
class="grid gap-sm bg-card text-card-foreground rounded-md shadow-sm overflow-clip"
|
|
744
|
+
>
|
|
745
|
+
<figure class="grid aspect-landscape rounded-t-md overflow-clip">
|
|
746
|
+
<img
|
|
747
|
+
class="size-full object-cover hover:scale-102 hover:opacity-75 transition"
|
|
748
|
+
width="300"
|
|
749
|
+
height="200"
|
|
750
|
+
loading="lazy"
|
|
751
|
+
src="https://images.unsplash.com/photo-1564760055775-d63b17a55c44?auto=format&fit=crop&w=300&h=200&q=60"
|
|
752
|
+
alt="A lion resting in tall golden grass"
|
|
753
|
+
/>
|
|
754
|
+
</figure>
|
|
755
|
+
<div class="grid gap-sm px-sm pb-sm">
|
|
756
|
+
<header class="grid gap-xs">
|
|
757
|
+
<div class="flex items-center gap-xs">
|
|
758
|
+
<span class="ui-badge" data-variant="muted">Wildlife</span>
|
|
759
|
+
</div>
|
|
760
|
+
<hgroup class="grid gap-xs">
|
|
761
|
+
<h3 class="text-lg font-heading">Lions at golden hour</h3>
|
|
762
|
+
<p class="text-sm text-muted-foreground line-clamp-2">
|
|
763
|
+
Warm light and long shadows make dawn patrols the best time to photograph
|
|
764
|
+
big cats on the open plain.
|
|
765
|
+
</p>
|
|
766
|
+
</hgroup>
|
|
767
|
+
</header>
|
|
768
|
+
<footer class="grid justify-start gap-sm pt-sm border-t">
|
|
769
|
+
<div class="text-link">View gallery</div>
|
|
770
|
+
</footer>
|
|
771
|
+
</div>
|
|
772
|
+
</div>
|
|
773
|
+
</a>
|
|
774
|
+
|
|
775
|
+
<a class="grid cursor-pointer" href="#">
|
|
776
|
+
<div
|
|
777
|
+
class="grid gap-sm bg-card text-card-foreground rounded-md shadow-sm overflow-clip"
|
|
778
|
+
>
|
|
779
|
+
<figure class="grid aspect-landscape rounded-t-md overflow-clip">
|
|
780
|
+
<img
|
|
781
|
+
class="size-full object-cover hover:scale-102 hover:opacity-75 transition"
|
|
782
|
+
width="300"
|
|
783
|
+
height="200"
|
|
784
|
+
loading="lazy"
|
|
785
|
+
src="https://images.unsplash.com/photo-1511735111819-9a3f7709049c?auto=format&fit=crop&w=300&h=200&q=60"
|
|
786
|
+
alt="Elephants crossing a dusty riverbed"
|
|
787
|
+
/>
|
|
788
|
+
</figure>
|
|
789
|
+
<div class="grid gap-sm px-sm pb-sm">
|
|
790
|
+
<header class="grid gap-xs">
|
|
791
|
+
<div class="flex items-center gap-xs">
|
|
792
|
+
<span class="ui-badge" data-variant="muted">Research</span>
|
|
793
|
+
</div>
|
|
794
|
+
<hgroup class="grid gap-xs">
|
|
795
|
+
<h3 class="text-lg font-heading">Migration patterns decoded</h3>
|
|
796
|
+
<p class="text-sm text-muted-foreground line-clamp-2">
|
|
797
|
+
Satellite collars reveal ancient routes herds still follow each dry season
|
|
798
|
+
across the floodplain.
|
|
799
|
+
</p>
|
|
800
|
+
</hgroup>
|
|
801
|
+
</header>
|
|
802
|
+
<footer class="grid justify-start gap-sm pt-sm border-t">
|
|
803
|
+
<div class="text-link">See the data</div>
|
|
804
|
+
</footer>
|
|
805
|
+
</div>
|
|
806
|
+
</div>
|
|
807
|
+
</a>
|
|
808
|
+
</div>
|
|
809
|
+
</div>
|
|
810
|
+
|
|
811
|
+
<!-- Avatars -->
|
|
812
|
+
<div>
|
|
813
|
+
<h2 class="text-h6 font-heading pb-sm">Avatars</h2>
|
|
814
|
+
<div class="flex items-center gap-md">
|
|
815
|
+
<div class="flex items-center gap-xs">
|
|
816
|
+
<figure
|
|
817
|
+
class="grid grid-area-pile size-lg bg-background border rounded-full overflow-clip"
|
|
818
|
+
role="img"
|
|
819
|
+
>
|
|
820
|
+
<img
|
|
821
|
+
class="size-full object-cover order-last bg-transparent"
|
|
822
|
+
width="64"
|
|
823
|
+
height="64"
|
|
824
|
+
loading="lazy"
|
|
825
|
+
src="https://images.unsplash.com/photo-1535713875002-d1d0cf377fde?auto=format&fit=facearea&facepad=2&w=64&h=64&q=90"
|
|
826
|
+
alt="John Doe"
|
|
827
|
+
aria-hidden="true"
|
|
828
|
+
/>
|
|
829
|
+
<figcaption
|
|
830
|
+
class="order-first bg-muted size-full text-muted-foreground flex items-center justify-center text-center text-md font-strong"
|
|
831
|
+
>
|
|
832
|
+
<span class="sr-only">John Doe</span>
|
|
833
|
+
<span aria-hidden="true">JD</span>
|
|
834
|
+
</figcaption>
|
|
835
|
+
</figure>
|
|
836
|
+
<div class="flex flex-col">
|
|
837
|
+
<span class="text-sm font-strong leading-none">John Doe</span>
|
|
838
|
+
<span class="text-xs text-muted-foreground">Founder, ACME Inc.</span>
|
|
839
|
+
</div>
|
|
840
|
+
</div>
|
|
841
|
+
|
|
842
|
+
<div class="flex items-center gap-xs">
|
|
843
|
+
<figure
|
|
844
|
+
class="grid grid-area-pile size-lg bg-background border rounded-full overflow-clip"
|
|
845
|
+
role="img"
|
|
846
|
+
>
|
|
847
|
+
<figcaption
|
|
848
|
+
class="order-first bg-muted size-full text-muted-foreground flex items-center justify-center text-center text-md font-strong"
|
|
849
|
+
>
|
|
850
|
+
<span class="sr-only">Ada Lovelace</span>
|
|
851
|
+
<span aria-hidden="true">AL</span>
|
|
852
|
+
</figcaption>
|
|
853
|
+
</figure>
|
|
854
|
+
<div class="flex flex-col">
|
|
855
|
+
<span class="text-sm font-strong leading-none">Ada Lovelace</span>
|
|
856
|
+
<span class="text-xs text-muted-foreground">Initials fallback</span>
|
|
857
|
+
</div>
|
|
858
|
+
</div>
|
|
859
|
+
</div>
|
|
860
|
+
</div>
|
|
861
|
+
</div>
|
|
862
|
+
</section>
|
|
863
|
+
|
|
864
|
+
<!-- Prose, in an article reading column -->
|
|
865
|
+
<article class="py-xl border-t">
|
|
866
|
+
<div class="container ui-prose" data-variant="article" data-container="sm">
|
|
867
|
+
<hgroup>
|
|
868
|
+
<span class="text-eyebrow">Prose</span>
|
|
869
|
+
<h2>Long-form content</h2>
|
|
870
|
+
<p class="text-lg text-muted-foreground">
|
|
871
|
+
Wrap rich text in <code>.ui-prose</code> for tuned typography. Body and paragraphs
|
|
872
|
+
default to <code>.text-md</code>; override size with <code>.text-xs</code> through
|
|
873
|
+
<code>.text-xl</code>.
|
|
874
|
+
</p>
|
|
875
|
+
</hgroup>
|
|
876
|
+
|
|
877
|
+
<hgroup>
|
|
878
|
+
<h1>How vexingly quick daft zebras jump.</h1>
|
|
879
|
+
<p>
|
|
880
|
+
Default paragraph — no class needed; matches body size. Lorem ipsum dolor sit amet,
|
|
881
|
+
consectetur adipiscing elit.
|
|
882
|
+
</p>
|
|
883
|
+
|
|
884
|
+
<h2>How vexingly quick daft zebras jump.</h2>
|
|
885
|
+
<p>
|
|
886
|
+
Default paragraph — no class needed; matches body size. Lorem ipsum dolor sit amet,
|
|
887
|
+
consectetur adipiscing elit.
|
|
888
|
+
</p>
|
|
889
|
+
|
|
890
|
+
<h3>How vexingly quick daft zebras jump.</h3>
|
|
891
|
+
<p>
|
|
892
|
+
Default paragraph — no class needed; matches body size. Lorem ipsum dolor sit amet,
|
|
893
|
+
consectetur adipiscing elit.
|
|
894
|
+
</p>
|
|
895
|
+
|
|
896
|
+
<h4>How vexingly quick daft zebras jump.</h4>
|
|
897
|
+
<p>
|
|
898
|
+
Default paragraph — no class needed; matches body size. Lorem ipsum dolor sit amet,
|
|
899
|
+
consectetur adipiscing elit.
|
|
900
|
+
</p>
|
|
901
|
+
|
|
902
|
+
<h5>How vexingly quick daft zebras jump.</h5>
|
|
903
|
+
<p>
|
|
904
|
+
Default paragraph — no class needed; matches body size. Lorem ipsum dolor sit amet,
|
|
905
|
+
consectetur adipiscing elit.
|
|
906
|
+
</p>
|
|
907
|
+
|
|
908
|
+
<h6>How vexingly quick daft zebras jump.</h6>
|
|
909
|
+
<p>
|
|
910
|
+
Default paragraph — no class needed; matches body size. Lorem ipsum dolor sit amet,
|
|
911
|
+
consectetur adipiscing elit.
|
|
912
|
+
</p>
|
|
913
|
+
</hgroup>
|
|
914
|
+
|
|
915
|
+
<hr />
|
|
916
|
+
|
|
917
|
+
<span class="text-eyebrow">text-xl</span>
|
|
918
|
+
<p class="text-xl">
|
|
919
|
+
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit
|
|
920
|
+
amet ipsum mauris.
|
|
921
|
+
</p>
|
|
922
|
+
|
|
923
|
+
<span class="text-eyebrow">text-lg</span>
|
|
924
|
+
<p class="text-lg">
|
|
925
|
+
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit
|
|
926
|
+
amet ipsum mauris.
|
|
927
|
+
</p>
|
|
928
|
+
|
|
929
|
+
<span class="text-eyebrow">text-md</span>
|
|
930
|
+
<p>
|
|
931
|
+
Default paragraph — no class needed; matches body size. Lorem ipsum dolor sit amet,
|
|
932
|
+
consectetur adipiscing elit.
|
|
933
|
+
</p>
|
|
934
|
+
|
|
935
|
+
<span class="text-eyebrow">text-sm</span>
|
|
936
|
+
<p class="text-sm">
|
|
937
|
+
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit
|
|
938
|
+
amet ipsum mauris.
|
|
939
|
+
</p>
|
|
940
|
+
|
|
941
|
+
<span class="text-eyebrow">text-xs</span>
|
|
942
|
+
<p class="text-xs">
|
|
943
|
+
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec a diam lectus. Sed sit
|
|
944
|
+
amet ipsum mauris.
|
|
945
|
+
</p>
|
|
946
|
+
|
|
947
|
+
<hr />
|
|
948
|
+
|
|
949
|
+
<hgroup>
|
|
950
|
+
<span class="text-eyebrow">Prose</span>
|
|
951
|
+
<h2>Paragraph spacing</h2>
|
|
952
|
+
<p class="text-lg text-muted-foreground">
|
|
953
|
+
Wrap rich text in <code>.ui-prose</code> for tuned typography. Body and paragraphs
|
|
954
|
+
default to <code>.text-md</code>; override size with <code>.text-xs</code> through
|
|
955
|
+
<code>.text-xl</code>.
|
|
956
|
+
</p>
|
|
957
|
+
</hgroup>
|
|
958
|
+
|
|
959
|
+
<p>
|
|
960
|
+
Inline semantics: <strong>strong emphasis</strong>, <em>italic emphasis</em>,
|
|
961
|
+
<a href="#">a prose link</a>, and <code>inline code</code>.
|
|
962
|
+
</p>
|
|
963
|
+
|
|
964
|
+
<blockquote>
|
|
965
|
+
<p>Typography is the craft of endowing human language with a durable visual form.</p>
|
|
966
|
+
<cite>— Robert Bringhurst</cite>
|
|
967
|
+
</blockquote>
|
|
968
|
+
|
|
969
|
+
<figure>
|
|
970
|
+
<figcaption>Unordered list</figcaption>
|
|
971
|
+
<ul>
|
|
972
|
+
<li>Unordered list item with disc markers.</li>
|
|
973
|
+
<li>Sentence case headings and labels throughout.</li>
|
|
974
|
+
<li>Semantic role tokens, so dark mode swaps for free.</li>
|
|
975
|
+
</ul>
|
|
976
|
+
</figure>
|
|
977
|
+
|
|
978
|
+
<figure>
|
|
979
|
+
<figcaption>Ordered list</figcaption>
|
|
980
|
+
<ol>
|
|
981
|
+
<li>Ordered list item one.</li>
|
|
982
|
+
<li>Ordered list item two.</li>
|
|
983
|
+
<li>Ordered list item three.</li>
|
|
984
|
+
</ol>
|
|
985
|
+
</figure>
|
|
986
|
+
|
|
987
|
+
<dl>
|
|
988
|
+
<dt>Soliloquy</dt>
|
|
989
|
+
<dd>
|
|
990
|
+
In drama, where a character speaks to themselves, representing their inner thoughts or
|
|
991
|
+
feelings and in the process relaying them to the audience (but not to other
|
|
992
|
+
characters.)
|
|
993
|
+
</dd>
|
|
994
|
+
<dt>Monologue</dt>
|
|
995
|
+
<dd>
|
|
996
|
+
In drama, where a character speaks their thoughts out loud to share them with the
|
|
997
|
+
audience and any other characters present.
|
|
998
|
+
</dd>
|
|
999
|
+
<dt>Aside</dt>
|
|
1000
|
+
<dd>
|
|
1001
|
+
In drama, where a character shares a comment only with the audience for humorous or
|
|
1002
|
+
dramatic effect. This is usually a feeling, thought, or piece of additional background
|
|
1003
|
+
information.
|
|
1004
|
+
</dd>
|
|
1005
|
+
</dl>
|
|
1006
|
+
|
|
1007
|
+
<figure>
|
|
1008
|
+
<img
|
|
1009
|
+
sizes="auto"
|
|
1010
|
+
loading="lazy"
|
|
1011
|
+
width="800"
|
|
1012
|
+
height="400"
|
|
1013
|
+
src="https://placehold.co/800x400"
|
|
1014
|
+
alt="Placeholder demonstrating figure and image styling within prose"
|
|
1015
|
+
/>
|
|
1016
|
+
<figcaption>
|
|
1017
|
+
Figure with caption — images pick up radius and border from prose tokens.
|
|
1018
|
+
</figcaption>
|
|
1019
|
+
</figure>
|
|
1020
|
+
</div>
|
|
1021
|
+
</article>
|
|
1022
|
+
</main>
|
|
1023
|
+
|
|
1024
|
+
<footer class="border-t" data-transition-layer="global-footer">
|
|
1025
|
+
<div class="container py-xl">
|
|
1026
|
+
<div class="flex items-center justify-between gap-md">
|
|
1027
|
+
<div class="text-h6 font-black">Zazz tests</div>
|
|
1028
|
+
<menu class="flex gap-sm">
|
|
1029
|
+
<li><a class="ui-button" data-variant="link" href="about.html">About</a></li>
|
|
1030
|
+
<li><a class="ui-button" data-variant="link" href="layout.html">Layout</a></li>
|
|
1031
|
+
<li><a class="ui-button" data-variant="link" href="responsive.html">Responsive</a></li>
|
|
1032
|
+
<li><a class="ui-button" data-variant="link" href="products.html">Products</a></li>
|
|
1033
|
+
<li><a class="ui-button" data-variant="link" href="components.html">Components</a></li>
|
|
1034
|
+
<li><a class="ui-button" data-variant="link" href="forms.html">Forms</a></li>
|
|
1035
|
+
</menu>
|
|
1036
|
+
</div>
|
|
1037
|
+
</div>
|
|
1038
|
+
</footer>
|
|
1039
|
+
</body>
|
|
1040
|
+
</html>
|