@threadlabs/looma 0.52.11 → 0.53.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 (341) hide show
  1. package/components/shared/overlay.js +7 -0
  2. package/components/ui-editor-toolbar/ui-editor-toolbar.html +2 -2
  3. package/components/ui-meter/ui-meter.html +1 -1
  4. package/dist/index.js +1 -1
  5. package/docs/catalog.json +1 -1
  6. package/editor/components.css +19 -19
  7. package/editor/index.js +1125 -853
  8. package/package.json +3 -3
  9. package/styles/ui-action-bar.css +1 -1
  10. package/styles/ui-affordance-scope.css +1 -1
  11. package/styles/ui-avatar-group.css +1 -1
  12. package/styles/ui-avatar.css +1 -1
  13. package/styles/ui-badge.css +1 -1
  14. package/styles/ui-breadcrumb-item.css +1 -1
  15. package/styles/ui-breadcrumbs.css +1 -1
  16. package/styles/ui-button.css +1 -1
  17. package/styles/ui-calendar.css +1 -1
  18. package/styles/ui-callout.css +1 -1
  19. package/styles/ui-card-group.css +1 -1
  20. package/styles/ui-card.css +1 -1
  21. package/styles/ui-checkbox.css +1 -1
  22. package/styles/ui-cluster.css +1 -1
  23. package/styles/ui-color-picker.css +1 -1
  24. package/styles/ui-column.css +1 -1
  25. package/styles/ui-combobox.css +1 -1
  26. package/styles/ui-compact-content.css +1 -1
  27. package/styles/ui-compact-editor.css +1 -1
  28. package/styles/ui-compact-mark.css +1 -1
  29. package/styles/ui-compact-node.css +1 -1
  30. package/styles/ui-container.css +1 -1
  31. package/styles/ui-context-menu.css +1 -1
  32. package/styles/ui-cover.css +1 -1
  33. package/styles/ui-curve-editor.css +1 -1
  34. package/styles/ui-cycle-button.css +1 -1
  35. package/styles/ui-data-table.css +1 -1
  36. package/styles/ui-date-field.css +1 -1
  37. package/styles/ui-date-picker.css +1 -1
  38. package/styles/ui-date-range-picker.css +1 -1
  39. package/styles/ui-description-item.css +1 -1
  40. package/styles/ui-description-list.css +1 -1
  41. package/styles/ui-dialog.css +1 -1
  42. package/styles/ui-disclosure.css +1 -1
  43. package/styles/ui-editable.css +1 -1
  44. package/styles/ui-editor-block-actions.css +1 -1
  45. package/styles/ui-editor-chip-editor.css +1 -1
  46. package/styles/ui-editor-code-language.css +1 -1
  47. package/styles/ui-editor-footnote-editor.css +1 -1
  48. package/styles/ui-editor-formatting-tools.css +1 -1
  49. package/styles/ui-editor-image-toolbar.css +1 -1
  50. package/styles/ui-editor-insert-table-grid.css +1 -1
  51. package/styles/ui-editor-link-card.css +1 -1
  52. package/styles/ui-editor-link-form.css +1 -1
  53. package/styles/ui-editor-mention-menu-item.css +1 -1
  54. package/styles/ui-editor-mention-menu.css +1 -1
  55. package/styles/ui-editor-slash-menu-group.css +1 -1
  56. package/styles/ui-editor-slash-menu-item.css +1 -1
  57. package/styles/ui-editor-slash-menu.css +1 -1
  58. package/styles/ui-editor-surface.css +1 -1
  59. package/styles/ui-editor-table-context-menu.css +1 -1
  60. package/styles/ui-editor-table-overlay.css +1 -1
  61. package/styles/ui-editor-table-toolbar.css +1 -1
  62. package/styles/ui-editor-toolbar.css +1 -1
  63. package/styles/ui-editor.css +1 -1
  64. package/styles/ui-file-input.css +1 -1
  65. package/styles/ui-floating-action-button.css +1 -1
  66. package/styles/ui-form-field.css +1 -1
  67. package/styles/ui-grid.css +1 -1
  68. package/styles/ui-icon-button.css +1 -1
  69. package/styles/ui-icon.css +1 -1
  70. package/styles/ui-image.css +1 -1
  71. package/styles/ui-input-group.css +1 -1
  72. package/styles/ui-input.css +1 -1
  73. package/styles/ui-light-editor.css +1 -1
  74. package/styles/ui-list-item.css +1 -1
  75. package/styles/ui-list.css +1 -1
  76. package/styles/ui-listbox.css +1 -1
  77. package/styles/ui-menu-group.css +1 -1
  78. package/styles/ui-menu-item.css +1 -1
  79. package/styles/ui-menu.css +1 -1
  80. package/styles/ui-meter.css +1 -1
  81. package/styles/ui-nav-item.css +1 -1
  82. package/styles/ui-notice-stripe.css +1 -1
  83. package/styles/ui-number-input.css +1 -1
  84. package/styles/ui-page-header.css +1 -1
  85. package/styles/ui-pagination.css +1 -1
  86. package/styles/ui-popover.css +1 -1
  87. package/styles/ui-radio-group.css +1 -1
  88. package/styles/ui-radio.css +1 -1
  89. package/styles/ui-reel.css +1 -1
  90. package/styles/ui-scroll-area.css +1 -1
  91. package/styles/ui-search-result-row.css +1 -1
  92. package/styles/ui-search-shell.css +1 -1
  93. package/styles/ui-section.css +1 -1
  94. package/styles/ui-segmented-control.css +1 -1
  95. package/styles/ui-select.css +1 -1
  96. package/styles/ui-separator.css +1 -1
  97. package/styles/ui-sidebar.css +1 -1
  98. package/styles/ui-site-header.css +1 -1
  99. package/styles/ui-skeleton.css +1 -1
  100. package/styles/ui-slider.css +1 -1
  101. package/styles/ui-spinner.css +1 -1
  102. package/styles/ui-stack.css +1 -1
  103. package/styles/ui-status-message.css +1 -1
  104. package/styles/ui-swatch.css +1 -1
  105. package/styles/ui-switch.css +1 -1
  106. package/styles/ui-switcher.css +1 -1
  107. package/styles/ui-table.css +1 -1
  108. package/styles/ui-tabs.css +1 -1
  109. package/styles/ui-text.css +1 -1
  110. package/styles/ui-textarea.css +1 -1
  111. package/styles/ui-time-field.css +1 -1
  112. package/styles/ui-time-picker.css +1 -1
  113. package/styles/ui-toast-region.css +1 -1
  114. package/styles/ui-toast.css +1 -1
  115. package/styles/ui-tooltip.css +1 -1
  116. package/styles/ui-top-bar.css +1 -1
  117. package/styles/ui-tree-item.css +1 -1
  118. package/styles/ui-tree.css +1 -1
  119. package/styles/ui-wizard.css +1 -1
  120. package/vanilla/UiActionBar.d.ts +1 -1
  121. package/vanilla/UiActionBar.js +14 -12
  122. package/vanilla/UiAffordanceScope.d.ts +1 -1
  123. package/vanilla/UiAffordanceScope.js +13 -11
  124. package/vanilla/UiAvatar.d.ts +1 -1
  125. package/vanilla/UiAvatar.js +27 -25
  126. package/vanilla/UiAvatarGroup.d.ts +1 -1
  127. package/vanilla/UiAvatarGroup.js +26 -23
  128. package/vanilla/UiBadge.d.ts +1 -1
  129. package/vanilla/UiBadge.js +14 -12
  130. package/vanilla/UiBreadcrumbItem.d.ts +1 -1
  131. package/vanilla/UiBreadcrumbItem.js +14 -13
  132. package/vanilla/UiBreadcrumbs.d.ts +1 -1
  133. package/vanilla/UiBreadcrumbs.js +10 -10
  134. package/vanilla/UiButton.d.ts +1 -1
  135. package/vanilla/UiButton.js +187 -244
  136. package/vanilla/UiCalendar.d.ts +1 -1
  137. package/vanilla/UiCalendar.js +272 -193
  138. package/vanilla/UiCallout.d.ts +1 -1
  139. package/vanilla/UiCallout.js +32 -27
  140. package/vanilla/UiCard.d.ts +1 -1
  141. package/vanilla/UiCard.js +72 -69
  142. package/vanilla/UiCardGroup.d.ts +1 -1
  143. package/vanilla/UiCardGroup.js +17 -15
  144. package/vanilla/UiCheckbox.d.ts +1 -1
  145. package/vanilla/UiCheckbox.js +32 -30
  146. package/vanilla/UiCluster.d.ts +1 -1
  147. package/vanilla/UiCluster.js +20 -18
  148. package/vanilla/UiColorPicker.d.ts +1 -1
  149. package/vanilla/UiColorPicker.js +22 -20
  150. package/vanilla/UiColumn.d.ts +2 -2
  151. package/vanilla/UiColumn.js +18 -15
  152. package/vanilla/UiCombobox.d.ts +3 -3
  153. package/vanilla/UiCombobox.js +237 -174
  154. package/vanilla/UiCompactContent.d.ts +1 -1
  155. package/vanilla/UiCompactContent.js +13 -8
  156. package/vanilla/UiCompactEditor.d.ts +1 -1
  157. package/vanilla/UiCompactEditor.js +17 -12
  158. package/vanilla/UiCompactMark.d.ts +1 -1
  159. package/vanilla/UiCompactMark.js +47 -45
  160. package/vanilla/UiCompactNode.d.ts +2 -2
  161. package/vanilla/UiCompactNode.js +37 -33
  162. package/vanilla/UiContainer.d.ts +1 -1
  163. package/vanilla/UiContainer.js +13 -11
  164. package/vanilla/UiContextMenu.d.ts +1 -1
  165. package/vanilla/UiContextMenu.js +11 -9
  166. package/vanilla/UiCover.d.ts +1 -1
  167. package/vanilla/UiCover.js +13 -11
  168. package/vanilla/UiCurveEditor.d.ts +1 -1
  169. package/vanilla/UiCurveEditor.js +40 -38
  170. package/vanilla/UiCycleButton.d.ts +2 -2
  171. package/vanilla/UiCycleButton.js +31 -26
  172. package/vanilla/UiDataTable.d.ts +1 -1
  173. package/vanilla/UiDataTable.js +26 -20
  174. package/vanilla/UiDateField.d.ts +1 -1
  175. package/vanilla/UiDateField.js +78 -75
  176. package/vanilla/UiDatePicker.d.ts +1 -1
  177. package/vanilla/UiDatePicker.js +155 -149
  178. package/vanilla/UiDateRangePicker.d.ts +1 -1
  179. package/vanilla/UiDateRangePicker.js +136 -128
  180. package/vanilla/UiDescriptionItem.d.ts +1 -1
  181. package/vanilla/UiDescriptionItem.js +13 -11
  182. package/vanilla/UiDescriptionList.d.ts +1 -1
  183. package/vanilla/UiDescriptionList.js +13 -11
  184. package/vanilla/UiDialog.d.ts +1 -1
  185. package/vanilla/UiDialog.js +14 -14
  186. package/vanilla/UiDisclosure.d.ts +1 -1
  187. package/vanilla/UiDisclosure.js +28 -26
  188. package/vanilla/UiEditable.d.ts +1 -1
  189. package/vanilla/UiEditable.js +29 -27
  190. package/vanilla/UiEditor.d.ts +1 -1
  191. package/vanilla/UiEditor.js +62 -58
  192. package/vanilla/UiEditorBlockActions.d.ts +1 -1
  193. package/vanilla/UiEditorBlockActions.js +14 -12
  194. package/vanilla/UiEditorChipEditor.d.ts +1 -1
  195. package/vanilla/UiEditorChipEditor.js +22 -14
  196. package/vanilla/UiEditorCodeLanguage.d.ts +1 -1
  197. package/vanilla/UiEditorCodeLanguage.js +23 -16
  198. package/vanilla/UiEditorFootnoteEditor.d.ts +1 -1
  199. package/vanilla/UiEditorFootnoteEditor.js +17 -9
  200. package/vanilla/UiEditorFormattingTools.d.ts +1 -1
  201. package/vanilla/UiEditorFormattingTools.js +108 -71
  202. package/vanilla/UiEditorImageToolbar.d.ts +1 -1
  203. package/vanilla/UiEditorImageToolbar.js +68 -66
  204. package/vanilla/UiEditorInsertTableGrid.d.ts +1 -1
  205. package/vanilla/UiEditorInsertTableGrid.js +50 -35
  206. package/vanilla/UiEditorLinkCard.d.ts +1 -1
  207. package/vanilla/UiEditorLinkCard.js +27 -25
  208. package/vanilla/UiEditorLinkForm.d.ts +1 -1
  209. package/vanilla/UiEditorLinkForm.js +79 -57
  210. package/vanilla/UiEditorMentionMenu.d.ts +1 -1
  211. package/vanilla/UiEditorMentionMenu.js +63 -44
  212. package/vanilla/UiEditorMentionMenuItem.d.ts +1 -1
  213. package/vanilla/UiEditorMentionMenuItem.js +22 -16
  214. package/vanilla/UiEditorSlashMenu.d.ts +1 -1
  215. package/vanilla/UiEditorSlashMenu.js +52 -33
  216. package/vanilla/UiEditorSlashMenuGroup.d.ts +1 -1
  217. package/vanilla/UiEditorSlashMenuGroup.js +19 -14
  218. package/vanilla/UiEditorSlashMenuItem.d.ts +1 -1
  219. package/vanilla/UiEditorSlashMenuItem.js +27 -25
  220. package/vanilla/UiEditorSurface.d.ts +1 -1
  221. package/vanilla/UiEditorSurface.js +13 -11
  222. package/vanilla/UiEditorTableContextMenu.d.ts +1 -1
  223. package/vanilla/UiEditorTableContextMenu.js +81 -52
  224. package/vanilla/UiEditorTableOverlay.d.ts +1 -1
  225. package/vanilla/UiEditorTableOverlay.js +107 -68
  226. package/vanilla/UiEditorTableToolbar.d.ts +1 -1
  227. package/vanilla/UiEditorTableToolbar.js +121 -70
  228. package/vanilla/UiEditorToolbar.d.ts +1 -1
  229. package/vanilla/UiEditorToolbar.js +20 -12
  230. package/vanilla/UiFileInput.d.ts +1 -1
  231. package/vanilla/UiFileInput.js +94 -80
  232. package/vanilla/UiFloatingActionButton.d.ts +1 -1
  233. package/vanilla/UiFloatingActionButton.js +21 -20
  234. package/vanilla/UiFormField.d.ts +1 -1
  235. package/vanilla/UiFormField.js +21 -19
  236. package/vanilla/UiGrid.d.ts +1 -1
  237. package/vanilla/UiGrid.js +26 -23
  238. package/vanilla/UiIcon.d.ts +1 -1
  239. package/vanilla/UiIcon.js +20 -15
  240. package/vanilla/UiIconButton.d.ts +1 -1
  241. package/vanilla/UiIconButton.js +35 -43
  242. package/vanilla/UiImage.d.ts +1 -1
  243. package/vanilla/UiImage.js +16 -14
  244. package/vanilla/UiInput.d.ts +1 -1
  245. package/vanilla/UiInput.js +29 -35
  246. package/vanilla/UiInputGroup.d.ts +1 -1
  247. package/vanilla/UiInputGroup.js +16 -14
  248. package/vanilla/UiLightEditor.d.ts +1 -1
  249. package/vanilla/UiLightEditor.js +29 -27
  250. package/vanilla/UiList.d.ts +1 -1
  251. package/vanilla/UiList.js +33 -27
  252. package/vanilla/UiListItem.d.ts +1 -1
  253. package/vanilla/UiListItem.js +12 -12
  254. package/vanilla/UiListbox.d.ts +1 -1
  255. package/vanilla/UiListbox.js +90 -80
  256. package/vanilla/UiMenu.d.ts +1 -1
  257. package/vanilla/UiMenu.js +20 -12
  258. package/vanilla/UiMenuGroup.d.ts +1 -1
  259. package/vanilla/UiMenuGroup.js +14 -11
  260. package/vanilla/UiMenuItem.d.ts +1 -1
  261. package/vanilla/UiMenuItem.js +74 -75
  262. package/vanilla/UiMeter.d.ts +1 -1
  263. package/vanilla/UiMeter.js +67 -62
  264. package/vanilla/UiNavItem.d.ts +1 -1
  265. package/vanilla/UiNavItem.js +63 -65
  266. package/vanilla/UiNoticeStripe.d.ts +1 -1
  267. package/vanilla/UiNoticeStripe.js +16 -16
  268. package/vanilla/UiNumberInput.d.ts +1 -1
  269. package/vanilla/UiNumberInput.js +41 -38
  270. package/vanilla/UiPageHeader.d.ts +1 -1
  271. package/vanilla/UiPageHeader.js +17 -15
  272. package/vanilla/UiPagination.d.ts +1 -1
  273. package/vanilla/UiPagination.js +53 -44
  274. package/vanilla/UiPopover.d.ts +1 -1
  275. package/vanilla/UiPopover.js +13 -11
  276. package/vanilla/UiRadio.d.ts +1 -1
  277. package/vanilla/UiRadio.js +25 -23
  278. package/vanilla/UiRadioGroup.d.ts +1 -1
  279. package/vanilla/UiRadioGroup.js +33 -36
  280. package/vanilla/UiReel.d.ts +1 -1
  281. package/vanilla/UiReel.js +20 -12
  282. package/vanilla/UiScrollArea.d.ts +1 -1
  283. package/vanilla/UiScrollArea.js +13 -11
  284. package/vanilla/UiSearchResultRow.d.ts +1 -1
  285. package/vanilla/UiSearchResultRow.js +21 -20
  286. package/vanilla/UiSearchShell.d.ts +1 -1
  287. package/vanilla/UiSearchShell.js +16 -14
  288. package/vanilla/UiSection.d.ts +1 -1
  289. package/vanilla/UiSection.js +48 -45
  290. package/vanilla/UiSegmentedControl.d.ts +2 -2
  291. package/vanilla/UiSegmentedControl.js +52 -47
  292. package/vanilla/UiSelect.d.ts +1 -1
  293. package/vanilla/UiSelect.js +17 -21
  294. package/vanilla/UiSeparator.d.ts +1 -1
  295. package/vanilla/UiSeparator.js +12 -12
  296. package/vanilla/UiSidebar.d.ts +1 -1
  297. package/vanilla/UiSidebar.js +17 -15
  298. package/vanilla/UiSiteHeader.d.ts +1 -1
  299. package/vanilla/UiSiteHeader.js +25 -23
  300. package/vanilla/UiSkeleton.d.ts +1 -1
  301. package/vanilla/UiSkeleton.js +21 -20
  302. package/vanilla/UiSlider.d.ts +1 -1
  303. package/vanilla/UiSlider.js +50 -47
  304. package/vanilla/UiSpinner.d.ts +1 -1
  305. package/vanilla/UiSpinner.js +34 -27
  306. package/vanilla/UiStack.d.ts +1 -1
  307. package/vanilla/UiStack.js +12 -12
  308. package/vanilla/UiStatusMessage.d.ts +1 -1
  309. package/vanilla/UiStatusMessage.js +22 -21
  310. package/vanilla/UiSwatch.d.ts +1 -1
  311. package/vanilla/UiSwatch.js +20 -17
  312. package/vanilla/UiSwitch.d.ts +1 -1
  313. package/vanilla/UiSwitch.js +25 -23
  314. package/vanilla/UiSwitcher.d.ts +1 -1
  315. package/vanilla/UiSwitcher.js +13 -11
  316. package/vanilla/UiTable.d.ts +1 -1
  317. package/vanilla/UiTable.js +13 -11
  318. package/vanilla/UiTabs.d.ts +1 -1
  319. package/vanilla/UiTabs.js +39 -28
  320. package/vanilla/UiText.d.ts +1 -1
  321. package/vanilla/UiText.js +128 -125
  322. package/vanilla/UiTextarea.d.ts +1 -1
  323. package/vanilla/UiTextarea.js +27 -39
  324. package/vanilla/UiTimeField.d.ts +1 -1
  325. package/vanilla/UiTimeField.js +42 -40
  326. package/vanilla/UiTimePicker.d.ts +1 -1
  327. package/vanilla/UiTimePicker.js +105 -102
  328. package/vanilla/UiToast.d.ts +1 -1
  329. package/vanilla/UiToast.js +14 -14
  330. package/vanilla/UiToastRegion.d.ts +1 -1
  331. package/vanilla/UiToastRegion.js +61 -31
  332. package/vanilla/UiTooltip.d.ts +1 -1
  333. package/vanilla/UiTooltip.js +17 -14
  334. package/vanilla/UiTopBar.d.ts +1 -1
  335. package/vanilla/UiTopBar.js +24 -22
  336. package/vanilla/UiTree.d.ts +1 -1
  337. package/vanilla/UiTree.js +17 -12
  338. package/vanilla/UiTreeItem.d.ts +1 -1
  339. package/vanilla/UiTreeItem.js +73 -79
  340. package/vanilla/UiWizard.d.ts +1 -1
  341. package/vanilla/UiWizard.js +61 -40
