@threadlabs/looma 0.33.1 → 0.34.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.
Files changed (184) hide show
  1. package/components/shared/overlay.js +8 -2
  2. package/components/shared/surface-material.js +21 -0
  3. package/components/ui-button/ui-button.html +63 -47
  4. package/components/ui-card/ui-card.html +44 -2
  5. package/components/ui-curve-editor/curve.js +10 -0
  6. package/components/ui-curve-editor/ui-curve-editor.html +181 -0
  7. package/components/ui-curve-editor/ui-curve-editor.js +51 -0
  8. package/components/ui-dialog/ui-dialog.html +62 -1
  9. package/components/ui-dialog/ui-dialog.js +9 -1
  10. package/components/ui-icon-button/ui-icon-button.html +75 -23
  11. package/components/ui-menu/ui-menu.html +60 -0
  12. package/components/ui-menu/ui-menu.js +1 -1
  13. package/components/ui-number-input/arithmetic.js +47 -0
  14. package/components/ui-number-input/ui-number-input.html +62 -0
  15. package/components/ui-number-input/ui-number-input.js +44 -0
  16. package/components/ui-popover/ui-popover.html +64 -1
  17. package/components/ui-popover/ui-popover.js +1 -1
  18. package/components/ui-slider/ui-slider.html +84 -0
  19. package/components/ui-slider/ui-slider.js +29 -0
  20. package/components/ui-tabs/ui-tabs.html +6 -1
  21. package/components/ui-text/ui-text.html +31 -6
  22. package/components/ui-tooltip/ui-tooltip.html +60 -0
  23. package/components/ui-tooltip/ui-tooltip.js +1 -1
  24. package/dist/index.js +46 -43
  25. package/docs/README.md +34 -4
  26. package/docs/card.html +16 -2
  27. package/docs/card.js +17 -2
  28. package/docs/catalog.json +1154 -144
  29. package/docs/customizer-render.mjs +35 -9
  30. package/docs/customizer.js +83 -20
  31. package/docs/documentation.css +9 -1
  32. package/docs/index.d.ts +4 -2
  33. package/docs/index.mjs +1 -1
  34. package/docs/preview.js +2 -0
  35. package/docs/render.mjs +15 -6
  36. package/docs/site.mjs +50 -9
  37. package/docs/theme-session.mjs +51 -0
  38. package/docs/theme.mjs +134 -15
  39. package/docs/value-editors.mjs +33 -0
  40. package/package.json +2 -2
  41. package/styles/ui-button.css +45 -45
  42. package/styles/ui-card.css +47 -0
  43. package/styles/ui-curve-editor.css +109 -0
  44. package/styles/ui-dialog.css +132 -0
  45. package/styles/ui-icon-button.css +63 -20
  46. package/styles/ui-menu.css +72 -0
  47. package/styles/ui-number-input.css +34 -0
  48. package/styles/ui-popover.css +74 -0
  49. package/styles/ui-slider.css +53 -0
  50. package/styles/ui-tabs.css +6 -1
  51. package/styles/ui-text.css +23 -1
  52. package/styles/ui-tooltip.css +72 -0
  53. package/theme-system.css +26 -10
  54. package/tokens.css +8 -2
  55. package/vanilla/UiButton.d.ts +1 -0
  56. package/vanilla/UiButton.js +195 -130
  57. package/vanilla/UiCard.d.ts +1 -1
  58. package/vanilla/UiCard.js +1 -1
  59. package/vanilla/UiCurveEditor.d.ts +28 -0
  60. package/vanilla/UiCurveEditor.js +134 -0
  61. package/vanilla/UiIconButton.d.ts +2 -1
  62. package/vanilla/UiIconButton.js +58 -31
  63. package/vanilla/UiNumberInput.d.ts +33 -0
  64. package/vanilla/UiNumberInput.js +79 -0
  65. package/vanilla/UiSlider.d.ts +33 -0
  66. package/vanilla/UiSlider.js +125 -0
  67. package/vanilla/UiText.d.ts +2 -2
  68. package/vanilla/UiText.js +45 -11
  69. package/vanilla/index.js +3 -0
  70. package/vue/UiButton.d.ts +6 -0
  71. package/vue/UiButton.vue +155 -56
  72. package/vue/UiCard.d.ts +2 -2
  73. package/vue/UiCard.vue +55 -5
  74. package/vue/UiCurveEditor.d.ts +53 -0
  75. package/vue/UiCurveEditor.js +2 -0
  76. package/vue/UiCurveEditor.vue +427 -0
  77. package/vue/UiDialog.vue +177 -1
  78. package/vue/UiIconButton.d.ts +8 -2
  79. package/vue/UiIconButton.vue +164 -34
  80. package/vue/UiMenu.vue +89 -0
  81. package/vue/UiNumberInput.d.ts +83 -0
  82. package/vue/UiNumberInput.js +2 -0
  83. package/vue/UiNumberInput.vue +370 -0
  84. package/vue/UiPopover.vue +92 -1
  85. package/vue/UiSlider.d.ts +83 -0
  86. package/vue/UiSlider.js +2 -0
  87. package/vue/UiSlider.vue +412 -0
  88. package/vue/UiTabs.vue +6 -1
  89. package/vue/UiText.d.ts +7 -5
  90. package/vue/UiText.vue +104 -22
  91. package/vue/UiTooltip.vue +89 -0
  92. package/vue/chunks/UiActionBar.js +1 -1
  93. package/vue/chunks/UiAffordanceScope.js +2 -2
  94. package/vue/chunks/UiAvatar.js +2 -2
  95. package/vue/chunks/UiAvatarGroup.js +2 -2
  96. package/vue/chunks/UiBadge.js +2 -2
  97. package/vue/chunks/UiBreadcrumbItem.js +2 -2
  98. package/vue/chunks/UiBreadcrumbs.js +2 -2
  99. package/vue/chunks/UiButton.js +94 -11
  100. package/vue/chunks/UiCallout.js +2 -2
  101. package/vue/chunks/UiCard.js +6 -5
  102. package/vue/chunks/UiCheckbox.js +2 -2
  103. package/vue/chunks/UiCluster.js +2 -2
  104. package/vue/chunks/UiColorPicker.js +2 -2
  105. package/vue/chunks/UiCombobox.js +2 -2
  106. package/vue/chunks/UiContainer.js +2 -2
  107. package/vue/chunks/UiContextMenu.js +2 -2
  108. package/vue/chunks/UiCover.js +2 -2
  109. package/vue/chunks/UiCurveEditor.js +413 -0
  110. package/vue/chunks/UiDescriptionItem.js +2 -2
  111. package/vue/chunks/UiDescriptionList.js +2 -2
  112. package/vue/chunks/UiDialog.js +4 -4
  113. package/vue/chunks/UiDisclosure.js +2 -2
  114. package/vue/chunks/UiEditable.js +2 -2
  115. package/vue/chunks/UiEditorBlockActions.js +2 -2
  116. package/vue/chunks/UiEditorChipEditor.js +2 -2
  117. package/vue/chunks/UiEditorCodeLanguage.js +2 -2
  118. package/vue/chunks/UiEditorFootnoteEditor.js +2 -2
  119. package/vue/chunks/UiEditorImageToolbar.js +3 -3
  120. package/vue/chunks/UiEditorInsertTableGrid.js +2 -2
  121. package/vue/chunks/UiEditorLinkCard.js +3 -3
  122. package/vue/chunks/UiEditorLinkForm.js +3 -3
  123. package/vue/chunks/UiEditorMentionMenu.js +2 -2
  124. package/vue/chunks/UiEditorMentionMenuItem.js +2 -2
  125. package/vue/chunks/UiEditorSlashMenu.js +2 -2
  126. package/vue/chunks/UiEditorSlashMenuGroup.js +2 -2
  127. package/vue/chunks/UiEditorSlashMenuItem.js +2 -2
  128. package/vue/chunks/UiEditorSurface.js +2 -2
  129. package/vue/chunks/UiEditorTableContextMenu.js +2 -2
  130. package/vue/chunks/UiEditorTableOverlay.js +2 -2
  131. package/vue/chunks/UiEditorTableToolbar.js +2 -2
  132. package/vue/chunks/UiEditorToolbar.js +2 -2
  133. package/vue/chunks/UiFloatingActionButton.js +2 -2
  134. package/vue/chunks/UiFormField.js +2 -2
  135. package/vue/chunks/UiGrid.js +2 -2
  136. package/vue/chunks/UiIcon.js +2 -2
  137. package/vue/chunks/UiIconButton.js +77 -11
  138. package/vue/chunks/UiImage.js +2 -2
  139. package/vue/chunks/UiInput.js +2 -2
  140. package/vue/chunks/UiInputGroup.js +2 -2
  141. package/vue/chunks/UiList.js +2 -2
  142. package/vue/chunks/UiListItem.js +2 -2
  143. package/vue/chunks/UiListbox.js +2 -2
  144. package/vue/chunks/UiMenu.js +3 -3
  145. package/vue/chunks/UiMenuGroup.js +2 -2
  146. package/vue/chunks/UiMenuItem.js +2 -2
  147. package/vue/chunks/UiMeter.js +2 -2
  148. package/vue/chunks/UiNavItem.js +2 -2
  149. package/vue/chunks/UiNumberInput.js +390 -0
  150. package/vue/chunks/UiPageHeader.js +2 -2
  151. package/vue/chunks/UiPopover.js +4 -4
  152. package/vue/chunks/UiRadio.js +2 -2
  153. package/vue/chunks/UiRadioGroup.js +2 -2
  154. package/vue/chunks/UiReel.js +2 -2
  155. package/vue/chunks/UiScrollArea.js +2 -2
  156. package/vue/chunks/UiSearchResultRow.js +2 -2
  157. package/vue/chunks/UiSearchShell.js +2 -2
  158. package/vue/chunks/UiSection.js +2 -2
  159. package/vue/chunks/UiSelect.js +2 -2
  160. package/vue/chunks/UiSeparator.js +2 -2
  161. package/vue/chunks/UiSidebar.js +2 -2
  162. package/vue/chunks/UiSlider.js +396 -0
  163. package/vue/chunks/UiSpinner.js +2 -2
  164. package/vue/chunks/UiStack.js +2 -2
  165. package/vue/chunks/UiStatusMessage.js +2 -2
  166. package/vue/chunks/UiSwatch.js +2 -2
  167. package/vue/chunks/UiSwitch.js +2 -2
  168. package/vue/chunks/UiSwitcher.js +2 -2
  169. package/vue/chunks/UiTable.js +2 -2
  170. package/vue/chunks/UiTabs.js +3 -3
  171. package/vue/chunks/UiText.js +53 -12
  172. package/vue/chunks/UiTextarea.js +2 -2
  173. package/vue/chunks/UiToast.js +2 -2
  174. package/vue/chunks/UiToastRegion.js +2 -2
  175. package/vue/chunks/UiTooltip.js +3 -3
  176. package/vue/chunks/UiTopBar.js +1 -1
  177. package/vue/chunks/UiTree.js +2 -2
  178. package/vue/chunks/UiTreeItem.js +2 -2
  179. package/vue/chunks/_plugin-vue_export-helper.js +68 -2
  180. package/vue/chunks/props.js +24 -1
  181. package/vue/components.css +2215 -1203
  182. package/vue/editor/index.js +623 -211
  183. package/vue/index.d.ts +3 -0
  184. package/vue/index.js +5 -2
