zabi-components 8.1.0 → 9.0.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 +1011 -0
- package/README.md +1 -1
- package/THEME.md +18 -5
- package/THEMING.md +308 -74
- package/dist/atoms/ActionPanel.svelte +1 -1
- package/dist/atoms/Avatar.svelte +19 -3
- package/dist/atoms/Avatar.svelte.d.ts +12 -0
- package/dist/atoms/Badge.svelte +37 -8
- package/dist/atoms/Badge.svelte.d.ts +6 -0
- package/dist/atoms/Block.svelte +74 -0
- package/dist/atoms/Block.svelte.d.ts +29 -0
- package/dist/atoms/Button.svelte +52 -15
- package/dist/atoms/Button.svelte.d.ts +3 -2
- package/dist/atoms/Card.svelte +181 -25
- package/dist/atoms/Card.svelte.d.ts +55 -3
- package/dist/atoms/Checkbox.svelte +33 -0
- package/dist/atoms/Checkbox.svelte.d.ts +27 -0
- package/dist/atoms/Chip.svelte +351 -0
- package/dist/atoms/Chip.svelte.d.ts +57 -0
- package/dist/atoms/CodeField.svelte +385 -0
- package/dist/atoms/CodeField.svelte.d.ts +61 -0
- package/dist/atoms/ColorPicker.svelte +1 -0
- package/dist/atoms/DateField.svelte +41 -3
- package/dist/atoms/DateField.svelte.d.ts +31 -3
- package/dist/atoms/FloatingActionButton.svelte +5 -3
- package/dist/atoms/FloatingActionButton.svelte.d.ts +1 -1
- package/dist/atoms/Heading.svelte +27 -1
- package/dist/atoms/Heading.svelte.d.ts +7 -0
- package/dist/atoms/IconButton.svelte +81 -9
- package/dist/atoms/IconButton.svelte.d.ts +13 -0
- package/dist/atoms/Input.svelte +10 -5
- package/dist/atoms/Input.svelte.d.ts +3 -2
- package/dist/atoms/List.svelte +3 -2
- package/dist/atoms/ListItem.svelte +31 -7
- package/dist/atoms/ListItem.svelte.d.ts +6 -0
- package/dist/atoms/PickerField.svelte +239 -0
- package/dist/atoms/PickerField.svelte.d.ts +67 -0
- package/dist/atoms/Progress.svelte +78 -17
- package/dist/atoms/Progress.svelte.d.ts +11 -1
- package/dist/atoms/Radio.svelte +32 -0
- package/dist/atoms/Radio.svelte.d.ts +26 -0
- package/dist/atoms/Rating.svelte +132 -6
- package/dist/atoms/Rating.svelte.d.ts +24 -3
- package/dist/atoms/Select.svelte +24 -26
- package/dist/atoms/Select.svelte.d.ts +12 -0
- package/dist/atoms/SelectionControl.svelte +99 -6
- package/dist/atoms/SelectionControl.svelte.d.ts +25 -0
- package/dist/atoms/Skeleton.svelte +114 -18
- package/dist/atoms/Skeleton.svelte.d.ts +30 -3
- package/dist/atoms/SkeletonGroup.svelte +43 -0
- package/dist/atoms/SkeletonGroup.svelte.d.ts +20 -0
- package/dist/atoms/Slider.svelte +35 -0
- package/dist/atoms/Sparkline.svelte +109 -0
- package/dist/atoms/Sparkline.svelte.d.ts +27 -0
- package/dist/atoms/SpeechBubble.svelte +187 -0
- package/dist/atoms/SpeechBubble.svelte.d.ts +33 -0
- package/dist/atoms/Stat.svelte +72 -0
- package/dist/atoms/Stat.svelte.d.ts +19 -0
- package/dist/atoms/TemporalField.svelte +342 -10
- package/dist/atoms/TemporalField.svelte.d.ts +20 -4
- package/dist/atoms/Textarea.svelte +100 -5
- package/dist/atoms/Textarea.svelte.d.ts +21 -0
- package/dist/atoms/TimeColumn.svelte +150 -0
- package/dist/atoms/TimeColumn.svelte.d.ts +25 -0
- package/dist/atoms/TimeField.svelte +46 -3
- package/dist/atoms/TimeField.svelte.d.ts +34 -3
- package/dist/atoms/Toast.svelte +6 -5
- package/dist/atoms/Toggle.svelte +61 -10
- package/dist/atoms/Toggle.svelte.d.ts +15 -0
- package/dist/atoms/Tooltip.svelte +20 -1
- package/dist/atoms/Tooltip.svelte.d.ts +7 -0
- package/dist/atoms/index.d.ts +21 -0
- package/dist/atoms/index.js +17 -0
- package/dist/atoms/selection-control.styles.d.ts +15 -4
- package/dist/atoms/selection-control.styles.js +16 -5
- package/dist/components/atoms/index.d.ts +21 -0
- package/dist/components/atoms/index.d.ts.map +1 -1
- package/dist/components/atoms/selection-control.styles.d.ts +15 -4
- package/dist/components/atoms/selection-control.styles.d.ts.map +1 -1
- package/dist/components/index.d.ts +27 -3
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/map.d.ts +11 -0
- package/dist/components/map.d.ts.map +1 -0
- package/dist/components/molecules/index.d.ts +7 -2
- package/dist/components/molecules/index.d.ts.map +1 -1
- package/dist/components/molecules/toast-store.d.ts +30 -0
- package/dist/components/molecules/toast-store.d.ts.map +1 -1
- package/dist/components/organisms/index.d.ts +6 -1
- package/dist/components/organisms/index.d.ts.map +1 -1
- package/dist/components/types/variants.d.ts +12 -3
- package/dist/components/types/variants.d.ts.map +1 -1
- package/dist/components/util/app-shell.d.ts +55 -4
- package/dist/components/util/app-shell.d.ts.map +1 -1
- package/dist/components/util/avatar.d.ts +3 -0
- package/dist/components/util/avatar.d.ts.map +1 -1
- package/dist/components/util/bottom-tab-bar.d.ts +6 -0
- package/dist/components/util/bottom-tab-bar.d.ts.map +1 -1
- package/dist/components/util/chart.d.ts +140 -0
- package/dist/components/util/chart.d.ts.map +1 -0
- package/dist/components/util/chip.d.ts +66 -0
- package/dist/components/util/chip.d.ts.map +1 -0
- package/dist/components/util/cn.d.ts.map +1 -1
- package/dist/components/util/code-field.d.ts +63 -0
- package/dist/components/util/code-field.d.ts.map +1 -0
- package/dist/components/util/collapsible.d.ts +6 -0
- package/dist/components/util/collapsible.d.ts.map +1 -1
- package/dist/components/util/display-voice.d.ts +10 -0
- package/dist/components/util/display-voice.d.ts.map +1 -0
- package/dist/components/util/field-control.d.ts +30 -0
- package/dist/components/util/field-control.d.ts.map +1 -0
- package/dist/components/util/field.d.ts +6 -0
- package/dist/components/util/field.d.ts.map +1 -1
- package/dist/components/util/focus-utils.d.ts +2 -0
- package/dist/components/util/focus-utils.d.ts.map +1 -1
- package/dist/components/util/map-view.d.ts +144 -0
- package/dist/components/util/map-view.d.ts.map +1 -0
- package/dist/components/util/photo.d.ts +19 -0
- package/dist/components/util/photo.d.ts.map +1 -1
- package/dist/components/util/progress.d.ts +19 -0
- package/dist/components/util/progress.d.ts.map +1 -0
- package/dist/components/util/scroll-edge.d.ts +33 -0
- package/dist/components/util/scroll-edge.d.ts.map +1 -0
- package/dist/components/util/sheet-drag.d.ts +25 -1
- package/dist/components/util/sheet-drag.d.ts.map +1 -1
- package/dist/components/util/skeleton.d.ts +15 -0
- package/dist/components/util/skeleton.d.ts.map +1 -0
- package/dist/components/util/sliding-indicator.d.ts +25 -0
- package/dist/components/util/sliding-indicator.d.ts.map +1 -0
- package/dist/components/util/temporal-field.d.ts +89 -0
- package/dist/components/util/temporal-field.d.ts.map +1 -0
- package/dist/components/util/toaster.d.ts +40 -0
- package/dist/components/util/toaster.d.ts.map +1 -1
- package/dist/components/util/tone-surface.d.ts +34 -0
- package/dist/components/util/tone-surface.d.ts.map +1 -0
- package/dist/components/util/top-navbar.d.ts +26 -2
- package/dist/components/util/top-navbar.d.ts.map +1 -1
- package/dist/components/util/zabi-strings.d.ts +9 -0
- package/dist/components/util/zabi-strings.d.ts.map +1 -1
- package/dist/create-theme/cli.js +6 -2
- package/dist/create-theme/index.d.ts +17 -3
- package/dist/create-theme/index.js +252 -35
- package/dist/create-theme/lib/resolve.js +97 -0
- package/dist/create-theme/theme-data.js +1618 -90
- package/dist/index.d.ts +27 -3
- package/dist/index.js +18 -0
- package/dist/map.d.ts +10 -0
- package/dist/map.js +9 -0
- package/dist/molecules/Alert.svelte +31 -12
- package/dist/molecules/Alert.svelte.d.ts +12 -1
- package/dist/molecules/AppBar.svelte +287 -28
- package/dist/molecules/AppBar.svelte.d.ts +62 -0
- package/dist/molecules/AvatarGroup.svelte +1 -1
- package/dist/molecules/BarChart.svelte +381 -0
- package/dist/molecules/BarChart.svelte.d.ts +45 -0
- package/dist/molecules/BottomSheet.svelte +88 -20
- package/dist/molecules/BottomSheet.svelte.d.ts +17 -1
- package/dist/molecules/BottomTabBar.svelte +134 -28
- package/dist/molecules/BottomTabBar.svelte.d.ts +36 -2
- package/dist/molecules/Calendar.svelte.d.ts +1 -1
- package/dist/molecules/ChipGroup.svelte +325 -0
- package/dist/molecules/ChipGroup.svelte.d.ts +41 -0
- package/dist/molecules/Collapsible.svelte +158 -54
- package/dist/molecules/Collapsible.svelte.d.ts +23 -6
- package/dist/molecules/CollapsibleGroup.svelte +16 -6
- package/dist/molecules/ConfirmDialog.svelte +5 -1
- package/dist/molecules/ConfirmDialog.svelte.d.ts +3 -0
- package/dist/molecules/Drawer.svelte +33 -12
- package/dist/molecules/Dropdown.svelte +9 -1
- package/dist/molecules/Dropdown.svelte.d.ts +2 -0
- package/dist/molecules/DropdownItem.svelte +1 -1
- package/dist/molecules/ImageUpload.svelte +230 -120
- package/dist/molecules/ImageUpload.svelte.d.ts +38 -3
- package/dist/molecules/LineChart.svelte +459 -0
- package/dist/molecules/LineChart.svelte.d.ts +53 -0
- package/dist/molecules/MapView.svelte +565 -0
- package/dist/molecules/MapView.svelte.d.ts +88 -0
- package/dist/molecules/Modal.svelte +11 -6
- package/dist/molecules/PhotoGrid.svelte +100 -10
- package/dist/molecules/PhotoGrid.svelte.d.ts +11 -0
- package/dist/molecules/PhotoViewer.svelte +121 -24
- package/dist/molecules/PhotoViewer.svelte.d.ts +18 -0
- package/dist/molecules/PieChart.svelte +421 -0
- package/dist/molecules/PieChart.svelte.d.ts +51 -0
- package/dist/molecules/RadioGroup.svelte +20 -4
- package/dist/molecules/RadioGroup.svelte.d.ts +5 -0
- package/dist/molecules/SegmentedControl.svelte +136 -3
- package/dist/molecules/SegmentedControl.svelte.d.ts +6 -0
- package/dist/molecules/SidebarFooter.svelte +1 -1
- package/dist/molecules/SidebarNavSection.svelte +1 -1
- package/dist/molecules/SortableList.svelte +1 -0
- package/dist/molecules/Stepper.svelte +21 -7
- package/dist/molecules/StickyActionBar.svelte +67 -8
- package/dist/molecules/StickyActionBar.svelte.d.ts +14 -1
- package/dist/molecules/Tabs.svelte +79 -2
- package/dist/molecules/Toaster.svelte +171 -7
- package/dist/molecules/Toaster.svelte.d.ts +60 -2
- package/dist/molecules/ToasterToast.svelte +292 -60
- package/dist/molecules/ToasterToast.svelte.d.ts +6 -0
- package/dist/molecules/UnsavedChangesBar.svelte +13 -2
- package/dist/molecules/index.d.ts +7 -2
- package/dist/molecules/index.js +4 -0
- package/dist/molecules/toast-store.d.ts +30 -0
- package/dist/molecules/toast-store.js +4 -1
- package/dist/organisms/AppNavigation.svelte +440 -0
- package/dist/organisms/AppNavigation.svelte.d.ts +72 -0
- package/dist/organisms/AppShell.svelte +539 -39
- package/dist/organisms/AppShell.svelte.d.ts +102 -6
- package/dist/organisms/AppShellHeaderPart.svelte +163 -0
- package/dist/organisms/AppShellHeaderPart.svelte.d.ts +57 -0
- package/dist/organisms/SidebarNavigation.svelte +23 -36
- package/dist/organisms/SidebarPanel.svelte +10 -14
- package/dist/organisms/SidebarPanel.svelte.d.ts +1 -0
- package/dist/organisms/SidebarShell.svelte +2 -3
- package/dist/organisms/TopNavbar.svelte +117 -28
- package/dist/organisms/TopNavbar.svelte.d.ts +22 -1
- package/dist/organisms/TopNavbarSheetContent.svelte +145 -0
- package/dist/organisms/TopNavbarSheetContent.svelte.d.ts +24 -0
- package/dist/organisms/index.d.ts +6 -1
- package/dist/organisms/index.js +4 -0
- package/dist/types/components.d.ts +17 -1
- package/dist/types/components.d.ts.map +1 -1
- package/dist/types/index.d.ts +497 -10
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/variants.ts +14 -3
- package/dist/util/app-shell.d.ts +55 -4
- package/dist/util/app-shell.js +32 -7
- package/dist/util/avatar.d.ts +3 -0
- package/dist/util/bottom-tab-bar.d.ts +6 -0
- package/dist/util/chart.d.ts +139 -0
- package/dist/util/chart.js +305 -0
- package/dist/util/chip.d.ts +65 -0
- package/dist/util/chip.js +58 -0
- package/dist/util/cn.js +28 -2
- package/dist/util/code-field.d.ts +62 -0
- package/dist/util/code-field.js +112 -0
- package/dist/util/collapsible.d.ts +6 -0
- package/dist/util/display-voice.d.ts +9 -0
- package/dist/util/display-voice.js +9 -0
- package/dist/util/field-control.d.ts +29 -0
- package/dist/util/field-control.js +32 -0
- package/dist/util/field.d.ts +6 -0
- package/dist/util/focus-utils.d.ts +2 -0
- package/dist/util/focus-utils.js +4 -0
- package/dist/util/map-view.d.ts +143 -0
- package/dist/util/map-view.js +121 -0
- package/dist/util/photo.d.ts +19 -0
- package/dist/util/photo.js +3 -0
- package/dist/util/progress.d.ts +18 -0
- package/dist/util/progress.js +17 -0
- package/dist/util/scroll-edge.d.ts +32 -0
- package/dist/util/scroll-edge.js +87 -0
- package/dist/util/sheet-drag.d.ts +25 -1
- package/dist/util/sheet-drag.js +71 -1
- package/dist/util/skeleton.d.ts +14 -0
- package/dist/util/skeleton.js +22 -0
- package/dist/util/sliding-indicator.d.ts +24 -0
- package/dist/util/sliding-indicator.js +44 -0
- package/dist/util/temporal-field.d.ts +88 -0
- package/dist/util/temporal-field.js +136 -0
- package/dist/util/toaster.d.ts +40 -0
- package/dist/util/toaster.js +55 -0
- package/dist/util/tone-surface.d.ts +33 -0
- package/dist/util/tone-surface.js +35 -0
- package/dist/util/top-navbar.d.ts +26 -2
- package/dist/util/top-navbar.js +23 -0
- package/dist/util/zabi-strings.d.ts +9 -0
- package/dist/zabi-components-colors.css +9 -3
- package/dist/zabi-components-theme-dark-only.css +474 -164
- package/dist/zabi-components-theme-dark.css +474 -164
- package/dist/zabi-components-theme-only.css +933 -99
- package/dist/zabi-components-theme.css +933 -99
- package/dist/zabi-components.css +2275 -321
- package/package.json +11 -1
package/dist/atoms/Toggle.svelte
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
|
+
import type { Snippet } from "svelte";
|
|
2
3
|
import type { HTMLButtonAttributes } from "svelte/elements";
|
|
3
4
|
import { generateId } from "../util/ssr-safe.js";
|
|
4
5
|
import { cn } from "../util/cn.js";
|
|
@@ -20,6 +21,20 @@
|
|
|
20
21
|
disabled?: boolean;
|
|
21
22
|
loading?: boolean;
|
|
22
23
|
label?: string;
|
|
24
|
+
/**
|
|
25
|
+
* Drawn inside the one label, between the switch and the label text,
|
|
26
|
+
* as decoration for the name `label` already gives. A leading image
|
|
27
|
+
* should have an empty alt: the label names the row.
|
|
28
|
+
*/
|
|
29
|
+
leading?: Snippet;
|
|
30
|
+
/**
|
|
31
|
+
* A line under the label, tied to the switch with `aria-describedby`.
|
|
32
|
+
* It is inside the label, so a tap on it toggles; it does not join
|
|
33
|
+
* the name. It needs a `label`.
|
|
34
|
+
*/
|
|
35
|
+
description?: string;
|
|
36
|
+
/** Ids of other elements that describe the switch. The description is added after them. */
|
|
37
|
+
"aria-describedby"?: string | null;
|
|
23
38
|
/**
|
|
24
39
|
* The switch's accessible name when there is no visible `label`. With
|
|
25
40
|
* neither this, `aria-labelledby` nor `label`, it is called "Toggle".
|
|
@@ -40,6 +55,9 @@
|
|
|
40
55
|
disabled = false,
|
|
41
56
|
loading = false,
|
|
42
57
|
label = "",
|
|
58
|
+
leading,
|
|
59
|
+
description = "",
|
|
60
|
+
"aria-describedby": describedBy,
|
|
43
61
|
"aria-label": ariaLabel,
|
|
44
62
|
"aria-labelledby": ariaLabelledby,
|
|
45
63
|
onclick,
|
|
@@ -61,6 +79,8 @@
|
|
|
61
79
|
const fallbackId = generateId("toggle");
|
|
62
80
|
const toggleId = $derived(idProp ?? fallbackId);
|
|
63
81
|
const isDisabled = $derived(disabled || loading);
|
|
82
|
+
const showDescription = $derived(!!description && !!label);
|
|
83
|
+
const descriptionId = $derived(`${toggleId}-description`);
|
|
64
84
|
|
|
65
85
|
function handleClick(event: MouseEvent) {
|
|
66
86
|
if (isDisabled) return;
|
|
@@ -72,13 +92,19 @@
|
|
|
72
92
|
|
|
73
93
|
const toggleButtonClasses = $derived(() => {
|
|
74
94
|
const base =
|
|
75
|
-
`focus-ring relative inline-flex w-10 h-6 flex-shrink-0 rounded-full border-0 transition-colors duration-
|
|
95
|
+
`toggle-switch focus-ring relative inline-flex w-10 h-6 flex-shrink-0 rounded-full border-0 transition-colors duration-(--duration-moderate) ease-standard focus:outline-none focus-visible:outline-none ${TOUCH_HIT_AREA}`;
|
|
96
|
+
// Forced colours drop the fills and the ring, so `app.css` draws the track
|
|
97
|
+
// there as a 1px edge with the thumb in a system colour (`.toggle-switch`).
|
|
76
98
|
// A disabled switch has no hover or pressed fill: `:active` still matches a disabled button.
|
|
99
|
+
// The off track is a light tint whose 1px edge carries the 3:1; the
|
|
100
|
+
// edge is left off when on, where the primary fill is the boundary.
|
|
101
|
+
// The on fill wears the control veil, as a primary Button does, but
|
|
102
|
+
// not when disabled (a flat, dimmed switch).
|
|
77
103
|
const colorClass = checked
|
|
78
|
-
? "bg-action-primary hover:bg-action-primary-hover active:bg-action-primary-active
|
|
104
|
+
? `${isDisabled ? "" : "bg-control-gradient "}bg-action-primary hover:bg-action-primary-hover active:bg-action-primary-active`
|
|
79
105
|
: isDisabled
|
|
80
|
-
? "bg-
|
|
81
|
-
: "bg-
|
|
106
|
+
? "bg-(--color-toggle-track) ring-toggle-track"
|
|
107
|
+
: "bg-toggle-track ring-toggle-track";
|
|
82
108
|
const stateClass = isDisabled
|
|
83
109
|
? "opacity-50 cursor-not-allowed"
|
|
84
110
|
: "cursor-pointer";
|
|
@@ -87,8 +113,8 @@
|
|
|
87
113
|
|
|
88
114
|
const toggleThumbClasses = $derived(() => {
|
|
89
115
|
const base =
|
|
90
|
-
"pointer-events-none absolute top-0.5 left-0.5 w-5 h-5 rounded-full
|
|
91
|
-
const positionClasses = checked ? "translate-x-4" : "translate-x-0";
|
|
116
|
+
"toggle-switch-thumb pointer-events-none absolute top-0.5 left-0.5 w-5 h-5 rounded-full shadow-sm transition-transform duration-(--duration-moderate) ease-spring flex items-center justify-center";
|
|
117
|
+
const positionClasses = checked ? "bg-toggle-thumb-checked translate-x-4" : "bg-toggle-thumb translate-x-0";
|
|
92
118
|
return `${base} ${positionClasses}`;
|
|
93
119
|
});
|
|
94
120
|
</script>
|
|
@@ -96,7 +122,14 @@
|
|
|
96
122
|
<!-- On a coarse pointer the row is 44px tall, so the switch's hit area (44px, around a
|
|
97
123
|
24px switch) has room of its own: stacked 8px apart, the layer of one switch lay
|
|
98
124
|
over the visible edge of the one above it and took its taps. -->
|
|
99
|
-
<div
|
|
125
|
+
<div
|
|
126
|
+
class={cn(
|
|
127
|
+
"flex gap-3 pointer-coarse:min-h-11",
|
|
128
|
+
// With a description the row is two lines: the switch sits at the top.
|
|
129
|
+
showDescription ? "items-start pointer-coarse:py-3" : "items-center",
|
|
130
|
+
className,
|
|
131
|
+
)}
|
|
132
|
+
>
|
|
100
133
|
<button
|
|
101
134
|
type="button"
|
|
102
135
|
role="switch"
|
|
@@ -104,6 +137,7 @@
|
|
|
104
137
|
aria-checked={checked}
|
|
105
138
|
aria-label={ariaLabel ?? (label || ariaLabelledby ? undefined : "Toggle")}
|
|
106
139
|
aria-labelledby={ariaLabelledby}
|
|
140
|
+
aria-describedby={[describedBy, showDescription ? descriptionId : ""].filter(Boolean).join(" ") || undefined}
|
|
107
141
|
aria-busy={loading ? "true" : undefined}
|
|
108
142
|
disabled={isDisabled}
|
|
109
143
|
onclick={handleClick}
|
|
@@ -124,14 +158,31 @@
|
|
|
124
158
|
<input type="hidden" {name} {value} />
|
|
125
159
|
{/if}
|
|
126
160
|
|
|
127
|
-
{#if label}
|
|
161
|
+
{#if label || leading}
|
|
128
162
|
<label
|
|
129
163
|
for={toggleId}
|
|
130
|
-
class="text-sm font-medium text-label {
|
|
164
|
+
class="text-sm font-medium text-label {leading
|
|
165
|
+
? 'inline-flex items-center gap-3 '
|
|
166
|
+
: ''}{showDescription ? 'mt-0.5 ' : ''}{isDisabled
|
|
131
167
|
? 'cursor-not-allowed opacity-50'
|
|
132
168
|
: 'cursor-pointer'}"
|
|
133
169
|
>
|
|
134
|
-
{
|
|
170
|
+
{#if leading}
|
|
171
|
+
<span class="inline-flex shrink-0 items-center">
|
|
172
|
+
{@render leading()}
|
|
173
|
+
</span>
|
|
174
|
+
{/if}
|
|
175
|
+
{#if showDescription}
|
|
176
|
+
<span class="flex flex-col gap-1">
|
|
177
|
+
<span>{label}</span>
|
|
178
|
+
<!-- aria-hidden keeps it out of the name; aria-describedby still reads it. -->
|
|
179
|
+
<span id={descriptionId} class="font-normal text-description" aria-hidden="true">
|
|
180
|
+
{description}
|
|
181
|
+
</span>
|
|
182
|
+
</span>
|
|
183
|
+
{:else}
|
|
184
|
+
{label}
|
|
185
|
+
{/if}
|
|
135
186
|
</label>
|
|
136
187
|
{/if}
|
|
137
188
|
</div>
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { Snippet } from "svelte";
|
|
1
2
|
import type { HTMLButtonAttributes } from "svelte/elements";
|
|
2
3
|
/** Other attributes (`data-*`, `aria-*`, ...) land on the switch, which is a `<button>`. */
|
|
3
4
|
type Props = Omit<HTMLButtonAttributes, "class" | "id" | "name" | "value" | "disabled" | "type" | "role" | "onclick" | "onchange" | "children"> & {
|
|
@@ -12,6 +13,20 @@ type Props = Omit<HTMLButtonAttributes, "class" | "id" | "name" | "value" | "dis
|
|
|
12
13
|
disabled?: boolean;
|
|
13
14
|
loading?: boolean;
|
|
14
15
|
label?: string;
|
|
16
|
+
/**
|
|
17
|
+
* Drawn inside the one label, between the switch and the label text,
|
|
18
|
+
* as decoration for the name `label` already gives. A leading image
|
|
19
|
+
* should have an empty alt: the label names the row.
|
|
20
|
+
*/
|
|
21
|
+
leading?: Snippet;
|
|
22
|
+
/**
|
|
23
|
+
* A line under the label, tied to the switch with `aria-describedby`.
|
|
24
|
+
* It is inside the label, so a tap on it toggles; it does not join
|
|
25
|
+
* the name. It needs a `label`.
|
|
26
|
+
*/
|
|
27
|
+
description?: string;
|
|
28
|
+
/** Ids of other elements that describe the switch. The description is added after them. */
|
|
29
|
+
"aria-describedby"?: string | null;
|
|
15
30
|
/**
|
|
16
31
|
* The switch's accessible name when there is no visible `label`. With
|
|
17
32
|
* neither this, `aria-labelledby` nor `label`, it is called "Toggle".
|
|
@@ -43,6 +43,13 @@
|
|
|
43
43
|
* did. A mouse and a keyboard are not affected.
|
|
44
44
|
*/
|
|
45
45
|
touchDuration?: number;
|
|
46
|
+
/**
|
|
47
|
+
* `material` (default): the bubble is the thick glass overlay material
|
|
48
|
+
* with body text and no arrow. `inverted`: the 8.1 bubble, a dark fill
|
|
49
|
+
* with light text (`--color-tooltip-bg` / `--color-tooltip-fg`) and an
|
|
50
|
+
* arrow.
|
|
51
|
+
*/
|
|
52
|
+
tone?: "material" | "inverted";
|
|
46
53
|
class?: string;
|
|
47
54
|
children?: Snippet;
|
|
48
55
|
};
|
|
@@ -67,6 +74,7 @@
|
|
|
67
74
|
block = false,
|
|
68
75
|
fixed = false,
|
|
69
76
|
touchDuration = 0,
|
|
77
|
+
tone = "material",
|
|
70
78
|
class: className = "",
|
|
71
79
|
children,
|
|
72
80
|
...restProps
|
|
@@ -596,9 +604,13 @@
|
|
|
596
604
|
<div
|
|
597
605
|
bind:this={bubbleElement}
|
|
598
606
|
id={tooltipId}
|
|
599
|
-
class=
|
|
607
|
+
class={cn(
|
|
608
|
+
"tooltip pointer-events-none invisible absolute z-tooltip whitespace-normal wrap-break-word rounded-control px-3 py-2 text-sm leading-5 opacity-0 transition-[opacity,visibility,transform] duration-(--duration-moderate) ease-standard",
|
|
609
|
+
tone === "inverted" ? "bg-tooltip-bg text-tooltip-fg" : "material-thick text-body",
|
|
610
|
+
)}
|
|
600
611
|
role="tooltip"
|
|
601
612
|
aria-hidden={!isVisible}
|
|
613
|
+
data-tone={tone}
|
|
602
614
|
data-visible={isVisible}
|
|
603
615
|
data-parked={parked}
|
|
604
616
|
data-placement={side}
|
|
@@ -747,6 +759,13 @@
|
|
|
747
759
|
left: auto;
|
|
748
760
|
}
|
|
749
761
|
|
|
762
|
+
/* The arrow is a second shape on a translucent fill: its blur edge would
|
|
763
|
+
show a seam where it meets the bubble, and HIG tooltips have none. Only
|
|
764
|
+
the inverted bubble, which is opaque, keeps it. */
|
|
765
|
+
.tooltip[data-tone="material"]::before {
|
|
766
|
+
display: none;
|
|
767
|
+
}
|
|
768
|
+
|
|
750
769
|
.tooltip::before {
|
|
751
770
|
content: "";
|
|
752
771
|
position: absolute;
|
|
@@ -31,6 +31,13 @@ type Props = Omit<HTMLAttributes<HTMLDivElement>, "class"> & {
|
|
|
31
31
|
* did. A mouse and a keyboard are not affected.
|
|
32
32
|
*/
|
|
33
33
|
touchDuration?: number;
|
|
34
|
+
/**
|
|
35
|
+
* `material` (default): the bubble is the thick glass overlay material
|
|
36
|
+
* with body text and no arrow. `inverted`: the 8.1 bubble, a dark fill
|
|
37
|
+
* with light text (`--color-tooltip-bg` / `--color-tooltip-fg`) and an
|
|
38
|
+
* arrow.
|
|
39
|
+
*/
|
|
40
|
+
tone?: "material" | "inverted";
|
|
34
41
|
class?: string;
|
|
35
42
|
children?: Snippet;
|
|
36
43
|
};
|
package/dist/atoms/index.d.ts
CHANGED
|
@@ -1,13 +1,23 @@
|
|
|
1
1
|
export { default as Toggle } from './Toggle.svelte';
|
|
2
2
|
export { default as Badge } from './Badge.svelte';
|
|
3
|
+
export { default as Stat } from './Stat.svelte';
|
|
4
|
+
export { default as SpeechBubble } from './SpeechBubble.svelte';
|
|
5
|
+
export { default as Sparkline } from './Sparkline.svelte';
|
|
6
|
+
export { default as Chip } from './Chip.svelte';
|
|
3
7
|
export { default as Button } from './Button.svelte';
|
|
4
8
|
export { default as IconButton } from './IconButton.svelte';
|
|
9
|
+
export { default as Block } from './Block.svelte';
|
|
5
10
|
export { default as Card } from './Card.svelte';
|
|
6
11
|
export { default as CardHeader } from './CardHeader.svelte';
|
|
7
12
|
export { default as CardContent } from './CardContent.svelte';
|
|
8
13
|
export { default as CardFooter } from './CardFooter.svelte';
|
|
9
14
|
export { default as Input } from './Input.svelte';
|
|
15
|
+
export { default as CodeField } from './CodeField.svelte';
|
|
16
|
+
export { DEFAULT_CODE_FIELD_STRINGS } from '../util/code-field.js';
|
|
17
|
+
export type { CodeFieldMode, CodeFieldSize, CodeFieldStrings } from '../util/code-field.js';
|
|
10
18
|
export { default as Textarea } from './Textarea.svelte';
|
|
19
|
+
export type { TextareaCount } from '../util/field.js';
|
|
20
|
+
export { default as PickerField } from './PickerField.svelte';
|
|
11
21
|
export { default as Select } from './Select.svelte';
|
|
12
22
|
export { DEFAULT_SELECT_STRINGS } from '../util/select.js';
|
|
13
23
|
export type { SelectStrings, SelectPresentation } from '../util/select.js';
|
|
@@ -22,10 +32,21 @@ export { default as Divider } from './Divider.svelte';
|
|
|
22
32
|
export { default as Container } from './Container.svelte';
|
|
23
33
|
export { default as Text } from './Text.svelte';
|
|
24
34
|
export { default as Table } from './Table.svelte';
|
|
35
|
+
export { default as Toast } from './Toast.svelte';
|
|
36
|
+
export { default as Tooltip } from './Tooltip.svelte';
|
|
37
|
+
export { default as Progress } from './Progress.svelte';
|
|
38
|
+
export { default as Skeleton } from './Skeleton.svelte';
|
|
39
|
+
export { default as SkeletonGroup } from './SkeletonGroup.svelte';
|
|
40
|
+
export { DEFAULT_SKELETON_STRINGS } from '../util/skeleton.js';
|
|
41
|
+
export type { SkeletonStrings } from '../util/skeleton.js';
|
|
42
|
+
export { default as CodeBlock } from './CodeBlock.svelte';
|
|
43
|
+
export { default as FeatureCard } from './FeatureCard.svelte';
|
|
44
|
+
export { default as OptimizedImage } from './OptimizedImage.svelte';
|
|
25
45
|
export { default as Checkbox } from './Checkbox.svelte';
|
|
26
46
|
export { default as Radio } from './Radio.svelte';
|
|
27
47
|
export { default as Spinner } from './Spinner.svelte';
|
|
28
48
|
export { default as Rating } from './Rating.svelte';
|
|
49
|
+
export type { ProgressStrings } from '../util/progress.js';
|
|
29
50
|
export type { RatingStrings } from '../util/rating.js';
|
|
30
51
|
export { default as FloatingActionButton } from './FloatingActionButton.svelte';
|
|
31
52
|
export { default as DateField } from './DateField.svelte';
|
package/dist/atoms/index.js
CHANGED
|
@@ -1,13 +1,21 @@
|
|
|
1
1
|
export { default as Toggle } from './Toggle.svelte';
|
|
2
2
|
export { default as Badge } from './Badge.svelte';
|
|
3
|
+
export { default as Stat } from './Stat.svelte';
|
|
4
|
+
export { default as SpeechBubble } from './SpeechBubble.svelte';
|
|
5
|
+
export { default as Sparkline } from './Sparkline.svelte';
|
|
6
|
+
export { default as Chip } from './Chip.svelte';
|
|
3
7
|
export { default as Button } from './Button.svelte';
|
|
4
8
|
export { default as IconButton } from './IconButton.svelte';
|
|
9
|
+
export { default as Block } from './Block.svelte';
|
|
5
10
|
export { default as Card } from './Card.svelte';
|
|
6
11
|
export { default as CardHeader } from './CardHeader.svelte';
|
|
7
12
|
export { default as CardContent } from './CardContent.svelte';
|
|
8
13
|
export { default as CardFooter } from './CardFooter.svelte';
|
|
9
14
|
export { default as Input } from './Input.svelte';
|
|
15
|
+
export { default as CodeField } from './CodeField.svelte';
|
|
16
|
+
export { DEFAULT_CODE_FIELD_STRINGS } from '../util/code-field.js';
|
|
10
17
|
export { default as Textarea } from './Textarea.svelte';
|
|
18
|
+
export { default as PickerField } from './PickerField.svelte';
|
|
11
19
|
export { default as Select } from './Select.svelte';
|
|
12
20
|
export { DEFAULT_SELECT_STRINGS } from '../util/select.js';
|
|
13
21
|
export { default as Slider } from './Slider.svelte';
|
|
@@ -21,6 +29,15 @@ export { default as Divider } from './Divider.svelte';
|
|
|
21
29
|
export { default as Container } from './Container.svelte';
|
|
22
30
|
export { default as Text } from './Text.svelte';
|
|
23
31
|
export { default as Table } from './Table.svelte';
|
|
32
|
+
export { default as Toast } from './Toast.svelte';
|
|
33
|
+
export { default as Tooltip } from './Tooltip.svelte';
|
|
34
|
+
export { default as Progress } from './Progress.svelte';
|
|
35
|
+
export { default as Skeleton } from './Skeleton.svelte';
|
|
36
|
+
export { default as SkeletonGroup } from './SkeletonGroup.svelte';
|
|
37
|
+
export { DEFAULT_SKELETON_STRINGS } from '../util/skeleton.js';
|
|
38
|
+
export { default as CodeBlock } from './CodeBlock.svelte';
|
|
39
|
+
export { default as FeatureCard } from './FeatureCard.svelte';
|
|
40
|
+
export { default as OptimizedImage } from './OptimizedImage.svelte';
|
|
24
41
|
export { default as Checkbox } from './Checkbox.svelte';
|
|
25
42
|
export { default as Radio } from './Radio.svelte';
|
|
26
43
|
export { default as Spinner } from './Spinner.svelte';
|
|
@@ -22,13 +22,22 @@ export declare const RADIO_GROUP_OPTION_LABEL_ROW: string;
|
|
|
22
22
|
* The checked fill is the primary action fill, so a ticked box and a primary
|
|
23
23
|
* button are the same colour; it used to be a step paler (2.8:1 on the page).
|
|
24
24
|
*
|
|
25
|
+
* The unchecked edge is the only thing that says a control is here, so it is
|
|
26
|
+
* the control boundary (3:1 on every surface, both themes); it was a fixed
|
|
27
|
+
* ramp step, 2.5:1 in light and 1.9 to 2.3:1 in dark.
|
|
28
|
+
*
|
|
29
|
+
* In forced colours every fill is gone, so a ticked box would read as an
|
|
30
|
+
* unticked one. `selection-control-shell` and `selection-control-dot` are the
|
|
31
|
+
* hooks for the rules in `app.css` that draw the ticked state as a system
|
|
32
|
+
* colour pair (`Highlight` / `HighlightText`) and the disabled one in `GrayText`.
|
|
33
|
+
*
|
|
25
34
|
* The pressed dip and the hover fills are for a control that can be used.
|
|
26
35
|
* The row around a disabled input still matches `:active` and `:hover`, so
|
|
27
36
|
* without that a disabled box dipped under a finger and lit up under the
|
|
28
37
|
* mouse. The unchecked ones are limited to `not-has-[:disabled]`; the checked
|
|
29
38
|
* hover is undone by a rule with one more `has-` in it, which outweighs it.
|
|
30
39
|
*/
|
|
31
|
-
export declare const SELECTION_CONTROL_SHELL_STATE = "group/control relative inline-flex items-center justify-center w-5 h-5 transition-all duration-200 border-2 not-has-[:disabled]:group-active:scale-95 border-
|
|
40
|
+
export declare const SELECTION_CONTROL_SHELL_STATE = "selection-control-shell group/control relative inline-flex shrink-0 items-center justify-center w-5 h-5 transition-all duration-200 border-2 not-has-[:disabled]:group-active:scale-95 border-control-border bg-transparent not-has-[:disabled]:group-hover:border-brand-500 not-has-[:disabled]:group-hover:bg-brand-50 has-[:checked]:border-action-primary has-[:checked]:bg-action-primary has-[:checked]:group-hover:bg-action-primary-hover has-[:checked]:group-hover:border-action-primary-hover has-[:disabled]:has-[:checked]:group-hover:bg-action-primary has-[:disabled]:has-[:checked]:group-hover:border-action-primary has-[:disabled]:opacity-50 has-[:disabled]:cursor-not-allowed";
|
|
32
41
|
export type SelectionControlShape = "square" | "circle";
|
|
33
42
|
export declare function selectionControlShellClasses(shape: SelectionControlShape): string;
|
|
34
43
|
/** Radio circle control; `mt-0.5` aligns with multi-line labels. */
|
|
@@ -45,12 +54,14 @@ export declare const RADIO_GROUP_CONTROL_SHELL: string;
|
|
|
45
54
|
* On a coarse pointer it is 44 by 44px, centred on the box (12px further out
|
|
46
55
|
* on each side), so the input itself is the touch target and not only the
|
|
47
56
|
* row around it. The row is 44px tall there, so the inputs of two rows never
|
|
48
|
-
* reach each other.
|
|
57
|
+
* reach each other. The 44 is in px and the centring is by halves: in rem it
|
|
58
|
+
* grew with the text (88px at 200%, 34px out on each side of a 20px box, and
|
|
59
|
+
* past the screen's edge from a box at the end of a row, Z-128).
|
|
49
60
|
*/
|
|
50
|
-
export declare const SELECTION_CONTROL_INPUT = "absolute -top-0.5 -
|
|
61
|
+
export declare const SELECTION_CONTROL_INPUT = "absolute -top-0.5 -left-0.5 m-0 size-5 cursor-pointer appearance-none opacity-0 disabled:cursor-not-allowed pointer-coarse:top-1/2 pointer-coarse:left-1/2 pointer-coarse:size-[44px] pointer-coarse:-translate-x-1/2 pointer-coarse:-translate-y-1/2";
|
|
51
62
|
/** Full-bleed ring behind the mark (same geometry as SelectionControl inner ring). Lets a press through to the input. */
|
|
52
63
|
export declare function selectionControlRingOverlayClasses(shape: SelectionControlShape): string;
|
|
53
64
|
/** Radio row: circle overlay + `pointer-events-none` so clicks hit the input. */
|
|
54
65
|
export declare const RADIO_GROUP_RING_OVERLAY: string;
|
|
55
66
|
/** Checked radio dot (shared with `Radio.svelte`). */
|
|
56
|
-
export declare const RADIO_CHECKED_DOT_CLASSES = "absolute size-2 rounded-full bg-action-primary-text pointer-events-none z-10 opacity-0 group-has-checked/control:opacity-100";
|
|
67
|
+
export declare const RADIO_CHECKED_DOT_CLASSES = "selection-control-dot absolute size-2 rounded-full bg-action-primary-text pointer-events-none z-10 opacity-0 group-has-checked/control:opacity-100";
|
|
@@ -22,19 +22,28 @@ export const RADIO_GROUP_OPTION_LABEL_ROW = `flex items-start gap-2 p-2 pointer-
|
|
|
22
22
|
* The checked fill is the primary action fill, so a ticked box and a primary
|
|
23
23
|
* button are the same colour; it used to be a step paler (2.8:1 on the page).
|
|
24
24
|
*
|
|
25
|
+
* The unchecked edge is the only thing that says a control is here, so it is
|
|
26
|
+
* the control boundary (3:1 on every surface, both themes); it was a fixed
|
|
27
|
+
* ramp step, 2.5:1 in light and 1.9 to 2.3:1 in dark.
|
|
28
|
+
*
|
|
29
|
+
* In forced colours every fill is gone, so a ticked box would read as an
|
|
30
|
+
* unticked one. `selection-control-shell` and `selection-control-dot` are the
|
|
31
|
+
* hooks for the rules in `app.css` that draw the ticked state as a system
|
|
32
|
+
* colour pair (`Highlight` / `HighlightText`) and the disabled one in `GrayText`.
|
|
33
|
+
*
|
|
25
34
|
* The pressed dip and the hover fills are for a control that can be used.
|
|
26
35
|
* The row around a disabled input still matches `:active` and `:hover`, so
|
|
27
36
|
* without that a disabled box dipped under a finger and lit up under the
|
|
28
37
|
* mouse. The unchecked ones are limited to `not-has-[:disabled]`; the checked
|
|
29
38
|
* hover is undone by a rule with one more `has-` in it, which outweighs it.
|
|
30
39
|
*/
|
|
31
|
-
export const SELECTION_CONTROL_SHELL_STATE = "group/control relative inline-flex items-center justify-center w-5 h-5 transition-all duration-200 border-2 not-has-[:disabled]:group-active:scale-95 border-
|
|
40
|
+
export const SELECTION_CONTROL_SHELL_STATE = "selection-control-shell group/control relative inline-flex shrink-0 items-center justify-center w-5 h-5 transition-all duration-200 border-2 not-has-[:disabled]:group-active:scale-95 border-control-border bg-transparent not-has-[:disabled]:group-hover:border-brand-500 not-has-[:disabled]:group-hover:bg-brand-50 has-[:checked]:border-action-primary has-[:checked]:bg-action-primary has-[:checked]:group-hover:bg-action-primary-hover has-[:checked]:group-hover:border-action-primary-hover has-[:disabled]:has-[:checked]:group-hover:bg-action-primary has-[:disabled]:has-[:checked]:group-hover:border-action-primary has-[:disabled]:opacity-50 has-[:disabled]:cursor-not-allowed";
|
|
32
41
|
export function selectionControlShellClasses(shape) {
|
|
33
42
|
const rounding = shape === "circle" ? "rounded-full" : "rounded";
|
|
34
43
|
return `${SELECTION_CONTROL_SHELL_STATE} ${rounding}`.trim();
|
|
35
44
|
}
|
|
36
45
|
/** Radio circle control; `mt-0.5` aligns with multi-line labels. */
|
|
37
|
-
export const RADIO_GROUP_CONTROL_SHELL = `${SELECTION_CONTROL_SHELL_STATE} mt-0.5
|
|
46
|
+
export const RADIO_GROUP_CONTROL_SHELL = `${SELECTION_CONTROL_SHELL_STATE} mt-0.5 rounded-full`.trim();
|
|
38
47
|
/**
|
|
39
48
|
* The real input, stretched over the 20px box and transparent, so a press on
|
|
40
49
|
* the box lands on the input itself. It used to be `sr-only`: a 1px box under
|
|
@@ -47,9 +56,11 @@ export const RADIO_GROUP_CONTROL_SHELL = `${SELECTION_CONTROL_SHELL_STATE} mt-0.
|
|
|
47
56
|
* On a coarse pointer it is 44 by 44px, centred on the box (12px further out
|
|
48
57
|
* on each side), so the input itself is the touch target and not only the
|
|
49
58
|
* row around it. The row is 44px tall there, so the inputs of two rows never
|
|
50
|
-
* reach each other.
|
|
59
|
+
* reach each other. The 44 is in px and the centring is by halves: in rem it
|
|
60
|
+
* grew with the text (88px at 200%, 34px out on each side of a 20px box, and
|
|
61
|
+
* past the screen's edge from a box at the end of a row, Z-128).
|
|
51
62
|
*/
|
|
52
|
-
export const SELECTION_CONTROL_INPUT = "absolute -top-0.5 -
|
|
63
|
+
export const SELECTION_CONTROL_INPUT = "absolute -top-0.5 -left-0.5 m-0 size-5 cursor-pointer appearance-none opacity-0 disabled:cursor-not-allowed pointer-coarse:top-1/2 pointer-coarse:left-1/2 pointer-coarse:size-[44px] pointer-coarse:-translate-x-1/2 pointer-coarse:-translate-y-1/2";
|
|
53
64
|
/** Full-bleed ring behind the mark (same geometry as SelectionControl inner ring). Lets a press through to the input. */
|
|
54
65
|
export function selectionControlRingOverlayClasses(shape) {
|
|
55
66
|
const rounding = shape === "circle" ? "rounded-full" : "rounded";
|
|
@@ -58,4 +69,4 @@ export function selectionControlRingOverlayClasses(shape) {
|
|
|
58
69
|
/** Radio row: circle overlay + `pointer-events-none` so clicks hit the input. */
|
|
59
70
|
export const RADIO_GROUP_RING_OVERLAY = selectionControlRingOverlayClasses("circle");
|
|
60
71
|
/** Checked radio dot (shared with `Radio.svelte`). */
|
|
61
|
-
export const RADIO_CHECKED_DOT_CLASSES = "absolute size-2 rounded-full bg-action-primary-text pointer-events-none z-10 opacity-0 group-has-checked/control:opacity-100";
|
|
72
|
+
export const RADIO_CHECKED_DOT_CLASSES = "selection-control-dot absolute size-2 rounded-full bg-action-primary-text pointer-events-none z-10 opacity-0 group-has-checked/control:opacity-100";
|
|
@@ -1,13 +1,23 @@
|
|
|
1
1
|
export { default as Toggle } from './Toggle.svelte';
|
|
2
2
|
export { default as Badge } from './Badge.svelte';
|
|
3
|
+
export { default as Stat } from './Stat.svelte';
|
|
4
|
+
export { default as SpeechBubble } from './SpeechBubble.svelte';
|
|
5
|
+
export { default as Sparkline } from './Sparkline.svelte';
|
|
6
|
+
export { default as Chip } from './Chip.svelte';
|
|
3
7
|
export { default as Button } from './Button.svelte';
|
|
4
8
|
export { default as IconButton } from './IconButton.svelte';
|
|
9
|
+
export { default as Block } from './Block.svelte';
|
|
5
10
|
export { default as Card } from './Card.svelte';
|
|
6
11
|
export { default as CardHeader } from './CardHeader.svelte';
|
|
7
12
|
export { default as CardContent } from './CardContent.svelte';
|
|
8
13
|
export { default as CardFooter } from './CardFooter.svelte';
|
|
9
14
|
export { default as Input } from './Input.svelte';
|
|
15
|
+
export { default as CodeField } from './CodeField.svelte';
|
|
16
|
+
export { DEFAULT_CODE_FIELD_STRINGS } from '../util/code-field.js';
|
|
17
|
+
export type { CodeFieldMode, CodeFieldSize, CodeFieldStrings } from '../util/code-field.js';
|
|
10
18
|
export { default as Textarea } from './Textarea.svelte';
|
|
19
|
+
export type { TextareaCount } from '../util/field.js';
|
|
20
|
+
export { default as PickerField } from './PickerField.svelte';
|
|
11
21
|
export { default as Select } from './Select.svelte';
|
|
12
22
|
export { DEFAULT_SELECT_STRINGS } from '../util/select.js';
|
|
13
23
|
export type { SelectStrings, SelectPresentation } from '../util/select.js';
|
|
@@ -22,10 +32,21 @@ export { default as Divider } from './Divider.svelte';
|
|
|
22
32
|
export { default as Container } from './Container.svelte';
|
|
23
33
|
export { default as Text } from './Text.svelte';
|
|
24
34
|
export { default as Table } from './Table.svelte';
|
|
35
|
+
export { default as Toast } from './Toast.svelte';
|
|
36
|
+
export { default as Tooltip } from './Tooltip.svelte';
|
|
37
|
+
export { default as Progress } from './Progress.svelte';
|
|
38
|
+
export { default as Skeleton } from './Skeleton.svelte';
|
|
39
|
+
export { default as SkeletonGroup } from './SkeletonGroup.svelte';
|
|
40
|
+
export { DEFAULT_SKELETON_STRINGS } from '../util/skeleton.js';
|
|
41
|
+
export type { SkeletonStrings } from '../util/skeleton.js';
|
|
42
|
+
export { default as CodeBlock } from './CodeBlock.svelte';
|
|
43
|
+
export { default as FeatureCard } from './FeatureCard.svelte';
|
|
44
|
+
export { default as OptimizedImage } from './OptimizedImage.svelte';
|
|
25
45
|
export { default as Checkbox } from './Checkbox.svelte';
|
|
26
46
|
export { default as Radio } from './Radio.svelte';
|
|
27
47
|
export { default as Spinner } from './Spinner.svelte';
|
|
28
48
|
export { default as Rating } from './Rating.svelte';
|
|
49
|
+
export type { ProgressStrings } from '../util/progress.js';
|
|
29
50
|
export type { RatingStrings } from '../util/rating.js';
|
|
30
51
|
export { default as FloatingActionButton } from './FloatingActionButton.svelte';
|
|
31
52
|
export { default as DateField } from './DateField.svelte';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/atoms/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,eAAe,CAAC;AAChD,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAC9D,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,sBAAsB,EAAE,MAAM,mBAAmB,CAAC;AAC3D,YAAY,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AAC3E,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAC9D,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,eAAe,CAAC;AAChD,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,OAAO,IAAI,OA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7E,YAAY,EAAE,kBAAkB,EAAE,MAAM,+BAA+B,CAAC;AACxE,OAAO,EAAE,OAAO,IAAI,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AAC9E,OAAO,EAAE,2BAA2B,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AACtF,YAAY,EAAE,WAAW,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,UAAU,EAAE,cAAc,EAAE,gBAAgB,EAAE,UAAU,EAAE,sBAAsB,EAAE,MAAM,yBAAyB,CAAC"}
|
|
@@ -22,13 +22,22 @@ export declare const RADIO_GROUP_OPTION_LABEL_ROW: string;
|
|
|
22
22
|
* The checked fill is the primary action fill, so a ticked box and a primary
|
|
23
23
|
* button are the same colour; it used to be a step paler (2.8:1 on the page).
|
|
24
24
|
*
|
|
25
|
+
* The unchecked edge is the only thing that says a control is here, so it is
|
|
26
|
+
* the control boundary (3:1 on every surface, both themes); it was a fixed
|
|
27
|
+
* ramp step, 2.5:1 in light and 1.9 to 2.3:1 in dark.
|
|
28
|
+
*
|
|
29
|
+
* In forced colours every fill is gone, so a ticked box would read as an
|
|
30
|
+
* unticked one. `selection-control-shell` and `selection-control-dot` are the
|
|
31
|
+
* hooks for the rules in `app.css` that draw the ticked state as a system
|
|
32
|
+
* colour pair (`Highlight` / `HighlightText`) and the disabled one in `GrayText`.
|
|
33
|
+
*
|
|
25
34
|
* The pressed dip and the hover fills are for a control that can be used.
|
|
26
35
|
* The row around a disabled input still matches `:active` and `:hover`, so
|
|
27
36
|
* without that a disabled box dipped under a finger and lit up under the
|
|
28
37
|
* mouse. The unchecked ones are limited to `not-has-[:disabled]`; the checked
|
|
29
38
|
* hover is undone by a rule with one more `has-` in it, which outweighs it.
|
|
30
39
|
*/
|
|
31
|
-
export declare const SELECTION_CONTROL_SHELL_STATE = "group/control relative inline-flex items-center justify-center w-5 h-5 transition-all duration-200 border-2 not-has-[:disabled]:group-active:scale-95 border-
|
|
40
|
+
export declare const SELECTION_CONTROL_SHELL_STATE = "selection-control-shell group/control relative inline-flex shrink-0 items-center justify-center w-5 h-5 transition-all duration-200 border-2 not-has-[:disabled]:group-active:scale-95 border-control-border bg-transparent not-has-[:disabled]:group-hover:border-brand-500 not-has-[:disabled]:group-hover:bg-brand-50 has-[:checked]:border-action-primary has-[:checked]:bg-action-primary has-[:checked]:group-hover:bg-action-primary-hover has-[:checked]:group-hover:border-action-primary-hover has-[:disabled]:has-[:checked]:group-hover:bg-action-primary has-[:disabled]:has-[:checked]:group-hover:border-action-primary has-[:disabled]:opacity-50 has-[:disabled]:cursor-not-allowed";
|
|
32
41
|
export type SelectionControlShape = "square" | "circle";
|
|
33
42
|
export declare function selectionControlShellClasses(shape: SelectionControlShape): string;
|
|
34
43
|
/** Radio circle control; `mt-0.5` aligns with multi-line labels. */
|
|
@@ -45,13 +54,15 @@ export declare const RADIO_GROUP_CONTROL_SHELL: string;
|
|
|
45
54
|
* On a coarse pointer it is 44 by 44px, centred on the box (12px further out
|
|
46
55
|
* on each side), so the input itself is the touch target and not only the
|
|
47
56
|
* row around it. The row is 44px tall there, so the inputs of two rows never
|
|
48
|
-
* reach each other.
|
|
57
|
+
* reach each other. The 44 is in px and the centring is by halves: in rem it
|
|
58
|
+
* grew with the text (88px at 200%, 34px out on each side of a 20px box, and
|
|
59
|
+
* past the screen's edge from a box at the end of a row, Z-128).
|
|
49
60
|
*/
|
|
50
|
-
export declare const SELECTION_CONTROL_INPUT = "absolute -top-0.5 -
|
|
61
|
+
export declare const SELECTION_CONTROL_INPUT = "absolute -top-0.5 -left-0.5 m-0 size-5 cursor-pointer appearance-none opacity-0 disabled:cursor-not-allowed pointer-coarse:top-1/2 pointer-coarse:left-1/2 pointer-coarse:size-[44px] pointer-coarse:-translate-x-1/2 pointer-coarse:-translate-y-1/2";
|
|
51
62
|
/** Full-bleed ring behind the mark (same geometry as SelectionControl inner ring). Lets a press through to the input. */
|
|
52
63
|
export declare function selectionControlRingOverlayClasses(shape: SelectionControlShape): string;
|
|
53
64
|
/** Radio row: circle overlay + `pointer-events-none` so clicks hit the input. */
|
|
54
65
|
export declare const RADIO_GROUP_RING_OVERLAY: string;
|
|
55
66
|
/** Checked radio dot (shared with `Radio.svelte`). */
|
|
56
|
-
export declare const RADIO_CHECKED_DOT_CLASSES = "absolute size-2 rounded-full bg-action-primary-text pointer-events-none z-10 opacity-0 group-has-checked/control:opacity-100";
|
|
67
|
+
export declare const RADIO_CHECKED_DOT_CLASSES = "selection-control-dot absolute size-2 rounded-full bg-action-primary-text pointer-events-none z-10 opacity-0 group-has-checked/control:opacity-100";
|
|
57
68
|
//# sourceMappingURL=selection-control.styles.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"selection-control.styles.d.ts","sourceRoot":"","sources":["../../../src/components/atoms/selection-control.styles.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,yEAAyE;AACzE,eAAO,MAAM,uCAAuC,4CACP,CAAC;AAE9C,2DAA2D;AAC3D,eAAO,MAAM,4BAA4B,iCAAiC,CAAC;AAE3E;;;;;;GAMG;AACH,eAAO,MAAM,gCAAgC,QACqE,CAAC;AAEnH,eAAO,MAAM,2BAA2B,QAAgE,CAAC;AAEzG,sGAAsG;AACtG,eAAO,MAAM,4BAA4B,QACuG,CAAC;AAEjJ
|
|
1
|
+
{"version":3,"file":"selection-control.styles.d.ts","sourceRoot":"","sources":["../../../src/components/atoms/selection-control.styles.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,yEAAyE;AACzE,eAAO,MAAM,uCAAuC,4CACP,CAAC;AAE9C,2DAA2D;AAC3D,eAAO,MAAM,4BAA4B,iCAAiC,CAAC;AAE3E;;;;;;GAMG;AACH,eAAO,MAAM,gCAAgC,QACqE,CAAC;AAEnH,eAAO,MAAM,2BAA2B,QAAgE,CAAC;AAEzG,sGAAsG;AACtG,eAAO,MAAM,4BAA4B,QACuG,CAAC;AAEjJ;;;;;;;;;;;;;;;;;;;GAmBG;AACH,eAAO,MAAM,6BAA6B,yqBACgoB,CAAC;AAE3qB,MAAM,MAAM,qBAAqB,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAExD,wBAAgB,4BAA4B,CAAC,KAAK,EAAE,qBAAqB,GAAG,MAAM,CAGjF;AAED,oEAAoE;AACpE,eAAO,MAAM,yBAAyB,QAAgE,CAAC;AAEvG;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,uBAAuB,0PACuN,CAAC;AAE5P,yHAAyH;AACzH,wBAAgB,kCAAkC,CAC9C,KAAK,EAAE,qBAAqB,GAC7B,MAAM,CAGR;AAED,iFAAiF;AACjF,eAAO,MAAM,wBAAwB,QAA+C,CAAC;AAErF,sDAAsD;AACtD,eAAO,MAAM,yBAAyB,uJACkH,CAAC"}
|
|
@@ -1,13 +1,23 @@
|
|
|
1
1
|
export { default as Toggle } from './atoms/Toggle.svelte';
|
|
2
2
|
export { default as Badge } from './atoms/Badge.svelte';
|
|
3
|
+
export { default as Stat } from './atoms/Stat.svelte';
|
|
4
|
+
export { default as SpeechBubble } from './atoms/SpeechBubble.svelte';
|
|
5
|
+
export { default as Sparkline } from './atoms/Sparkline.svelte';
|
|
6
|
+
export { default as Chip } from './atoms/Chip.svelte';
|
|
3
7
|
export { default as Button } from './atoms/Button.svelte';
|
|
4
8
|
export { default as IconButton } from './atoms/IconButton.svelte';
|
|
9
|
+
export { default as Block } from './atoms/Block.svelte';
|
|
5
10
|
export { default as Card } from './atoms/Card.svelte';
|
|
6
11
|
export { default as CardHeader } from './atoms/CardHeader.svelte';
|
|
7
12
|
export { default as CardContent } from './atoms/CardContent.svelte';
|
|
8
13
|
export { default as CardFooter } from './atoms/CardFooter.svelte';
|
|
9
14
|
export { default as Input } from './atoms/Input.svelte';
|
|
15
|
+
export { default as CodeField } from './atoms/CodeField.svelte';
|
|
16
|
+
export { DEFAULT_CODE_FIELD_STRINGS } from './util/code-field.js';
|
|
17
|
+
export type { CodeFieldMode, CodeFieldSize, CodeFieldStrings } from './util/code-field.js';
|
|
10
18
|
export { default as Textarea } from './atoms/Textarea.svelte';
|
|
19
|
+
export type { TextareaCount } from './util/field.js';
|
|
20
|
+
export { default as PickerField } from './atoms/PickerField.svelte';
|
|
11
21
|
export { default as Select } from './atoms/Select.svelte';
|
|
12
22
|
export { default as Slider } from './atoms/Slider.svelte';
|
|
13
23
|
export { default as ColorPicker } from './atoms/ColorPicker.svelte';
|
|
@@ -25,6 +35,9 @@ export { default as Toast } from './atoms/Toast.svelte';
|
|
|
25
35
|
export { default as Tooltip } from './atoms/Tooltip.svelte';
|
|
26
36
|
export { default as Progress } from './atoms/Progress.svelte';
|
|
27
37
|
export { default as Skeleton } from './atoms/Skeleton.svelte';
|
|
38
|
+
export { default as SkeletonGroup } from './atoms/SkeletonGroup.svelte';
|
|
39
|
+
export { DEFAULT_SKELETON_STRINGS } from './util/skeleton.js';
|
|
40
|
+
export type { SkeletonStrings } from './util/skeleton.js';
|
|
28
41
|
export { default as Checkbox } from './atoms/Checkbox.svelte';
|
|
29
42
|
export { default as Radio } from './atoms/Radio.svelte';
|
|
30
43
|
export { default as CodeBlock } from './atoms/CodeBlock.svelte';
|
|
@@ -33,6 +46,7 @@ export { default as OptimizedImage } from './atoms/OptimizedImage.svelte';
|
|
|
33
46
|
export { default as ActionPanel } from './atoms/ActionPanel.svelte';
|
|
34
47
|
export { default as Spinner } from './atoms/Spinner.svelte';
|
|
35
48
|
export { default as Rating } from './atoms/Rating.svelte';
|
|
49
|
+
export type { ProgressStrings } from './util/progress.js';
|
|
36
50
|
export type { RatingStrings } from './util/rating.js';
|
|
37
51
|
export { default as FloatingActionButton } from './atoms/FloatingActionButton.svelte';
|
|
38
52
|
export { default as DateField } from './atoms/DateField.svelte';
|
|
@@ -55,6 +69,7 @@ export { default as Modal } from './molecules/Modal.svelte';
|
|
|
55
69
|
export { default as SlideUp } from './molecules/SlideUp.svelte';
|
|
56
70
|
export { default as Tabs } from './molecules/Tabs.svelte';
|
|
57
71
|
export { default as RadioGroup } from './molecules/RadioGroup.svelte';
|
|
72
|
+
export { default as ChipGroup } from './molecules/ChipGroup.svelte';
|
|
58
73
|
export { default as SegmentedControl } from './molecules/SegmentedControl.svelte';
|
|
59
74
|
export type { SegmentedControlIcon, SegmentedControlOption, } from './util/segmented-control.js';
|
|
60
75
|
export { default as NavigationMenu } from './molecules/NavigationMenu.svelte';
|
|
@@ -94,20 +109,25 @@ export { default as Calendar } from './molecules/Calendar.svelte';
|
|
|
94
109
|
export type { CalendarEvent, CalendarStrings, CalendarTone, } from './util/calendar.js';
|
|
95
110
|
export { default as PhotoGrid } from './molecules/PhotoGrid.svelte';
|
|
96
111
|
export { default as PhotoViewer } from './molecules/PhotoViewer.svelte';
|
|
97
|
-
export type { Photo, PhotoGridSelectDetail, PhotoGridStrings, PhotoKey, PhotoViewerAction, PhotoViewerCloseReason, PhotoViewerStrings, } from './util/photo.js';
|
|
112
|
+
export type { Photo, PhotoGridSelectDetail, PhotoGridStrings, PhotoKey, PhotoStatus, PhotoViewerAction, PhotoViewerCloseReason, PhotoViewerStrings, } from './util/photo.js';
|
|
98
113
|
export { default as Avatar } from './atoms/Avatar.svelte';
|
|
99
114
|
export { default as AvatarGroup } from './molecules/AvatarGroup.svelte';
|
|
100
115
|
export { DEFAULT_AVATAR_GROUP_STRINGS } from './util/avatar.js';
|
|
101
116
|
export type { AvatarGroupStrings, AvatarPerson, AvatarSize } from './util/avatar.js';
|
|
117
|
+
export { default as LineChart } from './molecules/LineChart.svelte';
|
|
118
|
+
export { default as BarChart } from './molecules/BarChart.svelte';
|
|
119
|
+
export { default as PieChart } from './molecules/PieChart.svelte';
|
|
120
|
+
export type { ChartColor, ChartColorName, ChartDatum, ChartFormat, ChartSeries, } from './util/chart.js';
|
|
102
121
|
export { default as Stepper } from './molecules/Stepper.svelte';
|
|
103
122
|
export type { StepperItem, StepperLayout, StepperStep, StepperStepState, StepperStrings, } from './util/stepper.js';
|
|
104
123
|
export { toastStore, pushToast, dismissToast, focusToasts, type ToastItem, type ToastAction, type ToastLevel, } from './molecules/toast-store.js';
|
|
105
124
|
export { DEFAULT_TOASTER_STRINGS, TOAST_DURATIONS } from './util/toaster.js';
|
|
106
|
-
export type { ToasterStrings, ToastPauseChange, ToastDuration } from './util/toaster.js';
|
|
125
|
+
export type { ToasterStrings, ToasterMode, ToastPauseChange, ToastDuration } from './util/toaster.js';
|
|
107
126
|
export { DEFAULT_SELECT_STRINGS } from './util/select.js';
|
|
108
127
|
export type { SelectStrings, SelectPresentation } from './util/select.js';
|
|
109
128
|
export { DEFAULT_TOP_NAVBAR_STRINGS } from './util/top-navbar.js';
|
|
110
|
-
export type { TopNavbarStrings } from './util/top-navbar.js';
|
|
129
|
+
export type { TopNavbarStrings, TopNavbarPlace } from './util/top-navbar.js';
|
|
130
|
+
export { getTopNavbarPlace } from './util/top-navbar.js';
|
|
111
131
|
export { DEFAULT_SIDEBAR_ACCOUNT_PANEL_STRINGS, DEFAULT_SIDEBAR_BRAND_HEADER_STRINGS, DEFAULT_SIDEBAR_FOOTER_STRINGS, DEFAULT_SIDEBAR_NAVIGATION_STRINGS, } from './util/sidebar.js';
|
|
112
132
|
export type { SidebarAccountPanelStrings, SidebarBrandHeaderStrings, SidebarFooterStrings, SidebarNavigationStrings, } from './util/sidebar.js';
|
|
113
133
|
export { DEFAULT_COLOR_PICKER_STRINGS, DEFAULT_COMPONENT_DEMO_STRINGS, DEFAULT_CONTACT_FORM_STRINGS, DEFAULT_PROPS_TABLE_STRINGS, } from './util/ready-made-strings.js';
|
|
@@ -118,6 +138,10 @@ export { default as SidebarShell } from './organisms/SidebarShell.svelte';
|
|
|
118
138
|
export { default as SidebarAccountPanel } from './organisms/SidebarAccountPanel.svelte';
|
|
119
139
|
export { default as SidebarPanel } from './organisms/SidebarPanel.svelte';
|
|
120
140
|
export { default as AppShell } from './organisms/AppShell.svelte';
|
|
141
|
+
export { default as AppShellHeaderPart } from './organisms/AppShellHeaderPart.svelte';
|
|
142
|
+
export { default as AppNavigation } from './organisms/AppNavigation.svelte';
|
|
143
|
+
export { APP_SHELL_RAIL_MIN_WIDTH, APP_SHELL_SIDEBAR_MIN_WIDTH, } from './util/app-shell.js';
|
|
144
|
+
export type { AppShellNavigationContext, AppShellNavigationMode, AppShellNavigationPlacement, } from './util/app-shell.js';
|
|
121
145
|
import { generateId } from './util/ssr-safe.js';
|
|
122
146
|
export { generateId };
|
|
123
147
|
/**
|