@@ -1,5 +1,5 @@
1
- // Generated by HTML Next 1.0.0-alpha.91 for Vanilla DOM. Do not edit.
2
- import { attachGeneratedController, buildTemplate, clearRegion, NONCONFORMING, readIndex, textCall, toAttribute, truthy, writeAttribute, writeUrlAttribute, dispatchDeclared, detailCheck, dispose, formatOf, keywordFormat, hostState, acceptProps, manageProps, generatedInputs, project, fillSlot, armElement, replaceRoot, checkBoolean, checkConstrained, checkFormat, checkObject, checkString, defineComponent, activateModule } from "@nextwebwg/html-next/generated-runtime";
1
+ // Generated by HTML Next 1.0.0-alpha.92 for Vanilla DOM. Do not edit.
2
+ import { attachGeneratedController, equalValue, buildTemplate, clearRegion, NONCONFORMING, readIndex, textCall, toAttribute, truthy, writeAttribute, writeUrlAttribute, dispatchDeclared, detailCheck, dispose, formatOf, keywordFormat, hostState, acceptProps, manageProps, generatedInputs, project, armElement, replaceRoot, checkBoolean, checkConstrained, checkFormat, checkObject, checkString, initializeSlot, sharePlainSlots, forwardAttributes, resetForwardedAttributes, defineComponent, activateModule } from "@nextwebwg/html-next/generated-runtime";
3
3
  import * as controller from "../components/ui-menu-item/ui-menu-item.js";
