@threadlabs/looma 0.36.0 → 0.37.1
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/components/shared/icons.js +3 -0
- package/components/ui-avatar/ui-avatar.html +1 -1
- package/components/ui-avatar-group/ui-avatar-group.html +1 -1
- package/components/ui-button/ui-button.html +3 -12
- package/components/ui-card/ui-card.html +5 -5
- package/components/ui-checkbox/ui-checkbox.html +0 -6
- package/components/ui-color-picker/ui-color-picker.html +0 -9
- package/components/ui-combobox/ui-combobox.html +1 -13
- package/components/ui-cycle-button/ui-cycle-button.html +41 -0
- package/components/ui-cycle-button/ui-cycle-button.js +19 -0
- package/components/ui-dialog/ui-dialog.html +1 -1
- package/components/ui-icon/ui-icon.html +3 -0
- package/components/ui-icon-button/ui-icon-button.html +10 -14
- package/components/ui-input/ui-input.html +1 -16
- package/components/ui-input-group/ui-input-group.html +0 -10
- package/components/ui-menu/ui-menu.html +1 -1
- package/components/ui-popover/ui-popover.html +1 -1
- package/components/ui-radio/ui-radio.html +0 -6
- package/components/ui-select/ui-select.html +2 -8
- package/components/ui-switch/ui-switch.html +0 -6
- package/components/ui-tooltip/ui-tooltip.html +1 -1
- package/dist/index.js +47 -46
- package/docs/README.md +47 -8
- package/docs/card.html +2 -1
- package/docs/catalog.json +214 -39
- package/docs/customizer-render.mjs +8 -7
- package/docs/customizer.js +39 -21
- package/docs/theme.mjs +6 -5
- package/docs/value-editors.mjs +4 -3
- package/editor/icons.d.ts +3 -0
- package/editor/index.js +4 -1
- package/package.json +2 -2
- package/styles/ui-avatar-group.css +1 -1
- package/styles/ui-avatar.css +1 -1
- package/styles/ui-button.css +2 -14
- package/styles/ui-card.css +1 -1
- package/styles/ui-checkbox.css +0 -9
- package/styles/ui-color-picker.css +0 -13
- package/styles/ui-combobox.css +2 -28
- package/styles/ui-cycle-button.css +36 -0
- package/styles/ui-dialog.css +2 -2
- package/styles/ui-icon-button.css +6 -13
- package/styles/ui-input-group.css +0 -13
- package/styles/ui-input.css +2 -18
- package/styles/ui-menu.css +1 -1
- package/styles/ui-popover.css +1 -1
- package/styles/ui-radio.css +0 -9
- package/styles/ui-select.css +3 -10
- package/styles/ui-switch.css +0 -9
- package/styles/ui-tooltip.css +1 -1
- package/theme-system.css +19 -18
- package/tokens.css +20 -25
- package/vanilla/UiCycleButton.d.ts +29 -0
- package/vanilla/UiCycleButton.js +85 -0
- package/vanilla/UiIcon.js +1 -1
- package/vanilla/index.js +1 -0
- package/vue/UiAvatar.vue +1 -1
- package/vue/UiAvatarGroup.vue +1 -1
- package/vue/UiButton.vue +2 -11
- package/vue/UiCard.vue +5 -3
- package/vue/UiCheckbox.vue +0 -6
- package/vue/UiColorPicker.vue +0 -9
- package/vue/UiCombobox.vue +2 -26
- package/vue/UiCycleButton.d.ts +69 -0
- package/vue/UiCycleButton.js +2 -0
- package/vue/UiCycleButton.vue +403 -0
- package/vue/UiDialog.vue +6 -2
- package/vue/UiIcon.vue +22 -0
- package/vue/UiIconButton.vue +2 -16
- package/vue/UiInput.vue +1 -22
- package/vue/UiInputGroup.vue +0 -10
- package/vue/UiMenu.vue +3 -1
- package/vue/UiPopover.vue +3 -1
- package/vue/UiRadio.vue +0 -6
- package/vue/UiSelect.vue +2 -8
- package/vue/UiSwitch.vue +0 -6
- package/vue/UiTooltip.vue +3 -1
- package/vue/chunks/UiAffordanceScope.js +1 -1
- package/vue/chunks/UiAvatar.js +2 -2
- package/vue/chunks/UiAvatarGroup.js +2 -2
- package/vue/chunks/UiBadge.js +1 -1
- package/vue/chunks/UiBreadcrumbItem.js +1 -1
- package/vue/chunks/UiBreadcrumbs.js +1 -1
- package/vue/chunks/UiButton.js +3 -3
- package/vue/chunks/UiCallout.js +1 -1
- package/vue/chunks/UiCard.js +4 -4
- package/vue/chunks/UiCheckbox.js +2 -2
- package/vue/chunks/UiCluster.js +1 -1
- package/vue/chunks/UiColorPicker.js +2 -2
- package/vue/chunks/UiCombobox.js +2 -2
- package/vue/chunks/UiContainer.js +1 -1
- package/vue/chunks/UiContextMenu.js +1 -1
- package/vue/chunks/UiCover.js +1 -1
- package/vue/chunks/UiCurveEditor.js +1 -1
- package/vue/chunks/UiCycleButton.js +352 -0
- package/vue/chunks/UiDescriptionItem.js +1 -1
- package/vue/chunks/UiDescriptionList.js +1 -1
- package/vue/chunks/UiDialog.js +2 -2
- package/vue/chunks/UiDisclosure.js +1 -1
- package/vue/chunks/UiEditable.js +1 -1
- package/vue/chunks/UiEditorBlockActions.js +1 -1
- package/vue/chunks/UiEditorChipEditor.js +1 -1
- package/vue/chunks/UiEditorCodeLanguage.js +1 -1
- package/vue/chunks/UiEditorFootnoteEditor.js +1 -1
- package/vue/chunks/UiEditorImageToolbar.js +1 -1
- package/vue/chunks/UiEditorInsertTableGrid.js +1 -1
- package/vue/chunks/UiEditorLinkCard.js +1 -1
- package/vue/chunks/UiEditorLinkForm.js +1 -1
- package/vue/chunks/UiEditorMentionMenu.js +1 -1
- package/vue/chunks/UiEditorMentionMenuItem.js +1 -1
- package/vue/chunks/UiEditorSlashMenu.js +1 -1
- package/vue/chunks/UiEditorSlashMenuGroup.js +1 -1
- package/vue/chunks/UiEditorSlashMenuItem.js +1 -1
- package/vue/chunks/UiEditorSurface.js +1 -1
- package/vue/chunks/UiEditorTableContextMenu.js +1 -1
- package/vue/chunks/UiEditorTableOverlay.js +1 -1
- package/vue/chunks/UiEditorTableToolbar.js +1 -1
- package/vue/chunks/UiEditorToolbar.js +1 -1
- package/vue/chunks/UiFloatingActionButton.js +1 -1
- package/vue/chunks/UiFormField.js +1 -1
- package/vue/chunks/UiGrid.js +1 -1
- package/vue/chunks/UiIcon.js +70 -2
- package/vue/chunks/UiIconButton.js +4 -4
- package/vue/chunks/UiImage.js +1 -1
- package/vue/chunks/UiInput.js +2 -2
- package/vue/chunks/UiInputGroup.js +2 -2
- package/vue/chunks/UiLightEditor.js +1 -1
- package/vue/chunks/UiList.js +1 -1
- package/vue/chunks/UiListItem.js +1 -1
- package/vue/chunks/UiListbox.js +1 -1
- package/vue/chunks/UiMenu.js +2 -2
- package/vue/chunks/UiMenuGroup.js +1 -1
- package/vue/chunks/UiMenuItem.js +1 -1
- package/vue/chunks/UiMeter.js +1 -1
- package/vue/chunks/UiNavItem.js +1 -1
- package/vue/chunks/UiNumberInput.js +1 -1
- package/vue/chunks/UiPageHeader.js +1 -1
- package/vue/chunks/UiPopover.js +2 -2
- package/vue/chunks/UiRadio.js +2 -2
- package/vue/chunks/UiRadioGroup.js +1 -1
- package/vue/chunks/UiReel.js +1 -1
- package/vue/chunks/UiScrollArea.js +1 -1
- package/vue/chunks/UiSearchResultRow.js +1 -1
- package/vue/chunks/UiSearchShell.js +1 -1
- package/vue/chunks/UiSection.js +1 -1
- package/vue/chunks/UiSelect.js +2 -2
- package/vue/chunks/UiSeparator.js +1 -1
- package/vue/chunks/UiSidebar.js +1 -1
- package/vue/chunks/UiSlider.js +1 -1
- package/vue/chunks/UiSpinner.js +1 -1
- package/vue/chunks/UiStack.js +1 -1
- package/vue/chunks/UiStatusMessage.js +1 -1
- package/vue/chunks/UiSwatch.js +1 -1
- package/vue/chunks/UiSwitch.js +2 -2
- package/vue/chunks/UiSwitcher.js +1 -1
- package/vue/chunks/UiTable.js +1 -1
- package/vue/chunks/UiTabs.js +1 -1
- package/vue/chunks/UiText.js +1 -1
- package/vue/chunks/UiTextarea.js +1 -1
- package/vue/chunks/UiToast.js +1 -1
- package/vue/chunks/UiToastRegion.js +1 -1
- package/vue/chunks/UiTooltip.js +2 -2
- package/vue/chunks/UiTree.js +1 -1
- package/vue/chunks/UiTreeItem.js +1 -1
- package/vue/chunks/props.js +12 -1
- package/vue/components.css +76 -181
- package/vue/editor/index.js +68 -0
- package/vue/index.d.ts +1 -0
- package/vue/index.js +2 -1
package/styles/ui-popover.css
CHANGED
|
@@ -74,7 +74,7 @@
|
|
|
74
74
|
/* Purpose and measured size shape one shared separation lever. The content plane stays opaque;
|
|
75
75
|
transparency, saturation and edge light belong to the surrounding decorative material. */
|
|
76
76
|
.surface {
|
|
77
|
-
--_ui-material-glassiness: clamp(0, var(--ui-glassiness, 0), 1);
|
|
77
|
+
--_ui-material-glassiness: calc(clamp(0, var(--ui-glassiness, 0), 1) + 2 * pow(clamp(0, var(--ui-glassiness, 0), 1), 4));
|
|
78
78
|
--_ui-material-separation: clamp(0, var(--ui-surface-separation, 0), 1);
|
|
79
79
|
--_ui-material-active: clamp(0, calc((var(--_ui-material-glassiness) + var(--_ui-material-separation)) * 100000), 1);
|
|
80
80
|
--_ui-material-rim: calc((var(--_ui-material-separation) + var(--_ui-material-glassiness) * 0.25) * var(--_ui-material-scale, 0.55) * 8px);
|
package/styles/ui-radio.css
CHANGED
|
@@ -110,12 +110,6 @@
|
|
|
110
110
|
padding-block: max(0px, calc((var(--_row) - max(var(--_line), var(--_ui-radio-size, 1.125rem))) / 2)) !important;
|
|
111
111
|
}
|
|
112
112
|
|
|
113
|
-
@media (pointer: coarse) {
|
|
114
|
-
:scope:where([data-component~="ui-radio"])[data-ui-radio-state~="size=sm"] {
|
|
115
|
-
--_row: var(--ui-control-min-block-size);
|
|
116
|
-
}
|
|
117
|
-
}
|
|
118
|
-
|
|
119
113
|
/* A component that sets its display still honours the hidden attribute on its root. */
|
|
120
114
|
:scope:where([data-component~="ui-radio"])[hidden] {
|
|
121
115
|
display: none !important;
|
|
@@ -130,8 +124,5 @@
|
|
|
130
124
|
and the first line centres in that control height, so the label shares a row's baseline.
|
|
131
125
|
Multi-line labels and descriptions still grow downward from that first line. */
|
|
132
126
|
|
|
133
|
-
@media (pointer: coarse) {
|
|
134
|
-
}
|
|
135
|
-
|
|
136
127
|
/* A component that sets its display still honours the hidden attribute on its root. */
|
|
137
128
|
}
|
package/styles/ui-select.css
CHANGED
|
@@ -143,16 +143,10 @@
|
|
|
143
143
|
font-size: var(--ui-font-size-md);
|
|
144
144
|
}
|
|
145
145
|
|
|
146
|
-
/*
|
|
147
|
-
body-size text: below 16px, iOS zooms the page into the focused field. */
|
|
146
|
+
/* Touch may use body-size text in a small native field to avoid focus zoom; this does not impose a larger visible control height. */
|
|
148
147
|
@media (pointer: coarse) {
|
|
149
|
-
:scope:where([data-component~="ui-select"]) {
|
|
150
|
-
min-block-size: max(var(--ui-control-size-md), var(--ui-control-min-block-size));
|
|
151
|
-
}
|
|
152
|
-
|
|
153
148
|
:scope:where([data-component~="ui-select"])[data-ui-select-state~="size=sm"] {
|
|
154
|
-
|
|
155
|
-
font-size: inherit;
|
|
149
|
+
font-size: var(--ui-font-size-md);
|
|
156
150
|
}
|
|
157
151
|
}
|
|
158
152
|
|
|
@@ -169,8 +163,7 @@
|
|
|
169
163
|
|
|
170
164
|
/* The app's invalid flag, or the browser's own verdict once the user has left an invalid field. */
|
|
171
165
|
|
|
172
|
-
/*
|
|
173
|
-
body-size text: below 16px, iOS zooms the page into the focused field. */
|
|
166
|
+
/* Touch may use body-size text in a small native field to avoid focus zoom; this does not impose a larger visible control height. */
|
|
174
167
|
@media (pointer: coarse) {
|
|
175
168
|
}
|
|
176
169
|
|
package/styles/ui-switch.css
CHANGED
|
@@ -166,12 +166,6 @@
|
|
|
166
166
|
padding-block: max(0px, calc((var(--_row) - max(var(--_line), var(--_ui-switch-track-height, 1.5rem))) / 2)) !important;
|
|
167
167
|
}
|
|
168
168
|
|
|
169
|
-
@media (pointer: coarse) {
|
|
170
|
-
:scope:where([data-component~="ui-switch"])[data-ui-switch-state~="size=sm"] {
|
|
171
|
-
--_row: var(--ui-control-min-block-size);
|
|
172
|
-
}
|
|
173
|
-
}
|
|
174
|
-
|
|
175
169
|
/* A component that sets its display still honours the hidden attribute on its root. */
|
|
176
170
|
:scope:where([data-component~="ui-switch"])[hidden] {
|
|
177
171
|
display: none !important;
|
|
@@ -189,8 +183,5 @@
|
|
|
189
183
|
and the first line centres in that control height, so the label shares a row's baseline.
|
|
190
184
|
Multi-line labels and descriptions still grow downward from that first line. */
|
|
191
185
|
|
|
192
|
-
@media (pointer: coarse) {
|
|
193
|
-
}
|
|
194
|
-
|
|
195
186
|
/* A component that sets its display still honours the hidden attribute on its root. */
|
|
196
187
|
}
|
package/styles/ui-tooltip.css
CHANGED
|
@@ -106,7 +106,7 @@
|
|
|
106
106
|
/* Purpose and measured size shape one shared separation lever. The content plane stays opaque;
|
|
107
107
|
transparency, saturation and edge light belong to the surrounding decorative material. */
|
|
108
108
|
.surface {
|
|
109
|
-
--_ui-material-glassiness: clamp(0, var(--ui-glassiness, 0), 1);
|
|
109
|
+
--_ui-material-glassiness: calc(clamp(0, var(--ui-glassiness, 0), 1) + 2 * pow(clamp(0, var(--ui-glassiness, 0), 1), 4));
|
|
110
110
|
--_ui-material-separation: clamp(0, var(--ui-surface-separation, 0), 1);
|
|
111
111
|
--_ui-material-active: clamp(0, calc((var(--_ui-material-glassiness) + var(--_ui-material-separation)) * 100000), 1);
|
|
112
112
|
--_ui-material-rim: calc((var(--_ui-material-separation) + var(--_ui-material-glassiness) * 0.25) * var(--_ui-material-scale, 0.08) * 8px);
|
package/theme-system.css
CHANGED
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
/* Reserve the same order when the remembered theme arrives before baseline CSS. */
|
|
6
6
|
@layer tokens, base, theme, components;
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
/* Keep the root font seed unregistered: a registered rem length used by root
|
|
9
|
+
font-size creates a dependency cycle (CSS Properties and Values API 2.7.2). */
|
|
9
10
|
@property --ui-control-size { syntax: "<length>"; inherits: true; initial-value: 40px; }
|
|
10
11
|
@property --ui-radius-md { syntax: "<length>"; inherits: true; initial-value: 8px; }
|
|
11
12
|
@property --ui-border-width { syntax: "<length>"; inherits: true; initial-value: 1px; }
|
|
@@ -33,9 +34,9 @@
|
|
|
33
34
|
:where(:root, [data-theme], [data-contrast]) {
|
|
34
35
|
/* Controls use a ratio. Spacing uses an independent curve, so increasing the size
|
|
35
36
|
contrast cannot unexpectedly turn linear spacing into quadratic spacing. */
|
|
36
|
-
--ui-control-size: calc(
|
|
37
|
+
--ui-control-size: calc(1rem * var(--ui-control-roominess));
|
|
37
38
|
--_ui-theme-ratio: max(1, var(--ui-scale-ratio));
|
|
38
|
-
--_ui-theme-unit: calc(
|
|
39
|
+
--_ui-theme-unit: calc(1rem * 0.25 * max(0, var(--ui-spacing)));
|
|
39
40
|
--_ui-theme-curve: max(0, var(--ui-space-curve));
|
|
40
41
|
--ui-control-size-sm: calc(var(--ui-control-size) / var(--_ui-theme-ratio));
|
|
41
42
|
--ui-control-size-md: var(--ui-control-size);
|
|
@@ -53,10 +54,10 @@
|
|
|
53
54
|
--ui-control-inset-block-sm: max(0px, calc((var(--ui-control-size-sm) - var(--ui-font-size-sm) * var(--ui-line-height-tight) - 2 * var(--ui-border-width)) / 2));
|
|
54
55
|
--ui-control-inset-block-md: max(0px, calc((var(--ui-control-size-md) - var(--ui-font-size-md) * var(--ui-line-height-tight) - 2 * var(--ui-border-width)) / 2));
|
|
55
56
|
--ui-control-inset-block-lg: max(0px, calc((var(--ui-control-size-lg) - var(--ui-font-size-md) * var(--ui-line-height-tight) - 2 * var(--ui-border-width)) / 2));
|
|
56
|
-
--ui-font-size-xs: max(12px, calc(
|
|
57
|
-
--ui-action-inset-sm: var(--ui-space-2);
|
|
58
|
-
--ui-action-inset-md: var(--ui-space-3);
|
|
59
|
-
--ui-action-inset-lg: var(--ui-space-4);
|
|
57
|
+
--ui-font-size-xs: max(12px, calc(1rem * 0.75));
|
|
58
|
+
--ui-action-inset-sm: max(var(--ui-space-2), var(--ui-control-inset-block-sm));
|
|
59
|
+
--ui-action-inset-md: max(var(--ui-space-3), var(--ui-control-inset-block-md));
|
|
60
|
+
--ui-action-inset-lg: max(var(--ui-space-4), var(--ui-control-inset-block-lg));
|
|
60
61
|
|
|
61
62
|
--ui-radius-sm: calc(var(--ui-radius-md) * 0.5);
|
|
62
63
|
--ui-radius-lg: calc(var(--ui-radius-md) * 1.5);
|
|
@@ -73,7 +74,8 @@
|
|
|
73
74
|
--_ui-shadow-x: calc((0.5 - var(--ui-light-x)) * 2);
|
|
74
75
|
--_ui-shadow-y: calc((0.5 - var(--ui-light-y)) * 2);
|
|
75
76
|
--_ui-light-block: calc((0.5 - var(--ui-light-y)) * 2px);
|
|
76
|
-
|
|
77
|
+
/* Catch light at the silhouette, not as a second frame inside the border. */
|
|
78
|
+
--_ui-theme-edge-paint: calc(-1 * var(--_ui-light-inline)) calc(-1 * var(--_ui-light-block)) 0 rgb(255 255 255 / calc(var(--_ui-theme-edge) * var(--ui-light-strength) * 0.3)), var(--_ui-light-inline) var(--_ui-light-block) 0 rgb(0 0 0 / calc(var(--_ui-theme-edge) * 0.1));
|
|
77
79
|
--ui-action-edge: var(--_ui-theme-edge-paint);
|
|
78
80
|
--ui-shadow-xs: calc(1px * var(--_ui-theme-outer) * var(--_ui-shadow-x)) calc(1px * var(--_ui-theme-outer) * var(--_ui-shadow-y)) calc(2px * var(--_ui-theme-outer)) rgb(0 0 0 / 0.08);
|
|
79
81
|
--ui-shadow-sm: calc(1px * var(--_ui-theme-outer) * var(--_ui-shadow-x)) calc(1px * var(--_ui-theme-outer) * var(--_ui-shadow-y)) calc(3px * var(--_ui-theme-outer)) rgb(0 0 0 / 0.12), calc(4px * var(--_ui-theme-outer) * var(--_ui-shadow-x)) calc(4px * var(--_ui-theme-outer) * var(--_ui-shadow-y)) calc(12px * var(--_ui-theme-outer)) rgb(0 0 0 / 0.06);
|
|
@@ -102,13 +104,15 @@
|
|
|
102
104
|
--ui-success-highlight: radial-gradient(ellipse calc(35% + var(--ui-light-spread) * 165%) calc(55% + var(--ui-light-spread) * 200%) at calc(var(--ui-light-x) * 100%) calc(var(--ui-light-y) * 100%), color-mix(in srgb, var(--ui-success-reflection, var(--ui-surface-raised)) calc(var(--ui-finish) * var(--ui-light-strength) * 100%), transparent), transparent 85%);
|
|
103
105
|
--ui-warning-highlight: radial-gradient(ellipse calc(35% + var(--ui-light-spread) * 165%) calc(55% + var(--ui-light-spread) * 200%) at calc(var(--ui-light-x) * 100%) calc(var(--ui-light-y) * 100%), color-mix(in srgb, var(--ui-warning-reflection, var(--ui-surface-raised)) calc(var(--ui-finish) * var(--ui-light-strength) * 100%), transparent), transparent 85%);
|
|
104
106
|
--ui-info-highlight: radial-gradient(ellipse calc(35% + var(--ui-light-spread) * 165%) calc(55% + var(--ui-light-spread) * 200%) at calc(var(--ui-light-x) * 100%) calc(var(--ui-light-y) * 100%), color-mix(in srgb, var(--ui-info-reflection, var(--ui-surface-raised)) calc(var(--ui-finish) * var(--ui-light-strength) * 100%), transparent), transparent 85%);
|
|
105
|
-
|
|
106
|
-
--
|
|
107
|
-
--ui-
|
|
108
|
-
--ui-
|
|
109
|
-
--ui-
|
|
110
|
-
--ui-
|
|
111
|
-
--ui-
|
|
107
|
+
/* Keep the low end gentle; the upper range deliberately reaches beyond restrained ornament. */
|
|
108
|
+
--_ui-theme-glow: calc(clamp(0, var(--ui-glow), 1) + 2 * pow(clamp(0, var(--ui-glow), 1), 4));
|
|
109
|
+
--ui-material-glow: 0 0 calc(18px * var(--_ui-theme-glow)) color-mix(in srgb, var(--ui-accent) calc(var(--_ui-theme-glow) * var(--ui-light-strength) * 18%), transparent);
|
|
110
|
+
--ui-neutral-glow: 0 0 calc(18px * var(--_ui-theme-glow)) color-mix(in srgb, var(--ui-text) calc(var(--_ui-theme-glow) * var(--ui-light-strength) * 18%), transparent);
|
|
111
|
+
--ui-accent-glow: 0 0 calc(18px * var(--_ui-theme-glow)) color-mix(in srgb, var(--ui-accent) calc(var(--_ui-theme-glow) * var(--ui-light-strength) * 18%), transparent);
|
|
112
|
+
--ui-danger-glow: 0 0 calc(18px * var(--_ui-theme-glow)) color-mix(in srgb, var(--ui-danger) calc(var(--_ui-theme-glow) * var(--ui-light-strength) * 18%), transparent);
|
|
113
|
+
--ui-success-glow: 0 0 calc(18px * var(--_ui-theme-glow)) color-mix(in srgb, var(--ui-success) calc(var(--_ui-theme-glow) * var(--ui-light-strength) * 18%), transparent);
|
|
114
|
+
--ui-warning-glow: 0 0 calc(18px * var(--_ui-theme-glow)) color-mix(in srgb, var(--ui-warning) calc(var(--_ui-theme-glow) * var(--ui-light-strength) * 18%), transparent);
|
|
115
|
+
--ui-info-glow: 0 0 calc(18px * var(--_ui-theme-glow)) color-mix(in srgb, var(--ui-info) calc(var(--_ui-theme-glow) * var(--ui-light-strength) * 18%), transparent);
|
|
112
116
|
--ui-raised-highlight: var(--ui-surface-highlight);
|
|
113
117
|
|
|
114
118
|
/* Existing timing and easing names stay canonical. */
|
|
@@ -120,9 +124,6 @@
|
|
|
120
124
|
|
|
121
125
|
@media (pointer: coarse) {
|
|
122
126
|
:where(:root, [data-theme], [data-contrast]) {
|
|
123
|
-
--ui-control-size-sm: max(calc(var(--ui-control-size) / var(--_ui-theme-ratio)), var(--ui-control-min-block-size));
|
|
124
|
-
--ui-control-size-md: calc(var(--ui-control-size-sm) * var(--_ui-theme-ratio));
|
|
125
|
-
--ui-control-size-lg: calc(var(--ui-control-size-md) * var(--_ui-theme-ratio));
|
|
126
127
|
/* Small native fields use body-size text on touch to avoid focus zoom. */
|
|
127
128
|
--ui-control-inset-block-sm: max(0px, calc((var(--ui-control-size-sm) - var(--ui-font-size-md) * var(--ui-line-height-tight) - 2 * var(--ui-border-width)) / 2));
|
|
128
129
|
}
|
package/tokens.css
CHANGED
|
@@ -25,6 +25,9 @@
|
|
|
25
25
|
--ui-text: #1a1a1a;
|
|
26
26
|
--ui-focus-halo: 0 0 0 calc(var(--ui-focus-width) * 1.5) color-mix(in srgb, var(--ui-focus-ring) 40%, transparent);
|
|
27
27
|
|
|
28
|
+
/* The base type token owns the document root; rem-based roles scale from it once. */
|
|
29
|
+
font-size: var(--ui-font-size);
|
|
30
|
+
|
|
28
31
|
/* Type. */
|
|
29
32
|
--ui-font-sans:
|
|
30
33
|
system-ui,
|
|
@@ -38,7 +41,7 @@
|
|
|
38
41
|
"Apple Color Emoji",
|
|
39
42
|
"Segoe UI Emoji";
|
|
40
43
|
--ui-font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
|
|
41
|
-
--ui-font-size:
|
|
44
|
+
--ui-font-size: 16px;
|
|
42
45
|
--ui-font-medium: 500;
|
|
43
46
|
--ui-line-height: 1.4;
|
|
44
47
|
|
|
@@ -75,8 +78,7 @@
|
|
|
75
78
|
/* Controls: the contract every button and field shares. */
|
|
76
79
|
--ui-control-size: 2.5rem;
|
|
77
80
|
--ui-control-size-sm: 2rem;
|
|
78
|
-
/*
|
|
79
|
-
a touch target below 44. */
|
|
81
|
+
/* Adjustable comfort preference for expanded targets, independent of visible control size. */
|
|
80
82
|
--ui-control-min-block-size: 44px;
|
|
81
83
|
}
|
|
82
84
|
|
|
@@ -92,14 +94,14 @@
|
|
|
92
94
|
--ui-accent-line-width: var(--ui-border-width);
|
|
93
95
|
|
|
94
96
|
/* Type scale, from the base size. */
|
|
95
|
-
--ui-font-size-2xs: calc(
|
|
96
|
-
--ui-font-size-xs: calc(
|
|
97
|
+
--ui-font-size-2xs: calc(1rem * 0.6875);
|
|
98
|
+
--ui-font-size-xs: calc(1rem * 0.75);
|
|
97
99
|
/* Dense text: controls, labels, and metadata. Two steps below body copy, never one pixel. */
|
|
98
|
-
--ui-font-size-sm: calc(
|
|
99
|
-
--ui-font-size-md:
|
|
100
|
-
--ui-font-size-lg: calc(
|
|
101
|
-
--ui-font-size-xl: calc(
|
|
102
|
-
--ui-font-size-2xl: calc(
|
|
100
|
+
--ui-font-size-sm: calc(1rem * 0.875);
|
|
101
|
+
--ui-font-size-md: 1rem;
|
|
102
|
+
--ui-font-size-lg: calc(1rem * 1.125);
|
|
103
|
+
--ui-font-size-xl: calc(1rem * 1.25);
|
|
104
|
+
--ui-font-size-2xl: calc(1rem * 1.5);
|
|
103
105
|
--ui-line-height-tight: 1.2;
|
|
104
106
|
--ui-line-height-md: var(--ui-line-height);
|
|
105
107
|
/* Prose, not controls: the editor's document body reads at a looser line height. */
|
|
@@ -260,14 +262,14 @@
|
|
|
260
262
|
--ui-control-size-lg: calc(var(--ui-control-size) * 1.2);
|
|
261
263
|
|
|
262
264
|
/* Choice marks follow typography; row heights follow the shared control scale. */
|
|
263
|
-
--ui-choice-mark-size: calc(
|
|
264
|
-
--ui-choice-track-height: calc(
|
|
265
|
-
--ui-choice-track-width: calc(
|
|
265
|
+
--ui-choice-mark-size: calc(1rem * 1.125);
|
|
266
|
+
--ui-choice-track-height: calc(1rem * 1.5);
|
|
267
|
+
--ui-choice-track-width: calc(1rem * 2.5);
|
|
266
268
|
|
|
267
269
|
/* Icon sizes, used by icon buttons and field affordances. */
|
|
268
|
-
--ui-icon-size-sm:
|
|
269
|
-
--ui-icon-size-md: calc(
|
|
270
|
-
--ui-icon-size-lg: calc(
|
|
270
|
+
--ui-icon-size-sm: 1rem;
|
|
271
|
+
--ui-icon-size-md: calc(1rem * 1.25);
|
|
272
|
+
--ui-icon-size-lg: calc(1rem * 1.5);
|
|
271
273
|
|
|
272
274
|
/* Anticipatory interaction: guide → near → direct. */
|
|
273
275
|
--ui-affordance-guide-size: var(--ui-space-1);
|
|
@@ -283,14 +285,7 @@
|
|
|
283
285
|
--ui-motion-fast: 0ms;
|
|
284
286
|
}
|
|
285
287
|
}
|
|
286
|
-
|
|
287
|
-
@media (pointer: coarse) {
|
|
288
|
-
:root, :where([data-theme], [data-contrast]) {
|
|
289
|
-
--ui-control-size-sm: max(calc(var(--ui-control-size) / 1.2), var(--ui-control-min-block-size));
|
|
290
|
-
--ui-control-size-md: calc(var(--ui-control-size-sm) * 1.2);
|
|
291
|
-
--ui-control-size-lg: calc(var(--ui-control-size-md) * 1.2);
|
|
292
|
-
}
|
|
293
|
-
}
|
|
288
|
+
|
|
294
289
|
|
|
295
290
|
}
|
|
296
291
|
|
|
@@ -392,7 +387,7 @@
|
|
|
392
387
|
background-color: var(--ui-control-surface);
|
|
393
388
|
background-repeat: no-repeat;
|
|
394
389
|
background-position: center;
|
|
395
|
-
background-size: calc(
|
|
390
|
+
background-size: calc(1rem * 0.7);
|
|
396
391
|
}
|
|
397
392
|
|
|
398
393
|
[data-ui-choice-option][data-multiple][aria-selected="true"]::before {
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
// Generated by HTML Next 1.0.0-alpha.69 for Vanilla DOM. Do not edit.
|
|
2
|
+
export interface UiCycleButtonEventMap {
|
|
3
|
+
change: CustomEvent<{ readonly value: string; readonly index: number }>;
|
|
4
|
+
}
|
|
5
|
+
export interface UiCycleButtonElement extends HTMLSpanElement {
|
|
6
|
+
addEventListener<K extends keyof UiCycleButtonEventMap>(type: K, listener: (this: UiCycleButtonElement, event: UiCycleButtonEventMap[K]) => unknown, options?: boolean | AddEventListenerOptions): void;
|
|
7
|
+
addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: UiCycleButtonElement, event: HTMLElementEventMap[K]) => unknown, options?: boolean | AddEventListenerOptions): void;
|
|
8
|
+
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
|
|
9
|
+
removeEventListener<K extends keyof UiCycleButtonEventMap>(type: K, listener: (this: UiCycleButtonElement, event: UiCycleButtonEventMap[K]) => unknown, options?: boolean | EventListenerOptions): void;
|
|
10
|
+
removeEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: UiCycleButtonElement, event: HTMLElementEventMap[K]) => unknown, options?: boolean | EventListenerOptions): void;
|
|
11
|
+
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
|
|
12
|
+
}
|
|
13
|
+
export interface UiCycleButtonProps {
|
|
14
|
+
disabled?: boolean | null;
|
|
15
|
+
index?: number | null;
|
|
16
|
+
items: readonly ({ readonly value: string; readonly label: string; readonly icon: string })[];
|
|
17
|
+
label?: string | null;
|
|
18
|
+
size?: "sm" | "md" | "lg" | null;
|
|
19
|
+
variant?: "ghost" | "outline" | "solid" | null;
|
|
20
|
+
attributes?: Readonly<Record<string, string | number | boolean | null | undefined>>;
|
|
21
|
+
children?: readonly (string | Node)[];
|
|
22
|
+
slots?: Readonly<Record<string, readonly (string | Node)[]>>;
|
|
23
|
+
}
|
|
24
|
+
export declare function createUiCycleButton(props: UiCycleButtonProps): UiCycleButtonElement;
|
|
25
|
+
declare global {
|
|
26
|
+
interface ComponentTagMap {
|
|
27
|
+
"ui-cycle-button": { element: UiCycleButtonElement; props: Omit<UiCycleButtonProps, "attributes" | "children" | "slots"> };
|
|
28
|
+
}
|
|
29
|
+
}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
// Generated by HTML Next 1.0.0-alpha.69 for Vanilla DOM. Do not edit.
|
|
2
|
+
import { attachGeneratedController, stateInitializers, binaryValue, buildTemplate, checkReference, defaultValue, NONCONFORMING, readDeclared, readFailing, readIndex, readMember, textCall, toAttribute, truthy, writeAttribute, computedCycle, dispatchDeclared, detailCheck, formatOf, keywordFormat, acceptProps, manageProps, generatedInputs, awaitInput, evaluateInput, inputRead, inputDefault, READY_INPUT, UNRESOLVED_INPUT, notifyPropertySet, ABSENT, readonlyView, checkBoolean, checkFormat, checkList, checkNumber, checkObject, checkString, defineComponent, activateModule } from "@nextwebwg/html-next/generated-runtime";
|
|
3
|
+
import * as controller from "../components/ui-cycle-button/ui-cycle-button.js";
|
|
4
|
+
import "../styles/ui-cycle-button.css";
|
|
5
|
+
|
|
6
|
+
const T0 = ["",[],["ui-icon-button",["tone","neutral","aria-description","Activate to choose the next state."],["ui-icon",[]]]];
|
|
7
|
+
let P0;
|
|
8
|
+
const S = { n: ["current","selected"], t: ["n","?"], f: import.meta.url, g: "ui-cycle-button", k: 1, d: { "change": [detailCheck(checkObject([["value", checkString, false], ["index", checkNumber, false]], false)), true, true, false] }, x: dispatchDeclared, r: readonlyView, a: (host, I) => C(host, I), b: generatedInputs };
|
|
9
|
+
const D = { g: "ui-cycle-button", props: { "disabled": { "required":false,"default":false, c: checkBoolean, t: "boolean", j: 0, m: "b" }, "index": { "required":false,"default":0, c: checkNumber, t: "number", j: 0, m: "n" }, "items": { "required":true, c: checkList(checkObject([["value", checkString, false], ["label", checkString, false], ["icon", checkString, false]], false)), j: 1, m: ["l",["o",["value","s","label","s","icon","s"]]] }, "label": { "required":false,"default":"State", c: checkString, t: "string", j: 0, m: "s" }, "size": { "required":false,"values":["sm","md","lg"],"default":"md", c: checkFormat("keyword", keywordFormat), t: "keyword", j: 0, m: ["p",formatOf(keywordFormat)] }, "variant": { "required":false,"values":["ghost","outline","solid"],"default":"outline", c: checkFormat("keyword", keywordFormat), t: "keyword", j: 0, m: ["p",formatOf(keywordFormat)] } } };
|
|
10
|
+
const C = (host) => activateModule(controller, host);
|
|
11
|
+
|
|
12
|
+
export function createUiCycleButton(options, html) {
|
|
13
|
+
const { attributes = {}, children = [], slots = {}, ...componentProps } = options;
|
|
14
|
+
const element = document.createElement("span");
|
|
15
|
+
for (const [name, value] of Object.entries(attributes)) {
|
|
16
|
+
if (value === null || value === undefined || value === false) continue;
|
|
17
|
+
element.setAttribute(name, value === true ? "" : String(value));
|
|
18
|
+
}
|
|
19
|
+
element.setAttribute("data-component", "ui-cycle-button");
|
|
20
|
+
element.append((P0 ??= buildTemplate(T0)).cloneNode(true));
|
|
21
|
+
const v = [null, undefined, null, null, null, null, null, null];
|
|
22
|
+
const B = acceptProps(element, D, S.n, v, componentProps, [], html);
|
|
23
|
+
const CS = [];
|
|
24
|
+
const inputStatus = (j) => { if (j === 0) return E.status(j); if (j >= 1 && j < 2) { g(j); return CS[j] ?? UNRESOLVED_INPUT; } if (j === 2) return awaitInput(B, "disabled", true); if (j === 3) return awaitInput(B, "index", true); if (j === 4) return awaitInput(B, "items", true); if (j === 5) return awaitInput(B, "label", true); if (j === 6) return awaitInput(B, "size", true); if (j === 7) return awaitInput(B, "variant", true); return v[j] === undefined ? UNRESOLVED_INPUT : READY_INPUT; };
|
|
25
|
+
const X = { e: 0, g: (j) => g(j), w: new Set(), a: CS, i: inputStatus };
|
|
26
|
+
const ke = [];
|
|
27
|
+
const K = [() => (checkReference(S, v[0], "n", "expression:default($items[default($current, 0)], $items[0]):current", "Reference `current` must satisfy number.") && checkReference(S, readDeclared(v[4], ["0"]), ["o",["value","s","label","s","icon","s"]], "expression:default($items[default($current, 0)], $items[0]):items.0", "Reference `items.0` must satisfy object({ value: string, label: string, icon: string }).") ? inputDefault(() => readIndex(inputRead(v[4], inputStatus(4)), inputDefault(() => inputRead(E.read(0), inputStatus(0)), () => 0, ABSENT)), () => readIndex(inputRead(v[4], inputStatus(4)), 0), ABSENT) : NONCONFORMING)];
|
|
28
|
+
const g = (j) => {
|
|
29
|
+
const i = j - 1;
|
|
30
|
+
if (ke[i] === X.e) return v[j];
|
|
31
|
+
if (ke[i] === -1) computedCycle();
|
|
32
|
+
ke[i] = -1;
|
|
33
|
+
let next;
|
|
34
|
+
try { const result = evaluateInput(K[i], CS[j], NONCONFORMING), previousStatus = CS[j]; CS[j] = result.status; notifyPropertySet(CS, j, previousStatus, result.status, undefined); next = !result.status.ready ? null : result.value === NONCONFORMING ? v[j] : result.value; } catch (error) { ke[i] = undefined; throw error; }
|
|
35
|
+
ke[i] = X.e;
|
|
36
|
+
const previous = v[j];
|
|
37
|
+
if (!Object.is(previous, next)) { v[j] = next; X.n?.(j, previous, next); }
|
|
38
|
+
return next;
|
|
39
|
+
};
|
|
40
|
+
const E = stateInitializers(S, v, X, { 0: () => inputRead(v[3], inputStatus(3)) });
|
|
41
|
+
const p0 = (r, c, d) => {
|
|
42
|
+
if (c & 1073741873) {
|
|
43
|
+
const x0 = textCall("concat", [v[5], ": ", defaultValue(readFailing(g(1), "label"), "No choices")]);
|
|
44
|
+
if (x0 !== NONCONFORMING) {
|
|
45
|
+
const s0 = toAttribute(x0, "label");
|
|
46
|
+
if (s0 !== r.v0) writeAttribute(r.a0, "label", r.v0 = s0);
|
|
47
|
+
}
|
|
48
|
+
if (x0 !== NONCONFORMING) {
|
|
49
|
+
const s1 = toAttribute(x0, "title");
|
|
50
|
+
if (s1 !== r.v1) writeAttribute(r.a0, "title", r.v1 = s1);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
if (c & 1073741888) {
|
|
54
|
+
const x1 = v[6];
|
|
55
|
+
const s2 = toAttribute(x1, "size");
|
|
56
|
+
if (s2 !== r.v2) writeAttribute(r.a0, "size", r.v2 = s2);
|
|
57
|
+
}
|
|
58
|
+
if (c & 1073741952) {
|
|
59
|
+
const x2 = v[7];
|
|
60
|
+
const s3 = toAttribute(x2, "variant");
|
|
61
|
+
if (s3 !== r.v3) writeAttribute(r.a0, "variant", r.v3 = s3);
|
|
62
|
+
}
|
|
63
|
+
if (c & 1073741844) {
|
|
64
|
+
const x3 = (truthy(v[2]) || truthy(binaryValue("<", readMember(v[4], "length"), 2)));
|
|
65
|
+
const s4 = toAttribute(x3, "disabled");
|
|
66
|
+
if (s4 !== r.v4) writeAttribute(r.a0, "disabled", r.v4 = s4);
|
|
67
|
+
}
|
|
68
|
+
if (c & 1073741841) {
|
|
69
|
+
const x4 = defaultValue(readFailing(g(1), "icon"), "");
|
|
70
|
+
if (x4 !== NONCONFORMING) {
|
|
71
|
+
const s5 = toAttribute(x4, "name");
|
|
72
|
+
if (s5 !== r.v5) writeAttribute(r.a1, "name", r.v5 = s5);
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
};
|
|
76
|
+
const t0 = element.firstChild;
|
|
77
|
+
const t1 = t0.firstChild;
|
|
78
|
+
const R = { a0: t0, a1: t1, v0: null, v1: null, v2: null, v3: null, v4: null, v5: null };
|
|
79
|
+
const I = { B, U: E };
|
|
80
|
+
I.R = new Set();
|
|
81
|
+
attachGeneratedController(element, S, v, (c, d) => { ((c, d) => p0(R, c, d))(c, d); for (const f of I.R) f(c, d); }, undefined, X, I);
|
|
82
|
+
manageProps(I);
|
|
83
|
+
return element;
|
|
84
|
+
}
|
|
85
|
+
defineComponent("ui-cycle-button", createUiCycleButton, ["disabled","index","items","label","size","variant"]);
|
package/vanilla/UiIcon.js
CHANGED
|
@@ -29,7 +29,7 @@ export function createUiIcon(options = {}, html) {
|
|
|
29
29
|
const inputStatus = (j) => { if (j >= 0 && j < 1) { g(j); return CS[j] ?? UNRESOLVED_INPUT; } if (j === 1) return awaitInput(B, "name", true); if (j === 2) return awaitInput(B, "tone", true); return v[j] === undefined ? UNRESOLVED_INPUT : READY_INPUT; };
|
|
30
30
|
const X = { e: 0, g: (j) => g(j), w: new Set(), a: CS, i: inputStatus };
|
|
31
31
|
const ke = [];
|
|
32
|
-
const K = [() => readIndex({ "align-center": [{ "tag": "path", "d": "M21 5H3" }, { "tag": "path", "d": "M17 12H7" }, { "tag": "path", "d": "M19 19H5" }], "align-left": [{ "tag": "path", "d": "M21 5H3" }, { "tag": "path", "d": "M15 12H3" }, { "tag": "path", "d": "M17 19H3" }], "align-right": [{ "tag": "path", "d": "M21 5H3" }, { "tag": "path", "d": "M21 12H9" }, { "tag": "path", "d": "M21 19H7" }], "arrow-left": [{ "tag": "path", "d": "m12 19-7-7 7-7" }, { "tag": "path", "d": "M19 12H5" }], "bell": [{ "tag": "path", "d": "M10.268 21a2 2 0 0 0 3.464 0" }, { "tag": "path", "d": "M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326" }], "bold": [{ "tag": "path", "d": "M6 12h9a4 4 0 0 1 0 8H7a1 1 0 0 1-1-1V5a1 1 0 0 1 1-1h7a4 4 0 0 1 0 8" }], "book-user": [{ "tag": "path", "d": "M15 13a3 3 0 1 0-6 0" }, { "tag": "path", "d": "M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20" }, { "tag": "circle", "cx": "12", "cy": "8", "r": "2" }], "braces": [{ "tag": "path", "d": "M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5c0 1.1.9 2 2 2h1" }, { "tag": "path", "d": "M16 21h1a2 2 0 0 0 2-2v-5c0-1.1.9-2 2-2a2 2 0 0 1-2-2V5a2 2 0 0 0-2-2h-1" }], "calculator": [{ "tag": "rect", "width": "16", "height": "20", "x": "4", "y": "2", "rx": "2" }, { "tag": "line", "x1": "8", "x2": "16", "y1": "6", "y2": "6" }, { "tag": "line", "x1": "16", "x2": "16", "y1": "14", "y2": "18" }, { "tag": "path", "d": "M16 10h.01" }, { "tag": "path", "d": "M12 10h.01" }, { "tag": "path", "d": "M8 10h.01" }, { "tag": "path", "d": "M12 14h.01" }, { "tag": "path", "d": "M8 14h.01" }, { "tag": "path", "d": "M12 18h.01" }, { "tag": "path", "d": "M8 18h.01" }], "check": [{ "tag": "path", "d": "M20 6 9 17l-5-5" }], "chevron-down": [{ "tag": "path", "d": "m6 9 6 6 6-6" }], "chevron-left": [{ "tag": "path", "d": "m15 18-6-6 6-6" }], "chevron-right": [{ "tag": "path", "d": "m9 18 6-6-6-6" }], "circle-check": [{ "tag": "circle", "cx": "12", "cy": "12", "r": "10" }, { "tag": "path", "d": "m9 12 2 2 4-4" }], "circle-dot": [{ "tag": "circle", "cx": "12", "cy": "12", "r": "10" }, { "tag": "circle", "cx": "12", "cy": "12", "r": "1" }], "circle-x": [{ "tag": "circle", "cx": "12", "cy": "12", "r": "10" }, { "tag": "path", "d": "m15 9-6 6" }, { "tag": "path", "d": "m9 9 6 6" }], "code-xml": [{ "tag": "path", "d": "m18 16 4-4-4-4" }, { "tag": "path", "d": "m6 8-4 4 4 4" }, { "tag": "path", "d": "m14.5 4-5 16" }], "columns": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2" }, { "tag": "path", "d": "M9 3v18" }, { "tag": "path", "d": "M15 3v18" }], "compass": [{ "tag": "path", "d": "m16.24 7.76-1.804 5.411a2 2 0 0 1-1.265 1.265L7.76 16.24l1.804-5.411a2 2 0 0 1 1.265-1.265z" }, { "tag": "circle", "cx": "12", "cy": "12", "r": "10" }], "credit-card": [{ "tag": "rect", "width": "20", "height": "14", "x": "2", "y": "5", "rx": "2" }, { "tag": "line", "x1": "2", "x2": "22", "y1": "10", "y2": "10" }], "ellipsis": [{ "tag": "circle", "cx": "12", "cy": "12", "r": "1" }, { "tag": "circle", "cx": "19", "cy": "12", "r": "1" }, { "tag": "circle", "cx": "5", "cy": "12", "r": "1" }], "eraser": [{ "tag": "path", "d": "M21 21H8a2 2 0 0 1-1.42-.587l-3.994-3.999a2 2 0 0 1 0-2.828l10-10a2 2 0 0 1 2.829 0l5.999 6a2 2 0 0 1 0 2.828L12.834 21" }, { "tag": "path", "d": "m5.082 11.09 8.828 8.828" }], "external-link": [{ "tag": "path", "d": "M15 3h6v6" }, { "tag": "path", "d": "M10 14 21 3" }, { "tag": "path", "d": "M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6" }], "file-text": [{ "tag": "path", "d": "M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z" }, { "tag": "path", "d": "M14 2v5a1 1 0 0 0 1 1h5" }, { "tag": "path", "d": "M10 9H8" }, { "tag": "path", "d": "M16 13H8" }, { "tag": "path", "d": "M16 17H8" }], "folder": [{ "tag": "path", "d": "M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z" }], "grip-horizontal": [{ "tag": "circle", "cx": "12", "cy": "9", "r": "1" }, { "tag": "circle", "cx": "19", "cy": "9", "r": "1" }, { "tag": "circle", "cx": "5", "cy": "9", "r": "1" }, { "tag": "circle", "cx": "12", "cy": "15", "r": "1" }, { "tag": "circle", "cx": "19", "cy": "15", "r": "1" }, { "tag": "circle", "cx": "5", "cy": "15", "r": "1" }], "grip-vertical": [{ "tag": "circle", "cx": "9", "cy": "12", "r": "1" }, { "tag": "circle", "cx": "9", "cy": "5", "r": "1" }, { "tag": "circle", "cx": "9", "cy": "19", "r": "1" }, { "tag": "circle", "cx": "15", "cy": "12", "r": "1" }, { "tag": "circle", "cx": "15", "cy": "5", "r": "1" }, { "tag": "circle", "cx": "15", "cy": "19", "r": "1" }], "heading-1": [{ "tag": "path", "d": "M4 12h8" }, { "tag": "path", "d": "M4 18V6" }, { "tag": "path", "d": "M12 18V6" }, { "tag": "path", "d": "m17 12 3-2v8" }], "heading-2": [{ "tag": "path", "d": "M4 12h8" }, { "tag": "path", "d": "M4 18V6" }, { "tag": "path", "d": "M12 18V6" }, { "tag": "path", "d": "M21 18h-4c0-4 4-3 4-6 0-1.5-2-2.5-4-1" }], "heading-3": [{ "tag": "path", "d": "M4 12h8" }, { "tag": "path", "d": "M4 18V6" }, { "tag": "path", "d": "M12 18V6" }, { "tag": "path", "d": "M17.5 10.5c1.7-1 3.5 0 3.5 1.5a2 2 0 0 1-2 2" }, { "tag": "path", "d": "M17 17.5c2 1.5 4 .3 4-1.5a2 2 0 0 0-2-2" }], "help": [{ "tag": "circle", "cx": "12", "cy": "12", "r": "10" }, { "tag": "path", "d": "M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3" }, { "tag": "path", "d": "M12 17h.01" }], "highlighter": [{ "tag": "path", "d": "m9 11-6 6v3h9l3-3" }, { "tag": "path", "d": "m22 12-4.6 4.6a2 2 0 0 1-2.8 0l-5.2-5.2a2 2 0 0 1 0-2.8L14 4" }], "history": [{ "tag": "path", "d": "M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8" }, { "tag": "path", "d": "M3 3v5h5" }, { "tag": "path", "d": "M12 7v5l4 2" }], "image": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2", "ry": "2" }, { "tag": "circle", "cx": "9", "cy": "9", "r": "2" }, { "tag": "path", "d": "m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21" }], "info": [{ "tag": "circle", "cx": "12", "cy": "12", "r": "10" }, { "tag": "path", "d": "M12 16v-4" }, { "tag": "path", "d": "M12 8h.01" }], "italic": [{ "tag": "line", "x1": "19", "x2": "10", "y1": "4", "y2": "4" }, { "tag": "line", "x1": "14", "x2": "5", "y1": "20", "y2": "20" }, { "tag": "line", "x1": "15", "x2": "9", "y1": "4", "y2": "20" }], "layout-dashboard": [{ "tag": "rect", "width": "7", "height": "9", "x": "3", "y": "3", "rx": "1" }, { "tag": "rect", "width": "7", "height": "5", "x": "14", "y": "3", "rx": "1" }, { "tag": "rect", "width": "7", "height": "9", "x": "14", "y": "12", "rx": "1" }, { "tag": "rect", "width": "7", "height": "5", "x": "3", "y": "16", "rx": "1" }], "lightbulb": [{ "tag": "path", "d": "M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5" }, { "tag": "path", "d": "M9 18h6" }, { "tag": "path", "d": "M10 22h4" }], "link": [{ "tag": "path", "d": "M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71" }, { "tag": "path", "d": "M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71" }], "list": [{ "tag": "path", "d": "M3 5h.01" }, { "tag": "path", "d": "M3 12h.01" }, { "tag": "path", "d": "M3 19h.01" }, { "tag": "path", "d": "M8 5h13" }, { "tag": "path", "d": "M8 12h13" }, { "tag": "path", "d": "M8 19h13" }], "list-ordered": [{ "tag": "path", "d": "M11 5h10" }, { "tag": "path", "d": "M11 12h10" }, { "tag": "path", "d": "M11 19h10" }, { "tag": "path", "d": "M4 4h1v5" }, { "tag": "path", "d": "M4 9h2" }, { "tag": "path", "d": "M6.5 20H3.4c0-1 2.6-1.925 2.6-3.5a1.5 1.5 0 0 0-2.6-1.02" }], "list-todo": [{ "tag": "path", "d": "M13 5h8" }, { "tag": "path", "d": "M13 12h8" }, { "tag": "path", "d": "M13 19h8" }, { "tag": "path", "d": "m3 17 2 2 4-4" }, { "tag": "rect", "x": "3", "y": "4", "width": "6", "height": "6", "rx": "1" }], "loader": [{ "tag": "path", "d": "M21 12a9 9 0 1 1-6.219-8.56" }], "merge": [{ "tag": "path", "d": "m8 6 4-4 4 4" }, { "tag": "path", "d": "M12 2v10.3a4 4 0 0 1-1.172 2.872L4 22" }, { "tag": "path", "d": "m20 22-5-5" }], "message-square-warning": [{ "tag": "path", "d": "M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z" }, { "tag": "path", "d": "M12 15h.01" }, { "tag": "path", "d": "M12 7v4" }], "minus": [{ "tag": "path", "d": "M5 12h14" }], "notebook-pen": [{ "tag": "path", "d": "M13.4 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-7.4" }, { "tag": "path", "d": "M2 6h4" }, { "tag": "path", "d": "M2 10h4" }, { "tag": "path", "d": "M2 14h4" }, { "tag": "path", "d": "M2 18h4" }, { "tag": "path", "d": "M21.378 5.626a1 1 0 1 0-3.004-3.004l-5.01 5.012a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506z" }], "paint-bucket": [{ "tag": "path", "d": "m19 11-8-8-8.6 8.6a2 2 0 0 0 0 2.8l5.2 5.2c.8.8 2 .8 2.8 0L19 11Z" }, { "tag": "path", "d": "m5 2 5 5" }, { "tag": "path", "d": "M2 13h15" }, { "tag": "path", "d": "M22 20a2 2 0 1 1-4 0c0-1.6 1.7-2.4 2-4 .3 1.6 2 2.4 2 4Z" }], "panel-bottom": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2" }, { "tag": "path", "d": "M3 15h18" }], "panel-left": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2" }, { "tag": "path", "d": "M9 3v18" }], "panel-right": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2" }, { "tag": "path", "d": "M15 3v18" }], "panel-top": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2" }, { "tag": "path", "d": "M3 9h18" }], "paperclip": [{ "tag": "path", "d": "m16 6-8.414 8.586a2 2 0 0 0 2.829 2.829l8.414-8.586a4 4 0 1 0-5.657-5.657l-8.379 8.551a6 6 0 1 0 8.485 8.485l8.379-8.551" }], "pencil": [{ "tag": "path", "d": "M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z" }, { "tag": "path", "d": "m15 5 4 4" }], "pilcrow": [{ "tag": "path", "d": "M13 4v16" }, { "tag": "path", "d": "M17 4v16" }, { "tag": "path", "d": "M19 4H9.5a4.5 4.5 0 0 0 0 9H13" }], "plus": [{ "tag": "path", "d": "M5 12h14" }, { "tag": "path", "d": "M12 5v14" }], "quote": [{ "tag": "path", "d": "M16 3a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2 1 1 0 0 1 1 1v1a2 2 0 0 1-2 2 1 1 0 0 0-1 1v2a1 1 0 0 0 1 1 6 6 0 0 0 6-6V5a2 2 0 0 0-2-2z" }, { "tag": "path", "d": "M5 3a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2 1 1 0 0 1 1 1v1a2 2 0 0 1-2 2 1 1 0 0 0-1 1v2a1 1 0 0 0 1 1 6 6 0 0 0 6-6V5a2 2 0 0 0-2-2z" }], "receipt": [{ "tag": "path", "d": "M4 2v20l2-1 2 1 2-1 2 1 2-1 2 1 2-1 2 1V2l-2 1-2-1-2 1-2-1-2 1-2-1-2 1Z" }, { "tag": "path", "d": "M16 8h-6a2 2 0 1 0 0 4h4a2 2 0 1 1 0 4H8" }, { "tag": "path", "d": "M12 17.5v-11" }], "redo": [{ "tag": "path", "d": "m15 14 5-5-5-5" }, { "tag": "path", "d": "M20 9H9.5A5.5 5.5 0 0 0 4 14.5A5.5 5.5 0 0 0 9.5 20H13" }], "rows": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2" }, { "tag": "path", "d": "M21 9H3" }, { "tag": "path", "d": "M21 15H3" }], "search": [{ "tag": "path", "d": "m21 21-4.34-4.34" }, { "tag": "circle", "cx": "11", "cy": "11", "r": "8" }], "settings": [{ "tag": "path", "d": "M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915" }, { "tag": "circle", "cx": "12", "cy": "12", "r": "3" }], "split": [{ "tag": "path", "d": "M16 3h5v5" }, { "tag": "path", "d": "M8 3H3v5" }, { "tag": "path", "d": "M12 22v-8.3a4 4 0 0 0-1.172-2.872L3 3" }, { "tag": "path", "d": "m15 9 6-6" }], "strikethrough": [{ "tag": "path", "d": "M16 4H9a3 3 0 0 0-2.83 4" }, { "tag": "path", "d": "M14 12a4 4 0 0 1 0 8H6" }, { "tag": "line", "x1": "4", "x2": "20", "y1": "12", "y2": "12" }], "superscript": [{ "tag": "path", "d": "m4 19 8-8" }, { "tag": "path", "d": "m12 19-8-8" }, { "tag": "path", "d": "M20 12h-4c0-1.5.442-2 1.5-2.5S20 8.334 20 7.002c0-.472-.17-.93-.484-1.29a2.105 2.105 0 0 0-2.617-.436c-.42.239-.738.614-.899 1.06" }], "table": [{ "tag": "path", "d": "M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v18m0 0h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9m0 0h18" }], "tag": [{ "tag": "path", "d": "M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z" }, { "tag": "circle", "cx": "7.5", "cy": "7.5", "r": ".5", "fill": "currentColor" }], "trash": [{ "tag": "path", "d": "M10 11v6" }, { "tag": "path", "d": "M14 11v6" }, { "tag": "path", "d": "M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6" }, { "tag": "path", "d": "M3 6h18" }, { "tag": "path", "d": "M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2" }], "triangle-alert": [{ "tag": "path", "d": "m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3" }, { "tag": "path", "d": "M12 9v4" }, { "tag": "path", "d": "M12 17h.01" }], "truck": [{ "tag": "path", "d": "M14 18V6a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v11a1 1 0 0 0 1 1h2" }, { "tag": "path", "d": "M15 18H9" }, { "tag": "path", "d": "M19 18h2a1 1 0 0 0 1-1v-3.65a1 1 0 0 0-.22-.624l-3.48-4.35A1 1 0 0 0 17.52 8H14" }, { "tag": "circle", "cx": "17", "cy": "18", "r": "2" }, { "tag": "circle", "cx": "7", "cy": "18", "r": "2" }], "underline": [{ "tag": "path", "d": "M6 4v6a6 6 0 0 0 12 0V4" }, { "tag": "line", "x1": "4", "x2": "20", "y1": "20", "y2": "20" }], "undo": [{ "tag": "path", "d": "M9 14 4 9l5-5" }, { "tag": "path", "d": "M4 9h10.5a5.5 5.5 0 0 1 5.5 5.5a5.5 5.5 0 0 1-5.5 5.5H11" }], "unlink": [{ "tag": "path", "d": "m18.84 12.25 1.72-1.71h-.02a5.004 5.004 0 0 0-.12-7.07 5.006 5.006 0 0 0-6.95 0l-1.72 1.71" }, { "tag": "path", "d": "m5.17 11.75-1.71 1.71a5.004 5.004 0 0 0 .12 7.07 5.006 5.006 0 0 0 6.95 0l1.71-1.71" }, { "tag": "line", "x1": "8", "x2": "8", "y1": "2", "y2": "5" }, { "tag": "line", "x1": "2", "x2": "5", "y1": "8", "y2": "8" }, { "tag": "line", "x1": "16", "x2": "16", "y1": "19", "y2": "22" }, { "tag": "line", "x1": "19", "x2": "22", "y1": "16", "y2": "16" }], "user-round": [{ "tag": "circle", "cx": "12", "cy": "8", "r": "5" }, { "tag": "path", "d": "M20 21a8 8 0 0 0-16 0" }], "users": [{ "tag": "path", "d": "M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2" }, { "tag": "path", "d": "M16 3.128a4 4 0 0 1 0 7.744" }, { "tag": "path", "d": "M22 21v-2a4 4 0 0 0-3-3.87" }, { "tag": "circle", "cx": "9", "cy": "7", "r": "4" }], "x": [{ "tag": "path", "d": "M18 6 6 18" }, { "tag": "path", "d": "m6 6 12 12" }] }, inputRead(v[1], inputStatus(1)))];
|
|
32
|
+
const K = [() => readIndex({ "align-center": [{ "tag": "path", "d": "M21 5H3" }, { "tag": "path", "d": "M17 12H7" }, { "tag": "path", "d": "M19 19H5" }], "align-left": [{ "tag": "path", "d": "M21 5H3" }, { "tag": "path", "d": "M15 12H3" }, { "tag": "path", "d": "M17 19H3" }], "align-right": [{ "tag": "path", "d": "M21 5H3" }, { "tag": "path", "d": "M21 12H9" }, { "tag": "path", "d": "M21 19H7" }], "arrow-left": [{ "tag": "path", "d": "m12 19-7-7 7-7" }, { "tag": "path", "d": "M19 12H5" }], "bell": [{ "tag": "path", "d": "M10.268 21a2 2 0 0 0 3.464 0" }, { "tag": "path", "d": "M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326" }], "bold": [{ "tag": "path", "d": "M6 12h9a4 4 0 0 1 0 8H7a1 1 0 0 1-1-1V5a1 1 0 0 1 1-1h7a4 4 0 0 1 0 8" }], "book-user": [{ "tag": "path", "d": "M15 13a3 3 0 1 0-6 0" }, { "tag": "path", "d": "M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20" }, { "tag": "circle", "cx": "12", "cy": "8", "r": "2" }], "braces": [{ "tag": "path", "d": "M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5c0 1.1.9 2 2 2h1" }, { "tag": "path", "d": "M16 21h1a2 2 0 0 0 2-2v-5c0-1.1.9-2 2-2a2 2 0 0 1-2-2V5a2 2 0 0 0-2-2h-1" }], "calculator": [{ "tag": "rect", "width": "16", "height": "20", "x": "4", "y": "2", "rx": "2" }, { "tag": "line", "x1": "8", "x2": "16", "y1": "6", "y2": "6" }, { "tag": "line", "x1": "16", "x2": "16", "y1": "14", "y2": "18" }, { "tag": "path", "d": "M16 10h.01" }, { "tag": "path", "d": "M12 10h.01" }, { "tag": "path", "d": "M8 10h.01" }, { "tag": "path", "d": "M12 14h.01" }, { "tag": "path", "d": "M8 14h.01" }, { "tag": "path", "d": "M12 18h.01" }, { "tag": "path", "d": "M8 18h.01" }], "check": [{ "tag": "path", "d": "M20 6 9 17l-5-5" }], "chevron-down": [{ "tag": "path", "d": "m6 9 6 6 6-6" }], "chevron-left": [{ "tag": "path", "d": "m15 18-6-6 6-6" }], "chevron-right": [{ "tag": "path", "d": "m9 18 6-6-6-6" }], "circle-check": [{ "tag": "circle", "cx": "12", "cy": "12", "r": "10" }, { "tag": "path", "d": "m9 12 2 2 4-4" }], "circle-dot": [{ "tag": "circle", "cx": "12", "cy": "12", "r": "10" }, { "tag": "circle", "cx": "12", "cy": "12", "r": "1" }], "circle-x": [{ "tag": "circle", "cx": "12", "cy": "12", "r": "10" }, { "tag": "path", "d": "m15 9-6 6" }, { "tag": "path", "d": "m9 9 6 6" }], "code-xml": [{ "tag": "path", "d": "m18 16 4-4-4-4" }, { "tag": "path", "d": "m6 8-4 4 4 4" }, { "tag": "path", "d": "m14.5 4-5 16" }], "columns": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2" }, { "tag": "path", "d": "M9 3v18" }, { "tag": "path", "d": "M15 3v18" }], "compass": [{ "tag": "path", "d": "m16.24 7.76-1.804 5.411a2 2 0 0 1-1.265 1.265L7.76 16.24l1.804-5.411a2 2 0 0 1 1.265-1.265z" }, { "tag": "circle", "cx": "12", "cy": "12", "r": "10" }], "credit-card": [{ "tag": "rect", "width": "20", "height": "14", "x": "2", "y": "5", "rx": "2" }, { "tag": "line", "x1": "2", "x2": "22", "y1": "10", "y2": "10" }], "ellipsis": [{ "tag": "circle", "cx": "12", "cy": "12", "r": "1" }, { "tag": "circle", "cx": "19", "cy": "12", "r": "1" }, { "tag": "circle", "cx": "5", "cy": "12", "r": "1" }], "eraser": [{ "tag": "path", "d": "M21 21H8a2 2 0 0 1-1.42-.587l-3.994-3.999a2 2 0 0 1 0-2.828l10-10a2 2 0 0 1 2.829 0l5.999 6a2 2 0 0 1 0 2.828L12.834 21" }, { "tag": "path", "d": "m5.082 11.09 8.828 8.828" }], "external-link": [{ "tag": "path", "d": "M15 3h6v6" }, { "tag": "path", "d": "M10 14 21 3" }, { "tag": "path", "d": "M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6" }], "file-text": [{ "tag": "path", "d": "M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z" }, { "tag": "path", "d": "M14 2v5a1 1 0 0 0 1 1h5" }, { "tag": "path", "d": "M10 9H8" }, { "tag": "path", "d": "M16 13H8" }, { "tag": "path", "d": "M16 17H8" }], "folder": [{ "tag": "path", "d": "M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z" }], "grip-horizontal": [{ "tag": "circle", "cx": "12", "cy": "9", "r": "1" }, { "tag": "circle", "cx": "19", "cy": "9", "r": "1" }, { "tag": "circle", "cx": "5", "cy": "9", "r": "1" }, { "tag": "circle", "cx": "12", "cy": "15", "r": "1" }, { "tag": "circle", "cx": "19", "cy": "15", "r": "1" }, { "tag": "circle", "cx": "5", "cy": "15", "r": "1" }], "grip-vertical": [{ "tag": "circle", "cx": "9", "cy": "12", "r": "1" }, { "tag": "circle", "cx": "9", "cy": "5", "r": "1" }, { "tag": "circle", "cx": "9", "cy": "19", "r": "1" }, { "tag": "circle", "cx": "15", "cy": "12", "r": "1" }, { "tag": "circle", "cx": "15", "cy": "5", "r": "1" }, { "tag": "circle", "cx": "15", "cy": "19", "r": "1" }], "heading-1": [{ "tag": "path", "d": "M4 12h8" }, { "tag": "path", "d": "M4 18V6" }, { "tag": "path", "d": "M12 18V6" }, { "tag": "path", "d": "m17 12 3-2v8" }], "heading-2": [{ "tag": "path", "d": "M4 12h8" }, { "tag": "path", "d": "M4 18V6" }, { "tag": "path", "d": "M12 18V6" }, { "tag": "path", "d": "M21 18h-4c0-4 4-3 4-6 0-1.5-2-2.5-4-1" }], "heading-3": [{ "tag": "path", "d": "M4 12h8" }, { "tag": "path", "d": "M4 18V6" }, { "tag": "path", "d": "M12 18V6" }, { "tag": "path", "d": "M17.5 10.5c1.7-1 3.5 0 3.5 1.5a2 2 0 0 1-2 2" }, { "tag": "path", "d": "M17 17.5c2 1.5 4 .3 4-1.5a2 2 0 0 0-2-2" }], "help": [{ "tag": "circle", "cx": "12", "cy": "12", "r": "10" }, { "tag": "path", "d": "M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3" }, { "tag": "path", "d": "M12 17h.01" }], "highlighter": [{ "tag": "path", "d": "m9 11-6 6v3h9l3-3" }, { "tag": "path", "d": "m22 12-4.6 4.6a2 2 0 0 1-2.8 0l-5.2-5.2a2 2 0 0 1 0-2.8L14 4" }], "history": [{ "tag": "path", "d": "M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8" }, { "tag": "path", "d": "M3 3v5h5" }, { "tag": "path", "d": "M12 7v5l4 2" }], "image": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2", "ry": "2" }, { "tag": "circle", "cx": "9", "cy": "9", "r": "2" }, { "tag": "path", "d": "m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21" }], "info": [{ "tag": "circle", "cx": "12", "cy": "12", "r": "10" }, { "tag": "path", "d": "M12 16v-4" }, { "tag": "path", "d": "M12 8h.01" }], "italic": [{ "tag": "line", "x1": "19", "x2": "10", "y1": "4", "y2": "4" }, { "tag": "line", "x1": "14", "x2": "5", "y1": "20", "y2": "20" }, { "tag": "line", "x1": "15", "x2": "9", "y1": "4", "y2": "20" }], "layout-dashboard": [{ "tag": "rect", "width": "7", "height": "9", "x": "3", "y": "3", "rx": "1" }, { "tag": "rect", "width": "7", "height": "5", "x": "14", "y": "3", "rx": "1" }, { "tag": "rect", "width": "7", "height": "9", "x": "14", "y": "12", "rx": "1" }, { "tag": "rect", "width": "7", "height": "5", "x": "3", "y": "16", "rx": "1" }], "lightbulb": [{ "tag": "path", "d": "M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5" }, { "tag": "path", "d": "M9 18h6" }, { "tag": "path", "d": "M10 22h4" }], "link": [{ "tag": "path", "d": "M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71" }, { "tag": "path", "d": "M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71" }], "list": [{ "tag": "path", "d": "M3 5h.01" }, { "tag": "path", "d": "M3 12h.01" }, { "tag": "path", "d": "M3 19h.01" }, { "tag": "path", "d": "M8 5h13" }, { "tag": "path", "d": "M8 12h13" }, { "tag": "path", "d": "M8 19h13" }], "list-ordered": [{ "tag": "path", "d": "M11 5h10" }, { "tag": "path", "d": "M11 12h10" }, { "tag": "path", "d": "M11 19h10" }, { "tag": "path", "d": "M4 4h1v5" }, { "tag": "path", "d": "M4 9h2" }, { "tag": "path", "d": "M6.5 20H3.4c0-1 2.6-1.925 2.6-3.5a1.5 1.5 0 0 0-2.6-1.02" }], "list-todo": [{ "tag": "path", "d": "M13 5h8" }, { "tag": "path", "d": "M13 12h8" }, { "tag": "path", "d": "M13 19h8" }, { "tag": "path", "d": "m3 17 2 2 4-4" }, { "tag": "rect", "x": "3", "y": "4", "width": "6", "height": "6", "rx": "1" }], "loader": [{ "tag": "path", "d": "M21 12a9 9 0 1 1-6.219-8.56" }], "merge": [{ "tag": "path", "d": "m8 6 4-4 4 4" }, { "tag": "path", "d": "M12 2v10.3a4 4 0 0 1-1.172 2.872L4 22" }, { "tag": "path", "d": "m20 22-5-5" }], "message-square-warning": [{ "tag": "path", "d": "M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z" }, { "tag": "path", "d": "M12 15h.01" }, { "tag": "path", "d": "M12 7v4" }], "minus": [{ "tag": "path", "d": "M5 12h14" }], "monitor": [{ "tag": "rect", "width": "20", "height": "14", "x": "2", "y": "3", "rx": "2" }, { "tag": "line", "x1": "8", "x2": "16", "y1": "21", "y2": "21" }, { "tag": "line", "x1": "12", "x2": "12", "y1": "17", "y2": "21" }], "moon": [{ "tag": "path", "d": "M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401" }], "notebook-pen": [{ "tag": "path", "d": "M13.4 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-7.4" }, { "tag": "path", "d": "M2 6h4" }, { "tag": "path", "d": "M2 10h4" }, { "tag": "path", "d": "M2 14h4" }, { "tag": "path", "d": "M2 18h4" }, { "tag": "path", "d": "M21.378 5.626a1 1 0 1 0-3.004-3.004l-5.01 5.012a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506z" }], "paint-bucket": [{ "tag": "path", "d": "m19 11-8-8-8.6 8.6a2 2 0 0 0 0 2.8l5.2 5.2c.8.8 2 .8 2.8 0L19 11Z" }, { "tag": "path", "d": "m5 2 5 5" }, { "tag": "path", "d": "M2 13h15" }, { "tag": "path", "d": "M22 20a2 2 0 1 1-4 0c0-1.6 1.7-2.4 2-4 .3 1.6 2 2.4 2 4Z" }], "panel-bottom": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2" }, { "tag": "path", "d": "M3 15h18" }], "panel-left": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2" }, { "tag": "path", "d": "M9 3v18" }], "panel-right": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2" }, { "tag": "path", "d": "M15 3v18" }], "panel-top": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2" }, { "tag": "path", "d": "M3 9h18" }], "paperclip": [{ "tag": "path", "d": "m16 6-8.414 8.586a2 2 0 0 0 2.829 2.829l8.414-8.586a4 4 0 1 0-5.657-5.657l-8.379 8.551a6 6 0 1 0 8.485 8.485l8.379-8.551" }], "pencil": [{ "tag": "path", "d": "M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z" }, { "tag": "path", "d": "m15 5 4 4" }], "pilcrow": [{ "tag": "path", "d": "M13 4v16" }, { "tag": "path", "d": "M17 4v16" }, { "tag": "path", "d": "M19 4H9.5a4.5 4.5 0 0 0 0 9H13" }], "plus": [{ "tag": "path", "d": "M5 12h14" }, { "tag": "path", "d": "M12 5v14" }], "quote": [{ "tag": "path", "d": "M16 3a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2 1 1 0 0 1 1 1v1a2 2 0 0 1-2 2 1 1 0 0 0-1 1v2a1 1 0 0 0 1 1 6 6 0 0 0 6-6V5a2 2 0 0 0-2-2z" }, { "tag": "path", "d": "M5 3a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2 1 1 0 0 1 1 1v1a2 2 0 0 1-2 2 1 1 0 0 0-1 1v2a1 1 0 0 0 1 1 6 6 0 0 0 6-6V5a2 2 0 0 0-2-2z" }], "receipt": [{ "tag": "path", "d": "M4 2v20l2-1 2 1 2-1 2 1 2-1 2 1 2-1 2 1V2l-2 1-2-1-2 1-2-1-2 1-2-1-2 1Z" }, { "tag": "path", "d": "M16 8h-6a2 2 0 1 0 0 4h4a2 2 0 1 1 0 4H8" }, { "tag": "path", "d": "M12 17.5v-11" }], "redo": [{ "tag": "path", "d": "m15 14 5-5-5-5" }, { "tag": "path", "d": "M20 9H9.5A5.5 5.5 0 0 0 4 14.5A5.5 5.5 0 0 0 9.5 20H13" }], "rows": [{ "tag": "rect", "width": "18", "height": "18", "x": "3", "y": "3", "rx": "2" }, { "tag": "path", "d": "M21 9H3" }, { "tag": "path", "d": "M21 15H3" }], "search": [{ "tag": "path", "d": "m21 21-4.34-4.34" }, { "tag": "circle", "cx": "11", "cy": "11", "r": "8" }], "settings": [{ "tag": "path", "d": "M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915" }, { "tag": "circle", "cx": "12", "cy": "12", "r": "3" }], "split": [{ "tag": "path", "d": "M16 3h5v5" }, { "tag": "path", "d": "M8 3H3v5" }, { "tag": "path", "d": "M12 22v-8.3a4 4 0 0 0-1.172-2.872L3 3" }, { "tag": "path", "d": "m15 9 6-6" }], "strikethrough": [{ "tag": "path", "d": "M16 4H9a3 3 0 0 0-2.83 4" }, { "tag": "path", "d": "M14 12a4 4 0 0 1 0 8H6" }, { "tag": "line", "x1": "4", "x2": "20", "y1": "12", "y2": "12" }], "sun": [{ "tag": "circle", "cx": "12", "cy": "12", "r": "4" }, { "tag": "path", "d": "M12 2v2" }, { "tag": "path", "d": "M12 20v2" }, { "tag": "path", "d": "m4.93 4.93 1.41 1.41" }, { "tag": "path", "d": "m17.66 17.66 1.41 1.41" }, { "tag": "path", "d": "M2 12h2" }, { "tag": "path", "d": "M20 12h2" }, { "tag": "path", "d": "m6.34 17.66-1.41 1.41" }, { "tag": "path", "d": "m19.07 4.93-1.41 1.41" }], "superscript": [{ "tag": "path", "d": "m4 19 8-8" }, { "tag": "path", "d": "m12 19-8-8" }, { "tag": "path", "d": "M20 12h-4c0-1.5.442-2 1.5-2.5S20 8.334 20 7.002c0-.472-.17-.93-.484-1.29a2.105 2.105 0 0 0-2.617-.436c-.42.239-.738.614-.899 1.06" }], "table": [{ "tag": "path", "d": "M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v18m0 0h10a2 2 0 0 0 2-2V9M9 21H5a2 2 0 0 1-2-2V9m0 0h18" }], "tag": [{ "tag": "path", "d": "M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z" }, { "tag": "circle", "cx": "7.5", "cy": "7.5", "r": ".5", "fill": "currentColor" }], "trash": [{ "tag": "path", "d": "M10 11v6" }, { "tag": "path", "d": "M14 11v6" }, { "tag": "path", "d": "M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6" }, { "tag": "path", "d": "M3 6h18" }, { "tag": "path", "d": "M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2" }], "triangle-alert": [{ "tag": "path", "d": "m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3" }, { "tag": "path", "d": "M12 9v4" }, { "tag": "path", "d": "M12 17h.01" }], "truck": [{ "tag": "path", "d": "M14 18V6a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v11a1 1 0 0 0 1 1h2" }, { "tag": "path", "d": "M15 18H9" }, { "tag": "path", "d": "M19 18h2a1 1 0 0 0 1-1v-3.65a1 1 0 0 0-.22-.624l-3.48-4.35A1 1 0 0 0 17.52 8H14" }, { "tag": "circle", "cx": "17", "cy": "18", "r": "2" }, { "tag": "circle", "cx": "7", "cy": "18", "r": "2" }], "underline": [{ "tag": "path", "d": "M6 4v6a6 6 0 0 0 12 0V4" }, { "tag": "line", "x1": "4", "x2": "20", "y1": "20", "y2": "20" }], "undo": [{ "tag": "path", "d": "M9 14 4 9l5-5" }, { "tag": "path", "d": "M4 9h10.5a5.5 5.5 0 0 1 5.5 5.5a5.5 5.5 0 0 1-5.5 5.5H11" }], "unlink": [{ "tag": "path", "d": "m18.84 12.25 1.72-1.71h-.02a5.004 5.004 0 0 0-.12-7.07 5.006 5.006 0 0 0-6.95 0l-1.72 1.71" }, { "tag": "path", "d": "m5.17 11.75-1.71 1.71a5.004 5.004 0 0 0 .12 7.07 5.006 5.006 0 0 0 6.95 0l1.71-1.71" }, { "tag": "line", "x1": "8", "x2": "8", "y1": "2", "y2": "5" }, { "tag": "line", "x1": "2", "x2": "5", "y1": "8", "y2": "8" }, { "tag": "line", "x1": "16", "x2": "16", "y1": "19", "y2": "22" }, { "tag": "line", "x1": "19", "x2": "22", "y1": "16", "y2": "16" }], "user-round": [{ "tag": "circle", "cx": "12", "cy": "8", "r": "5" }, { "tag": "path", "d": "M20 21a8 8 0 0 0-16 0" }], "users": [{ "tag": "path", "d": "M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2" }, { "tag": "path", "d": "M16 3.128a4 4 0 0 1 0 7.744" }, { "tag": "path", "d": "M22 21v-2a4 4 0 0 0-3-3.87" }, { "tag": "circle", "cx": "9", "cy": "7", "r": "4" }], "x": [{ "tag": "path", "d": "M18 6 6 18" }, { "tag": "path", "d": "m6 6 12 12" }] }, inputRead(v[1], inputStatus(1)))];
|
|
33
33
|
const g = (j) => {
|
|
34
34
|
const i = j - 0;
|
|
35
35
|
if (ke[i] === X.e) return v[j];
|
package/vanilla/index.js
CHANGED
|
@@ -16,6 +16,7 @@ export * from "./UiContainer.js";
|
|
|
16
16
|
export * from "./UiContextMenu.js";
|
|
17
17
|
export * from "./UiCover.js";
|
|
18
18
|
export * from "./UiCurveEditor.js";
|
|
19
|
+
export * from "./UiCycleButton.js";
|
|
19
20
|
export * from "./UiDescriptionItem.js";
|
|
20
21
|
export * from "./UiDescriptionList.js";
|
|
21
22
|
export * from "./UiDialog.js";
|
package/vue/UiAvatar.vue
CHANGED
|
@@ -366,7 +366,7 @@ useComponentHost(() => import('../components/ui-avatar/ui-avatar.js'), {
|
|
|
366
366
|
inline-size: 1.25rem;
|
|
367
367
|
block-size: 1.25rem;
|
|
368
368
|
/* Below the type scale on purpose: two initials need room inside a 1.25rem circle. */
|
|
369
|
-
font-size: calc(var(--ui-font-size) * 0.5625);
|
|
369
|
+
font-size: calc(var(--ui-font-size-md) * 0.5625);
|
|
370
370
|
letter-spacing: 0.02em;
|
|
371
371
|
}
|
|
372
372
|
|
package/vue/UiAvatarGroup.vue
CHANGED
|
@@ -301,7 +301,7 @@ useComponentHost(() => import('../components/ui-avatar-group/ui-avatar-group.js'
|
|
|
301
301
|
inline-size: 1.25rem;
|
|
302
302
|
block-size: 1.25rem;
|
|
303
303
|
/* Matches the xs Avatar's initials. */
|
|
304
|
-
font-size: calc(var(--ui-font-size) * 0.5625);
|
|
304
|
+
font-size: calc(var(--ui-font-size-md) * 0.5625);
|
|
305
305
|
line-height: 1;
|
|
306
306
|
}
|
|
307
307
|
|
package/vue/UiButton.vue
CHANGED
|
@@ -113,7 +113,7 @@ const propValidityContract = {
|
|
|
113
113
|
required: false,
|
|
114
114
|
target: { attribute: 'size' },
|
|
115
115
|
description:
|
|
116
|
-
'Height, padding, and type size. xs is 1.5rem with the smallest text, for a control inside a line of small text; sm is the small control height (2rem by\n default) with tighter padding and smaller text, md is the standard control height (2.5rem), and lg is taller (3rem) with roomier padding.
|
|
116
|
+
'Height, padding, and type size. xs is 1.5rem with the smallest text, for a control inside a line of small text; sm is the small control height (2rem by\n default) with tighter padding and smaller text, md is the standard control height (2.5rem), and lg is taller (3rem) with roomier padding. Visible sizes\n stay the same on touch. Inline xs and link actions can gain an adjustable invisible hit area.',
|
|
117
117
|
values: ['xs', 'sm', 'md', 'lg'],
|
|
118
118
|
default: 'md',
|
|
119
119
|
},
|
|
@@ -1037,8 +1037,7 @@ useComponentHost(() => import('../components/ui-button/ui-button.js'), {
|
|
|
1037
1037
|
/* The size states outrank :host, so sm is named too, or a small button would stay small. */
|
|
1038
1038
|
|
|
1039
1039
|
/* Under touch, a link-style button's press lands within the control minimum: an invisible hit
|
|
1040
|
-
area, centred on it, like IconButton's. A
|
|
1041
|
-
a link-style one keeps its text size, so a standalone one ("See all" under a list) needs the
|
|
1040
|
+
area, centred on it, like IconButton's. A link-style action keeps its text size, so a standalone one ("See all" under a list) needs the
|
|
1042
1041
|
area. xs sits inside a line of text the same way, so it keeps its size and gains the area too.
|
|
1043
1042
|
Only these need it: a hit area on every button would reach over its neighbours. */
|
|
1044
1043
|
|
|
@@ -1411,14 +1410,6 @@ useComponentHost(() => import('../components/ui-button/ui-button.js'), {
|
|
|
1411
1410
|
background-color: var(--ui-disabled-surface);
|
|
1412
1411
|
border-color: transparent;
|
|
1413
1412
|
}
|
|
1414
|
-
@media (pointer: coarse) {
|
|
1415
|
-
:global(:scope:where([data-hn-ui-button])) {
|
|
1416
|
-
min-block-size: max(var(--ui-control-size-md), var(--ui-control-min-block-size));
|
|
1417
|
-
}
|
|
1418
|
-
:global(:scope[data-ui-button-state~="size=sm"]:where([data-hn-ui-button])) {
|
|
1419
|
-
min-block-size: max(var(--ui-control-size-sm), var(--ui-control-min-block-size));
|
|
1420
|
-
}
|
|
1421
|
-
}
|
|
1422
1413
|
:global(html[data-ui-input-modality="touch"]
|
|
1423
1414
|
:scope[data-appearance="link"]:where([data-hn-ui-button])),
|
|
1424
1415
|
:global(html[data-ui-input-modality="touch"]
|