@@ -0,0 +1,412 @@
1
+ <!-- Generated by HTML Next 1.0.0-alpha.69 for Vue 3.5. Do not edit. -->
2
+ <script setup lang="ts">
3
+ import { computed, getCurrentInstance, provide, ref, useTemplateRef, watchSyncEffect } from 'vue'
4
+ import type { PropType } from 'vue'
5
+ import {
6
+ checkHydratedRoot,
7
+ concat,
8
+ createDispatch,
9
+ initializedState,
10
+ nativeAttrs,
11
+ useComponentHost,
12
+ useReflectedProp,
13
+ warnUnless,
14
+ } from './host'
15
+ import { acceptsControllerWrite } from './props'
16
+ import {
17
+ BINDING_INPUTS_PROP,
18
+ checkedProp,
19
+ checkPropInput,
20
+ copyStateSeed,
21
+ evaluateInput,
22
+ type InputBindings,
23
+ inputDefault,
24
+ inputRead,
25
+ propValidityState,
26
+ READY_INPUT,
27
+ requireInputStatus,
28
+ UNRESOLVED_INPUT,
29
+ vPropValidity,
30
+ vuePropInputs,
31
+ } from './props'
32
+ import UiNumberInput from './UiNumberInput.vue'
33
+
34
+ defineOptions({ inheritAttrs: false })
35
+
36
+ const propValidityContract = {
37
+ props: {
38
+ disabled: {
39
+ type: { kind: 'terminal', name: 'boolean' },
40
+ required: false,
41
+ target: { attribute: 'disabled' },
42
+ description:
43
+ 'Prevents typing, stepping and pointer or keyboard changes while keeping the value visible.',
44
+ default: false,
45
+ },
46
+ label: {
47
+ type: { kind: 'terminal', name: 'string' },
48
+ required: false,
49
+ target: { attribute: 'aria-label' },
50
+ description: 'Accessible name for the editing control.',
51
+ default: 'Value',
52
+ },
53
+ max: {
54
+ type: { kind: 'terminal', name: 'number' },
55
+ required: false,
56
+ target: { attribute: 'max' },
57
+ description: 'Inclusive upper bound for dragging, keyboard steps and exact entry.',
58
+ default: 100,
59
+ },
60
+ min: {
61
+ type: { kind: 'terminal', name: 'number' },
62
+ required: false,
63
+ target: { attribute: 'min' },
64
+ description: 'Inclusive lower bound for dragging, keyboard steps and exact entry.',
65
+ default: 0,
66
+ },
67
+ name: {
68
+ type: { kind: 'terminal', name: 'string' },
69
+ required: false,
70
+ target: { attribute: 'name' },
71
+ description: 'Optional numeric form field name.',
72
+ default: '',
73
+ },
74
+ size: {
75
+ type: { kind: 'terminal', name: 'keyword' },
76
+ required: false,
77
+ target: { attribute: 'size' },
78
+ description: 'Shared field and button height.',
79
+ values: ['sm', 'md', 'lg'],
80
+ default: 'md',
81
+ },
82
+ step: {
83
+ type: { kind: 'terminal', name: 'number' },
84
+ required: false,
85
+ target: { attribute: 'step' },
86
+ description: 'Positive native range and exact entry increment.',
87
+ default: 1,
88
+ },
89
+ unit: {
90
+ type: { kind: 'terminal', name: 'string' },
91
+ required: false,
92
+ target: { attribute: 'unit' },
93
+ description: 'Unit shown by the exact editor.',
94
+ default: '',
95
+ },
96
+ value: {
97
+ type: { kind: 'terminal', name: 'number' },
98
+ required: false,
99
+ target: { attribute: 'value' },
100
+ description: 'Current numeric value. Native range and exact entry share bounds.',
101
+ default: 0,
102
+ },
103
+ },
104
+ } as const
105
+ const props = defineProps({
106
+ disabled: { type: null as unknown as PropType<boolean | null> },
107
+ label: { type: null as unknown as PropType<string | null> },
108
+ max: { type: null as unknown as PropType<number | null> },
109
+ min: { type: null as unknown as PropType<number | null> },
110
+ name: { type: null as unknown as PropType<string | null> },
111
+ size: { type: null as unknown as PropType<'sm' | 'md' | 'lg' | null> },
112
+ step: { type: null as unknown as PropType<number | null> },
113
+ unit: { type: null as unknown as PropType<string | null> },
114
+ value: { type: null as unknown as PropType<number | null> },
115
+ [BINDING_INPUTS_PROP]: { type: null as unknown as PropType<InputBindings> },
116
+ })
117
+ const acceptedProps: Record<string, unknown> = {
118
+ disabled: false,
119
+ label: 'Value',
120
+ max: 100,
121
+ min: 0,
122
+ name: '',
123
+ size: 'md',
124
+ step: 1,
125
+ unit: '',
126
+ value: 0,
127
+ }
128
+ const inputTracking = vuePropInputs(acceptedProps, {
129
+ disabled: false,
130
+ label: 'Value',
131
+ max: 100,
132
+ min: 0,
133
+ name: '',
134
+ size: 'md',
135
+ step: 1,
136
+ unit: '',
137
+ value: 0,
138
+ }, (name, value, source, values) => {
139
+ switch (name) {
140
+ case 'disabled':
141
+ return checkPropInput(value, { kind: 'terminal', name: 'boolean' }, true, true)
142
+ case 'label':
143
+ return checkPropInput(value, { kind: 'terminal', name: 'string' }, true, true)
144
+ case 'max':
145
+ return checkPropInput(value, { kind: 'terminal', name: 'number' }, true, true)
146
+ case 'min':
147
+ return checkPropInput(value, { kind: 'terminal', name: 'number' }, true, true)
148
+ case 'name':
149
+ return checkPropInput(value, { kind: 'terminal', name: 'string' }, true, true)
150
+ case 'size':
151
+ return checkPropInput(value, { kind: 'terminal', name: 'keyword' }, true, true)
152
+ case 'step':
153
+ return checkPropInput(value, { kind: 'terminal', name: 'number' }, true, true)
154
+ case 'unit':
155
+ return checkPropInput(value, { kind: 'terminal', name: 'string' }, true, true)
156
+ case 'value':
157
+ return checkPropInput(value, { kind: 'terminal', name: 'number' }, true, true)
158
+ default:
159
+ return { ok: false }
160
+ }
161
+ }, () => {
162
+ void checkedProps.value
163
+ })
164
+ const propInputs = inputTracking.inputs
165
+ const checkedProps = computed(() => {
166
+ void inputTracking.version.value
167
+ return ({
168
+ disabled: propInputs.value<boolean | null>(
169
+ 'disabled',
170
+ props['disabled'],
171
+ props[BINDING_INPUTS_PROP],
172
+ ) as boolean,
173
+ label: propInputs.value<string | null>(
174
+ 'label',
175
+ props['label'],
176
+ props[BINDING_INPUTS_PROP],
177
+ ) as string,
178
+ max: propInputs.value<number | null>('max', props['max'], props[BINDING_INPUTS_PROP]) as number,
179
+ min: propInputs.value<number | null>('min', props['min'], props[BINDING_INPUTS_PROP]) as number,
180
+ name: propInputs.value<string | null>(
181
+ 'name',
182
+ props['name'],
183
+ props[BINDING_INPUTS_PROP],
184
+ ) as string,
185
+ size: propInputs.value<'sm' | 'md' | 'lg' | null>(
186
+ 'size',
187
+ props['size'],
188
+ props[BINDING_INPUTS_PROP],
189
+ ) as 'sm' | 'md' | 'lg',
190
+ step: propInputs.value<number | null>(
191
+ 'step',
192
+ props['step'],
193
+ props[BINDING_INPUTS_PROP],
194
+ ) as number,
195
+ unit: propInputs.value<string | null>(
196
+ 'unit',
197
+ props['unit'],
198
+ props[BINDING_INPUTS_PROP],
199
+ ) as string,
200
+ value: propInputs.value<number | null>(
201
+ 'value',
202
+ props['value'],
203
+ props[BINDING_INPUTS_PROP],
204
+ ) as number,
205
+ })
206
+ })
207
+ const inputStatus = (name: string, handlesError: boolean) => {
208
+ void checkedProps.value
209
+ void inputTracking.version.value
210
+ return requireInputStatus(propInputs.status(name), handlesError)
211
+ }
212
+ void checkedProps.value
213
+ watchSyncEffect(() => {
214
+ void checkedProps.value
215
+ })
216
+ const reflectedProp = useReflectedProp()
217
+ const hydrationInstance = getCurrentInstance()
218
+ const emit = defineEmits<{
219
+ 'update:value': [value: number]
220
+ input: [event: CustomEvent<{ readonly value: number }>]
221
+ change: [event: CustomEvent<{ readonly value: number }>]
222
+ }>()
223
+
224
+ const root = ref<HTMLElement | null>(null)
225
+ const rangeElement = useTemplateRef<HTMLElement>('rangeElement')
226
+ const current = initializedState<number>(
227
+ () =>
228
+ evaluateInput(() => {
229
+ return inputRead(checkedProps.value.value, propInputs.status('value'))
230
+ }),
231
+ (next: unknown) => (typeof next === 'number' && Number.isFinite(next)),
232
+ copyStateSeed,
233
+ () =>
234
+ warnUnless(false, 'initializer:current', 'State `current` does not satisfy its declared type.'),
235
+ )
236
+ let guardedPrevious: any = null
237
+ const guarded = computed(() => {
238
+ const candidate: any = concat(current.value, checkedProps.value.unit)
239
+ if (candidate === Symbol.for('html-next.invalid-result')) return guardedPrevious
240
+ return guardedPrevious = candidate
241
+ })
242
+ provide('html-next:ui-slider:current', current)
243
+ const declarationStatuses = { current: () => current.status() } as Record<
244
+ string,
245
+ () => typeof READY_INPUT
246
+ >
247
+ const declarationStatus = (name: string) => declarationStatuses[name]!()
248
+ current.start()
249
+ checkHydratedRoot('span', 'ui-slider')
250
+
251
+ /** The values the styles' :host() and :state() rules test. */
252
+ const hostState = computed(() =>
253
+ [
254
+ checkedProps.value.size && 'size',
255
+ checkedProps.value.size != null && `size=${encodeURIComponent(checkedProps.value.size)}`,
256
+ ].filter(Boolean).join(' ')
257
+ )
258
+
259
+ const isInputDetail = (
260
+ detail: unknown,
261
+ ): boolean => (detail !== null && typeof detail === 'object' && !Array.isArray(detail)
262
+ && (typeof (detail as Record<string, unknown>)['value'] === 'number'
263
+ && Number.isFinite((detail as Record<string, unknown>)['value']))
264
+ && Object.keys(detail as object).every((key) => ['value'].includes(key)))
265
+ const dispatch = createDispatch(root, emit as (name: string, detail: unknown) => void, {
266
+ checks: {
267
+ input: isInputDetail,
268
+ change: isInputDetail,
269
+ },
270
+ modeled: ['value'],
271
+ })
272
+
273
+ useComponentHost(() => import('../components/ui-slider/ui-slider.js'), {
274
+ root,
275
+ module: true,
276
+ dispatch,
277
+ acceptsState: (name: string, keys: readonly string[], value: unknown) =>
278
+ acceptsControllerWrite(
279
+ value,
280
+ ({ current: { kind: 'terminal', name: 'number' } } as Record<string, any>)[name],
281
+ keys,
282
+ ),
283
+ controllerSource: {
284
+ specifier: '../components/ui-slider/ui-slider.js',
285
+ definition: './components/ui-slider/ui-slider.html',
286
+ },
287
+ props: checkedProps,
288
+ inputs: propInputs,
289
+ inputTracking,
290
+ propInputs: (name: string) => {
291
+ const incoming = hydrationInstance?.vnode.props
292
+ const kebab = name.replace(/[A-Z]/g, (letter) => '-' + letter.toLowerCase())
293
+ return incoming !== null && incoming !== undefined
294
+ ? (incoming[name] ?? incoming[kebab] ?? null)
295
+ : null
296
+ },
297
+ propNames: ['disabled', 'label', 'max', 'min', 'name', 'size', 'step', 'unit', 'value'],
298
+ propValidity: (name: string) =>
299
+ propValidityState({ contract: propValidityContract, values: { ...props } }, name),
300
+ refs: { range: rangeElement },
301
+ state: { current },
302
+ availability: { current: () => declarationStatus('current') },
303
+ })
304
+ </script>
305
+
306
+ <template>
307
+ <span
308
+ class="ui-slider"
309
+ v-bind="nativeAttrs($attrs)"
310
+ data-hn
311
+ v-prop-validity="{ contract: propValidityContract, values: { ...props } }"
312
+ :data-ui-slider-prop-disabled="reflectedProp('disabled', 'disabled', checkedProps.disabled, undefined, false)"
313
+ :data-ui-slider-prop-label="reflectedProp('label', 'label', checkedProps.label, undefined, false)"
314
+ :data-ui-slider-prop-max="reflectedProp('max', 'max', checkedProps.max, undefined, false)"
315
+ :data-ui-slider-prop-min="reflectedProp('min', 'min', checkedProps.min, undefined, false)"
316
+ :data-ui-slider-prop-name="reflectedProp('name', 'name', checkedProps.name, undefined, false)"
317
+ :data-ui-slider-prop-size="reflectedProp('size', 'size', checkedProps.size, undefined, false)"
318
+ :data-ui-slider-prop-step="reflectedProp('step', 'step', checkedProps.step, undefined, false)"
319
+ :data-ui-slider-prop-unit="reflectedProp('unit', 'unit', checkedProps.unit, undefined, false)"
320
+ :data-ui-slider-prop-value="reflectedProp('value', 'value', checkedProps.value, undefined, false)"
321
+ :data-ui-slider-state="hostState || undefined"
322
+ ref="root"
323
+ ><input
324
+ type="range"
325
+ data-ui-field-control=""
326
+ :aria-label="checkedProps.label ?? undefined"
327
+ :aria-valuetext="guarded"
328
+ :value.attr="checkedProps.value?.toString()"
329
+ :min="checkedProps.min?.toString()"
330
+ :max="checkedProps.max?.toString()"
331
+ :step="checkedProps.step?.toString()"
332
+ :disabled="checkedProps.disabled ?? undefined"
333
+ :name="checkedProps.name ?? undefined"
334
+ ref="rangeElement"
335
+ >{{ ' ' }}<template
336
+ v-for="boundInput in [evaluateInput(
337
+ () =>
338
+ (concat(
339
+ inputRead(current, declarationStatus('current')),
340
+ inputRead(checkedProps.unit, inputStatus('unit', true)),
341
+ )) as any,
342
+ READY_INPUT,
343
+ )]"
344
+ ><UiNumberInput
345
+ class="ui-number-input"
346
+ data-slider-exact=""
347
+ :value="boundInput.value"
348
+ :unit="checkedProps.unit"
349
+ :min="checkedProps.min"
350
+ :max="checkedProps.max"
351
+ :step="checkedProps.step"
352
+ :size="checkedProps.size"
353
+ :disabled="checkedProps.disabled"
354
+ :label="checkedProps.label"
355
+ v-bind="{
356
+ [BINDING_INPUTS_PROP]: {
357
+ value: () => boundInput,
358
+ unit: () => ({ value: checkedProps.unit, status: inputStatus('unit', true) }),
359
+ min: () => ({ value: checkedProps.min, status: inputStatus('min', true) }),
360
+ max: () => ({ value: checkedProps.max, status: inputStatus('max', true) }),
361
+ step: () => ({ value: checkedProps.step, status: inputStatus('step', true) }),
362
+ size: () => ({ value: checkedProps.size, status: inputStatus('size', true) }),
363
+ disabled: () => ({ value: checkedProps.disabled, status: inputStatus('disabled', true) }),
364
+ label: () => ({ value: checkedProps.label, status: inputStatus('label', true) }),
365
+ },
366
+ }"
367
+ /></template></span>
368
+ </template>
369
+
370
+ <style scoped>
371
+ @scope (.ui-slider) to ([data-hn]) {
372
+ :global(:scope) {
373
+ display: grid !important;
374
+ grid-template-columns: minmax(4rem, 1fr) minmax(8rem, 1fr) !important;
375
+ align-items: center !important;
376
+ gap: var(--ui-space-2) !important;
377
+ margin: 0 !important;
378
+ padding: 0 !important;
379
+ min-inline-size: 0;
380
+ }
381
+ :global(input) {
382
+ inline-size: 100%;
383
+ min-inline-size: 0;
384
+ min-block-size: var(--ui-control-size-md);
385
+ margin: 0 !important;
386
+ accent-color: var(--ui-accent-solid);
387
+ cursor: pointer;
388
+ }
389
+ :global(:scope[data-ui-slider-state~="size=sm"] input) {
390
+ min-block-size: var(--ui-control-size-sm);
391
+ }
392
+ :global(:scope[data-ui-slider-state~="size=lg"] input) {
393
+ min-block-size: var(--ui-control-size-lg);
394
+ }
395
+ :global(input:focus-visible) {
396
+ outline: var(--ui-focus-width) solid var(--ui-control-focus, var(--ui-accent-solid));
397
+ outline-offset: var(--ui-space-1);
398
+ border-radius: var(--ui-radius-sm);
399
+ }
400
+ :global(input:disabled) {
401
+ cursor: not-allowed;
402
+ }
403
+ @media (pointer: coarse) {
404
+ :global(input) {
405
+ min-block-size: max(var(--ui-control-size-md), var(--ui-control-min-block-size));
406
+ }
407
+ }
408
+ :global(:scope[hidden]) {
409
+ display: none !important;
410
+ }
411
+ }
412
+ </style>
package/vue/UiTabs.vue CHANGED
@@ -348,6 +348,10 @@ useComponentHost(() => import('../components/ui-tabs/ui-tabs.js'), {
348
348
  syntax: "*";
349
349
  inherits: false;
350
350
  }
351
+ @property --ui-tabs-panel-padding {
352
+ syntax: "*";
353
+ inherits: false;
354
+ }
351
355
 
352
356
  /* Density resolves into the tab row's own values; the public tokens still override them. */
353
357
 
@@ -363,6 +367,7 @@ useComponentHost(() => import('../components/ui-tabs/ui-tabs.js'), {
363
367
  --_ui-tabs-tab-min-block-size: var(--ui-tabs-tab-min-block-size);
364
368
  --_ui-tabs-tab-padding-block: var(--ui-tabs-tab-padding-block);
365
369
  --_ui-tabs-tab-padding-inline: var(--ui-tabs-tab-padding-inline);
370
+ --_ui-tabs-panel-padding: var(--ui-tabs-panel-padding);
366
371
 
367
372
  --_tab-min-block-size: var(--ui-control-size);
368
373
  --_tab-padding-block: var(--ui-space-2);
@@ -460,7 +465,7 @@ useComponentHost(() => import('../components/ui-tabs/ui-tabs.js'), {
460
465
  min-inline-size: 0;
461
466
  }
462
467
  :global(.panels > :where(:not([data-hn-ui-tabs])):is(*)) {
463
- padding: var(--ui-space-4) !important;
468
+ padding: var(--_ui-tabs-panel-padding, var(--ui-space-4)) !important;
464
469
  }
465
470
 
466
471
  :global(:scope[data-ui-tabs-state~="orientation=vertical"]:where([data-hn-ui-tabs])) {
package/vue/UiText.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import type { PropType } from 'vue';
2
2
  import { type InputBindings } from './props.js';
3
- declare var __VLS_1: {}, __VLS_3: {}, __VLS_5: {}, __VLS_7: {}, __VLS_9: {}, __VLS_11: {}, __VLS_13: {}, __VLS_15: {}, __VLS_17: {}, __VLS_19: {}, __VLS_21: {};
3
+ declare var __VLS_1: {}, __VLS_3: {}, __VLS_5: {}, __VLS_7: {}, __VLS_9: {}, __VLS_11: {}, __VLS_13: {}, __VLS_15: {}, __VLS_17: {}, __VLS_19: {}, __VLS_21: {}, __VLS_23: {};
4
4
  type __VLS_Slots = {} & {
5
5
  default?: (props: typeof __VLS_1) => any;
6
6
  } & {
@@ -23,13 +23,15 @@ type __VLS_Slots = {} & {
23
23
  default?: (props: typeof __VLS_19) => any;
24
24
  } & {
25
25
  default?: (props: typeof __VLS_21) => any;
26
+ } & {
27
+ default?: (props: typeof __VLS_23) => any;
26
28
  };
27
29
  declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
28
30
  align: {
29
31
  type: PropType<"start" | "center" | null>;
30
32
  };
31
33
  as: {
32
- type: PropType<"p" | "span" | "div" | "small" | "strong" | "label" | "h2" | "h3" | "h4" | "h5" | "h6" | null>;
34
+ type: PropType<"p" | "span" | "div" | "small" | "strong" | "label" | "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | null>;
33
35
  };
34
36
  font: {
35
37
  type: PropType<"inherit" | "sans" | null>;
@@ -50,7 +52,7 @@ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPro
50
52
  type: PropType<boolean | null>;
51
53
  };
52
54
  variant: {
53
- type: PropType<"body" | "eyebrow" | "code" | null>;
55
+ type: PropType<"body" | "display" | "heading" | "label" | "caption" | "eyebrow" | "code" | null>;
54
56
  };
55
57
  weight: {
56
58
  type: PropType<"inherit" | "normal" | "medium" | "semibold" | null>;
@@ -66,7 +68,7 @@ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPro
66
68
  type: PropType<"start" | "center" | null>;
67
69
  };
68
70
  as: {
69
- type: PropType<"p" | "span" | "div" | "small" | "strong" | "label" | "h2" | "h3" | "h4" | "h5" | "h6" | null>;
71
+ type: PropType<"p" | "span" | "div" | "small" | "strong" | "label" | "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | null>;
70
72
  };
71
73
  font: {
72
74
  type: PropType<"inherit" | "sans" | null>;
@@ -87,7 +89,7 @@ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPro
87
89
  type: PropType<boolean | null>;
88
90
  };
89
91
  variant: {
90
- type: PropType<"body" | "eyebrow" | "code" | null>;
92
+ type: PropType<"body" | "display" | "heading" | "label" | "caption" | "eyebrow" | "code" | null>;
91
93
  };
92
94
  weight: {
93
95
  type: PropType<"inherit" | "normal" | "medium" | "semibold" | null>;