4
4
  import "../styles/ui-menu-item.css";
5
5
 
@@ -20,27 +20,20 @@ const D = { g: "ui-menu-item", props: { "checked": { "required":false,"default":
20
20
  const C = (host) => activateModule(controller, host);
21
21
 
22
22
  export function createUiMenuItem(options = {}, html) {
23
- const { attributes = {}, children = [], slots = {}, ...componentProps } = options;
23
+ const { attributes: authoredAttributes = {}, children = [], slots = {}, ...componentProps } = options;
24
+ const attributes = Object.fromEntries([...[], ...Object.entries(authoredAttributes)].filter(([name]) => !["checked","disabled","href","tone","type","value"].includes(name)));
24
25
  const v = [false, null, null, null, null, null, null];
25
26
  let B = acceptProps(undefined, D, S.n, v, componentProps, [], html);
26
- let a = ((truthy(v[3]) && (v[5] === "action")) ? 0 : 1);
27
+ let a = ((truthy(v[3]) && truthy(equalValue(v[5], "action"))) ? 0 : 1);
27
28
  let element;
28
29
  if (a === 0) {
29
30
  element = document.createElement("a");
30
- for (const [name, value] of Object.entries(attributes)) {
31
- if (value === null || value === undefined || value === false) continue;
32
- element.setAttribute(name, value === true ? "" : String(value));
33
- }
34
- if (!element.hasAttribute("role")) element.setAttribute("role", "menuitem");
35
- if (!element.hasAttribute("tabindex")) element.setAttribute("tabindex", "-1");
31
+ element.setAttribute("role", "menuitem");
32
+ element.setAttribute("tabindex", "-1");
36
33
  element.setAttribute("component", "ui-menu-item");
37
34
  } else {
38
35
  element = document.createElement("div");
39
- for (const [name, value] of Object.entries(attributes)) {
40
- if (value === null || value === undefined || value === false) continue;
41
- element.setAttribute(name, value === true ? "" : String(value));
42
- }
43
- if (!element.hasAttribute("tabindex")) element.setAttribute("tabindex", "-1");
36
+ element.setAttribute("tabindex", "-1");
44
37
  element.setAttribute("component", "ui-menu-item");
45
38
  }
46
39
  B = acceptProps(element, D, S.n, v, componentProps, Q[a], html);
@@ -107,42 +100,47 @@ export function createUiMenuItem(options = {}, html) {
107
100
  const t2 = t0.nextSibling.nextSibling;
108
101
  const t3 = t2.firstChild;
109
102
  const t4 = t2.nextSibling.nextSibling.firstChild;
110
- const r = { n, v0: undefined, v1: undefined, v2: undefined, v3: undefined, a1: t1, e0: t1.nextSibling, b0: undefined, f0: undefined, a2: t3, e1: t3.nextSibling, b1: undefined, f1: undefined, a3: t4, e2: t4.nextSibling, b2: undefined, f2: undefined };
103
+ const r = { n, v0: undefined, v1: undefined, v2: undefined, v3: undefined, v4: undefined, v5: undefined, g5: NONCONFORMING, v6: undefined, a1: t1, e0: t1.nextSibling, b0: undefined, f0: undefined, a2: t3, e1: t3.nextSibling, b1: undefined, f1: undefined, a3: t4, e2: t4.nextSibling, b2: undefined, f2: undefined };
111
104
  p0(r, -1, d);
112
105
  return r;
113
106
  };
114
107
  const p0 = (r, c, d) => {
115
- if (c & 4) {
116
- const x0 = v[2];
117
- const s0 = toAttribute(x0, "aria-disabled");
118
- if (s0 !== r.v0) writeAttribute(r.n, "aria-disabled", r.v0 = s0);
119
- }
120
- if (c & 64) {
121
- const x1 = v[6];
122
- const s1 = toAttribute(x1, "data-value");
123
- if (s1 !== r.v1) writeAttribute(r.n, "data-value", r.v1 = s1);
124
- }
125
- if (c & 1073741836) {
126
- const x2 = readIndex({ "true": null, "false": v[3] }, textCall("concat", [v[2]]));
127
- if (x2 !== NONCONFORMING) {
128
- const s2 = toAttribute(x2, "href");
129
- if (s2 !== r.v2) writeUrlAttribute(r.n, "href", r.v2 = s2);
108
+ if (c & 1073741900) {
109
+ resetForwardedAttributes(r.n, attributes, r.v0);
110
+ r.v0 = forwardAttributes(r.n, attributes);
111
+ const x0 = "menuitem";
112
+ const s1 = toAttribute(x0, "role");
113
+ writeAttribute(r.n, "role", r.v1 = s1);
114
+ const x1 = "-1";
115
+ const s2 = toAttribute(x1, "tabindex");
116
+ writeAttribute(r.n, "tabindex", r.v2 = s2);
117
+ const x2 = v[2];
118
+ const s3 = toAttribute(x2, "aria-disabled");
119
+ writeAttribute(r.n, "aria-disabled", r.v3 = s3);
120
+ const x3 = v[6];
121
+ const s4 = toAttribute(x3, "data-value");
122
+ writeAttribute(r.n, "data-value", r.v4 = s4);
123
+ const x4 = readIndex({ "true": null, "false": v[3] }, textCall("concat", [v[2]]));
124
+ if (x4 !== NONCONFORMING) r.g5 = x4;
125
+ if (r.g5 !== NONCONFORMING) {
126
+ const s5 = toAttribute(r.g5, "href");
127
+ writeUrlAttribute(r.n, "href", r.v5 = s5);
130
128
  }
131
129
  }
132
130
  if (c & 48) {
133
- const x3 = hostState(["tone","type"], [v[4], v[5]]);
134
- const s3 = x3;
135
- if (s3 !== r.v3) writeAttribute(r.n, "data-ui-menu-item-state", (r.v3 = s3) === "" ? null : s3);
131
+ const x5 = hostState(["tone","type"], [v[4], v[5]]);
132
+ const s6 = x5;
133
+ if (s6 !== r.v6) writeAttribute(r.n, "data-ui-menu-item-state", (r.v6 = s6) === "" ? null : s6);
136
134
  }
137
- if (r.f0 === undefined) { r.f0 = 1; const at = fillSlot(r.a1, r.e0, "icon", J, false, undefined, d);
138
- if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b0 = m1(d); at.before(r.b0.n); } }
139
- else if (r.b0 !== undefined) p1(r.b0, c, d);
140
- if (r.f1 === undefined) { r.f1 = 1; const at = fillSlot(r.a2, r.e1, "", J, false, undefined, d);
141
- if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b1 = m2(d); at.before(r.b1.n); } }
142
- else if (r.b1 !== undefined) p2(r.b1, c, d);
143
- if (r.f2 === undefined) { r.f2 = 1; const at = fillSlot(r.a3, r.e2, "shortcut", J, false, undefined, d);
144
- if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b2 = m3(d); at.before(r.b2.n); } }
145
- else if (r.b2 !== undefined) p3(r.b2, c, d);
135
+ if (r.f0 === undefined) { r.f0 = 1; const at = initializeSlot(r.a1, r.e0, "icon", J, false, undefined, d);
136
+ if (typeof at === "function") r.f0 = at(r, (d, at) => m1(d, undefined, r), p1); else if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b0 = m1(d); at.before(r.b0.n); } }
137
+ else if (typeof r.f0 === "function") r.f0(c, d); else if (r.b0 !== undefined) p1(r.b0, c, d);
138
+ if (r.f1 === undefined) { r.f1 = 1; const at = initializeSlot(r.a2, r.e1, "", J, false, undefined, d);
139
+ if (typeof at === "function") r.f1 = at(r, (d, at) => m2(d, undefined, r), p2); else if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b1 = m2(d); at.before(r.b1.n); } }
140
+ else if (typeof r.f1 === "function") r.f1(c, d); else if (r.b1 !== undefined) p2(r.b1, c, d);
141
+ if (r.f2 === undefined) { r.f2 = 1; const at = initializeSlot(r.a3, r.e2, "shortcut", J, false, undefined, d);
142
+ if (typeof at === "function") r.f2 = at(r, (d, at) => m3(d, undefined, r), p3); else if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b2 = m3(d); at.before(r.b2.n); } }
143
+ else if (typeof r.f2 === "function") r.f2(c, d); else if (r.b2 !== undefined) p3(r.b2, c, d);
146
144
  };
