@threadlabs/looma 0.52.12 → 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, checkReference, clearRegion, KeyedList, NONCONFORMING, readDeclared, readMember, toAttribute, toText, trackContainer, truthy, visitSelected, writeAttribute, dispatchDeclared, detailCheck, dispose, formatOf, keywordFormat, acceptProps, manageProps, generatedInputs, project, fillSlot, checkBoolean, checkInteger, checkList, checkNumber, checkObject, 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, checkedReferenceValue, equalValue, buildTemplate, clearRegion, KeyedList, NONCONFORMING, readMember, toAttribute, toText, trackContainer, truthy, visitSelected, writeAttribute, dispatchDeclared, detailCheck, dispose, formatOf, keywordFormat, acceptProps, manageProps, generatedInputs, project, fillSlot, checkBoolean, checkInteger, checkList, checkNumber, checkObject, forwardAttributes, resetForwardedAttributes, defineComponent, activateModule } from "@nextwebwg/html-next/generated-runtime";
3
3
  import * as controller from "../components/ui-editor-table-overlay/ui-editor-table-overlay.js";
4
4
  import "../styles/ui-editor-table-overlay.css";
5
5
 
@@ -9,6 +9,10 @@ const T2 = ["div",["class","control row"],"\n ",["span",["class","line","
9
9
  const T3 = ["div",["class","control col"],"\n ",["span",["class","line","aria-hidden","true"]],"\n ",["span",["class","guide","data-ui-guide","","aria-hidden","true"]],"\n ",["button",["type","button","class","handle"],"\n ",["ui-icon",["name","plus"]],"\n ",["span",["class","tooltip","role","tooltip"],0],"\n "],"\n "];
10
10
  const T4 = ["",[],"\n ",["button",["type","button","class","selector row","data-action","select-row","title","Drag row to reorder; click for actions","aria-label","Row actions"],"\n ",["span",["class","glyph"],["ui-icon",["name","grip-vertical"]]],"\n "],"\n ",["button",["type","button","class","selector column","data-action","select-column","title","Drag column to reorder; click for actions","aria-label","Column actions"],"\n ",["span",["class","glyph"],["ui-icon",["name","grip-horizontal"]]],"\n "],"\n "];
11
11
  const T5 = ["button",["type","button","class","cell-menu","data-action","open-cell-menu","title","Cell actions","aria-label","Cell actions"],"\n ",["ui-icon",["name","chevron-down"]],"\n "];
12
+ const RC0 = ["s", "string"];
13
+ const RC1 = [["p",formatOf(keywordFormat)], "keyword with values insert-row, insert-column"];
14
+ const RC2 = [["p",formatOf(keywordFormat)], "keyword with values add-row-before, add-row-after, add-column-before, add-column-after"];
15
+ const RC3 = ["i", "integer"];
12
16
  let P0, P1, P2, P3, P4, P5;
13
17
  const emptyDirty = new Map();
14
18
  const S = { n: ["rows","cols","hovered","active","activeKey"], t: [["l",["o",["key","s","index","i","offset","s","affordance",["p",formatOf(keywordFormat)],"action",["p",formatOf(keywordFormat)],"label","s"]]],["l",["o",["key","s","index","i","offset","s","affordance",["p",formatOf(keywordFormat)],"action",["p",formatOf(keywordFormat)],"label","s"]]],["o",["left","n","top","n","width","n","height","n","rowIndex","i","columnIndex","i","rowOffset","s","columnOffset","s"]],["o",["left","n","top","n","width","n","height","n","rowIndex","i","columnIndex","i","menuLeft","s","menuTop","s"]],"s"], f: import.meta.url, g: "ui-editor-table-overlay", d: { "add-row-before": [detailCheck(checkObject([["boundaryIndex", checkInteger, false]], false)), true, true, false], "add-row-after": [detailCheck(checkObject([["boundaryIndex", checkInteger, false]], false)), true, true, false], "add-column-before": [detailCheck(checkObject([["boundaryIndex", checkInteger, false]], false)), true, true, false], "add-column-after": [detailCheck(checkObject([["boundaryIndex", checkInteger, false]], false)), true, true, false], "select-row": [detailCheck(checkObject([["rowIndex", checkInteger, false], ["columnIndex", checkInteger, false]], false)), true, true, false], "select-column": [detailCheck(checkObject([["rowIndex", checkInteger, false], ["columnIndex", checkInteger, false]], false)), true, true, false], "reorder-row": [detailCheck(checkObject([["fromIndex", checkInteger, false], ["toIndex", checkInteger, false]], false)), true, true, false], "reorder-column": [detailCheck(checkObject([["fromIndex", checkInteger, false], ["toIndex", checkInteger, false]], false)), true, true, false], "open-cell-menu": [detailCheck(checkObject([["rowIndex", checkInteger, false], ["columnIndex", checkInteger, false], ["anchor", checkObject([["left", checkNumber, false], ["top", checkNumber, false], ["right", checkNumber, false], ["bottom", checkNumber, false]], false), false]], false)), true, true, false], "open-row-menu": [detailCheck(checkObject([["rowIndex", checkInteger, false], ["columnIndex", checkInteger, false], ["anchor", checkObject([["left", checkNumber, false], ["top", checkNumber, false], ["right", checkNumber, false], ["bottom", checkNumber, false]], false), false]], false)), true, true, false], "open-column-menu": [detailCheck(checkObject([["rowIndex", checkInteger, false], ["columnIndex", checkInteger, false], ["anchor", checkObject([["left", checkNumber, false], ["top", checkNumber, false], ["right", checkNumber, false], ["bottom", checkNumber, false]], false), false]], false)), true, true, false] }, x: dispatchDeclared, a: (host, I) => C(host, I), b: generatedInputs, i: [[], [], null, null, ""] };
@@ -16,12 +20,9 @@ const D = { g: "ui-editor-table-overlay", props: { "geometry": { "required":fals
16
20
  const C = (host) => activateModule(controller, host);
17
21
 
18
22
  export function createUiEditorTableOverlay(options = {}, html) {
19
- const { attributes = {}, children = [], slots = {}, ...componentProps } = options;
23
+ const { attributes: authoredAttributes = {}, children = [], slots = {}, ...componentProps } = options;
24
+ const attributes = Object.fromEntries([...[], ...Object.entries(authoredAttributes)].filter(([name]) => !["geometry","open"].includes(name)));
20
25
  const element = document.createElement("div");
21
- for (const [name, value] of Object.entries(attributes)) {
22
- if (value === null || value === undefined || value === false) continue;
23
- element.setAttribute(name, value === true ? "" : String(value));
24
- }
25
26
  if (!element.hasAttribute("aria-label")) element.setAttribute("aria-label", "Table controls");
26
27
  element.setAttribute("component", "ui-editor-table-overlay");
27
28
  element.append((P0 ??= buildTemplate(T0)).cloneNode(true));
@@ -48,31 +49,47 @@ export function createUiEditorTableOverlay(options = {}, html) {
48
49
  const o = r.i;
49
50
  if (c & 1073741824) r.w = 0;
50
51
  if (c & 1073741840) {
51
- const x0 = (readMember(o, "key") === v[4]);
52
- const s0 = x0;
53
- if (s0 !== r.v0) r.n.classList.toggle("active", r.v0 = s0);
52
+ const x0 = equalValue(checkedReferenceValue(S, readMember(o, "key"), RC0, "expression:$control.key = $activeKey:control.key", "control.key"), v[4]);
53
+ if (x0 !== NONCONFORMING) {
54
+ const s0 = truthy(x0);
55
+ if (s0 !== r.v0) r.n.classList.toggle("active", r.v0 = s0);
56
+ }
54
57
  }
55
58
  if (c & 1073741824) {
56
- const x1 = trackContainer(r, readMember(o, "offset"));
57
- const s1 = toText(x1);
58
- if (s1 !== r.v1) r.n.style.setProperty("top", r.v1 = s1);
59
- const x2 = trackContainer(r, readMember(o, "key"));
60
- const s2 = toAttribute(x2, "data-control-key");
61
- if (s2 !== r.v2) writeAttribute(r.n, "data-control-key", r.v2 = s2);
62
- const x3 = trackContainer(r, readMember(o, "affordance"));
63
- const s3 = toAttribute(x3, "data-ui-affordance");
64
- if (s3 !== r.v3) writeAttribute(r.a1, "data-ui-affordance", r.v3 = s3);
65
- const x4 = trackContainer(r, readMember(o, "action"));
66
- const s4 = toAttribute(x4, "data-action");
67
- if (s4 !== r.v4) writeAttribute(r.a1, "data-action", r.v4 = s4);
68
- const x5 = trackContainer(r, readMember(o, "index"));
69
- const s5 = toAttribute(x5, "data-boundary-index");
70
- if (s5 !== r.v5) writeAttribute(r.a1, "data-boundary-index", r.v5 = s5);
71
- const x6 = trackContainer(r, readMember(o, "label"));
72
- const s6 = toAttribute(x6, "aria-label");
73
- if (s6 !== r.v6) writeAttribute(r.a1, "aria-label", r.v6 = s6);
74
- const s7 = toText(x6);
75
- if (s7 !== r.v7) r.a2.data = r.v7 = s7;
59
+ const x1 = trackContainer(r, checkedReferenceValue(S, readMember(o, "offset"), RC0, "expression:$control.offset:control.offset", "control.offset"));
60
+ if (x1 !== NONCONFORMING) {
61
+ const s1 = toText(x1);
62
+ if (s1 !== r.v1) r.n.style.setProperty("top", r.v1 = s1);
63
+ }
64
+ const x2 = trackContainer(r, checkedReferenceValue(S, readMember(o, "key"), RC0, "expression:$control.key:control.key", "control.key"));
65
+ if (x2 !== NONCONFORMING) {
66
+ const s2 = toAttribute(x2, "data-control-key");
67
+ if (s2 !== r.v2) writeAttribute(r.n, "data-control-key", r.v2 = s2);
68
+ }
69
+ const x3 = trackContainer(r, checkedReferenceValue(S, readMember(o, "affordance"), RC1, "expression:$control.affordance:control.affordance", "control.affordance"));
70
+ if (x3 !== NONCONFORMING) {
71
+ const s3 = toAttribute(x3, "data-ui-affordance");
72
+ if (s3 !== r.v3) writeAttribute(r.a1, "data-ui-affordance", r.v3 = s3);
73
+ }
74
+ const x4 = trackContainer(r, checkedReferenceValue(S, readMember(o, "action"), RC2, "expression:$control.action:control.action", "control.action"));
75
+ if (x4 !== NONCONFORMING) {
76
+ const s4 = toAttribute(x4, "data-action");
77
+ if (s4 !== r.v4) writeAttribute(r.a1, "data-action", r.v4 = s4);
78
+ }
79
+ const x5 = trackContainer(r, checkedReferenceValue(S, readMember(o, "index"), RC3, "expression:$control.index:control.index", "control.index"));
80
+ if (x5 !== NONCONFORMING) {
81
+ const s5 = toAttribute(x5, "data-boundary-index");
82
+ if (s5 !== r.v5) writeAttribute(r.a1, "data-boundary-index", r.v5 = s5);
83
+ }
84
+ const x6 = trackContainer(r, checkedReferenceValue(S, readMember(o, "label"), RC0, "expression:$control.label:control.label", "control.label"));
85
+ if (x6 !== NONCONFORMING) {
86
+ const s6 = toAttribute(x6, "aria-label");
87
+ if (s6 !== r.v6) writeAttribute(r.a1, "aria-label", r.v6 = s6);
88
+ }
89
+ if (x6 !== NONCONFORMING) {
90
+ const s7 = toText(x6);
91
+ if (s7 !== r.v7) r.a2.data = r.v7 = s7;
92
+ }
76
93
  }
77
94
  };
78
95
  const m3 = (o, j, l) => {
@@ -87,31 +104,47 @@ export function createUiEditorTableOverlay(options = {}, html) {
87
104
  const o = r.i;
88
105
  if (c & 1073741824) r.w = 0;
89
106
  if (c & 1073741840) {
90
- const x0 = (readMember(o, "key") === v[4]);
91
- const s0 = x0;
92
- if (s0 !== r.v0) r.n.classList.toggle("active", r.v0 = s0);
107
+ const x0 = equalValue(checkedReferenceValue(S, readMember(o, "key"), RC0, "expression:$control.key = $activeKey:control.key", "control.key"), v[4]);
108
+ if (x0 !== NONCONFORMING) {
109
+ const s0 = truthy(x0);
110
+ if (s0 !== r.v0) r.n.classList.toggle("active", r.v0 = s0);
111
+ }
93
112
  }
94
113
  if (c & 1073741824) {
95
- const x1 = trackContainer(r, readMember(o, "offset"));
96
- const s1 = toText(x1);
97
- if (s1 !== r.v1) r.n.style.setProperty("left", r.v1 = s1);
98
- const x2 = trackContainer(r, readMember(o, "key"));
99
- const s2 = toAttribute(x2, "data-control-key");
100
- if (s2 !== r.v2) writeAttribute(r.n, "data-control-key", r.v2 = s2);
101
- const x3 = trackContainer(r, readMember(o, "affordance"));
102
- const s3 = toAttribute(x3, "data-ui-affordance");
103
- if (s3 !== r.v3) writeAttribute(r.a1, "data-ui-affordance", r.v3 = s3);
104
- const x4 = trackContainer(r, readMember(o, "action"));
105
- const s4 = toAttribute(x4, "data-action");
106
- if (s4 !== r.v4) writeAttribute(r.a1, "data-action", r.v4 = s4);
107
- const x5 = trackContainer(r, readMember(o, "index"));
108
- const s5 = toAttribute(x5, "data-boundary-index");
109
- if (s5 !== r.v5) writeAttribute(r.a1, "data-boundary-index", r.v5 = s5);
110
- const x6 = trackContainer(r, readMember(o, "label"));
111
- const s6 = toAttribute(x6, "aria-label");
112
- if (s6 !== r.v6) writeAttribute(r.a1, "aria-label", r.v6 = s6);
113
- const s7 = toText(x6);
114
- if (s7 !== r.v7) r.a2.data = r.v7 = s7;
114
+ const x1 = trackContainer(r, checkedReferenceValue(S, readMember(o, "offset"), RC0, "expression:$control.offset:control.offset", "control.offset"));
115
+ if (x1 !== NONCONFORMING) {
116
+ const s1 = toText(x1);
117
+ if (s1 !== r.v1) r.n.style.setProperty("left", r.v1 = s1);
118
+ }
119
+ const x2 = trackContainer(r, checkedReferenceValue(S, readMember(o, "key"), RC0, "expression:$control.key:control.key", "control.key"));
120
+ if (x2 !== NONCONFORMING) {
121
+ const s2 = toAttribute(x2, "data-control-key");
122
+ if (s2 !== r.v2) writeAttribute(r.n, "data-control-key", r.v2 = s2);
123
+ }
124
+ const x3 = trackContainer(r, checkedReferenceValue(S, readMember(o, "affordance"), RC1, "expression:$control.affordance:control.affordance", "control.affordance"));
125
+ if (x3 !== NONCONFORMING) {
126
+ const s3 = toAttribute(x3, "data-ui-affordance");
127
+ if (s3 !== r.v3) writeAttribute(r.a1, "data-ui-affordance", r.v3 = s3);
128
+ }
129
+ const x4 = trackContainer(r, checkedReferenceValue(S, readMember(o, "action"), RC2, "expression:$control.action:control.action", "control.action"));
130
+ if (x4 !== NONCONFORMING) {
131
+ const s4 = toAttribute(x4, "data-action");
132
+ if (s4 !== r.v4) writeAttribute(r.a1, "data-action", r.v4 = s4);
133
+ }
134
+ const x5 = trackContainer(r, checkedReferenceValue(S, readMember(o, "index"), RC3, "expression:$control.index:control.index", "control.index"));
135
+ if (x5 !== NONCONFORMING) {
136
+ const s5 = toAttribute(x5, "data-boundary-index");
137
+ if (s5 !== r.v5) writeAttribute(r.a1, "data-boundary-index", r.v5 = s5);
138
+ }
139
+ const x6 = trackContainer(r, checkedReferenceValue(S, readMember(o, "label"), RC0, "expression:$control.label:control.label", "control.label"));
140
+ if (x6 !== NONCONFORMING) {
141
+ const s6 = toAttribute(x6, "aria-label");
142
+ if (s6 !== r.v6) writeAttribute(r.a1, "aria-label", r.v6 = s6);
143
+ }
144
+ if (x6 !== NONCONFORMING) {
145
+ const s7 = toText(x6);
146
+ if (s7 !== r.v7) r.a2.data = r.v7 = s7;
147
+ }
115
148
  }
116
149
  };
117
150
  const m4 = (d) => {
@@ -124,22 +157,22 @@ export function createUiEditorTableOverlay(options = {}, html) {
124
157
  };
125
158
  const p4 = (r, c, d) => {
126
159
  if (c & 1073741828) {
127
- const x0 = (checkReference(S, readDeclared(v[2], ["rowOffset"]), "s", "expression:$hovered.rowOffset:hovered.rowOffset", "Reference `hovered.rowOffset` must satisfy string.") ? readMember(v[2], "rowOffset") : NONCONFORMING);
160
+ const x0 = checkedReferenceValue(S, readMember(v[2], "rowOffset"), RC0, "expression:$hovered.rowOffset:hovered.rowOffset", "hovered.rowOffset");
128
161
  if (x0 !== NONCONFORMING) {
129
162
  const s0 = toText(x0);
130
163
  if (s0 !== r.v0) r.a0.style.setProperty("top", r.v0 = s0);
131
164
  }
132
- const x1 = (checkReference(S, readDeclared(v[2], ["rowIndex"]), "i", "expression:$hovered.rowIndex:hovered.rowIndex", "Reference `hovered.rowIndex` must satisfy integer.") ? readMember(v[2], "rowIndex") : NONCONFORMING);
165
+ const x1 = checkedReferenceValue(S, readMember(v[2], "rowIndex"), RC3, "expression:$hovered.rowIndex:hovered.rowIndex", "hovered.rowIndex");
133
166
  if (x1 !== NONCONFORMING) {
134
167
  const s1 = toAttribute(x1, "data-row-index");
135
168
  if (s1 !== r.v1) writeAttribute(r.a0, "data-row-index", r.v1 = s1);
136
169
  }
137
- const x2 = (checkReference(S, readDeclared(v[2], ["columnIndex"]), "i", "expression:$hovered.columnIndex:hovered.columnIndex", "Reference `hovered.columnIndex` must satisfy integer.") ? readMember(v[2], "columnIndex") : NONCONFORMING);
170
+ const x2 = checkedReferenceValue(S, readMember(v[2], "columnIndex"), RC3, "expression:$hovered.columnIndex:hovered.columnIndex", "hovered.columnIndex");
138
171
  if (x2 !== NONCONFORMING) {
139
172
  const s2 = toAttribute(x2, "data-column-index");
140
173
  if (s2 !== r.v2) writeAttribute(r.a0, "data-column-index", r.v2 = s2);
141
174
  }
142
- const x3 = (checkReference(S, readDeclared(v[2], ["columnOffset"]), "s", "expression:$hovered.columnOffset:hovered.columnOffset", "Reference `hovered.columnOffset` must satisfy string.") ? readMember(v[2], "columnOffset") : NONCONFORMING);
175
+ const x3 = checkedReferenceValue(S, readMember(v[2], "columnOffset"), RC0, "expression:$hovered.columnOffset:hovered.columnOffset", "hovered.columnOffset");
143
176
  if (x3 !== NONCONFORMING) {
144
177
  const s3 = toText(x3);
145
178
  if (s3 !== r.v3) r.a1.style.setProperty("left", r.v3 = s3);
@@ -162,22 +195,22 @@ export function createUiEditorTableOverlay(options = {}, html) {
162
195
  };
163
196
  const p5 = (r, c, d) => {
164
197
  if (c & 1073741832) {
165
- const x0 = (checkReference(S, readDeclared(v[3], ["menuLeft"]), "s", "expression:$active.menuLeft:active.menuLeft", "Reference `active.menuLeft` must satisfy string.") ? readMember(v[3], "menuLeft") : NONCONFORMING);
198
+ const x0 = checkedReferenceValue(S, readMember(v[3], "menuLeft"), RC0, "expression:$active.menuLeft:active.menuLeft", "active.menuLeft");
166
199
  if (x0 !== NONCONFORMING) {
167
200
  const s0 = toText(x0);
168
201
  if (s0 !== r.v0) r.n.style.setProperty("left", r.v0 = s0);
169
202
  }
170
- const x1 = (checkReference(S, readDeclared(v[3], ["menuTop"]), "s", "expression:$active.menuTop:active.menuTop", "Reference `active.menuTop` must satisfy string.") ? readMember(v[3], "menuTop") : NONCONFORMING);
203
+ const x1 = checkedReferenceValue(S, readMember(v[3], "menuTop"), RC0, "expression:$active.menuTop:active.menuTop", "active.menuTop");
171
204
  if (x1 !== NONCONFORMING) {
172
205
  const s1 = toText(x1);
173
206
  if (s1 !== r.v1) r.n.style.setProperty("top", r.v1 = s1);
174
207
  }
175
- const x2 = (checkReference(S, readDeclared(v[3], ["rowIndex"]), "i", "expression:$active.rowIndex:active.rowIndex", "Reference `active.rowIndex` must satisfy integer.") ? readMember(v[3], "rowIndex") : NONCONFORMING);
208
+ const x2 = checkedReferenceValue(S, readMember(v[3], "rowIndex"), RC3, "expression:$active.rowIndex:active.rowIndex", "active.rowIndex");
176
209
  if (x2 !== NONCONFORMING) {
177
210
  const s2 = toAttribute(x2, "data-row-index");
178
211
  if (s2 !== r.v2) writeAttribute(r.n, "data-row-index", r.v2 = s2);
179
212
  }
180
- const x3 = (checkReference(S, readDeclared(v[3], ["columnIndex"]), "i", "expression:$active.columnIndex:active.columnIndex", "Reference `active.columnIndex` must satisfy integer.") ? readMember(v[3], "columnIndex") : NONCONFORMING);
213
+ const x3 = checkedReferenceValue(S, readMember(v[3], "columnIndex"), RC3, "expression:$active.columnIndex:active.columnIndex", "active.columnIndex");
181
214
  if (x3 !== NONCONFORMING) {
182
215
  const s3 = toAttribute(x3, "data-column-index");
183
216
  if (s3 !== r.v3) writeAttribute(r.n, "data-column-index", r.v3 = s3);
@@ -186,10 +219,18 @@ export function createUiEditorTableOverlay(options = {}, html) {
186
219
  };
187
220
  const p0 = (r, c, d) => {
188
221
  if (c & 64) {
189
- const x0 = !truthy(v[6]);
190
- const s0 = toAttribute(x0, "hidden");
191
- if (s0 !== r.v0) writeAttribute(r.n, "hidden", r.v0 = s0);
222
+ resetForwardedAttributes(r.n, attributes, r.v0);
223
+ r.v0 = forwardAttributes(r.n, attributes);
224
+ const x0 = "Table controls";
225
+ const s1 = toAttribute(x0, "aria-label");
226
+ writeAttribute(r.n, "aria-label", r.v1 = s1);
227
+ const x1 = !truthy(v[6]);
228
+ const s2 = toAttribute(x1, "hidden");
229
+ writeAttribute(r.n, "hidden", r.v2 = s2);
192
230
  }
231
+ if (r.f0 === undefined) { r.f0 = 1; const at = fillSlot(r.a1, r.e0, "", J, false, undefined, d);
232
+ 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); } }
233
+ else if (r.b0 !== undefined) p1(r.b0, c, d);
193
234
  if (c & 1073741825) r.L1.update(v[0], d, c);
194
235
  if (c !== -1 && c & 16) visitSelected(r.L1.m, s4, v[4], p2, c);
195
236
  if (c & 1073741826) r.L2.update(v[1], d, c);
@@ -202,9 +243,6 @@ export function createUiEditorTableOverlay(options = {}, html) {
202
243
  if (r.b4) { r.b4 = undefined; clearRegion(r.a5, r.e4); }
203
244
  else { r.b4 = m5(d); r.e4.before(r.b4.n); }
204
245
  } else if (r.b4 !== undefined) p5(r.b4, c, d);
205
- if (r.f0 === undefined) { r.f0 = 1; const at = fillSlot(r.a1, r.e0, "", J, false, undefined, d);
206
- 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); } }
207
- else if (r.b0 !== undefined) p1(r.b0, c, d);
208
246
  s4 = v[4];
209
247
  };
210
248
  const t0 = element.firstChild.nextSibling;
@@ -214,10 +252,11 @@ export function createUiEditorTableOverlay(options = {}, html) {
214
252
  const t4 = t3.firstChild.nextSibling;
215
253
  const t5 = t3.nextSibling.nextSibling;
216
254
  const t6 = t5.nextSibling.nextSibling.nextSibling;
217
- const R = { n: element, v0: undefined, a1: t0, e0: t0.nextSibling, b0: undefined, f0: undefined, L1: new KeyedList(t2, t2.nextSibling, m2, p2, (o) => readMember(o, "key"), "control"), L2: new KeyedList(t4, t4.nextSibling, m3, p3, (o) => readMember(o, "key"), "control"), a4: t5, e3: t5.nextSibling, b3: undefined, a5: t6, e4: t6.nextSibling, b4: undefined };
255
+ const R = { n: element, v0: undefined, v1: undefined, v2: undefined, a1: t0, e0: t0.nextSibling, b0: undefined, f0: undefined, L1: new KeyedList(t2, t2.nextSibling, m2, p2, (o) => readMember(o, "key"), "control"), L2: new KeyedList(t4, t4.nextSibling, m3, p3, (o) => readMember(o, "key"), "control"), a4: t5, e3: t5.nextSibling, b3: undefined, a5: t6, e4: t6.nextSibling, b4: undefined };
218
256
  const I = { B };
219
257
  const J = project(I, children, slots);
220
258
  I.R = new Set();
259
+ I.F = { values: attributes, draw: () => ((c, d) => p0(R, c, d))(-1) };
221
260
  attachGeneratedController(element, S, v, (c, d) => { ((c, d) => p0(R, c, d))(c, d); for (const f of I.R) f(c, d); }, undefined, undefined, I);
222
261
  manageProps(I);
223
262
  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 UiEditorTableToolbarEventMap {
3
3
  action: CustomEvent<{ readonly action: "align-left" | "align-center" | "align-right" | "background-none" | "background-gray" | "background-yellow" | "background-blue" | "background-green" | "background-red" | "add-row-before" | "add-row-after" | "add-column-before" | "add-column-after" | "toggle-header-row" | "toggle-header-column" | "move-row-up" | "move-row-down" | "move-column-left" | "move-column-right" | "clear-cells" | "merge-cells" | "split-cell" | "delete-row" | "delete-column" | "delete-table" }>;
4
4
  }
@@ -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, KeyedList, NONCONFORMING, readIndex, readMember, textCall, toAttribute, toText, trackContainer, truthy, writeAttribute, dispatchDeclared, detailCheck, formatOf, keywordFormat, acceptProps, manageProps, generatedInputs, checkBoolean, checkConstrained, checkFormat, checkList, 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, checkedReferenceValue, buildTemplate, clearRegion, KeyedList, NONCONFORMING, notValue, readIndex, readMember, recordValue, textCall, toAttribute, toText, trackContainer, truthy, truthyValue, writeAttribute, dispatchDeclared, detailCheck, formatOf, keywordFormat, acceptProps, manageProps, generatedInputs, checkBoolean, checkConstrained, checkFormat, checkList, checkObject, checkString, forwardAttributes, resetForwardedAttributes, defineComponent, activateModule } from "@nextwebwg/html-next/generated-runtime";
3
3
  import * as controller from "../components/ui-editor-table-toolbar/ui-editor-table-toolbar.js";
4
4
  import "../styles/ui-editor-table-toolbar.css";
5
5
 
@@ -16,6 +16,11 @@ const T9 = ["div",["class","menu-section","role","none"],"\n ",["div",[
16
16
  const T10 = ["button",["type","button","class","swatch-button","role","menuitemradio"],"\n ",["span",["class","swatch"]],"\n ",["span",[],0],"\n "];
17
17
  const T11 = ["div",["class","menu-section divided","role","none"],"\n ",["div",["class","menu-heading","role","presentation"],0],"\n ",2,"\n "];
18
18
  const T12 = ["button",["type","button"],"\n ",["ui-icon",[]],"\n ",["span",[],0],"\n "];
19
+ const RC0 = ["b", "boolean"];
20
+ const RC1 = [["p",formatOf(keywordFormat)], "keyword with values align-left, align-center, align-right"];
21
+ const RC2 = ["s", "string"];
22
+ const RC3 = [["p",formatOf(keywordFormat)], "keyword with values add-row-after, add-column-after"];
23
+ const RC4 = [["l"], "list(object({ action: string, label: string, icon: string, danger: boolean, checkable: boolean, checked: boolean }))"];
19
24
  let P0, P1, P2, P3, P4, P5, P6, P7, P8, P9, P10, P11, P12;
20
25
  const emptyDirty = new Map();
21
26
  const S = { n: ["alignments","structure","swatches","sections","hasOverflow","overflowOpen"], t: [["l",["o",["action",["p",formatOf(keywordFormat)],"label","s","active","b"]]],["l",["o",["action",["p",formatOf(keywordFormat)],"label","s","icon","s"]]],["l",["o",["action","s","label","s","color","s","selected","b"]]],["l",["o",["heading","s","items",["l",["o",["action","s","label","s","icon","s","danger","b","checkable","b","checked","b"]]]]]],"b","b"], f: import.meta.url, g: "ui-editor-table-toolbar", d: { "action": [detailCheck(checkObject([["action", checkConstrained(checkFormat("keyword", keywordFormat), "keyword", {"values":["align-left","align-center","align-right","background-none","background-gray","background-yellow","background-blue","background-green","background-red","add-row-before","add-row-after","add-column-before","add-column-after","toggle-header-row","toggle-header-column","move-row-up","move-row-down","move-column-left","move-column-right","clear-cells","merge-cells","split-cell","delete-row","delete-column","delete-table"]}), false]], false)), true, true, false] }, x: dispatchDeclared, a: (host, I) => C(host, I), b: generatedInputs, i: [[], [], [], [], false, false] };
@@ -23,12 +28,9 @@ const D = { g: "ui-editor-table-toolbar", props: { "actions": { "required":false
23
28
  const C = (host) => activateModule(controller, host);
24
29
 
25
30
  export function createUiEditorTableToolbar(options = {}, html) {
26
- const { attributes = {}, children = [], slots = {}, ...componentProps } = options;
31
+ const { attributes: authoredAttributes = {}, children = [], slots = {}, ...componentProps } = options;
32
+ const attributes = Object.fromEntries([...[], ...Object.entries(authoredAttributes)].filter(([name]) => !["actions","cell-alignment","cell-background","header-column","header-row","open"].includes(name)));
27
33
  const element = document.createElement("div");
28
- for (const [name, value] of Object.entries(attributes)) {
29
- if (value === null || value === undefined || value === false) continue;
30
- element.setAttribute(name, value === true ? "" : String(value));
31
- }
32
34
  if (!element.hasAttribute("role")) element.setAttribute("role", "toolbar");
33
35
  if (!element.hasAttribute("aria-label")) element.setAttribute("aria-label", "Table actions");
34
36
  element.setAttribute("component", "ui-editor-table-toolbar");
@@ -56,21 +58,33 @@ export function createUiEditorTableToolbar(options = {}, html) {
56
58
  const o = r.i;
57
59
  if (c & 1073741824) {
58
60
  r.w = 0;
59
- const x0 = trackContainer(r, readMember(o, "active"));
60
- const s0 = truthy(x0);
61
- if (s0 !== r.v0) r.n.classList.toggle("active", r.v0 = s0);
62
- const x1 = trackContainer(r, readMember(o, "action"));
63
- const s1 = toAttribute(x1, "data-action");
64
- if (s1 !== r.v1) writeAttribute(r.n, "data-action", r.v1 = s1);
65
- const x2 = trackContainer(r, readMember(o, "label"));
66
- const s2 = toAttribute(x2, "aria-label");
67
- if (s2 !== r.v2) writeAttribute(r.n, "aria-label", r.v2 = s2);
68
- const s3 = toAttribute(x2, "title");
69
- if (s3 !== r.v3) writeAttribute(r.n, "title", r.v3 = s3);
70
- const s4 = toAttribute(x0, "aria-pressed");
71
- if (s4 !== r.v4) writeAttribute(r.n, "aria-pressed", r.v4 = s4);
72
- const s5 = toAttribute(x1, "name");
73
- if (s5 !== r.v5) writeAttribute(r.a1, "name", r.v5 = s5);
61
+ const x0 = trackContainer(r, checkedReferenceValue(S, readMember(o, "active"), RC0, "expression:$item.active:item.active", "item.active"));
62
+ if (x0 !== NONCONFORMING) {
63
+ const s0 = truthy(x0);
64
+ if (s0 !== r.v0) r.n.classList.toggle("active", r.v0 = s0);
65
+ }
66
+ const x1 = trackContainer(r, checkedReferenceValue(S, readMember(o, "action"), RC1, "expression:$item.action:item.action", "item.action"));
67
+ if (x1 !== NONCONFORMING) {
68
+ const s1 = toAttribute(x1, "data-action");
69
+ if (s1 !== r.v1) writeAttribute(r.n, "data-action", r.v1 = s1);
70
+ }
71
+ const x2 = trackContainer(r, checkedReferenceValue(S, readMember(o, "label"), RC2, "expression:$item.label:item.label", "item.label"));
72
+ if (x2 !== NONCONFORMING) {
73
+ const s2 = toAttribute(x2, "aria-label");
74
+ if (s2 !== r.v2) writeAttribute(r.n, "aria-label", r.v2 = s2);
75
+ }
76
+ if (x2 !== NONCONFORMING) {
77
+ const s3 = toAttribute(x2, "title");
78
+ if (s3 !== r.v3) writeAttribute(r.n, "title", r.v3 = s3);
79
+ }
80
+ if (x0 !== NONCONFORMING) {
81
+ const s4 = toAttribute(x0, "aria-pressed");
82
+ if (s4 !== r.v4) writeAttribute(r.n, "aria-pressed", r.v4 = s4);
83
+ }
84
+ if (x1 !== NONCONFORMING) {
85
+ const s5 = toAttribute(x1, "name");
86
+ if (s5 !== r.v5) writeAttribute(r.a1, "name", r.v5 = s5);
87
+ }
74
88
  }
75
89
  };
76
90
  const m3 = (d) => {
@@ -103,15 +117,21 @@ export function createUiEditorTableToolbar(options = {}, html) {
103
117
  const o = r.i;
104
118
  if (c & 1073741824) {
105
119
  r.w = 0;
106
- const x0 = trackContainer(r, readMember(o, "action"));
107
- const s0 = toAttribute(x0, "data-action");
108
- if (s0 !== r.v0) writeAttribute(r.n, "data-action", r.v0 = s0);
109
- const x1 = trackContainer(r, readMember(o, "icon"));
110
- const s1 = toAttribute(x1, "name");
111
- if (s1 !== r.v1) writeAttribute(r.a1, "name", r.v1 = s1);
112
- const x2 = trackContainer(r, readMember(o, "label"));
113
- const s2 = toText(x2);
114
- if (s2 !== r.v2) r.a2.data = r.v2 = s2;
120
+ const x0 = trackContainer(r, checkedReferenceValue(S, readMember(o, "action"), RC3, "expression:$item.action:item.action", "item.action"));
121
+ if (x0 !== NONCONFORMING) {
122
+ const s0 = toAttribute(x0, "data-action");
123
+ if (s0 !== r.v0) writeAttribute(r.n, "data-action", r.v0 = s0);
124
+ }
125
+ const x1 = trackContainer(r, checkedReferenceValue(S, readMember(o, "icon"), RC2, "expression:$item.icon:item.icon", "item.icon"));
126
+ if (x1 !== NONCONFORMING) {
127
+ const s1 = toAttribute(x1, "name");
128
+ if (s1 !== r.v1) writeAttribute(r.a1, "name", r.v1 = s1);
129
+ }
130
+ const x2 = trackContainer(r, checkedReferenceValue(S, readMember(o, "label"), RC2, "expression:$item.label:item.label", "item.label"));
131
+ if (x2 !== NONCONFORMING) {
132
+ const s2 = toText(x2);
133
+ if (s2 !== r.v2) r.a2.data = r.v2 = s2;
134
+ }
115
135
  }
116
136
  };
117
137
  const m6 = (d) => {
@@ -178,23 +198,35 @@ export function createUiEditorTableToolbar(options = {}, html) {
178
198
  const o = r.i;
179
199
  if (c & 1073741824) {
180
200
  r.w = 0;
181
- const x0 = trackContainer(r, readMember(o, "selected"));
182
- const s0 = truthy(x0);
183
- if (s0 !== r.v0) r.n.classList.toggle("selected", r.v0 = s0);
184
- const s1 = toAttribute(x0, "aria-checked");
185
- if (s1 !== r.v1) writeAttribute(r.n, "aria-checked", r.v1 = s1);
186
- const x1 = trackContainer(r, readMember(o, "action"));
187
- const s2 = toAttribute(x1, "data-action");
188
- if (s2 !== r.v2) writeAttribute(r.n, "data-action", r.v2 = s2);
189
- const x2 = !truthy(trackContainer(r, readMember(o, "color")));
190
- const s3 = x2;
191
- if (s3 !== r.v3) r.a1.classList.toggle("default", r.v3 = s3);
192
- const x3 = trackContainer(r, readMember(o, "color"));
193
- const s4 = toText(x3);
194
- if (s4 !== r.v4) r.a1.style.setProperty("--_swatch", r.v4 = s4);
195
- const x4 = trackContainer(r, readMember(o, "label"));
196
- const s5 = toText(x4);
197
- if (s5 !== r.v5) r.a2.data = r.v5 = s5;
201
+ const x0 = trackContainer(r, checkedReferenceValue(S, readMember(o, "selected"), RC0, "expression:$swatch.selected:swatch.selected", "swatch.selected"));
202
+ if (x0 !== NONCONFORMING) {
203
+ const s0 = truthy(x0);
204
+ if (s0 !== r.v0) r.n.classList.toggle("selected", r.v0 = s0);
205
+ }
206
+ if (x0 !== NONCONFORMING) {
207
+ const s1 = toAttribute(x0, "aria-checked");
208
+ if (s1 !== r.v1) writeAttribute(r.n, "aria-checked", r.v1 = s1);
209
+ }
210
+ const x1 = trackContainer(r, checkedReferenceValue(S, readMember(o, "action"), RC2, "expression:$swatch.action:swatch.action", "swatch.action"));
211
+ if (x1 !== NONCONFORMING) {
212
+ const s2 = toAttribute(x1, "data-action");
213
+ if (s2 !== r.v2) writeAttribute(r.n, "data-action", r.v2 = s2);
214
+ }
215
+ const x2 = notValue(truthyValue(trackContainer(r, checkedReferenceValue(S, readMember(o, "color"), RC2, "expression:not $swatch.color:swatch.color", "swatch.color"))));
216
+ if (x2 !== NONCONFORMING) {
217
+ const s3 = truthy(x2);
218
+ if (s3 !== r.v3) r.a1.classList.toggle("default", r.v3 = s3);
219
+ }
220
+ const x3 = trackContainer(r, checkedReferenceValue(S, readMember(o, "color"), RC2, "expression:$swatch.color:swatch.color", "swatch.color"));
221
+ if (x3 !== NONCONFORMING) {
222
+ const s4 = toText(x3);
223
+ if (s4 !== r.v4) r.a1.style.setProperty("--_swatch", r.v4 = s4);
224
+ }
225
+ const x4 = trackContainer(r, checkedReferenceValue(S, readMember(o, "label"), RC2, "expression:$swatch.label:swatch.label", "swatch.label"));
226
+ if (x4 !== NONCONFORMING) {
227
+ const s5 = toText(x4);
228
+ if (s5 !== r.v5) r.a2.data = r.v5 = s5;
229
+ }
198
230
  }
199
231
  };
200
232
  const m11 = (o, j, l) => {
@@ -210,11 +242,13 @@ export function createUiEditorTableToolbar(options = {}, html) {
210
242
  const o = r.i;
211
243
  if (c & 1073741824) {
212
244
  r.w = 0;
213
- const x0 = trackContainer(r, readMember(o, "heading"));
214
- const s0 = toText(x0);
215
- if (s0 !== r.v0) r.a0.data = r.v0 = s0;
245
+ const x0 = trackContainer(r, checkedReferenceValue(S, readMember(o, "heading"), RC2, "expression:$section.heading:section.heading", "section.heading"));
246
+ if (x0 !== NONCONFORMING) {
247
+ const s0 = toText(x0);
248
+ if (s0 !== r.v0) r.a0.data = r.v0 = s0;
249
+ }
216
250
  }
217
- if (c & 1073741824) r.L0.update(readMember(o, "items"), d, c);
251
+ if (c & 1073741824) { const l = checkedReferenceValue(S, readMember(o, "items"), RC4, "expression:$section.items:section.items", "section.items"); if (l !== NONCONFORMING) { r.L0.update(l, d, c); } }
218
252
  };
219
253
  const m12 = (o, j, l) => {
220
254
  const n = (P12 ??= buildTemplate(T12)).cloneNode(true);
@@ -228,35 +262,51 @@ export function createUiEditorTableToolbar(options = {}, html) {
228
262
  const o = r.i;
229
263
  if (c & 1073741824) {
230
264
  r.w = 0;
231
- const x0 = trackContainer(r, readIndex({ "true": "menuitemcheckbox", "false": "menuitem" }, textCall("concat", [trackContainer(r, readMember(o, "checkable"))])));
265
+ const x0 = trackContainer(r, readIndex({ "true": "menuitemcheckbox", "false": "menuitem" }, textCall("concat", [trackContainer(r, checkedReferenceValue(S, readMember(o, "checkable"), RC0, "expression:{ true: 'menuitemcheckbox', false: 'menuitem' }[concat($item.checkable)]:item.checkable", "item.checkable"))])));
232
266
  if (x0 !== NONCONFORMING) {
233
267
  const s0 = toAttribute(x0, "role");
234
268
  if (s0 !== r.v0) writeAttribute(r.n, "role", r.v0 = s0);
235
269
  }
236
- const x1 = trackContainer(r, readIndex({ "true": readMember(o, "checked"), "false": null }, textCall("concat", [trackContainer(r, readMember(o, "checkable"))])));
270
+ const x1 = trackContainer(r, readIndex(recordValue(["true","false"], [checkedReferenceValue(S, readMember(o, "checked"), RC0, "expression:{ true: $item.checked, false: null }[concat($item.checkable)]:item.checked", "item.checked"), null]), textCall("concat", [trackContainer(r, checkedReferenceValue(S, readMember(o, "checkable"), RC0, "expression:{ true: $item.checked, false: null }[concat($item.checkable)]:item.checkable", "item.checkable"))])));
237
271
  if (x1 !== NONCONFORMING) {
238
272
  const s1 = toAttribute(x1, "aria-checked");
239
273
  if (s1 !== r.v1) writeAttribute(r.n, "aria-checked", r.v1 = s1);
240
274
  }
241
- const x2 = trackContainer(r, readMember(o, "danger"));
242
- const s2 = truthy(x2);
243
- if (s2 !== r.v2) r.n.classList.toggle("danger", r.v2 = s2);
244
- const x3 = trackContainer(r, readMember(o, "action"));
245
- const s3 = toAttribute(x3, "data-action");
246
- if (s3 !== r.v3) writeAttribute(r.n, "data-action", r.v3 = s3);
247
- const x4 = trackContainer(r, readMember(o, "icon"));
248
- const s4 = toAttribute(x4, "name");
249
- if (s4 !== r.v4) writeAttribute(r.a1, "name", r.v4 = s4);
250
- const x5 = trackContainer(r, readMember(o, "label"));
251
- const s5 = toText(x5);
252
- if (s5 !== r.v5) r.a2.data = r.v5 = s5;
275
+ const x2 = trackContainer(r, checkedReferenceValue(S, readMember(o, "danger"), RC0, "expression:$item.danger:item.danger", "item.danger"));
276
+ if (x2 !== NONCONFORMING) {
277
+ const s2 = truthy(x2);
278
+ if (s2 !== r.v2) r.n.classList.toggle("danger", r.v2 = s2);
279
+ }
280
+ const x3 = trackContainer(r, checkedReferenceValue(S, readMember(o, "action"), RC2, "expression:$item.action:item.action", "item.action"));
281
+ if (x3 !== NONCONFORMING) {
282
+ const s3 = toAttribute(x3, "data-action");
283
+ if (s3 !== r.v3) writeAttribute(r.n, "data-action", r.v3 = s3);
284
+ }
285
+ const x4 = trackContainer(r, checkedReferenceValue(S, readMember(o, "icon"), RC2, "expression:$item.icon:item.icon", "item.icon"));
286
+ if (x4 !== NONCONFORMING) {
287
+ const s4 = toAttribute(x4, "name");
288
+ if (s4 !== r.v4) writeAttribute(r.a1, "name", r.v4 = s4);
289
+ }
290
+ const x5 = trackContainer(r, checkedReferenceValue(S, readMember(o, "label"), RC2, "expression:$item.label:item.label", "item.label"));
291
+ if (x5 !== NONCONFORMING) {
292
+ const s5 = toText(x5);
293
+ if (s5 !== r.v5) r.a2.data = r.v5 = s5;
294
+ }
253
295
  }
254
296
  };
255
297
  const p0 = (r, c, d) => {
256
298
  if (c & 2048) {
257
- const x0 = !truthy(v[11]);
258
- const s0 = toAttribute(x0, "hidden");
259
- if (s0 !== r.v0) writeAttribute(r.n, "hidden", r.v0 = s0);
299
+ resetForwardedAttributes(r.n, attributes, r.v0);
300
+ r.v0 = forwardAttributes(r.n, attributes);
301
+ const x0 = "toolbar";
302
+ const s1 = toAttribute(x0, "role");
303
+ writeAttribute(r.n, "role", r.v1 = s1);
304
+ const x1 = "Table actions";
305
+ const s2 = toAttribute(x1, "aria-label");
306
+ writeAttribute(r.n, "aria-label", r.v2 = s2);
307
+ const x2 = !truthy(v[11]);
308
+ const s3 = toAttribute(x2, "hidden");
309
+ writeAttribute(r.n, "hidden", r.v3 = s3);
260
310
  }
261
311
  if (c & 1073741825 && !(truthy(v[0])) !== !r.b0) {
262
312
  if (r.b0) { r.b0 = undefined; clearRegion(r.a1, r.e0); }
@@ -284,9 +334,10 @@ export function createUiEditorTableToolbar(options = {}, html) {
284
334
  const t2 = t1.nextSibling.nextSibling.nextSibling;
285
335
  const t3 = t2.nextSibling.nextSibling.nextSibling;
286
336
  const t4 = t3.nextSibling.nextSibling.nextSibling;
287
- const R = { n: element, v0: undefined, a1: t0, e0: t0.nextSibling, b0: undefined, a2: t1, e1: t1.nextSibling, b1: undefined, a3: t2, e2: t2.nextSibling, b2: undefined, a4: t3, e3: t3.nextSibling, b3: undefined, a5: t4, e4: t4.nextSibling, b4: undefined };
337
+ const R = { n: element, v0: undefined, v1: undefined, v2: undefined, v3: undefined, a1: t0, e0: t0.nextSibling, b0: undefined, a2: t1, e1: t1.nextSibling, b1: undefined, a3: t2, e2: t2.nextSibling, b2: undefined, a4: t3, e3: t3.nextSibling, b3: undefined, a5: t4, e4: t4.nextSibling, b4: undefined };
288
338
  const I = { B };
289
339
  I.R = new Set();
340
+ I.F = { values: attributes, draw: () => ((c, d) => p0(R, c, d))(-1) };
290
341
  attachGeneratedController(element, S, v, (c, d) => { ((c, d) => p0(R, c, d))(c, d); for (const f of I.R) f(c, d); }, undefined, undefined, I);
291
342
  manageProps(I);
292
343
  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 UiEditorToolbarEventMap {
3
3
  }
4
4
  export interface UiEditorToolbarElement extends HTMLDivElement {