147
145
  const m4 = (n, d) => {
148
146
  n.append((P4 ??= buildTemplate(T4)).cloneNode(true));
@@ -153,49 +151,48 @@ export function createUiMenuItem(options = {}, html) {
153
151
  const t4 = t2.nextSibling.nextSibling;
154
152
  const t5 = t4.firstChild;
155
153
  const t6 = t4.nextSibling.nextSibling.firstChild;
156
- const r = { n, v0: undefined, v1: undefined, v2: undefined, v3: undefined, v4: undefined, a1: t1, e0: t1.nextSibling, b0: undefined, a2: t3, e1: t3.nextSibling, b1: undefined, f1: undefined, a3: t5, e2: t5.nextSibling, b2: undefined, f2: undefined, a4: t6, e3: t6.nextSibling, b3: undefined, f3: undefined };
154
+ const r = { n, v0: undefined, v1: undefined, v2: undefined, v3: undefined, v4: undefined, v5: undefined, v6: undefined, a1: t1, e0: t1.nextSibling, b0: undefined, a2: t3, e1: t3.nextSibling, b1: undefined, f1: undefined, a3: t5, e2: t5.nextSibling, b2: undefined, f2: undefined, a4: t6, e3: t6.nextSibling, b3: undefined, f3: undefined };
157
155
  p4(r, -1, d);
158
156
  return r;
159
157
  };
160
158
  const p4 = (r, c, d) => {
161
- if (c & 1073741856) {
159
+ if (c & 1073741925) {
160
+ resetForwardedAttributes(r.n, attributes, r.v0);
161
+ r.v0 = forwardAttributes(r.n, attributes);
162
162
  const x0 = readIndex({ "action": "menuitem", "checkbox": "menuitemcheckbox", "radio": "menuitemradio" }, v[5]);
163
- const s0 = toAttribute(x0, "role");
164
- if (s0 !== r.v0) writeAttribute(r.n, "role", r.v0 = s0);
165
- }
166
- if (c & 1073741857) {
163
+ const s1 = toAttribute(x0, "role");
164
+ writeAttribute(r.n, "role", r.v1 = s1);
167
165
  const x1 = readIndex({ "action": null, "checkbox": v[0], "radio": v[0] }, v[5]);
168
- const s1 = toAttribute(x1, "aria-checked");
169
- if (s1 !== r.v1) writeAttribute(r.n, "aria-checked", r.v1 = s1);
170
- }
171
- if (c & 4) {
172
- const x2 = v[2];
173
- const s2 = toAttribute(x2, "aria-disabled");
174
- if (s2 !== r.v2) writeAttribute(r.n, "aria-disabled", r.v2 = s2);
175
- }
176
- if (c & 64) {
177
- const x3 = v[6];
178
- const s3 = toAttribute(x3, "data-value");
179
- if (s3 !== r.v3) writeAttribute(r.n, "data-value", r.v3 = s3);
166
+ const s2 = toAttribute(x1, "aria-checked");
167
+ writeAttribute(r.n, "aria-checked", r.v2 = s2);
168
+ const x2 = "-1";
169
+ const s3 = toAttribute(x2, "tabindex");
170
+ writeAttribute(r.n, "tabindex", r.v3 = s3);
171
+ const x3 = v[2];
172
+ const s4 = toAttribute(x3, "aria-disabled");
173
+ writeAttribute(r.n, "aria-disabled", r.v4 = s4);
174
+ const x4 = v[6];
175
+ const s5 = toAttribute(x4, "data-value");
176
+ writeAttribute(r.n, "data-value", r.v5 = s5);
180
177
  }
181
178
  if (c & 48) {
182
- const x4 = hostState(["tone","type"], [v[4], v[5]]);
183
- const s4 = x4;
184
- if (s4 !== r.v4) writeAttribute(r.n, "data-ui-menu-item-state", (r.v4 = s4) === "" ? null : s4);
179
+ const x5 = hostState(["tone","type"], [v[4], v[5]]);
180
+ const s6 = x5;
181
+ if (s6 !== r.v6) writeAttribute(r.n, "data-ui-menu-item-state", (r.v6 = s6) === "" ? null : s6);
185
182
  }
186
- if (c & 33 && !((((v[5] === "checkbox") || (v[5] === "radio")) && v[0])) !== !r.b0) {
183
+ if (c & 33 && !(((truthy(equalValue(v[5], "checkbox")) || truthy(equalValue(v[5], "radio"))) && v[0])) !== !r.b0) {
187
184
  if (r.b0) { r.b0 = undefined; clearRegion(r.a1, r.e0); }
188
185
  else { r.b0 = m5(d); r.e0.before(r.b0.n); }
189
186
  } else if (r.b0 !== undefined) p5(r.b0, c, d);
190
- if (r.f1 === undefined) { r.f1 = 1; const at = fillSlot(r.a2, r.e1, "icon", J, false, undefined, d);
191
- if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b1 = m6(d); at.before(r.b1.n); } }
192
- else if (r.b1 !== undefined) p6(r.b1, c, d);
193
- if (r.f2 === undefined) { r.f2 = 1; const at = fillSlot(r.a3, r.e2, "", J, false, undefined, d);
194
- if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b2 = m7(d); at.before(r.b2.n); } }
195
- else if (r.b2 !== undefined) p7(r.b2, c, d);
196
- if (r.f3 === undefined) { r.f3 = 1; const at = fillSlot(r.a4, r.e3, "shortcut", J, false, undefined, d);
197
- if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b3 = m8(d); at.before(r.b3.n); } }
198
- else if (r.b3 !== undefined) p8(r.b3, c, d);
187
+ if (r.f1 === undefined) { r.f1 = 1; const at = initializeSlot(r.a2, r.e1, "icon", J, false, undefined, d);
188
+ if (typeof at === "function") r.f1 = at(r, (d, at) => m6(d, undefined, r), p6); else if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b1 = m6(d); at.before(r.b1.n); } }
189
+ else if (typeof r.f1 === "function") r.f1(c, d); else if (r.b1 !== undefined) p6(r.b1, c, d);
190
+ if (r.f2 === undefined) { r.f2 = 1; const at = initializeSlot(r.a3, r.e2, "", J, false, undefined, d);
191
+ if (typeof at === "function") r.f2 = at(r, (d, at) => m7(d, undefined, r), p7); else if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b2 = m7(d); at.before(r.b2.n); } }
192
+ else if (typeof r.f2 === "function") r.f2(c, d); else if (r.b2 !== undefined) p7(r.b2, c, d);
193
+ if (r.f3 === undefined) { r.f3 = 1; const at = initializeSlot(r.a4, r.e3, "shortcut", J, false, undefined, d);
194
+ if (typeof at === "function") r.f3 = at(r, (d, at) => m8(d, undefined, r), p8); else if (Array.isArray(at)) (r.z ??= []).push(() => { at[0].l.delete(at[1]); dispose(at[1]); }); else if (at !== undefined) { r.b3 = m8(d); at.before(r.b3.n); } }
195
+ else if (typeof r.f3 === "function") r.f3(c, d); else if (r.b3 !== undefined) p8(r.b3, c, d);
199
196
  };
200
197
  const M = [m0, m4], N = [p0, p4];
201
198
  let R;
@@ -203,7 +200,7 @@ export function createUiMenuItem(options = {}, html) {
203
200
  if (R === null) return;
204
201
  if (R === undefined) { R = M[a](element, d); return; }
205
202
  if (c & 40) {
206
- const t = ((truthy(v[3]) && (v[5] === "action")) ? 0 : 1);
203
+ const t = ((truthy(v[3]) && truthy(equalValue(v[5], "action"))) ? 0 : 1);
207
204
  if (t !== a) {
208
205
  dispose(R);
209
206
  for (const key in I.r) delete I.r[key];
@@ -220,7 +217,9 @@ export function createUiMenuItem(options = {}, html) {
220
217
  };
221
218
  const I = { B };
222
219
  const J = project(I, children, slots);
220
+ sharePlainSlots(I, J, ["icon","","shortcut"]);
223
221
  I.R = new Set();
222
+ I.F = { values: attributes, draw: () => p(-1) };
224
223
  attachGeneratedController(element, S, v, (c, d) => { p(c, d); for (const f of I.R) f(c, d); }, undefined, undefined, I);
225
224
  manageProps(I);
226
225
  return element;
@@ -1,4 +1,4 @@
1
- // Generated by HTML Next 1.0.0-alpha.91 for Vanilla DOM. Do not edit.
1
+ // Generated by HTML Next 1.0.0-alpha.92 for Vanilla DOM. Do not edit.
2
2
  export interface UiMeterEventMap {
3
3
  }
4
4
  export interface UiMeterElement extends HTMLSpanElement {
@@ -1,5 +1,5 @@
1
- // Generated by HTML Next 1.0.0-alpha.91 for Vanilla DOM. Do not edit.
2
- import { attachGeneratedController, binaryValue, buildTemplate, clearRegion, formatCall, mathCall, NONCONFORMING, readIndex, readMember, recordValue, textCall, toAttribute, toText, trackContainer, truthy, writeAttribute, computedCycle, formatOf, keywordFormat, hostState, acceptProps, manageProps, generatedInputs, awaitInput, evaluateInput, inputRead, READY_INPUT, UNRESOLVED_INPUT, notifyPropertySet, RangedIndexedList, readonlyView, checkFormat, checkList, checkNumber, checkObject, checkString, defineComponent, subtract, multiply } from "@nextwebwg/html-next/generated-runtime";
1
+ // Generated by HTML Next 1.0.0-alpha.92 for Vanilla DOM. Do not edit.
2
+ import { attachGeneratedController, checkedReferenceValue, equalValue, binaryValue, buildTemplate, clearRegion, formatCall, mathCall, NONCONFORMING, readIndex, readMember, recordValue, textCall, toAttribute, toText, trackContainer, truthy, truthyValue, writeAttribute, computedCycle, formatOf, keywordFormat, hostState, acceptProps, manageProps, generatedInputs, awaitInput, evaluateInput, inputRead, READY_INPUT, UNRESOLVED_INPUT, notifyPropertySet, RangedIndexedList, readonlyView, checkFormat, checkList, checkNumber, checkObject, checkString, forwardAttributes, resetForwardedAttributes, defineComponent, subtract, multiply } from "@nextwebwg/html-next/generated-runtime";
3
3
  import "../styles/ui-meter.css";
4
4
 
5
5
  const T0 = ["",[],"\n ",1,"\n ",1,"\n "];
@@ -7,18 +7,17 @@ const T1 = ["span",["class","fill"]];
7
7
  const T2 = ["",[],"\n ",2,"\n "];
8
8
  const T3 = ["",[],"\n ",1,"\n "];
9
9
  const T4 = ["span",["class","part","aria-hidden","true"]];
10
+ const RC0 = ["n", "number"];
11
+ const RC1 = ["s", "string"];
10
12
  let P0, P1, P2, P3, P4;
11
13
  const emptyDirty = new Map();
12
14
  const S = { n: ["amount","percent"], t: ["?","?"], f: import.meta.url, g: "ui-meter", k: 0, r: readonlyView, b: generatedInputs };
13
15
  const D = { g: "ui-meter", props: { "label": { "required":false,"default":"", c: checkString, t: "string", j: 0, m: "s" }, "max": { "required":false,"default":1, c: checkNumber, t: "number", j: 0, m: "n" }, "parts": { "required":false,"default":[], c: checkList(checkObject([["value", checkNumber, false], ["color", checkString, false]], false)), j: 1, m: ["l",["o",["value","n","color","s"]]] }, "segments": { "required":false,"default":0, c: checkNumber, t: "number", j: 0, m: "n" }, "size": { "required":false,"values":["sm","md"],"default":"md", c: checkFormat("keyword", keywordFormat), t: "keyword", j: 0, m: ["p",formatOf(keywordFormat)] }, "tone": { "required":false,"values":["neutral","accent","accent-secondary","accent-tertiary","info","success","warning","danger"],"default":"neutral", c: checkFormat("keyword", keywordFormat), t: "keyword", j: 0, m: ["p",formatOf(keywordFormat)] }, "value": { "required":false,"default":0, c: checkNumber, t: "number", j: 0, m: "n" }, "valueText": { "required":false,"default":"", c: checkString, t: "string", j: 0, m: "s" }, "variant": { "required":false,"values":["progress","distribution"],"default":"progress", c: checkFormat("keyword", keywordFormat), t: "keyword", j: 0, m: ["p",formatOf(keywordFormat)] } } };
14
16
 
15
17
  export function createUiMeter(options = {}, html) {
16
- const { attributes = {}, children = [], slots = {}, ...componentProps } = options;
18
+ const { attributes: authoredAttributes = {}, children = [], slots = {}, ...componentProps } = options;
19
+ const attributes = Object.fromEntries([...[], ...Object.entries(authoredAttributes)].filter(([name]) => !["label","max","parts","segments","size","tone","value","value-text","variant"].includes(name)));
17
20
  const element = document.createElement("span");
18
- for (const [name, value] of Object.entries(attributes)) {
19
- if (value === null || value === undefined || value === false) continue;
20
- element.setAttribute(name, value === true ? "" : String(value));
21
- }
22
21
  element.setAttribute("component", "ui-meter");
23
22
  element.append((P0 ??= buildTemplate(T0)).cloneNode(true));
24
23
  const v = [undefined, undefined, null, null, null, null, null, null, null, null, null];
@@ -27,7 +26,7 @@ export function createUiMeter(options = {}, html) {
27
26
  const inputStatus = (j) => { if (j >= 0 && j < 2) { g(j); return CS[j] ?? UNRESOLVED_INPUT; } if (j === 2) return awaitInput(B, "label", true); if (j === 3) return awaitInput(B, "max", true); if (j === 4) return awaitInput(B, "parts", true); if (j === 5) return awaitInput(B, "segments", true); if (j === 6) return awaitInput(B, "size", true); if (j === 7) return awaitInput(B, "tone", true); if (j === 8) return awaitInput(B, "value", true); if (j === 9) return awaitInput(B, "valueText", true); if (j === 10) return awaitInput(B, "variant", true); return v[j] === undefined ? UNRESOLVED_INPUT : READY_INPUT; };
28
27
  const X = { e: 0, g: (j) => g(j), w: new Set(), a: CS, i: inputStatus };
29
28
  const ke = [];
30
- const K = [() => mathCall("clamp", [0, inputRead(v[8], inputStatus(8)), inputRead(v[3], inputStatus(3))], undefined, []), () => readIndex(recordValue(["true","false"], [binaryValue("*", binaryValue("/", inputRead(g(0), inputStatus(0)), inputRead(v[3], inputStatus(3))), 100, undefined, undefined, multiply), 0]), textCall("concat", [binaryValue(">", inputRead(v[3], inputStatus(3)), 0)]))];
29
+ const K = [() => mathCall("clamp", [0, inputRead(v[8], inputStatus(8)), inputRead(v[3], inputStatus(3))], undefined, []), () => (truthy(binaryValue(">", inputRead(v[3], inputStatus(3)), 0)) ? binaryValue("*", binaryValue("/", inputRead(g(0), inputStatus(0)), inputRead(v[3], inputStatus(3))), 100, undefined, undefined, multiply) : 0)];
31
30
  const g = (j) => {
32
31
  const i = j - 0;
33
32
  if (ke[i] === X.e) return v[j];
@@ -47,7 +46,7 @@ export function createUiMeter(options = {}, html) {
47
46
  return r;
48
47
  };
49
48
  const p1 = (r, c, d) => {
50
- if (c & 1073742088) {
49
+ if (c & 264) {
51
50
  const x0 = textCall("concat", [g(1), "%"]);
52
51
  if (x0 !== NONCONFORMING) {
53
52
  const s0 = toText(x0);
@@ -77,9 +76,11 @@ export function createUiMeter(options = {}, html) {
77
76
  };
78
77
  const p3 = (r, c, d) => {
79
78
  const o = r.i;
80
- if (c & 1073741824 && !((truthy(binaryValue(">", readMember(o, "value"), 0)) && (binaryValue("-", readMember(o, "value"), readMember(o, "value"), undefined, undefined, subtract) === 0))) !== !r.b0) {
81
- if (r.b0) { r.b0 = undefined; clearRegion(r.a0, r.e0); }
82
- else { r.b0 = m4(d, undefined, r); r.e0.before(r.b0.n); }
79
+ let t0;
80
+ if (c & 1073741824 && (t0 = truthyValue(((q) => q === NONCONFORMING ? q : q ? truthyValue(equalValue(binaryValue("-", checkedReferenceValue(S, readMember(o, "value"), RC0, "expression:$part.value > 0 and $part.value - $part.value = 0:part.value", "part.value"), checkedReferenceValue(S, readMember(o, "value"), RC0, "expression:$part.value > 0 and $part.value - $part.value = 0:part.value", "part.value"), undefined, undefined, subtract), 0)) : false)(truthyValue(binaryValue(">", checkedReferenceValue(S, readMember(o, "value"), RC0, "expression:$part.value > 0 and $part.value - $part.value = 0:part.value", "part.value"), 0))))) !== NONCONFORMING && !t0 !== !r.b0) {
81
+ r.b0 = undefined;
82
+ clearRegion(r.a0, r.e0);
83
+ if (t0) { r.b0 = m4(d, undefined, r); r.e0.before(r.b0.n); }
83
84
  } else if (r.b0 !== undefined) p4(r.b0, c, d);
84
85
  };
85
86
  const m4 = (d, o, u) => {
@@ -91,80 +92,84 @@ export function createUiMeter(options = {}, html) {
91
92
  const p4 = (r, c, d) => {
92
93
  if (c & 1073741824) {
93
94
  r.w = 0;
94
- const x0 = trackContainer(r, readMember(r.u.i, "value"));
95
- const s0 = toText(x0);
96
- if (s0 !== r.v0) r.n.style.setProperty("flex-grow", r.v0 = s0);
97
- const x1 = trackContainer(r, readMember(r.u.i, "color"));
98
- const s1 = toText(x1);
99
- if (s1 !== r.v1) r.n.style.setProperty("background-color", r.v1 = s1);
100
- }
101
- };
102
- const p0 = (r, c, d) => {
103
- if (c & 1073742848) {
104
- const x0 = readIndex({ "true": "img", "false": "meter" }, textCall("concat", [(v[10] === "distribution")]));
95
+ const x0 = trackContainer(r, checkedReferenceValue(S, readMember(r.u.i, "value"), RC0, "expression:$part.value:part.value", "part.value"));
105
96
  if (x0 !== NONCONFORMING) {
106
- const s0 = toAttribute(x0, "role");
107
- if (s0 !== r.v0) writeAttribute(r.n, "role", r.v0 = s0);
97
+ const s0 = toText(x0);
98
+ if (s0 !== r.v0) r.n.style.setProperty("flex-grow", r.v0 = s0);
108
99
  }
109
- const x1 = readIndex({ "true": null, "false": 0 }, textCall("concat", [(v[10] === "distribution")]));
100
+ const x1 = trackContainer(r, checkedReferenceValue(S, readMember(r.u.i, "color"), RC1, "expression:$part.color:part.color", "part.color"));
110
101
  if (x1 !== NONCONFORMING) {
111
- const s1 = toAttribute(x1, "aria-valuemin");
112
- if (s1 !== r.v1) writeAttribute(r.n, "aria-valuemin", r.v1 = s1);
102
+ const s1 = toText(x1);
103
+ if (s1 !== r.v1) r.n.style.setProperty("background-color", r.v1 = s1);
113
104
  }
114
105
  }
115
- if (c & 1073742856) {
116
- const x2 = readIndex({ "true": null, "false": v[3] }, textCall("concat", [(v[10] === "distribution")]));
117
- if (x2 !== NONCONFORMING) {
118
- const s2 = toAttribute(x2, "aria-valuemax");
119
- if (s2 !== r.v2) writeAttribute(r.n, "aria-valuemax", r.v2 = s2);
106
+ };
107
+ const p0 = (r, c, d) => {
108
+ if (c & 1073743660) {
109
+ resetForwardedAttributes(r.n, attributes, r.v0);
110
+ r.v0 = forwardAttributes(r.n, attributes);
111
+ const x0 = readIndex({ "true": "img", "false": "meter" }, textCall("concat", [equalValue(v[10], "distribution")]));
112
+ if (x0 !== NONCONFORMING) r.g1 = x0;
113
+ if (r.g1 !== NONCONFORMING) {
114
+ const s1 = toAttribute(r.g1, "role");
115
+ writeAttribute(r.n, "role", r.v1 = s1);
120
116
  }
121
- }
122
- if (c & 1073743112) {
123
- const x3 = readIndex(recordValue(["true","false"], [null, g(0)]), textCall("concat", [(v[10] === "distribution")]));
124
- if (x3 !== NONCONFORMING) {
125
- const s3 = toAttribute(x3, "aria-valuenow");
126
- if (s3 !== r.v3) writeAttribute(r.n, "aria-valuenow", r.v3 = s3);
117
+ const x1 = readIndex({ "true": null, "false": 0 }, textCall("concat", [equalValue(v[10], "distribution")]));
118
+ if (x1 !== NONCONFORMING) r.g2 = x1;
119
+ if (r.g2 !== NONCONFORMING) {
120
+ const s2 = toAttribute(r.g2, "aria-valuemin");
121
+ writeAttribute(r.n, "aria-valuemin", r.v2 = s2);
127
122
  }
128
- }
129
- if (c & 1073743624) {
130
- const x4 = readIndex(recordValue(["true","false"], [null, readIndex(recordValue(["true","false"], [v[9], formatCall("format", [binaryValue("/", g(1), 100), "percent", { "maximumFractionDigits": 0 }], "number")]), textCall("concat", [(v[9] !== "")]))]), textCall("concat", [(v[10] === "distribution")]));
131
- if (x4 !== NONCONFORMING) {
132
- const s4 = toAttribute(x4, "aria-valuetext");
133
- if (s4 !== r.v4) writeAttribute(r.n, "aria-valuetext", r.v4 = s4);
123
+ const x2 = readIndex({ "true": null, "false": v[3] }, textCall("concat", [equalValue(v[10], "distribution")]));
124
+ if (x2 !== NONCONFORMING) r.g3 = x2;
125
+ if (r.g3 !== NONCONFORMING) {
126
+ const s3 = toAttribute(r.g3, "aria-valuemax");
127
+ writeAttribute(r.n, "aria-valuemax", r.v3 = s3);
134
128
  }
135
- }
136
- if (c & 1073743364) {
137
- const x5 = readIndex(recordValue(["true","false"], [readIndex(recordValue(["true","false"], [textCall("concat", [v[2], ": ", v[9]]), v[2]]), textCall("concat", [((v[10] === "distribution") && (v[9] !== ""))])), null]), textCall("concat", [(v[2] !== "")]));
138
- if (x5 !== NONCONFORMING) {
139
- const s5 = toAttribute(x5, "aria-label");
140
- if (s5 !== r.v5) writeAttribute(r.n, "aria-label", r.v5 = s5);
129
+ const x3 = readIndex(recordValue(["true","false"], [null, g(0)]), textCall("concat", [equalValue(v[10], "distribution")]));
130
+ if (x3 !== NONCONFORMING) r.g4 = x3;
131
+ if (r.g4 !== NONCONFORMING) {
132
+ const s4 = toAttribute(r.g4, "aria-valuenow");
133
+ writeAttribute(r.n, "aria-valuenow", r.v4 = s4);
141
134
  }
142
- }
143
- if (c & 1073742880) {
144
- const x6 = readIndex({ "true": v[5], "false": null }, textCall("concat", [((v[10] === "progress") && truthy(binaryValue(">", v[5], 1)))]));
145
- if (x6 !== NONCONFORMING) {
146
- const s6 = toAttribute(x6, "data-ui-meter-segments");
147
- if (s6 !== r.v6) writeAttribute(r.n, "data-ui-meter-segments", r.v6 = s6);
135
+ const x4 = readIndex(recordValue(["true","false"], [null, readIndex(recordValue(["true","false"], [v[9], formatCall("format", [binaryValue("/", g(1), 100), "percent", { "maximumFractionDigits": 0 }], "number")]), textCall("concat", [equalValue(v[9], "", true)]))]), textCall("concat", [equalValue(v[10], "distribution")]));
136
+ if (x4 !== NONCONFORMING) r.g5 = x4;
137
+ if (r.g5 !== NONCONFORMING) {
138
+ const s5 = toAttribute(r.g5, "aria-valuetext");
139
+ writeAttribute(r.n, "aria-valuetext", r.v5 = s5);
140
+ }
141
+ const x5 = readIndex(recordValue(["true","false"], [readIndex(recordValue(["true","false"], [textCall("concat", [v[2], ": ", v[9]]), v[2]]), textCall("concat", [(truthy(equalValue(v[10], "distribution")) && truthy(equalValue(v[9], "", true)))])), null]), textCall("concat", [equalValue(v[2], "", true)]));
142
+ if (x5 !== NONCONFORMING) r.g6 = x5;
143
+ if (r.g6 !== NONCONFORMING) {
144
+ const s6 = toAttribute(r.g6, "aria-label");
145
+ writeAttribute(r.n, "aria-label", r.v6 = s6);
146
+ }
147
+ const x6 = readIndex({ "true": v[5], "false": null }, textCall("concat", [(truthy(equalValue(v[10], "progress")) && truthy(binaryValue(">", v[5], 1)))]));
148
+ if (x6 !== NONCONFORMING) r.g7 = x6;
149
+ if (r.g7 !== NONCONFORMING) {
150
+ const s7 = toAttribute(r.g7, "data-ui-meter-segments");
151
+ writeAttribute(r.n, "data-ui-meter-segments", r.v7 = s7);
148
152
  }
149
153
  }
150
154
  if (c & 1216) {
151
155
  const x7 = hostState(["size","tone","variant"], [v[6], v[7], v[10]]);
152
- const s7 = x7;
153
- if (s7 !== r.v7) writeAttribute(r.n, "data-ui-meter-state", (r.v7 = s7) === "" ? null : s7);
156
+ const s8 = x7;
157
+ if (s8 !== r.v8) writeAttribute(r.n, "data-ui-meter-state", (r.v8 = s8) === "" ? null : s8);
154
158
  }
155
- if (c & 1024 && !((v[10] === "progress")) !== !r.b0) {
159
+ if (c & 1024 && !(truthy(equalValue(v[10], "progress"))) !== !r.b0) {
156
160
  if (r.b0) { r.b0 = undefined; clearRegion(r.a1, r.e0); }
157
161
  else { r.b0 = m1(d); r.e0.before(r.b0.n); }
158
162
  } else if (r.b0 !== undefined) p1(r.b0, c, d);
159
- if (c & 1024 && !((v[10] === "distribution")) !== !r.b1) {
163
+ if (c & 1024 && !(truthy(equalValue(v[10], "distribution"))) !== !r.b1) {
160
164
  if (r.b1) { r.b1 = undefined; clearRegion(r.a2, r.e1); }
161
165
  else { r.b1 = m2(d); r.e1.before(r.b1.n); }
162
166
  } else if (r.b1 !== undefined) p2(r.b1, c, d);
163
167
  };
164
168
  const t0 = element.firstChild.nextSibling;
165
169
  const t1 = t0.nextSibling.nextSibling.nextSibling;
166
- const R = { n: element, v0: undefined, v1: undefined, v2: undefined, v3: undefined, v4: undefined, v5: undefined, v6: undefined, v7: undefined, a1: t0, e0: t0.nextSibling, b0: undefined, a2: t1, e1: t1.nextSibling, b1: undefined };
170
+ const R = { n: element, v0: undefined, v1: undefined, g1: NONCONFORMING, v2: undefined, g2: NONCONFORMING, v3: undefined, g3: NONCONFORMING, v4: undefined, g4: NONCONFORMING, v5: undefined, g5: NONCONFORMING, v6: undefined, g6: NONCONFORMING, v7: undefined, g7: NONCONFORMING, v8: undefined, a1: t0, e0: t0.nextSibling, b0: undefined, a2: t1, e1: t1.nextSibling, b1: undefined };
167
171
  const I = { B };
172
+ I.F = { values: attributes, draw: () => ((c, d) => p0(R, c, d))(-1) };
168
173
  attachGeneratedController(element, S, v, ((c, d) => p0(R, c, d)), undefined, X, I);
169
174
  manageProps(I);
170
175
  return element;
@@ -1,4 +1,4 @@
1
- // Generated by HTML Next 1.0.0-alpha.91 for Vanilla DOM. Do not edit.
1
+ // Generated by HTML Next 1.0.0-alpha.92 for Vanilla DOM. Do not edit.
2
2
  export interface UiNavItemEventMap {
3
3
  }
4
4
  export interface UiNavItemElement extends HTMLElement {