@threadlabs/looma 0.47.5 → 0.49.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 (933) hide show
  1. package/README.md +39 -16
  2. package/components/shared/input-modality.d.ts +2 -0
  3. package/components/shared/input-modality.js +2 -0
  4. package/components/shared/overlay.js +9 -0
  5. package/components/ui-card/ui-card.html +8 -0
  6. package/components/ui-compact-content/ui-compact-content.html +8 -0
  7. package/components/ui-compact-content/ui-compact-content.js +1 -0
  8. package/components/ui-compact-editor/ui-compact-editor.css +39 -0
  9. package/components/ui-compact-editor/ui-compact-editor.html +22 -0
  10. package/components/ui-compact-editor/ui-compact-editor.js +30 -0
  11. package/components/ui-compact-mark/ui-compact-mark.html +26 -0
  12. package/components/ui-compact-node/ui-compact-node.html +14 -0
  13. package/components/ui-dialog/ui-dialog.html +4 -1
  14. package/components/ui-editor/ui-editor.css +531 -0
  15. package/components/ui-editor/ui-editor.html +399 -0
  16. package/components/ui-editor/ui-editor.js +87 -0
  17. package/components/ui-editor-chip-editor/ui-editor-chip-editor.html +2 -1
  18. package/components/ui-editor-chip-editor/ui-editor-chip-editor.js +6 -0
  19. package/components/ui-editor-formatting-tools/ui-editor-formatting-tools.html +59 -0
  20. package/components/ui-editor-formatting-tools/ui-editor-formatting-tools.js +44 -0
  21. package/components/ui-editor-link-form/ui-editor-link-form.html +1 -0
  22. package/components/ui-editor-link-form/ui-editor-link-form.js +7 -0
  23. package/components/ui-editor-surface/ui-editor-surface.css +109 -0
  24. package/components/ui-editor-table-context-menu/ui-editor-table-context-menu.html +1 -1
  25. package/components/ui-editor-table-toolbar/ui-editor-table-toolbar.js +7 -4
  26. package/components/ui-menu/ui-menu.html +4 -1
  27. package/components/ui-meter/ui-meter.html +7 -7
  28. package/components/ui-popover/ui-popover.html +4 -1
  29. package/components/ui-radio-group/ui-radio-group.html +3 -1
  30. package/components/ui-radio-group/ui-radio-group.js +5 -0
  31. package/dist/index.js +57 -53
  32. package/docs/README.md +5 -7
  33. package/docs/catalog.json +945 -86
  34. package/docs/catalog.mjs +2 -2
  35. package/docs/framework-examples.d.mts +7 -0
  36. package/docs/framework-examples.mjs +89 -0
  37. package/docs/index.d.ts +1 -1
  38. package/docs/render.mjs +3 -40
  39. package/editor/chunks/content.js +29 -0
  40. package/{vue/chunks/compact.js → editor/chunks/dist.js} +103 -230
  41. package/editor/chunks/expressmark.js +1 -24
  42. package/editor/chunks/extensions.js +63 -455
  43. package/editor/chunks/session.js +61 -0
  44. package/editor/chunks/{ui.js → table-overlay.js} +51 -1
  45. package/editor/compact.d.ts +22 -0
  46. package/editor/compact.js +63 -0
  47. package/editor/components.css +3699 -0
  48. package/editor/document-session.d.ts +274 -0
  49. package/editor/extensions/index.js +2 -2
  50. package/editor/index.d.ts +4 -0
  51. package/editor/index.js +15578 -4
  52. package/editor/session.d.ts +1 -1
  53. package/editor/toolbar-tooltip.d.ts +5 -1
  54. package/editor/ui.js +1 -2
  55. package/package.json +31 -46
  56. package/styles/ui-action-bar.css +1 -1
  57. package/styles/ui-affordance-scope.css +1 -1
  58. package/styles/ui-avatar-group.css +1 -1
  59. package/styles/ui-avatar.css +1 -1
  60. package/styles/ui-badge.css +1 -1
  61. package/styles/ui-breadcrumb-item.css +1 -1
  62. package/styles/ui-breadcrumbs.css +1 -1
  63. package/styles/ui-button.css +1 -1
  64. package/styles/ui-callout.css +1 -1
  65. package/styles/ui-card-group.css +1 -1
  66. package/styles/ui-card.css +9 -1
  67. package/styles/ui-checkbox.css +1 -1
  68. package/styles/ui-cluster.css +1 -1
  69. package/styles/ui-color-picker.css +1 -1
  70. package/styles/ui-combobox.css +1 -1
  71. package/styles/ui-compact-content.css +1 -0
  72. package/styles/ui-compact-editor.css +1 -0
  73. package/styles/ui-compact-mark.css +1 -0
  74. package/styles/ui-compact-node.css +1 -0
  75. package/styles/ui-container.css +1 -1
  76. package/styles/ui-context-menu.css +1 -1
  77. package/styles/ui-cover.css +1 -1
  78. package/styles/ui-curve-editor.css +1 -1
  79. package/styles/ui-cycle-button.css +1 -1
  80. package/styles/ui-description-item.css +1 -1
  81. package/styles/ui-description-list.css +1 -1
  82. package/styles/ui-dialog.css +9 -3
  83. package/styles/ui-disclosure.css +1 -1
  84. package/styles/ui-editable.css +1 -1
  85. package/styles/ui-editor-block-actions.css +1 -1
  86. package/styles/ui-editor-chip-editor.css +1 -1
  87. package/styles/ui-editor-code-language.css +1 -1
  88. package/styles/ui-editor-footnote-editor.css +1 -1
  89. package/styles/ui-editor-formatting-tools.css +1 -0
  90. package/styles/ui-editor-image-toolbar.css +1 -1
  91. package/styles/ui-editor-insert-table-grid.css +1 -1
  92. package/styles/ui-editor-link-card.css +1 -1
  93. package/styles/ui-editor-link-form.css +1 -1
  94. package/styles/ui-editor-mention-menu-item.css +1 -1
  95. package/styles/ui-editor-mention-menu.css +1 -1
  96. package/styles/ui-editor-slash-menu-group.css +1 -1
  97. package/styles/ui-editor-slash-menu-item.css +1 -1
  98. package/styles/ui-editor-slash-menu.css +1 -1
  99. package/styles/ui-editor-surface.css +1 -1
  100. package/styles/ui-editor-table-context-menu.css +1 -1
  101. package/styles/ui-editor-table-overlay.css +1 -1
  102. package/styles/ui-editor-table-toolbar.css +1 -1
  103. package/styles/ui-editor-toolbar.css +1 -1
  104. package/styles/ui-editor.css +1 -0
  105. package/styles/ui-floating-action-button.css +1 -1
  106. package/styles/ui-form-field.css +1 -1
  107. package/styles/ui-grid.css +1 -1
  108. package/styles/ui-icon-button.css +1 -1
  109. package/styles/ui-icon.css +1 -1
  110. package/styles/ui-image.css +1 -1
  111. package/styles/ui-input-group.css +1 -1
  112. package/styles/ui-input.css +1 -1
  113. package/styles/ui-light-editor.css +1 -1
  114. package/styles/ui-list-item.css +1 -1
  115. package/styles/ui-list.css +1 -1
  116. package/styles/ui-listbox.css +1 -1
  117. package/styles/ui-menu-group.css +1 -1
  118. package/styles/ui-menu-item.css +1 -1
  119. package/styles/ui-menu.css +5 -2
  120. package/styles/ui-meter.css +8 -8
  121. package/styles/ui-nav-item.css +1 -1
  122. package/styles/ui-number-input.css +1 -1
  123. package/styles/ui-page-header.css +1 -1
  124. package/styles/ui-pagination.css +1 -1
  125. package/styles/ui-popover.css +5 -2
  126. package/styles/ui-radio-group.css +1 -1
  127. package/styles/ui-radio.css +1 -1
  128. package/styles/ui-reel.css +1 -1
  129. package/styles/ui-scroll-area.css +1 -1
  130. package/styles/ui-search-result-row.css +1 -1
  131. package/styles/ui-search-shell.css +1 -1
  132. package/styles/ui-section.css +1 -1
  133. package/styles/ui-select.css +1 -1
  134. package/styles/ui-separator.css +1 -1
  135. package/styles/ui-sidebar.css +1 -1
  136. package/styles/ui-site-header.css +1 -1
  137. package/styles/ui-skeleton.css +1 -1
  138. package/styles/ui-slider.css +1 -1
  139. package/styles/ui-spinner.css +1 -1
  140. package/styles/ui-stack.css +1 -1
  141. package/styles/ui-status-message.css +1 -1
  142. package/styles/ui-swatch.css +1 -1
  143. package/styles/ui-switch.css +1 -1
  144. package/styles/ui-switcher.css +1 -1
  145. package/styles/ui-table.css +1 -1
  146. package/styles/ui-tabs.css +1 -1
  147. package/styles/ui-text.css +1 -1
  148. package/styles/ui-textarea.css +1 -1
  149. package/styles/ui-toast-region.css +1 -1
  150. package/styles/ui-toast.css +1 -1
  151. package/styles/ui-tooltip.css +1 -1
  152. package/styles/ui-top-bar.css +1 -1
  153. package/styles/ui-tree-item.css +1 -1
  154. package/styles/ui-tree.css +1 -1
  155. package/vanilla/UiActionBar.d.ts +1 -1
  156. package/vanilla/UiActionBar.js +1 -1
  157. package/vanilla/UiAffordanceScope.d.ts +1 -1
  158. package/vanilla/UiAffordanceScope.js +1 -1
  159. package/vanilla/UiAvatar.d.ts +1 -1
  160. package/vanilla/UiAvatar.js +1 -1
  161. package/vanilla/UiAvatarGroup.d.ts +1 -1
  162. package/vanilla/UiAvatarGroup.js +1 -1
  163. package/vanilla/UiBadge.d.ts +1 -1
  164. package/vanilla/UiBadge.js +1 -1
  165. package/vanilla/UiBreadcrumbItem.d.ts +1 -1
  166. package/vanilla/UiBreadcrumbItem.js +1 -1
  167. package/vanilla/UiBreadcrumbs.d.ts +1 -1
  168. package/vanilla/UiBreadcrumbs.js +1 -1
  169. package/vanilla/UiButton.d.ts +1 -1
  170. package/vanilla/UiButton.js +1 -1
  171. package/vanilla/UiCallout.d.ts +1 -1
  172. package/vanilla/UiCallout.js +1 -1
  173. package/vanilla/UiCard.d.ts +1 -1
  174. package/vanilla/UiCard.js +1 -1
  175. package/vanilla/UiCardGroup.d.ts +1 -1
  176. package/vanilla/UiCardGroup.js +1 -1
  177. package/vanilla/UiCheckbox.d.ts +1 -1
  178. package/vanilla/UiCheckbox.js +1 -1
  179. package/vanilla/UiCluster.d.ts +1 -1
  180. package/vanilla/UiCluster.js +1 -1
  181. package/vanilla/UiColorPicker.d.ts +1 -1
  182. package/vanilla/UiColorPicker.js +1 -1
  183. package/vanilla/UiCombobox.d.ts +1 -1
  184. package/vanilla/UiCombobox.js +1 -1
  185. package/vanilla/UiCompactContent.d.ts +23 -0
  186. package/vanilla/UiCompactContent.js +51 -0
  187. package/vanilla/UiCompactEditor.d.ts +29 -0
  188. package/vanilla/UiCompactEditor.js +59 -0
  189. package/vanilla/UiCompactMark.d.ts +25 -0
  190. package/vanilla/UiCompactMark.js +206 -0
  191. package/vanilla/UiCompactNode.d.ts +23 -0
  192. package/vanilla/UiCompactNode.js +156 -0
  193. package/vanilla/UiContainer.d.ts +1 -1
  194. package/vanilla/UiContainer.js +1 -1
  195. package/vanilla/UiContextMenu.d.ts +1 -1
  196. package/vanilla/UiContextMenu.js +1 -1
  197. package/vanilla/UiCover.d.ts +1 -1
  198. package/vanilla/UiCover.js +1 -1
  199. package/vanilla/UiCurveEditor.d.ts +1 -1
  200. package/vanilla/UiCurveEditor.js +1 -1
  201. package/vanilla/UiCycleButton.d.ts +1 -1
  202. package/vanilla/UiCycleButton.js +1 -1
  203. package/vanilla/UiDescriptionItem.d.ts +1 -1
  204. package/vanilla/UiDescriptionItem.js +1 -1
  205. package/vanilla/UiDescriptionList.d.ts +1 -1
  206. package/vanilla/UiDescriptionList.js +1 -1
  207. package/vanilla/UiDialog.d.ts +1 -1
  208. package/vanilla/UiDialog.js +1 -1
  209. package/vanilla/UiDisclosure.d.ts +1 -1
  210. package/vanilla/UiDisclosure.js +1 -1
  211. package/vanilla/UiEditable.d.ts +1 -1
  212. package/vanilla/UiEditable.js +1 -1
  213. package/vanilla/UiEditor.d.ts +57 -0
  214. package/vanilla/UiEditor.js +1067 -0
  215. package/vanilla/UiEditorBlockActions.d.ts +1 -1
  216. package/vanilla/UiEditorBlockActions.js +1 -1
  217. package/vanilla/UiEditorChipEditor.d.ts +2 -1
  218. package/vanilla/UiEditorChipEditor.js +10 -10
  219. package/vanilla/UiEditorCodeLanguage.d.ts +1 -1
  220. package/vanilla/UiEditorCodeLanguage.js +1 -1
  221. package/vanilla/UiEditorFootnoteEditor.d.ts +1 -1
  222. package/vanilla/UiEditorFootnoteEditor.js +1 -1
  223. package/vanilla/UiEditorFormattingTools.d.ts +27 -0
  224. package/vanilla/UiEditorFormattingTools.js +188 -0
  225. package/vanilla/UiEditorImageToolbar.d.ts +1 -1
  226. package/vanilla/UiEditorImageToolbar.js +1 -1
  227. package/vanilla/UiEditorInsertTableGrid.d.ts +1 -1
  228. package/vanilla/UiEditorInsertTableGrid.js +1 -1
  229. package/vanilla/UiEditorLinkCard.d.ts +1 -1
  230. package/vanilla/UiEditorLinkCard.js +1 -1
  231. package/vanilla/UiEditorLinkForm.d.ts +2 -1
  232. package/vanilla/UiEditorLinkForm.js +41 -41
  233. package/vanilla/UiEditorMentionMenu.d.ts +1 -1
  234. package/vanilla/UiEditorMentionMenu.js +1 -1
  235. package/vanilla/UiEditorMentionMenuItem.d.ts +1 -1
  236. package/vanilla/UiEditorMentionMenuItem.js +1 -1
  237. package/vanilla/UiEditorSlashMenu.d.ts +1 -1
  238. package/vanilla/UiEditorSlashMenu.js +1 -1
  239. package/vanilla/UiEditorSlashMenuGroup.d.ts +1 -1
  240. package/vanilla/UiEditorSlashMenuGroup.js +1 -1
  241. package/vanilla/UiEditorSlashMenuItem.d.ts +1 -1
  242. package/vanilla/UiEditorSlashMenuItem.js +1 -1
  243. package/vanilla/UiEditorSurface.d.ts +1 -1
  244. package/vanilla/UiEditorSurface.js +1 -1
  245. package/vanilla/UiEditorTableContextMenu.d.ts +1 -1
  246. package/vanilla/UiEditorTableContextMenu.js +10 -5
  247. package/vanilla/UiEditorTableOverlay.d.ts +1 -1
  248. package/vanilla/UiEditorTableOverlay.js +1 -1
  249. package/vanilla/UiEditorTableToolbar.d.ts +1 -1
  250. package/vanilla/UiEditorTableToolbar.js +1 -1
  251. package/vanilla/UiEditorToolbar.d.ts +1 -1
  252. package/vanilla/UiEditorToolbar.js +1 -1
  253. package/vanilla/UiFloatingActionButton.d.ts +1 -1
  254. package/vanilla/UiFloatingActionButton.js +1 -1
  255. package/vanilla/UiFormField.d.ts +1 -1
  256. package/vanilla/UiFormField.js +1 -1
  257. package/vanilla/UiGrid.d.ts +1 -1
  258. package/vanilla/UiGrid.js +1 -1
  259. package/vanilla/UiIcon.d.ts +1 -1
  260. package/vanilla/UiIcon.js +1 -1
  261. package/vanilla/UiIconButton.d.ts +1 -1
  262. package/vanilla/UiIconButton.js +1 -1
  263. package/vanilla/UiImage.d.ts +1 -1
  264. package/vanilla/UiImage.js +1 -1
  265. package/vanilla/UiInput.d.ts +1 -1
  266. package/vanilla/UiInput.js +1 -1
  267. package/vanilla/UiInputGroup.d.ts +1 -1
  268. package/vanilla/UiInputGroup.js +1 -1
  269. package/vanilla/UiLightEditor.d.ts +1 -1
  270. package/vanilla/UiLightEditor.js +1 -1
  271. package/vanilla/UiList.d.ts +1 -1
  272. package/vanilla/UiList.js +1 -1
  273. package/vanilla/UiListItem.d.ts +1 -1
  274. package/vanilla/UiListItem.js +1 -1
  275. package/vanilla/UiListbox.d.ts +1 -1
  276. package/vanilla/UiListbox.js +1 -1
  277. package/vanilla/UiMenu.d.ts +1 -1
  278. package/vanilla/UiMenu.js +1 -1
  279. package/vanilla/UiMenuGroup.d.ts +1 -1
  280. package/vanilla/UiMenuGroup.js +1 -1
  281. package/vanilla/UiMenuItem.d.ts +1 -1
  282. package/vanilla/UiMenuItem.js +1 -1
  283. package/vanilla/UiMeter.d.ts +1 -1
  284. package/vanilla/UiMeter.js +1 -1
  285. package/vanilla/UiNavItem.d.ts +1 -1
  286. package/vanilla/UiNavItem.js +1 -1
  287. package/vanilla/UiNumberInput.d.ts +1 -1
  288. package/vanilla/UiNumberInput.js +1 -1
  289. package/vanilla/UiPageHeader.d.ts +1 -1
  290. package/vanilla/UiPageHeader.js +1 -1
  291. package/vanilla/UiPagination.d.ts +1 -1
  292. package/vanilla/UiPagination.js +1 -1
  293. package/vanilla/UiPopover.d.ts +1 -1
  294. package/vanilla/UiPopover.js +1 -1
  295. package/vanilla/UiRadio.d.ts +1 -1
  296. package/vanilla/UiRadio.js +1 -1
  297. package/vanilla/UiRadioGroup.d.ts +2 -1
  298. package/vanilla/UiRadioGroup.js +33 -28
  299. package/vanilla/UiReel.d.ts +1 -1
  300. package/vanilla/UiReel.js +1 -1
  301. package/vanilla/UiScrollArea.d.ts +1 -1
  302. package/vanilla/UiScrollArea.js +1 -1
  303. package/vanilla/UiSearchResultRow.d.ts +1 -1
  304. package/vanilla/UiSearchResultRow.js +1 -1
  305. package/vanilla/UiSearchShell.d.ts +1 -1
  306. package/vanilla/UiSearchShell.js +1 -1
  307. package/vanilla/UiSection.d.ts +1 -1
  308. package/vanilla/UiSection.js +1 -1
  309. package/vanilla/UiSelect.d.ts +1 -1
  310. package/vanilla/UiSelect.js +1 -1
  311. package/vanilla/UiSeparator.d.ts +1 -1
  312. package/vanilla/UiSeparator.js +1 -1
  313. package/vanilla/UiSidebar.d.ts +1 -1
  314. package/vanilla/UiSidebar.js +1 -1
  315. package/vanilla/UiSiteHeader.d.ts +1 -1
  316. package/vanilla/UiSiteHeader.js +1 -1
  317. package/vanilla/UiSkeleton.d.ts +1 -1
  318. package/vanilla/UiSkeleton.js +1 -1
  319. package/vanilla/UiSlider.d.ts +1 -1
  320. package/vanilla/UiSlider.js +1 -1
  321. package/vanilla/UiSpinner.d.ts +1 -1
  322. package/vanilla/UiSpinner.js +1 -1
  323. package/vanilla/UiStack.d.ts +1 -1
  324. package/vanilla/UiStack.js +1 -1
  325. package/vanilla/UiStatusMessage.d.ts +1 -1
  326. package/vanilla/UiStatusMessage.js +1 -1
  327. package/vanilla/UiSwatch.d.ts +1 -1
  328. package/vanilla/UiSwatch.js +1 -1
  329. package/vanilla/UiSwitch.d.ts +1 -1
  330. package/vanilla/UiSwitch.js +1 -1
  331. package/vanilla/UiSwitcher.d.ts +1 -1
  332. package/vanilla/UiSwitcher.js +1 -1
  333. package/vanilla/UiTable.d.ts +1 -1
  334. package/vanilla/UiTable.js +1 -1
  335. package/vanilla/UiTabs.d.ts +1 -1
  336. package/vanilla/UiTabs.js +1 -1
  337. package/vanilla/UiText.d.ts +1 -1
  338. package/vanilla/UiText.js +1 -1
  339. package/vanilla/UiTextarea.d.ts +1 -1
  340. package/vanilla/UiTextarea.js +1 -1
  341. package/vanilla/UiToast.d.ts +1 -1
  342. package/vanilla/UiToast.js +1 -1
  343. package/vanilla/UiToastRegion.d.ts +1 -1
  344. package/vanilla/UiToastRegion.js +1 -1
  345. package/vanilla/UiTooltip.d.ts +1 -1
  346. package/vanilla/UiTooltip.js +1 -1
  347. package/vanilla/UiTopBar.d.ts +1 -1
  348. package/vanilla/UiTopBar.js +1 -1
  349. package/vanilla/UiTree.d.ts +1 -1
  350. package/vanilla/UiTree.js +1 -1
  351. package/vanilla/UiTreeItem.d.ts +1 -1
  352. package/vanilla/UiTreeItem.js +1 -1
  353. package/vanilla/index.js +6 -0
  354. package/editor/chunks/table-backgrounds.js +0 -51
  355. package/vue/UiActionBar.d.ts +0 -19
  356. package/vue/UiActionBar.js +0 -2
  357. package/vue/UiActionBar.vue +0 -90
  358. package/vue/UiAffordanceScope.d.ts +0 -35
  359. package/vue/UiAffordanceScope.js +0 -2
  360. package/vue/UiAffordanceScope.vue +0 -182
  361. package/vue/UiAvatar.d.ts +0 -71
  362. package/vue/UiAvatar.js +0 -2
  363. package/vue/UiAvatar.vue +0 -394
  364. package/vue/UiAvatarGroup.d.ts +0 -53
  365. package/vue/UiAvatarGroup.js +0 -2
  366. package/vue/UiAvatarGroup.vue +0 -305
  367. package/vue/UiBadge.d.ts +0 -49
  368. package/vue/UiBadge.js +0 -2
  369. package/vue/UiBadge.vue +0 -810
  370. package/vue/UiBreadcrumbItem.d.ts +0 -29
  371. package/vue/UiBreadcrumbItem.js +0 -2
  372. package/vue/UiBreadcrumbItem.vue +0 -192
  373. package/vue/UiBreadcrumbs.d.ts +0 -29
  374. package/vue/UiBreadcrumbs.js +0 -2
  375. package/vue/UiBreadcrumbs.vue +0 -117
  376. package/vue/UiButton.d.ts +0 -131
  377. package/vue/UiButton.js +0 -2
  378. package/vue/UiButton.vue +0 -1609
  379. package/vue/UiCallout.d.ts +0 -35
  380. package/vue/UiCallout.js +0 -2
  381. package/vue/UiCallout.vue +0 -418
  382. package/vue/UiCard.d.ts +0 -81
  383. package/vue/UiCard.js +0 -2
  384. package/vue/UiCard.vue +0 -522
  385. package/vue/UiCardGroup.d.ts +0 -41
  386. package/vue/UiCardGroup.js +0 -2
  387. package/vue/UiCardGroup.vue +0 -168
  388. package/vue/UiCheckbox.d.ts +0 -95
  389. package/vue/UiCheckbox.js +0 -2
  390. package/vue/UiCheckbox.vue +0 -601
  391. package/vue/UiCluster.d.ts +0 -65
  392. package/vue/UiCluster.js +0 -2
  393. package/vue/UiCluster.vue +0 -304
  394. package/vue/UiColorPicker.d.ts +0 -71
  395. package/vue/UiColorPicker.js +0 -2
  396. package/vue/UiColorPicker.vue +0 -563
  397. package/vue/UiCombobox.d.ts +0 -538
  398. package/vue/UiCombobox.js +0 -2
  399. package/vue/UiCombobox.vue +0 -2894
  400. package/vue/UiContainer.d.ts +0 -41
  401. package/vue/UiContainer.js +0 -2
  402. package/vue/UiContainer.vue +0 -177
  403. package/vue/UiContextMenu.d.ts +0 -69
  404. package/vue/UiContextMenu.js +0 -2
  405. package/vue/UiContextMenu.vue +0 -289
  406. package/vue/UiCover.d.ts +0 -29
  407. package/vue/UiCover.js +0 -2
  408. package/vue/UiCover.vue +0 -127
  409. package/vue/UiCurveEditor.d.ts +0 -59
  410. package/vue/UiCurveEditor.js +0 -2
  411. package/vue/UiCurveEditor.vue +0 -429
  412. package/vue/UiCycleButton.d.ts +0 -69
  413. package/vue/UiCycleButton.js +0 -2
  414. package/vue/UiCycleButton.vue +0 -403
  415. package/vue/UiDescriptionItem.d.ts +0 -29
  416. package/vue/UiDescriptionItem.js +0 -2
  417. package/vue/UiDescriptionItem.vue +0 -124
  418. package/vue/UiDescriptionList.d.ts +0 -41
  419. package/vue/UiDescriptionList.js +0 -2
  420. package/vue/UiDescriptionList.vue +0 -217
  421. package/vue/UiDialog.d.ts +0 -97
  422. package/vue/UiDialog.js +0 -2
  423. package/vue/UiDialog.vue +0 -817
  424. package/vue/UiDisclosure.d.ts +0 -107
  425. package/vue/UiDisclosure.js +0 -2
  426. package/vue/UiDisclosure.vue +0 -605
  427. package/vue/UiEditable.d.ts +0 -113
  428. package/vue/UiEditable.js +0 -2
  429. package/vue/UiEditable.vue +0 -582
  430. package/vue/UiEditorBlockActions.d.ts +0 -33
  431. package/vue/UiEditorBlockActions.js +0 -2
  432. package/vue/UiEditorBlockActions.vue +0 -163
  433. package/vue/UiEditorChipEditor.d.ts +0 -45
  434. package/vue/UiEditorChipEditor.js +0 -2
  435. package/vue/UiEditorChipEditor.vue +0 -208
  436. package/vue/UiEditorCodeLanguage.d.ts +0 -41
  437. package/vue/UiEditorCodeLanguage.js +0 -2
  438. package/vue/UiEditorCodeLanguage.vue +0 -200
  439. package/vue/UiEditorFootnoteEditor.d.ts +0 -39
  440. package/vue/UiEditorFootnoteEditor.js +0 -2
  441. package/vue/UiEditorFootnoteEditor.vue +0 -152
  442. package/vue/UiEditorImageToolbar.d.ts +0 -51
  443. package/vue/UiEditorImageToolbar.js +0 -2
  444. package/vue/UiEditorImageToolbar.vue +0 -446
  445. package/vue/UiEditorInsertTableGrid.d.ts +0 -49
  446. package/vue/UiEditorInsertTableGrid.js +0 -2
  447. package/vue/UiEditorInsertTableGrid.vue +0 -367
  448. package/vue/UiEditorLinkCard.d.ts +0 -49
  449. package/vue/UiEditorLinkCard.js +0 -2
  450. package/vue/UiEditorLinkCard.vue +0 -385
  451. package/vue/UiEditorLinkForm.d.ts +0 -131
  452. package/vue/UiEditorLinkForm.js +0 -2
  453. package/vue/UiEditorLinkForm.vue +0 -664
  454. package/vue/UiEditorMentionMenu.d.ts +0 -121
  455. package/vue/UiEditorMentionMenu.js +0 -2
  456. package/vue/UiEditorMentionMenu.vue +0 -596
  457. package/vue/UiEditorMentionMenuItem.d.ts +0 -43
  458. package/vue/UiEditorMentionMenuItem.js +0 -2
  459. package/vue/UiEditorMentionMenuItem.vue +0 -205
  460. package/vue/UiEditorSlashMenu.d.ts +0 -111
  461. package/vue/UiEditorSlashMenu.js +0 -2
  462. package/vue/UiEditorSlashMenu.vue +0 -549
  463. package/vue/UiEditorSlashMenuGroup.d.ts +0 -29
  464. package/vue/UiEditorSlashMenuGroup.js +0 -2
  465. package/vue/UiEditorSlashMenuGroup.vue +0 -113
  466. package/vue/UiEditorSlashMenuItem.d.ts +0 -53
  467. package/vue/UiEditorSlashMenuItem.js +0 -2
  468. package/vue/UiEditorSlashMenuItem.vue +0 -249
  469. package/vue/UiEditorSurface.d.ts +0 -29
  470. package/vue/UiEditorSurface.js +0 -2
  471. package/vue/UiEditorSurface.vue +0 -117
  472. package/vue/UiEditorTableContextMenu.d.ts +0 -57
  473. package/vue/UiEditorTableContextMenu.js +0 -2
  474. package/vue/UiEditorTableContextMenu.vue +0 -694
  475. package/vue/UiEditorTableOverlay.d.ts +0 -191
  476. package/vue/UiEditorTableOverlay.js +0 -2
  477. package/vue/UiEditorTableOverlay.vue +0 -1099
  478. package/vue/UiEditorTableToolbar.d.ts +0 -57
  479. package/vue/UiEditorTableToolbar.js +0 -2
  480. package/vue/UiEditorTableToolbar.vue +0 -834
  481. package/vue/UiEditorToolbar.d.ts +0 -29
  482. package/vue/UiEditorToolbar.js +0 -2
  483. package/vue/UiEditorToolbar.vue +0 -296
  484. package/vue/UiFloatingActionButton.d.ts +0 -41
  485. package/vue/UiFloatingActionButton.js +0 -2
  486. package/vue/UiFloatingActionButton.vue +0 -201
  487. package/vue/UiFormField.d.ts +0 -49
  488. package/vue/UiFormField.js +0 -2
  489. package/vue/UiFormField.vue +0 -256
  490. package/vue/UiGrid.d.ts +0 -41
  491. package/vue/UiGrid.js +0 -2
  492. package/vue/UiGrid.vue +0 -190
  493. package/vue/UiIcon.d.ts +0 -25
  494. package/vue/UiIcon.js +0 -2
  495. package/vue/UiIcon.vue +0 -612
  496. package/vue/UiIconButton.d.ts +0 -101
  497. package/vue/UiIconButton.js +0 -2
  498. package/vue/UiIconButton.vue +0 -1141
  499. package/vue/UiImage.d.ts +0 -85
  500. package/vue/UiImage.js +0 -2
  501. package/vue/UiImage.vue +0 -462
  502. package/vue/UiInput.d.ts +0 -50
  503. package/vue/UiInput.js +0 -2
  504. package/vue/UiInput.vue +0 -671
  505. package/vue/UiInputGroup.d.ts +0 -59
  506. package/vue/UiInputGroup.js +0 -2
  507. package/vue/UiInputGroup.vue +0 -447
  508. package/vue/UiLightEditor.d.ts +0 -83
  509. package/vue/UiLightEditor.js +0 -2
  510. package/vue/UiLightEditor.vue +0 -537
  511. package/vue/UiList.d.ts +0 -49
  512. package/vue/UiList.js +0 -2
  513. package/vue/UiList.vue +0 -260
  514. package/vue/UiListItem.d.ts +0 -65
  515. package/vue/UiListItem.js +0 -2
  516. package/vue/UiListItem.vue +0 -407
  517. package/vue/UiListbox.d.ts +0 -87
  518. package/vue/UiListbox.js +0 -2
  519. package/vue/UiListbox.vue +0 -554
  520. package/vue/UiMenu.d.ts +0 -99
  521. package/vue/UiMenu.js +0 -2
  522. package/vue/UiMenu.vue +0 -541
  523. package/vue/UiMenuGroup.d.ts +0 -29
  524. package/vue/UiMenuGroup.js +0 -2
  525. package/vue/UiMenuGroup.vue +0 -105
  526. package/vue/UiMenuItem.d.ts +0 -89
  527. package/vue/UiMenuItem.js +0 -2
  528. package/vue/UiMenuItem.vue +0 -532
  529. package/vue/UiMeter.d.ts +0 -73
  530. package/vue/UiMeter.js +0 -2
  531. package/vue/UiMeter.vue +0 -1112
  532. package/vue/UiNavItem.d.ts +0 -79
  533. package/vue/UiNavItem.js +0 -2
  534. package/vue/UiNavItem.vue +0 -493
  535. package/vue/UiNumberInput.d.ts +0 -89
  536. package/vue/UiNumberInput.js +0 -2
  537. package/vue/UiNumberInput.vue +0 -445
  538. package/vue/UiPageHeader.d.ts +0 -37
  539. package/vue/UiPageHeader.js +0 -2
  540. package/vue/UiPageHeader.vue +0 -192
  541. package/vue/UiPagination.d.ts +0 -115
  542. package/vue/UiPagination.js +0 -2
  543. package/vue/UiPagination.vue +0 -596
  544. package/vue/UiPopover.d.ts +0 -77
  545. package/vue/UiPopover.js +0 -2
  546. package/vue/UiPopover.vue +0 -495
  547. package/vue/UiRadio.d.ts +0 -77
  548. package/vue/UiRadio.js +0 -2
  549. package/vue/UiRadio.vue +0 -475
  550. package/vue/UiRadioGroup.d.ts +0 -95
  551. package/vue/UiRadioGroup.js +0 -2
  552. package/vue/UiRadioGroup.vue +0 -393
  553. package/vue/UiReel.d.ts +0 -41
  554. package/vue/UiReel.js +0 -2
  555. package/vue/UiReel.vue +0 -223
  556. package/vue/UiScrollArea.d.ts +0 -53
  557. package/vue/UiScrollArea.js +0 -2
  558. package/vue/UiScrollArea.vue +0 -307
  559. package/vue/UiSearchResultRow.d.ts +0 -49
  560. package/vue/UiSearchResultRow.js +0 -2
  561. package/vue/UiSearchResultRow.vue +0 -268
  562. package/vue/UiSearchShell.d.ts +0 -67
  563. package/vue/UiSearchShell.js +0 -2
  564. package/vue/UiSearchShell.vue +0 -391
  565. package/vue/UiSection.d.ts +0 -51
  566. package/vue/UiSection.js +0 -2
  567. package/vue/UiSection.vue +0 -331
  568. package/vue/UiSelect.d.ts +0 -69
  569. package/vue/UiSelect.js +0 -2
  570. package/vue/UiSelect.vue +0 -391
  571. package/vue/UiSeparator.d.ts +0 -37
  572. package/vue/UiSeparator.js +0 -2
  573. package/vue/UiSeparator.vue +0 -199
  574. package/vue/UiSidebar.d.ts +0 -99
  575. package/vue/UiSidebar.js +0 -2
  576. package/vue/UiSidebar.vue +0 -579
  577. package/vue/UiSiteHeader.d.ts +0 -59
  578. package/vue/UiSiteHeader.js +0 -2
  579. package/vue/UiSiteHeader.vue +0 -904
  580. package/vue/UiSkeleton.d.ts +0 -37
  581. package/vue/UiSkeleton.js +0 -2
  582. package/vue/UiSkeleton.vue +0 -287
  583. package/vue/UiSlider.d.ts +0 -89
  584. package/vue/UiSlider.js +0 -2
  585. package/vue/UiSlider.vue +0 -448
  586. package/vue/UiSpinner.d.ts +0 -25
  587. package/vue/UiSpinner.js +0 -2
  588. package/vue/UiSpinner.vue +0 -330
  589. package/vue/UiStack.d.ts +0 -53
  590. package/vue/UiStack.js +0 -2
  591. package/vue/UiStack.vue +0 -247
  592. package/vue/UiStatusMessage.d.ts +0 -43
  593. package/vue/UiStatusMessage.js +0 -2
  594. package/vue/UiStatusMessage.vue +0 -239
  595. package/vue/UiSwatch.d.ts +0 -19
  596. package/vue/UiSwatch.js +0 -2
  597. package/vue/UiSwatch.vue +0 -188
  598. package/vue/UiSwitch.d.ts +0 -77
  599. package/vue/UiSwitch.js +0 -2
  600. package/vue/UiSwitch.vue +0 -478
  601. package/vue/UiSwitcher.d.ts +0 -47
  602. package/vue/UiSwitcher.js +0 -2
  603. package/vue/UiSwitcher.vue +0 -258
  604. package/vue/UiTable.d.ts +0 -35
  605. package/vue/UiTable.js +0 -2
  606. package/vue/UiTable.vue +0 -280
  607. package/vue/UiTabs.d.ts +0 -81
  608. package/vue/UiTabs.js +0 -2
  609. package/vue/UiTabs.vue +0 -493
  610. package/vue/UiText.d.ts +0 -111
  611. package/vue/UiText.js +0 -2
  612. package/vue/UiText.vue +0 -836
  613. package/vue/UiTextarea.d.ts +0 -77
  614. package/vue/UiTextarea.js +0 -2
  615. package/vue/UiTextarea.vue +0 -477
  616. package/vue/UiToast.d.ts +0 -49
  617. package/vue/UiToast.js +0 -2
  618. package/vue/UiToast.vue +0 -337
  619. package/vue/UiToastRegion.d.ts +0 -61
  620. package/vue/UiToastRegion.js +0 -2
  621. package/vue/UiToastRegion.vue +0 -631
  622. package/vue/UiTooltip.d.ts +0 -93
  623. package/vue/UiTooltip.js +0 -2
  624. package/vue/UiTooltip.vue +0 -627
  625. package/vue/UiTopBar.d.ts +0 -35
  626. package/vue/UiTopBar.js +0 -2
  627. package/vue/UiTopBar.vue +0 -240
  628. package/vue/UiTree.d.ts +0 -123
  629. package/vue/UiTree.js +0 -2
  630. package/vue/UiTree.vue +0 -419
  631. package/vue/UiTreeItem.d.ts +0 -133
  632. package/vue/UiTreeItem.js +0 -2
  633. package/vue/UiTreeItem.vue +0 -1962
  634. package/vue/chunks/UiActionBar.js +0 -42
  635. package/vue/chunks/UiAffordanceScope.js +0 -136
  636. package/vue/chunks/UiAvatar.js +0 -341
  637. package/vue/chunks/UiAvatarGroup.js +0 -234
  638. package/vue/chunks/UiBadge.js +0 -188
  639. package/vue/chunks/UiBreadcrumbItem.js +0 -104
  640. package/vue/chunks/UiBreadcrumbs.js +0 -67
  641. package/vue/chunks/UiButton.js +0 -881
  642. package/vue/chunks/UiCallout.js +0 -302
  643. package/vue/chunks/UiCard.js +0 -369
  644. package/vue/chunks/UiCardGroup.js +0 -153
  645. package/vue/chunks/UiCheckbox.js +0 -361
  646. package/vue/chunks/UiCluster.js +0 -236
  647. package/vue/chunks/UiColorPicker.js +0 -375
  648. package/vue/chunks/UiCombobox.js +0 -2186
  649. package/vue/chunks/UiContainer.js +0 -122
  650. package/vue/chunks/UiContextMenu.js +0 -157
  651. package/vue/chunks/UiCover.js +0 -66
  652. package/vue/chunks/UiCurveEditor.js +0 -415
  653. package/vue/chunks/UiCycleButton.js +0 -352
  654. package/vue/chunks/UiDescriptionItem.js +0 -64
  655. package/vue/chunks/UiDescriptionList.js +0 -133
  656. package/vue/chunks/UiDialog.js +0 -367
  657. package/vue/chunks/UiDisclosure.js +0 -403
  658. package/vue/chunks/UiEditable.js +0 -436
  659. package/vue/chunks/UiEditorBlockActions.js +0 -157
  660. package/vue/chunks/UiEditorChipEditor.js +0 -191
  661. package/vue/chunks/UiEditorCodeLanguage.js +0 -181
  662. package/vue/chunks/UiEditorFootnoteEditor.js +0 -114
  663. package/vue/chunks/UiEditorImageToolbar.js +0 -531
  664. package/vue/chunks/UiEditorInsertTableGrid.js +0 -325
  665. package/vue/chunks/UiEditorLinkCard.js +0 -391
  666. package/vue/chunks/UiEditorLinkForm.js +0 -711
  667. package/vue/chunks/UiEditorMentionMenu.js +0 -618
  668. package/vue/chunks/UiEditorMentionMenuItem.js +0 -140
  669. package/vue/chunks/UiEditorSlashMenu.js +0 -555
  670. package/vue/chunks/UiEditorSlashMenuGroup.js +0 -78
  671. package/vue/chunks/UiEditorSlashMenuItem.js +0 -197
  672. package/vue/chunks/UiEditorSurface.js +0 -66
  673. package/vue/chunks/UiEditorTableContextMenu.js +0 -500
  674. package/vue/chunks/UiEditorTableOverlay.js +0 -987
  675. package/vue/chunks/UiEditorTableToolbar.js +0 -707
  676. package/vue/chunks/UiEditorToolbar.js +0 -103
  677. package/vue/chunks/UiFloatingActionButton.js +0 -123
  678. package/vue/chunks/UiFormField.js +0 -172
  679. package/vue/chunks/UiGrid.js +0 -127
  680. package/vue/chunks/UiIcon.js +0 -1361
  681. package/vue/chunks/UiIconButton.js +0 -469
  682. package/vue/chunks/UiImage.js +0 -312
  683. package/vue/chunks/UiInput.js +0 -709
  684. package/vue/chunks/UiInputGroup.js +0 -225
  685. package/vue/chunks/UiLightEditor.js +0 -365
  686. package/vue/chunks/UiList.js +0 -178
  687. package/vue/chunks/UiListItem.js +0 -219
  688. package/vue/chunks/UiListbox.js +0 -489
  689. package/vue/chunks/UiMenu.js +0 -286
  690. package/vue/chunks/UiMenuGroup.js +0 -75
  691. package/vue/chunks/UiMenuItem.js +0 -374
  692. package/vue/chunks/UiMeter.js +0 -540
  693. package/vue/chunks/UiNavItem.js +0 -380
  694. package/vue/chunks/UiNumberInput.js +0 -432
  695. package/vue/chunks/UiPageHeader.js +0 -100
  696. package/vue/chunks/UiPagination.js +0 -537
  697. package/vue/chunks/UiPopover.js +0 -243
  698. package/vue/chunks/UiRadio.js +0 -291
  699. package/vue/chunks/UiRadioGroup.js +0 -300
  700. package/vue/chunks/UiReel.js +0 -133
  701. package/vue/chunks/UiScrollArea.js +0 -219
  702. package/vue/chunks/UiSearchResultRow.js +0 -164
  703. package/vue/chunks/UiSearchShell.js +0 -215
  704. package/vue/chunks/UiSection.js +0 -228
  705. package/vue/chunks/UiSelect.js +0 -251
  706. package/vue/chunks/UiSeparator.js +0 -144
  707. package/vue/chunks/UiSidebar.js +0 -358
  708. package/vue/chunks/UiSiteHeader.js +0 -335
  709. package/vue/chunks/UiSkeleton.js +0 -183
  710. package/vue/chunks/UiSlider.js +0 -427
  711. package/vue/chunks/UiSpinner.js +0 -181
  712. package/vue/chunks/UiStack.js +0 -177
  713. package/vue/chunks/UiStatusMessage.js +0 -176
  714. package/vue/chunks/UiSwatch.js +0 -93
  715. package/vue/chunks/UiSwitch.js +0 -292
  716. package/vue/chunks/UiSwitcher.js +0 -194
  717. package/vue/chunks/UiTable.js +0 -128
  718. package/vue/chunks/UiTabs.js +0 -334
  719. package/vue/chunks/UiText.js +0 -747
  720. package/vue/chunks/UiTextarea.js +0 -313
  721. package/vue/chunks/UiToast.js +0 -174
  722. package/vue/chunks/UiToastRegion.js +0 -275
  723. package/vue/chunks/UiTooltip.js +0 -297
  724. package/vue/chunks/UiTopBar.js +0 -129
  725. package/vue/chunks/UiTree.js +0 -282
  726. package/vue/chunks/UiTreeItem.js +0 -699
  727. package/vue/chunks/_plugin-vue_export-helper.js +0 -1265
  728. package/vue/chunks/control.js +0 -214
  729. package/vue/chunks/props.js +0 -1228
  730. package/vue/components.css +0 -17539
  731. package/vue/editor/LoomaEditor.d.ts +0 -433
  732. package/vue/editor/compact/index.d.ts +0 -84
  733. package/vue/editor/compact/index.js +0 -2
  734. package/vue/editor/index.d.ts +0 -5
  735. package/vue/editor/index.js +0 -17281
  736. package/vue/editor/primitives.d.ts +0 -120
  737. package/vue/host.ts +0 -2272
  738. package/vue/index.d.ts +0 -94
  739. package/vue/index.js +0 -95
  740. package/vue/props.d.ts +0 -272
  741. /package/{vue → editor}/chunks/1c.js +0 -0
  742. /package/{vue → editor}/chunks/abnf.js +0 -0
  743. /package/{vue → editor}/chunks/accesslog.js +0 -0
  744. /package/{vue → editor}/chunks/actionscript.js +0 -0
  745. /package/{vue → editor}/chunks/ada.js +0 -0
  746. /package/{vue → editor}/chunks/angelscript.js +0 -0
  747. /package/{vue → editor}/chunks/apache.js +0 -0
  748. /package/{vue → editor}/chunks/applescript.js +0 -0
  749. /package/{vue → editor}/chunks/arcade.js +0 -0
  750. /package/{vue → editor}/chunks/arduino.js +0 -0
  751. /package/{vue → editor}/chunks/armasm.js +0 -0
  752. /package/{vue → editor}/chunks/asciidoc.js +0 -0
  753. /package/{vue → editor}/chunks/aspectj.js +0 -0
  754. /package/{vue → editor}/chunks/autohotkey.js +0 -0
  755. /package/{vue → editor}/chunks/autoit.js +0 -0
  756. /package/{vue → editor}/chunks/avrasm.js +0 -0
  757. /package/{vue → editor}/chunks/awk.js +0 -0
  758. /package/{vue → editor}/chunks/axapta.js +0 -0
  759. /package/{vue → editor}/chunks/bash.js +0 -0
  760. /package/{vue → editor}/chunks/basic.js +0 -0
  761. /package/{vue → editor}/chunks/bnf.js +0 -0
  762. /package/{vue → editor}/chunks/brainfuck.js +0 -0
  763. /package/{vue → editor}/chunks/c.js +0 -0
  764. /package/{vue → editor}/chunks/cal.js +0 -0
  765. /package/{vue → editor}/chunks/capnproto.js +0 -0
  766. /package/{vue → editor}/chunks/ceylon.js +0 -0
  767. /package/{vue → editor}/chunks/clean.js +0 -0
  768. /package/{vue → editor}/chunks/clojure-repl.js +0 -0
  769. /package/{vue → editor}/chunks/clojure.js +0 -0
  770. /package/{vue → editor}/chunks/cmake.js +0 -0
  771. /package/{vue → editor}/chunks/coffeescript.js +0 -0
  772. /package/{vue → editor}/chunks/coq.js +0 -0
  773. /package/{vue → editor}/chunks/cos.js +0 -0
  774. /package/{vue → editor}/chunks/cpp.js +0 -0
  775. /package/{vue → editor}/chunks/crmsh.js +0 -0
  776. /package/{vue → editor}/chunks/crystal.js +0 -0
  777. /package/{vue → editor}/chunks/csharp.js +0 -0
  778. /package/{vue → editor}/chunks/csp.js +0 -0
  779. /package/{vue → editor}/chunks/css.js +0 -0
  780. /package/{vue → editor}/chunks/d.js +0 -0
  781. /package/{vue → editor}/chunks/dart.js +0 -0
  782. /package/{vue → editor}/chunks/delphi.js +0 -0
  783. /package/{vue → editor}/chunks/diff.js +0 -0
  784. /package/{vue → editor}/chunks/django.js +0 -0
  785. /package/{vue → editor}/chunks/dns.js +0 -0
  786. /package/{vue → editor}/chunks/dockerfile.js +0 -0
  787. /package/{vue → editor}/chunks/dos.js +0 -0
  788. /package/{vue → editor}/chunks/dsconfig.js +0 -0
  789. /package/{vue → editor}/chunks/dts.js +0 -0
  790. /package/{vue → editor}/chunks/dust.js +0 -0
  791. /package/{vue → editor}/chunks/ebnf.js +0 -0
  792. /package/{vue → editor}/chunks/elixir.js +0 -0
  793. /package/{vue → editor}/chunks/elm.js +0 -0
  794. /package/{vue → editor}/chunks/erb.js +0 -0
  795. /package/{vue → editor}/chunks/erlang-repl.js +0 -0
  796. /package/{vue → editor}/chunks/erlang.js +0 -0
  797. /package/{vue → editor}/chunks/excel.js +0 -0
  798. /package/{vue → editor}/chunks/fix.js +0 -0
  799. /package/{vue → editor}/chunks/flix.js +0 -0
  800. /package/{vue → editor}/chunks/fortran.js +0 -0
  801. /package/{vue → editor}/chunks/fsharp.js +0 -0
  802. /package/{vue → editor}/chunks/gams.js +0 -0
  803. /package/{vue → editor}/chunks/gauss.js +0 -0
  804. /package/{vue → editor}/chunks/gcode.js +0 -0
  805. /package/{vue → editor}/chunks/gherkin.js +0 -0
  806. /package/{vue → editor}/chunks/glsl.js +0 -0
  807. /package/{vue → editor}/chunks/gml.js +0 -0
  808. /package/{vue → editor}/chunks/go.js +0 -0
  809. /package/{vue → editor}/chunks/golo.js +0 -0
  810. /package/{vue → editor}/chunks/gradle.js +0 -0
  811. /package/{vue → editor}/chunks/graphql.js +0 -0
  812. /package/{vue → editor}/chunks/groovy.js +0 -0
  813. /package/{vue → editor}/chunks/haml.js +0 -0
  814. /package/{vue → editor}/chunks/handlebars.js +0 -0
  815. /package/{vue → editor}/chunks/haskell.js +0 -0
  816. /package/{vue → editor}/chunks/haxe.js +0 -0
  817. /package/{vue → editor}/chunks/hsp.js +0 -0
  818. /package/{vue → editor}/chunks/http.js +0 -0
  819. /package/{vue → editor}/chunks/hy.js +0 -0
  820. /package/{vue → editor}/chunks/inform7.js +0 -0
  821. /package/{vue → editor}/chunks/ini.js +0 -0
  822. /package/{vue → editor}/chunks/irpf90.js +0 -0
  823. /package/{vue → editor}/chunks/isbl.js +0 -0
  824. /package/{vue → editor}/chunks/java.js +0 -0
  825. /package/{vue → editor}/chunks/javascript.js +0 -0
  826. /package/{vue → editor}/chunks/jboss-cli.js +0 -0
  827. /package/{vue → editor}/chunks/json.js +0 -0
  828. /package/{vue → editor}/chunks/julia-repl.js +0 -0
  829. /package/{vue → editor}/chunks/julia.js +0 -0
  830. /package/{vue → editor}/chunks/kotlin.js +0 -0
  831. /package/{vue → editor}/chunks/lasso.js +0 -0
  832. /package/{vue → editor}/chunks/latex.js +0 -0
  833. /package/{vue → editor}/chunks/ldif.js +0 -0
  834. /package/{vue → editor}/chunks/leaf.js +0 -0
  835. /package/{vue → editor}/chunks/less.js +0 -0
  836. /package/{vue → editor}/chunks/lisp.js +0 -0
  837. /package/{vue → editor}/chunks/livecodeserver.js +0 -0
  838. /package/{vue → editor}/chunks/livescript.js +0 -0
  839. /package/{vue → editor}/chunks/llvm.js +0 -0
  840. /package/{vue → editor}/chunks/lsl.js +0 -0
  841. /package/{vue → editor}/chunks/lua.js +0 -0
  842. /package/{vue → editor}/chunks/makefile.js +0 -0
  843. /package/{vue → editor}/chunks/markdown.js +0 -0
  844. /package/{vue → editor}/chunks/mathematica.js +0 -0
  845. /package/{vue → editor}/chunks/matlab.js +0 -0
  846. /package/{vue → editor}/chunks/maxima.js +0 -0
  847. /package/{vue → editor}/chunks/mel.js +0 -0
  848. /package/{vue → editor}/chunks/mercury.js +0 -0
  849. /package/{vue → editor}/chunks/mipsasm.js +0 -0
  850. /package/{vue → editor}/chunks/mizar.js +0 -0
  851. /package/{vue → editor}/chunks/mojolicious.js +0 -0
  852. /package/{vue → editor}/chunks/monkey.js +0 -0
  853. /package/{vue → editor}/chunks/moonscript.js +0 -0
  854. /package/{vue → editor}/chunks/n1ql.js +0 -0
  855. /package/{vue → editor}/chunks/nestedtext.js +0 -0
  856. /package/{vue → editor}/chunks/nginx.js +0 -0
  857. /package/{vue → editor}/chunks/nim.js +0 -0
  858. /package/{vue → editor}/chunks/nix.js +0 -0
  859. /package/{vue → editor}/chunks/node-repl.js +0 -0
  860. /package/{vue → editor}/chunks/nsis.js +0 -0
  861. /package/{vue → editor}/chunks/objectivec.js +0 -0
  862. /package/{vue → editor}/chunks/ocaml.js +0 -0
  863. /package/{vue → editor}/chunks/openscad.js +0 -0
  864. /package/{vue → editor}/chunks/oxygene.js +0 -0
  865. /package/{vue → editor}/chunks/parser3.js +0 -0
  866. /package/{vue → editor}/chunks/perl.js +0 -0
  867. /package/{vue → editor}/chunks/pf.js +0 -0
  868. /package/{vue → editor}/chunks/pgsql.js +0 -0
  869. /package/{vue → editor}/chunks/php-template.js +0 -0
  870. /package/{vue → editor}/chunks/php.js +0 -0
  871. /package/{vue → editor}/chunks/plaintext.js +0 -0
  872. /package/{vue → editor}/chunks/pony.js +0 -0
  873. /package/{vue → editor}/chunks/powershell.js +0 -0
  874. /package/{vue → editor}/chunks/processing.js +0 -0
  875. /package/{vue → editor}/chunks/profile.js +0 -0
  876. /package/{vue → editor}/chunks/prolog.js +0 -0
  877. /package/{vue → editor}/chunks/properties.js +0 -0
  878. /package/{vue → editor}/chunks/protobuf.js +0 -0
  879. /package/{vue → editor}/chunks/puppet.js +0 -0
  880. /package/{vue → editor}/chunks/purebasic.js +0 -0
  881. /package/{vue → editor}/chunks/python-repl.js +0 -0
  882. /package/{vue → editor}/chunks/python.js +0 -0
  883. /package/{vue → editor}/chunks/q.js +0 -0
  884. /package/{vue → editor}/chunks/qml.js +0 -0
  885. /package/{vue → editor}/chunks/r.js +0 -0
  886. /package/{vue → editor}/chunks/reasonml.js +0 -0
  887. /package/{vue → editor}/chunks/rib.js +0 -0
  888. /package/{vue → editor}/chunks/roboconf.js +0 -0
  889. /package/{vue → editor}/chunks/routeros.js +0 -0
  890. /package/{vue → editor}/chunks/rsl.js +0 -0
  891. /package/{vue → editor}/chunks/ruby.js +0 -0
  892. /package/{vue → editor}/chunks/ruleslanguage.js +0 -0
  893. /package/{vue → editor}/chunks/rust.js +0 -0
  894. /package/{vue → editor}/chunks/sas.js +0 -0
  895. /package/{vue → editor}/chunks/scala.js +0 -0
  896. /package/{vue → editor}/chunks/scheme.js +0 -0
  897. /package/{vue → editor}/chunks/scilab.js +0 -0
  898. /package/{vue → editor}/chunks/scss.js +0 -0
  899. /package/{vue → editor}/chunks/shell.js +0 -0
  900. /package/{vue → editor}/chunks/smali.js +0 -0
  901. /package/{vue → editor}/chunks/smalltalk.js +0 -0
  902. /package/{vue → editor}/chunks/sml.js +0 -0
  903. /package/{vue → editor}/chunks/sqf.js +0 -0
  904. /package/{vue → editor}/chunks/sql.js +0 -0
  905. /package/{vue → editor}/chunks/stan.js +0 -0
  906. /package/{vue → editor}/chunks/stata.js +0 -0
  907. /package/{vue → editor}/chunks/step21.js +0 -0
  908. /package/{vue → editor}/chunks/stylus.js +0 -0
  909. /package/{vue → editor}/chunks/subunit.js +0 -0
  910. /package/{vue → editor}/chunks/swift.js +0 -0
  911. /package/{vue → editor}/chunks/taggerscript.js +0 -0
  912. /package/{vue → editor}/chunks/tap.js +0 -0
  913. /package/{vue → editor}/chunks/tcl.js +0 -0
  914. /package/{vue → editor}/chunks/thrift.js +0 -0
  915. /package/{vue → editor}/chunks/tp.js +0 -0
  916. /package/{vue → editor}/chunks/twig.js +0 -0
  917. /package/{vue → editor}/chunks/typescript.js +0 -0
  918. /package/{vue → editor}/chunks/vala.js +0 -0
  919. /package/{vue → editor}/chunks/vbnet.js +0 -0
  920. /package/{vue → editor}/chunks/vbscript-html.js +0 -0
  921. /package/{vue → editor}/chunks/vbscript.js +0 -0
  922. /package/{vue → editor}/chunks/verilog.js +0 -0
  923. /package/{vue → editor}/chunks/vhdl.js +0 -0
  924. /package/{vue → editor}/chunks/vim.js +0 -0
  925. /package/{vue → editor}/chunks/wasm.js +0 -0
  926. /package/{vue → editor}/chunks/wren.js +0 -0
  927. /package/{vue → editor}/chunks/x86asm.js +0 -0
  928. /package/{vue → editor}/chunks/xl.js +0 -0
  929. /package/{vue → editor}/chunks/xml.js +0 -0
  930. /package/{vue → editor}/chunks/xquery.js +0 -0
  931. /package/{vue → editor}/chunks/yaml.js +0 -0
  932. /package/{vue → editor}/chunks/zephir.js +0 -0
  933. /package/{vue/editor/compact/extensions.d.ts → editor/compact-extensions.d.ts} +0 -0
@@ -1,1265 +0,0 @@
1
- import { Fragment, computed, createTextVNode, customRef, defineComponent, getCurrentInstance, h, onBeforeUnmount, onBeforeUpdate, onMounted, onUpdated, ref, shallowRef, useSlots, watch, watchEffect } from "vue";
2
- //#region .build/vue/host.ts
3
- var READY_INPUT = {
4
- ready: true,
5
- pending: false,
6
- error: null,
7
- stale: false
8
- };
9
- /**
10
- * Each call owns a fresh native cancellation signal. The facade also owns subscriptions created
11
- * through host.on/effect after an await: retaining a stale host cannot start a new subscription.
12
- * It shares the instance's state, props, refs and other capabilities rather than copying them.
13
- */
14
- function activateModule(module, host, report = (error) => {
15
- queueMicrotask(() => {
16
- throw error;
17
- });
18
- }) {
19
- const controller = new AbortController();
20
- const owned = /* @__PURE__ */ new Set();
21
- let cleanup;
22
- const dispose = (stop) => {
23
- try {
24
- stop();
25
- } catch (error) {
26
- report(error);
27
- }
28
- };
29
- const scoped = Object.create(host);
30
- const stop = () => {
31
- if (controller.signal.aborted) return;
32
- controller.abort();
33
- for (const release of owned) release();
34
- const release = cleanup;
35
- cleanup = void 0;
36
- if (release !== void 0) dispose(release);
37
- };
38
- const failed = (error) => {
39
- const cancelled = controller.signal.aborted && error?.name === "AbortError";
40
- stop();
41
- if (!cancelled) report(error);
42
- };
43
- const own = (stop) => {
44
- let stopped = false;
45
- const release = () => {
46
- if (stopped) return;
47
- stopped = true;
48
- owned.delete(release);
49
- dispose(stop);
50
- };
51
- if (controller.signal.aborted) release();
52
- else owned.add(release);
53
- return release;
54
- };
55
- for (const name of [
56
- "on",
57
- "effect",
58
- "computed"
59
- ]) {
60
- const method = Reflect.get(host, name);
61
- if (typeof method !== "function") continue;
62
- Object.defineProperty(scoped, name, { value: (...args) => {
63
- if (controller.signal.aborted) {
64
- if (name === "computed") return { get: () => {
65
- throw controller.signal.reason;
66
- } };
67
- return () => {};
68
- }
69
- const result = Reflect.apply(method, host, args);
70
- const stop = name === "computed" ? result.stop?.bind(result) : result;
71
- if (stop === void 0) return result;
72
- const release = own(stop);
73
- return name === "computed" ? result : release;
74
- } });
75
- }
76
- const inputKey = Symbol.for("@nextwebwg/html-next.inputs.v1");
77
- const inputs = Reflect.get(host, inputKey);
78
- if (inputs !== void 0) {
79
- const port = Object.create(inputs);
80
- Object.defineProperty(port, "watch", { value: (run) => controller.signal.aborted ? () => {} : own(inputs.watch(run)) });
81
- const source = Reflect.get(inputs, "source");
82
- if (typeof source === "function") Object.defineProperty(port, "source", { value: (...args) => {
83
- if (controller.signal.aborted) throw controller.signal.reason;
84
- const result = Reflect.apply(source, inputs, args);
85
- const capability = Object.create(result);
86
- Object.defineProperty(capability, "dispose", { value: own(() => result.dispose()) });
87
- return capability;
88
- } });
89
- Object.defineProperty(scoped, inputKey, { value: port });
90
- }
91
- const accept = (result) => {
92
- if (result === void 0) return;
93
- if (typeof result !== "function") {
94
- failed(/* @__PURE__ */ new TypeError("A component connect export must return cleanup or undefined."));
95
- return;
96
- }
97
- if (controller.signal.aborted) dispose(result);
98
- else cleanup = result;
99
- };
100
- try {
101
- const result = module.connect?.(scoped, { signal: controller.signal });
102
- if (result !== void 0 && typeof result !== "function") Promise.resolve(result).then(accept, failed);
103
- else accept(result);
104
- } catch (error) {
105
- failed(error);
106
- }
107
- return stop;
108
- }
109
- /** A fresh copy of a state's declared value at `keys`, or null where it has none. */
110
- function initialAt(initial, keys) {
111
- let value = initial;
112
- for (const key of keys) {
113
- if (value === null || typeof value !== "object" || !Object.hasOwn(value, key)) return null;
114
- value = value[key];
115
- }
116
- return value === void 0 ? null : value !== null && typeof value === "object" ? structuredClone(value) : value;
117
- }
118
- function controllerNamespaces(options, source) {
119
- const reported = /* @__PURE__ */ new Set();
120
- const nested = /* @__PURE__ */ new WeakMap();
121
- const eventType = typeof Event === "undefined" ? void 0 : Object.getOwnPropertyDescriptor(Event.prototype, "type").get;
122
- const eventBrands = /* @__PURE__ */ new WeakMap();
123
- const nativeEvent = (value) => {
124
- if (!("type" in value) || eventType === void 0) return false;
125
- const known = eventBrands.get(value);
126
- if (known !== void 0) return known;
127
- let accepted = false;
128
- try {
129
- eventType.call(value);
130
- accepted = true;
131
- } catch {}
132
- eventBrands.set(value, accepted);
133
- return accepted;
134
- };
135
- const warn = (path, readonly) => {
136
- if (reported.has(path)) return;
137
- reported.add(path);
138
- console.warn(source + ": HR007: Destination " + path + (readonly ? " is read-only." : " does not satisfy its declared type."));
139
- };
140
- const write = (name, keys, value, readonly, apply) => {
141
- if (readonly || options.acceptsState?.(name, keys, value) === false) warn([name, ...keys].join("."), readonly);
142
- else apply();
143
- return true;
144
- };
145
- const plain = /* @__PURE__ */ new WeakMap();
146
- const unwrap = (value) => typeof value === "object" && value !== null && plain.has(value) ? plain.get(value) : value;
147
- const wrap = (value, name, keys, readonly) => {
148
- if (value === null || typeof value !== "object" || nativeEvent(value)) return value;
149
- const path = [name, ...keys].join(".");
150
- let paths = nested.get(value);
151
- if (paths === void 0) nested.set(value, paths = /* @__PURE__ */ new Map());
152
- const known = paths.get(path);
153
- if (known !== void 0) return known;
154
- const surface = readonly ? Array.isArray(value) ? [] : Object.create(Object.getPrototypeOf(value)) : value;
155
- if (readonly && Array.isArray(value)) surface.length = value.length;
156
- const proxy = new Proxy(surface, {
157
- get: (_target, key) => {
158
- if (!readonly) options.read?.(name, [...keys, String(key)]);
159
- return wrap(Reflect.get(value, key), name, [...keys, String(key)], readonly);
160
- },
161
- set: (_target, key, written) => {
162
- const next = unwrap(written) ?? initialAt(options.initials?.[name] ?? null, [...keys, String(key)]);
163
- return write(name, [...keys, String(key)], next, readonly, () => {
164
- const previous = Reflect.get(value, key);
165
- const length = Array.isArray(value) ? value.length : void 0;
166
- if (Reflect.set(value, key, next) && !Object.is(previous, next)) options.changed?.(name, [...keys, String(key)]);
167
- if (length !== void 0 && length !== value.length && key !== "length") options.changed?.(name, [...keys, "length"]);
168
- });
169
- },
170
- has: (_target, key) => Reflect.has(value, key),
171
- ownKeys: () => Reflect.ownKeys(value),
172
- getOwnPropertyDescriptor: (_target, key) => {
173
- if (readonly && Array.isArray(value) && key === "length") {
174
- surface.length = value.length;
175
- return Reflect.getOwnPropertyDescriptor(surface, key);
176
- }
177
- const descriptor = Reflect.getOwnPropertyDescriptor(value, key);
178
- return descriptor === void 0 ? void 0 : readonly ? {
179
- ...descriptor,
180
- configurable: true
181
- } : descriptor;
182
- },
183
- deleteProperty: (_target, key) => write(name, [...keys, String(key)], void 0, readonly, () => {
184
- if (Reflect.has(value, key) && Reflect.deleteProperty(value, key)) options.changed?.(name, [...keys, String(key)]);
185
- }),
186
- defineProperty: (_target, key, descriptor) => {
187
- if (readonly || !("value" in descriptor) || options.acceptsState?.(name, [...keys, String(key)], descriptor.value) === false) {
188
- warn([
189
- name,
190
- ...keys,
191
- String(key)
192
- ].join("."), readonly);
193
- return false;
194
- }
195
- const changed = Reflect.defineProperty(value, key, descriptor);
196
- if (changed) options.changed?.(name, [...keys, String(key)]);
197
- return changed;
198
- }
199
- });
200
- paths.set(path, proxy);
201
- plain.set(proxy, value);
202
- return proxy;
203
- };
204
- const state = new Proxy({}, {
205
- get: (_target, name) => {
206
- if (typeof name !== "string") return void 0;
207
- if (Object.hasOwn(options.state, name)) return wrap(options.state[name].get(), name, [], false);
208
- if (Object.hasOwn(options.computed, name)) return wrap(options.computed[name](), name, [], true);
209
- },
210
- set: (_target, name, value) => write(String(name), [], unwrap(value), typeof name !== "string" || !Object.hasOwn(options.state, name), () => options.state[String(name)].set(unwrap(value) ?? initialAt(options.initials?.[String(name)] ?? null, []))),
211
- deleteProperty: (_target, name) => {
212
- warn(String(name), true);
213
- return true;
214
- },
215
- defineProperty: (_target, name) => {
216
- warn(String(name), true);
217
- return false;
218
- },
219
- has: (_target, name) => typeof name === "string" && (Object.hasOwn(options.state, name) || Object.hasOwn(options.computed, name))
220
- });
221
- const data = new Proxy({}, {
222
- get: (_target, name) => typeof name === "string" && Object.hasOwn(options.data ?? {}, name) ? wrap(options.data[name](), "data." + name, [], true) : void 0,
223
- set: (_target, name, value) => write("data." + String(name), [], value, true, () => {}),
224
- deleteProperty: (_target, name) => {
225
- warn("data." + String(name), true);
226
- return true;
227
- },
228
- defineProperty: (_target, name) => {
229
- warn("data." + String(name), true);
230
- return false;
231
- },
232
- has: (_target, name) => typeof name === "string" && Object.hasOwn(options.data ?? {}, name)
233
- });
234
- const reset = (name) => {
235
- if (name !== void 0 && !Object.hasOwn(options.state, name)) throw new TypeError("`" + String(name) + "` is not a state of " + source + ".");
236
- for (const each of name === void 0 ? Object.keys(options.state) : [name]) options.state[each].set(initialAt(options.initials?.[each] ?? null, []));
237
- };
238
- return {
239
- state,
240
- data,
241
- reset
242
- };
243
- }
244
- var requestStateKey = Symbol.for("@nextwebwg/html-next.runtime.v1");
245
- var documentRecord = (root) => root.ownerDocument[requestStateKey] ??= {};
246
- /** Requests from inside root wait until its controller has run; the returned release ends the wait. */
247
- function holdController(root) {
248
- const { g: gates } = documentRecord(root).requests ??= { g: /* @__PURE__ */ new WeakMap() };
249
- let release;
250
- const gate = new Promise((resolve) => {
251
- release = resolve;
252
- });
253
- gates.set(root, gate);
254
- return () => {
255
- if (gates.get(root) === gate) gates.delete(root);
256
- release();
257
- };
258
- }
259
- /** A responder registered on root relays to the requests inside it that went unanswered, once a page asks. */
260
- function relayResponders(root, name) {
261
- documentRecord(root).relay?.(root, name);
262
- }
263
- /** Records a responder hasResponder can see on root until the returned function runs; own lists its controller's. */
264
- function knownResponder(root, name, own) {
265
- const record = documentRecord(root);
266
- const known = record.k ??= /* @__PURE__ */ new WeakMap();
267
- const names = known.get(root) ?? known.set(root, []).get(root);
268
- const change = (add) => {
269
- for (const list of own === void 0 ? [names] : [names, own]) if (add) list.push(name);
270
- else list.splice(list.indexOf(name), 1);
271
- record.w?.forEach((changed) => changed(name));
272
- };
273
- change(true);
274
- let held = true;
275
- return () => {
276
- if (held) {
277
- held = false;
278
- change(false);
279
- }
280
- };
281
- }
282
- /** For a component that asks: a responder announcement reaches its controller only as the relay to its root, which does not bubble. */
283
- function hostListener(type, callback) {
284
- return (event) => {
285
- if (type !== "responder" || !event.bubbles) callback(event);
286
- };
287
- }
288
- /** The connection signal requests use: it aborts when the component disconnects. */
289
- function requestConnection() {
290
- let current;
291
- return {
292
- signal: (connected) => connected ? (current ??= new AbortController()).signal : AbortSignal.abort(new DOMException("The component is not connected.", "AbortError")),
293
- end: () => {
294
- current?.abort();
295
- current = void 0;
296
- }
297
- };
298
- }
299
- function dispatchToTargets(recorded, send) {
300
- const targets = (recorded instanceof Set ? [...recorded] : Array.isArray(recorded) ? [...recorded] : [recorded]).map((ref) => ref?.nodeType === 1 ? ref : ref?.$el).filter((element) => element?.nodeType === 1 && element.isConnected).sort((a, b) => a === b ? 0 : a.compareDocumentPosition(b) & 4 ? -1 : 1);
301
- for (const target of targets) if (target.isConnected) send(target);
302
- }
303
- /** Vue refs a component invocation as its public instance; the ref is the root element it lowered to. */
304
- function refElement(ref) {
305
- return ref == null || ref.nodeType === 1 ? ref : ref.$el;
306
- }
307
- /** The root ref as an element: a delegating component's root ref holds the invoked component. */
308
- function rootElement(root) {
309
- return { get value() {
310
- return refElement(root.value);
311
- } };
312
- }
313
- var runtimeKey = Symbol.for("@nextwebwg/html-next.runtime.v1");
314
- function observeConnection(element, check) {
315
- const document = element.ownerDocument;
316
- const state = document[runtimeKey] ??= {};
317
- let hub = state.mutationHub;
318
- if (hub === void 0) {
319
- const Observer = document.defaultView?.MutationObserver ?? MutationObserver;
320
- const subscribers = /* @__PURE__ */ new Set();
321
- const observer = new Observer((mutations) => {
322
- for (const notify of Array.from(subscribers)) notify(mutations);
323
- });
324
- hub = {
325
- observer,
326
- subscribers
327
- };
328
- state.mutationHub = hub;
329
- observer.observe(document, {
330
- childList: true,
331
- subtree: true
332
- });
333
- }
334
- const shared = hub;
335
- const subscriber = () => check();
336
- shared.subscribers.add(subscriber);
337
- return () => {
338
- shared.subscribers.delete(subscriber);
339
- if (shared.subscribers.size === 0 && state.mutationHub === shared) {
340
- shared.observer.disconnect();
341
- delete state.mutationHub;
342
- }
343
- };
344
- }
345
- /** Keep native focus on the corresponding control when a root-level $match replaces its element. */
346
- function preserveRootFocus(componentRoot) {
347
- const root = rootElement(componentRoot);
348
- const focusable = "a[href], button, input, select, textarea, summary, [tabindex], [contenteditable]";
349
- let previous = null;
350
- let active = null;
351
- let focusIndex = -1;
352
- onBeforeUpdate(() => {
353
- previous = root.value;
354
- active = previous?.ownerDocument.activeElement ?? null;
355
- focusIndex = previous !== null && active !== null && active !== previous && previous.contains(active) ? Array.from(previous.querySelectorAll(focusable)).indexOf(active) : -1;
356
- });
357
- onUpdated(() => {
358
- const next = root.value;
359
- if (previous === null || next === null || previous === next) return;
360
- (active === previous ? next : active?.isConnected === true && next.contains(active) ? active : focusIndex >= 0 ? next.querySelectorAll(focusable)[focusIndex] : void 0)?.focus?.({ preventScroll: true });
361
- });
362
- }
363
- /** Vue does not promise a `v-for` ref array in source order, and the host does. */
364
- function inDocumentOrder(elements) {
365
- return [...elements].sort((a, b) => (a.compareDocumentPosition(b) & 4) !== 0 ? -1 : 1);
366
- }
367
- /** Slot content flattened to the elements Vue mounted for it, descending through fragments. */
368
- function slottedElements(nodes) {
369
- const elements = [];
370
- for (const node of nodes) if (node.type === Fragment && Array.isArray(node.children)) elements.push(...slottedElements(node.children));
371
- else if (node.el instanceof Element) elements.push(node.el);
372
- return elements;
373
- }
374
- /**
375
- * The controller host, built from Vue refs, effects, and lifecycle. Reads and writes reach the
376
- * component's own refs, so a controller's change renders as any other Vue change does. Vue
377
- * hooks cover mount/unmount; a shared native observer also detects external root detachment
378
- * and reinsertion without treating an in-tree move as a new connection.
379
- */
380
- function useComponentHost(controllerLoader, options) {
381
- const root = rootElement(options.root);
382
- const { dispatch, props, propInputs = () => null, propNames = [], refs = {}, state = {}, computed: computedValues = {}, data = {}, context = {} } = options;
383
- const vueSlots = useSlots();
384
- const component = getCurrentInstance();
385
- const report = (error) => {
386
- const handler = component?.appContext.config.errorHandler;
387
- if (handler === void 0) queueMicrotask(() => {
388
- throw error;
389
- });
390
- else handler(error, component?.proxy ?? null, "HTML Next controller");
391
- };
392
- const controllerDiagnostic = (code, reason) => {
393
- const edge = options.controllerSource;
394
- const source = edge?.definition ? new URL(edge.definition, document.baseURI).href : void 0;
395
- const url = new URL(edge?.specifier ?? "", source ?? document.baseURI).href;
396
- const message = code === "HJ002" ? options.module ? "Component module `" + url + "` export connect must be a function." : "Controller module `" + url + "` must default-export a function." : "Controller module `" + url + "` failed to load: " + (reason instanceof Error ? reason.message : String(reason)) + ".";
397
- return Object.assign(/* @__PURE__ */ new Error((source === void 0 ? "" : source + ": ") + code + ": " + message), {
398
- name: "HtmlDiagnosticError",
399
- diagnostic: Object.freeze({
400
- code,
401
- message,
402
- ...source === void 0 ? {} : { source }
403
- })
404
- });
405
- };
406
- let controllerModule;
407
- const loadControllerModule = () => controllerModule ??= Promise.resolve().then(controllerLoader).then((candidate) => {
408
- const loaded = candidate;
409
- if (options.module ? loaded === null || typeof loaded !== "object" || loaded.connect !== void 0 && typeof loaded.connect !== "function" : typeof loaded?.default !== "function") throw controllerDiagnostic("HJ002");
410
- return candidate;
411
- }).catch((error) => {
412
- if (error instanceof Error && "diagnostic" in error) throw error;
413
- throw controllerDiagnostic("HJ001", error);
414
- });
415
- const stops = [];
416
- const connected = shallowRef(false);
417
- const pauses = /* @__PURE__ */ new Map();
418
- const subscriptions = /* @__PURE__ */ new Set();
419
- const own = [];
420
- const track = (entry) => {
421
- entry.k?.();
422
- entry.k = entry.target === void 0 || entry.r?.() === false ? void 0 : knownResponder(entry.target, entry.type, entry.r ? void 0 : own);
423
- };
424
- const activate = (entry) => {
425
- if (entry.type === "connect") entry.cleanup = entry.callback(new Event("connect"));
426
- else if (entry.type !== "disconnect") {
427
- entry.target = root.value ?? void 0;
428
- entry.target?.addEventListener(entry.type, entry.callback);
429
- track(entry);
430
- if (entry.target !== void 0) relayResponders(entry.target, entry.type);
431
- }
432
- };
433
- const deactivate = (entry, disconnecting) => {
434
- entry.target?.removeEventListener(entry.type, entry.callback);
435
- entry.target = void 0;
436
- track(entry);
437
- const cleanup = entry.cleanup;
438
- entry.cleanup = void 0;
439
- cleanup?.();
440
- if (disconnecting && entry.type === "disconnect") entry.callback(new Event("disconnect"));
441
- };
442
- const propHandles = Object.create(null);
443
- for (const name of propNames) {
444
- const validity = () => options.propValidity?.(name);
445
- const value = computed(() => props?.value[name]);
446
- propHandles[name] = Object.freeze({
447
- get value() {
448
- return value.value;
449
- },
450
- get inputValue() {
451
- return propInputs(name);
452
- },
453
- get validity() {
454
- return validity();
455
- },
456
- validate: validity
457
- });
458
- }
459
- let lastRoot = null;
460
- const host = {
461
- get [Symbol.for("@nextwebwg/html-next.inputs.v1")]() {
462
- return options.inputs?.port({
463
- declarations: Object.fromEntries([
464
- ...Object.keys(state),
465
- ...Object.keys(computedValues),
466
- ...Object.keys(context)
467
- ].map((name) => [name, {
468
- read: () => host.state[name],
469
- status: () => options.availability?.[name]?.() ?? READY_INPUT
470
- }])),
471
- track: (name, kind) => options.inputTracking.track(name, kind),
472
- watch: (run) => host.effect(run),
473
- untracked: (run) => options.inputTracking.untracked(run)
474
- });
475
- },
476
- get element() {
477
- return root.value ?? lastRoot;
478
- },
479
- get root() {
480
- return root.value ?? lastRoot;
481
- },
482
- ...controllerNamespaces({
483
- state: Object.fromEntries(Object.entries(state).map(([name, value]) => [name, {
484
- get: () => value.value,
485
- set: (next) => {
486
- value.value = next;
487
- }
488
- }])),
489
- computed: Object.fromEntries([...Object.entries(computedValues), ...Object.entries(context)].map(([name, value]) => [name, () => value.value])),
490
- data: Object.fromEntries(Object.entries(data).map(([name, value]) => [name, () => value.value])),
491
- ...options.acceptsState === void 0 ? {} : { acceptsState: options.acceptsState },
492
- ...options.initials === void 0 ? {} : { initials: options.initials }
493
- }, options.controllerSource?.definition ?? "<component>"),
494
- scripts: options.scripts ?? Object.freeze({}),
495
- on(type, callback) {
496
- return listen(type, callback);
497
- },
498
- props: Object.freeze(propHandles),
499
- refs: Object.defineProperties({}, Object.fromEntries(Object.entries(refs).map(([name, ref]) => [name, {
500
- enumerable: true,
501
- get: () => Array.isArray(ref.value) ? inDocumentOrder(ref.value.map(refElement)) : refElement(ref.value)
502
- }]))),
503
- slots: new Proxy({}, {
504
- get: (_target, name) => {
505
- if (typeof name !== "string") return void 0;
506
- const render = vueSlots[name];
507
- return render === void 0 ? [] : slottedElements(render());
508
- },
509
- has: (_target, name) => typeof name === "string" && vueSlots[name] !== void 0
510
- }),
511
- signal(initialValue) {
512
- const value = shallowRef(initialValue);
513
- return {
514
- get: () => value.value,
515
- set: (next) => {
516
- value.value = next;
517
- },
518
- update: (next) => {
519
- value.value = next(value.value);
520
- }
521
- };
522
- },
523
- computed(compute) {
524
- const value = computed(compute);
525
- return { get: () => value.value };
526
- },
527
- effect(run) {
528
- let cleanup;
529
- const pause = () => {
530
- const previous = cleanup;
531
- cleanup = void 0;
532
- previous?.();
533
- };
534
- const stop = watchEffect(() => {
535
- pause();
536
- if (connected.value) cleanup = run();
537
- }, { flush: "post" });
538
- const dispose = () => {
539
- stop();
540
- pause();
541
- pauses.delete(dispose);
542
- const index = stops.indexOf(dispose);
543
- if (index >= 0) stops.splice(index, 1);
544
- };
545
- pauses.set(dispose, pause);
546
- stops.push(dispose);
547
- return dispose;
548
- },
549
- dispatch,
550
- ...options.request === void 0 ? {} : { request: (name, detail, requestOptions) => options.request(root.value, requests.signal(connected.value), name, detail, requestOptions) }
551
- };
552
- function listen(type, callback, set) {
553
- const entry = {
554
- type,
555
- callback: type === "connect" || type === "disconnect" || options.request === void 0 ? callback : hostListener(type, callback)
556
- };
557
- if (set !== void 0) entry.r = set;
558
- subscriptions.add(entry);
559
- if (connected.value) activate(entry);
560
- return () => {
561
- if (subscriptions.delete(entry)) deactivate(entry, false);
562
- };
563
- }
564
- if (options.request?.has !== void 0) Object.assign(host, { hasResponder: options.request.has(host, own) });
565
- const requests = requestConnection();
566
- const responders = Object.entries(options.responders ?? {});
567
- for (const [name, read] of responders) listen(name, (event) => read()?.(event), () => read() !== void 0);
568
- if (responders.length > 0) watch(() => responders.map(([, read]) => read() !== void 0), (now, before) => {
569
- for (const entry of subscriptions) if (entry.r !== void 0) track(entry);
570
- const element = root.value;
571
- if (element === null || !connected.value) return;
572
- now.forEach((set, index) => {
573
- if (set && !before[index]) relayResponders(element, responders[index][0]);
574
- });
575
- });
576
- let cleanup;
577
- let started;
578
- let stopObserving;
579
- let connection = 0;
580
- let initialized = false;
581
- let unmounted = false;
582
- let releaseController;
583
- const disconnect = () => {
584
- if (!connected.value) return;
585
- connected.value = false;
586
- connection += 1;
587
- requests.end();
588
- releaseController?.();
589
- for (const pause of pauses.values()) pause();
590
- for (const entry of subscriptions) deactivate(entry, true);
591
- cleanup?.();
592
- cleanup = void 0;
593
- };
594
- const synchronize = () => {
595
- if (unmounted) return;
596
- lastRoot = root.value ?? lastRoot;
597
- if (root.value?.isConnected !== true) {
598
- disconnect();
599
- return;
600
- }
601
- if (connected.value) {
602
- for (const entry of subscriptions) if (entry.type !== "connect" && entry.type !== "disconnect" && entry.target !== root.value) {
603
- deactivate(entry, false);
604
- activate(entry);
605
- }
606
- return;
607
- }
608
- connected.value = true;
609
- for (const entry of subscriptions) activate(entry);
610
- if (initialized && !options.module) return;
611
- const current = ++connection;
612
- const release = releaseController = holdController(root.value);
613
- started = loadControllerModule().then(async (loaded) => {
614
- if (!connected.value || current !== connection || initialized && !options.module) return loaded;
615
- initialized = true;
616
- if (options.module) {
617
- try {
618
- cleanup = activateModule(loaded, host, report);
619
- } finally {
620
- release();
621
- }
622
- return loaded;
623
- }
624
- let invoked;
625
- try {
626
- invoked = loaded.default(host);
627
- } finally {
628
- release();
629
- }
630
- const result = await invoked;
631
- if (typeof result === "function") {
632
- if (!connected.value || current !== connection) result();
633
- else cleanup = result;
634
- }
635
- return loaded;
636
- });
637
- started.catch(report).finally(release);
638
- };
639
- onMounted(() => {
640
- if (root.value === null) return;
641
- stopObserving = observeConnection(root.value, () => {
642
- try {
643
- synchronize();
644
- } catch (error) {
645
- report(error);
646
- }
647
- });
648
- synchronize();
649
- });
650
- onUpdated(synchronize);
651
- onBeforeUnmount(() => {
652
- unmounted = true;
653
- stopObserving?.();
654
- disconnect();
655
- for (const stop of stops.splice(0)) stop();
656
- subscriptions.clear();
657
- });
658
- return host;
659
- }
660
- var HtmlDiagnosticError = class extends Error {
661
- diagnostic;
662
- constructor(code, message) {
663
- super(code + ": " + message);
664
- this.name = "HtmlDiagnosticError";
665
- this.diagnostic = Object.freeze({
666
- code,
667
- message
668
- });
669
- }
670
- };
671
- /** Reports declared CustomEvents to Vue and dispatches them through the DOM. */
672
- function createDispatch(componentRoot, emit, options = {}) {
673
- const root = rootElement(componentRoot);
674
- const { declared = {}, checks = {}, modeled = [] } = options;
675
- const reported = /* @__PURE__ */ new Map();
676
- return (name, detail, targets) => {
677
- const check = checks[name];
678
- if (detail !== void 0 && check !== void 0 && !check(detail)) throw new HtmlDiagnosticError("HR002", `Event \`${name}\` detail does not satisfy its declared type.`);
679
- if (targets !== void 0) {
680
- let accepted = true;
681
- dispatchToTargets(targets, (target) => {
682
- if (!target.dispatchEvent(new CustomEvent(name, {
683
- bubbles: true,
684
- composed: true,
685
- ...declared[name],
686
- detail
687
- }))) accepted = false;
688
- });
689
- return accepted;
690
- }
691
- if (detail !== null && typeof detail === "object") for (const prop of modeled) {
692
- if (!(prop in detail)) continue;
693
- const value = detail[prop];
694
- if (reported.has(prop) && Object.is(reported.get(prop), value)) continue;
695
- if (reported.size === 0) queueMicrotask(() => reported.clear());
696
- reported.set(prop, value);
697
- emit?.(`update:${prop}`, value);
698
- }
699
- const event = new CustomEvent(name, {
700
- bubbles: true,
701
- composed: true,
702
- ...declared[name],
703
- detail
704
- });
705
- if (check !== void 0) emit?.(name, event);
706
- return root.value?.dispatchEvent(event) ?? true;
707
- };
708
- }
709
- /**
710
- * A consumer's attributes for the root. Vue sets a name that is also an object property, such as
711
- * `constructor`, as a DOM property; capitalized, it stays an attribute, which HTML lowercases.
712
- */
713
- function nativeAttrs(attrs) {
714
- const names = Object.keys(attrs);
715
- if (!names.some((name) => Object.hasOwn(Object.prototype, name))) return attrs;
716
- return Object.fromEntries(names.map((name) => [Object.hasOwn(Object.prototype, name) ? name === "__proto__" ? "__Proto__" : name[0].toUpperCase() + name.slice(1) : name, attrs[name]]));
717
- }
718
- /** Hydrating server markup needs its root to be the element this component renders. */
719
- function checkHydratedRoot(expected, tag) {
720
- const node = getCurrentInstance()?.vnode.el;
721
- if (typeof window === "undefined" || node == null || node instanceof Element && node.localName === expected) return;
722
- const message = `Server markup for <${tag}> has an incompatible root.`;
723
- throw Object.assign(/* @__PURE__ */ new Error(`HR005: ${message}`), {
724
- name: "HtmlDiagnosticError",
725
- diagnostic: Object.freeze({
726
- code: "HR005",
727
- message
728
- })
729
- });
730
- }
731
- function diagnostic(code, message) {
732
- return Object.assign(/* @__PURE__ */ new Error(`${code}: ${message}`), {
733
- name: "HtmlDiagnosticError",
734
- diagnostic: Object.freeze({
735
- code,
736
- message
737
- })
738
- });
739
- }
740
- /** Vue may return an in-progress computed value on a cyclic read; guard the public value access instead. */
741
- function cycleCheckedComputed(evaluate) {
742
- const value = computed(evaluate);
743
- let reading = false;
744
- return new Proxy(value, { get(target, property) {
745
- if (property !== "value") return Reflect.get(target, property);
746
- if (reading) throw diagnostic("HR006", "A reactive computed value depends on itself.");
747
- reading = true;
748
- try {
749
- return target.value;
750
- } finally {
751
- reading = false;
752
- }
753
- } });
754
- }
755
- /** A Vue state cell owns its first usable seed or an earlier accepted edit, including equal writes. */
756
- function initializedState(evaluate, accepts, copy, warn) {
757
- const cell = ref();
758
- let seed = cycleCheckedComputed(evaluate);
759
- let initialized = false;
760
- let stop;
761
- let notify = () => {};
762
- const claim = () => {
763
- if (initialized) return;
764
- initialized = true;
765
- seed = void 0;
766
- if (stop !== void 0) queueMicrotask(stop);
767
- };
768
- const initialize = () => {
769
- if (initialized) return;
770
- const next = seed.value;
771
- if (!next.status.ready || next.status.stale || next.value === void 0) return;
772
- if (!accepts(next.value)) {
773
- warn();
774
- return;
775
- }
776
- claim();
777
- cell.value = copy(next.value);
778
- notify();
779
- };
780
- const state = customRef((track, trigger) => {
781
- notify = trigger;
782
- return {
783
- get() {
784
- track();
785
- initialize();
786
- return cell.value;
787
- },
788
- set(value) {
789
- if (value != null && !accepts(value)) {
790
- warn();
791
- return;
792
- }
793
- const first = !initialized;
794
- claim();
795
- cell.value = value ?? null;
796
- if (first) trigger();
797
- }
798
- };
799
- });
800
- return Object.assign(state, {
801
- status() {
802
- state.value;
803
- return initialized ? cell.value === void 0 ? {
804
- ...READY_INPUT,
805
- ready: false
806
- } : READY_INPUT : {
807
- ...seed.value.status,
808
- ready: false,
809
- stale: false
810
- };
811
- },
812
- start() {
813
- if (initialized) return;
814
- stop = watchEffect(() => {
815
- state.value;
816
- });
817
- if (initialized) stop();
818
- }
819
- });
820
- }
821
- /**
822
- * A declared prop's reflected root attribute: the authored literal until the consumer passes the
823
- * prop, then its value as text, absent for null.
824
- */
825
- function useReflectedProp() {
826
- const instance = getCurrentInstance();
827
- return (name, kebab, value, fallback, bound, separator) => {
828
- const incoming = instance?.vnode.props;
829
- if (!bound && (incoming === null || incoming === void 0 || !Object.hasOwn(incoming, name) && !Object.hasOwn(incoming, kebab))) return fallback;
830
- if (value === null || value === void 0) return void 0;
831
- return Array.isArray(value) && separator !== void 0 ? value.join(separator) : typeof value === "object" ? JSON.stringify(value) : String(value);
832
- };
833
- }
834
- /** A scoped slot's name, which the consumer must fill with a `<template slot>` rather than plain children. */
835
- function useScopedSlotName() {
836
- const slots = useSlots();
837
- return (name) => {
838
- if (slots[name] === void 0 && slots.default?.().some((node) => node.props?.slot === name)) throw diagnostic("HR007", "Scoped slot `" + name + "` requires a consumer <template slot=\"" + name + "\">.");
839
- return name;
840
- };
841
- }
842
- function inlineTextSegment(value, accepted, text) {
843
- return {
844
- value,
845
- accepted,
846
- text: accepted && value !== Symbol.for("html-next.invalid-result") ? text(value) ?? "" : ""
847
- };
848
- }
849
- var RetainedInlineText = /* @__PURE__ */ defineComponent({
850
- props: { segments: {
851
- type: Array,
852
- required: true
853
- } },
854
- setup(props) {
855
- const previous = [];
856
- return () => createTextVNode(props.segments.map((segment, index) => {
857
- if (segment.accepted && segment.value !== Symbol.for("html-next.invalid-result")) previous[index] = segment.text;
858
- return previous[index] ?? "";
859
- }).join(""));
860
- }
861
- });
862
- var KeyedFailure = /* @__PURE__ */ defineComponent({
863
- props: { error: {
864
- type: null,
865
- required: true
866
- } },
867
- setup(props) {
868
- return () => {
869
- throw props.error;
870
- };
871
- }
872
- });
873
- /** A keyed list that produces a duplicate key keeps its last rows and reports the error in the browser. */
874
- var KeyedBoundary = /* @__PURE__ */ defineComponent({ setup(_props, { slots }) {
875
- let last = [];
876
- return () => {
877
- try {
878
- last = slots.default?.() ?? [];
879
- return last;
880
- } catch (error) {
881
- if (!(error instanceof Error) || error.diagnostic?.code !== "HR004") throw error;
882
- if (typeof window === "undefined") throw error;
883
- return [...last, h(KeyedFailure, { error })];
884
- }
885
- };
886
- } });
887
- var warned = /* @__PURE__ */ new Set();
888
- /** An authored value's check: false warns once per authored location. */
889
- function warnUnless(accepted, location, message) {
890
- if (!accepted && !warned.has(location)) {
891
- warned.add(location);
892
- console.warn(message);
893
- }
894
- return accepted;
895
- }
896
- function text(value) {
897
- if (Array.isArray(value)) return value.map(text).join(" ");
898
- return value === null || value === void 0 || typeof value === "object" ? "" : String(value);
899
- }
900
- function attribute(value) {
901
- if (value === null || value === void 0 || value === false || typeof value === "object" && !Array.isArray(value)) return void 0;
902
- return value === true ? "" : text(value);
903
- }
904
- function list(value) {
905
- return Array.isArray(value) ? value : [];
906
- }
907
- function number(value) {
908
- return typeof value === "number" && !Number.isNaN(value) ? value : void 0;
909
- }
910
- function concat(...values) {
911
- if (values.some((value) => value === Symbol.for("html-next.invalid-result"))) return Symbol.for("html-next.invalid-result");
912
- if (values.some((value) => value === void 0)) return void 0;
913
- if (values.length === 0 || values.some((value) => typeof value === "object" && value !== null)) return Symbol.for("html-next.invalid-result");
914
- return values.map((value) => value === null ? "" : String(value)).join("");
915
- }
916
- function math(fn, kinds, values) {
917
- if (values.includes(Symbol.for("html-next.invalid-result"))) return Symbol.for("html-next.invalid-result");
918
- if (values.some((value) => value === void 0 || value === null)) return void 0;
919
- if ((fn === "abs" || fn === "negate") && values.length !== 1 || fn === "round" && (values.length < 1 || values.length > 2) || (fn === "min" || fn === "max") && values.length === 0 || fn === "clamp" && values.length !== 3) return Symbol.for("html-next.invalid-result");
920
- const kind = kinds[0];
921
- const dimensional = kind === "length" || kind === "percentage" || kind === "duration";
922
- if (!dimensional && kind !== "number") return Symbol.for("html-next.invalid-result");
923
- let unit;
924
- const numbers = [];
925
- for (let index = 0; index < values.length; index++) {
926
- if (kinds[index] !== kind) return Symbol.for("html-next.invalid-result");
927
- const value = values[index];
928
- if (!dimensional) {
929
- if (typeof value !== "number" || !Number.isFinite(value)) return Symbol.for("html-next.invalid-result");
930
- numbers.push(value);
931
- continue;
932
- }
933
- if (typeof value !== "string") return Symbol.for("html-next.invalid-result");
934
- const match = /^(-?(?:\d+(?:\.\d+)?|\.\d+))(vmin|vmax|rem|px|em|vw|vh|ch|ex|cm|mm|in|pt|pc|q|ms|s|%)$/.exec(value);
935
- if (match === null || unit !== void 0 && match[2] !== unit) return Symbol.for("html-next.invalid-result");
936
- unit = match[2];
937
- if ((unit === "%" ? "percentage" : unit === "ms" || unit === "s" ? "duration" : "length") !== kind) return Symbol.for("html-next.invalid-result");
938
- const number = Number(match[1]);
939
- if (!Number.isFinite(number)) return Symbol.for("html-next.invalid-result");
940
- numbers.push(number);
941
- }
942
- let result;
943
- switch (fn) {
944
- case "abs":
945
- result = Math.abs(numbers[0]);
946
- break;
947
- case "negate":
948
- result = -numbers[0];
949
- break;
950
- case "round": {
951
- const step = Math.abs(numbers[1] ?? 1);
952
- if (step === 0) return Symbol.for("html-next.invalid-result");
953
- result = Math.round(numbers[0] / step) * step;
954
- break;
955
- }
956
- case "min":
957
- result = Math.min(...numbers);
958
- break;
959
- case "max":
960
- result = Math.max(...numbers);
961
- break;
962
- case "clamp":
963
- result = Math.max(numbers[0], Math.min(numbers[1], numbers[2]));
964
- break;
965
- default: return Symbol.for("html-next.invalid-result");
966
- }
967
- return !Number.isFinite(result) ? Symbol.for("html-next.invalid-result") : unit === void 0 ? result : String(result) + unit;
968
- }
969
- function uniqueKeys(items, keyOf) {
970
- const seen = /* @__PURE__ */ new Set();
971
- for (let index = 0; index < items.length; index += 1) {
972
- const key = keyOf(items[index], index, {
973
- index,
974
- first: index === 0,
975
- last: index === items.length - 1,
976
- count: items.length
977
- });
978
- if (seen.has(key)) {
979
- const message = `A keyed list produced duplicate key \`${text(key)}\`.`;
980
- throw Object.assign(/* @__PURE__ */ new Error(`HR004: ${message}`), {
981
- name: "HtmlDiagnosticError",
982
- diagnostic: Object.freeze({
983
- code: "HR004",
984
- message
985
- })
986
- });
987
- }
988
- seen.add(key);
989
- }
990
- return items;
991
- }
992
- /**
993
- * Digits after the point in `value`'s shortest round-trip text, as `Number#toString` writes it:
994
- * 2 for 1.25, 7 for 1e-7, and 0 for an integer, 1e21, NaN or Infinity. Writing that text made an
995
- * addition about ten times slower (200 ns against 20 ns), so up to 22 places, where 10^places is
996
- * exact, the fewest places at which `value` survives rounding stand in for it. That count is never
997
- * below the text's, and differs only for a value of more than 15 significant digits, which
998
- * `decimalResult` leaves as a double either way.
999
- */
1000
- function decimalPlaces(value) {
1001
- if (Number.isInteger(value)) return 0;
1002
- for (let places = 1; places <= 22; places += 1) if (Math.round(value * 10 ** places) / 10 ** places === value) return places;
1003
- const [digits, exponent] = String(value).split("e");
1004
- const point = digits.indexOf(".");
1005
- return Math.max(0, (point < 0 ? 0 : digits.length - point - 1) - Number(exponent ?? 0));
1006
- }
1007
- /**
1008
- * The double nearest the exact decimal result: `a` and `b` become integers at `left` and `right`
1009
- * places, `combine` joins them, and the integer is read back at `places`. Every step is exact while
1010
- * the operands and `result` stay below 10^15 at `places`, the 15 significant digits a double always
1011
- * holds; past that (or for a non-finite value, or with no places) the double `result` stands.
1012
- * Dividing by 10^places is exact only up to 10^22, so past 22 places a nonzero integer is read back
1013
- * by parsing its decimal text, which rounds exactly too. A zero divides, keeping its sign.
1014
- */
1015
- function decimalResult(result, a, b, left, right, places, combine) {
1016
- if (!(places > 0 && Math.max(Math.abs(a), Math.abs(b), Math.abs(result)) * 10 ** places < 0x38d7ea4c68000)) return result;
1017
- const integer = combine(Math.round(a * 10 ** left), Math.round(b * 10 ** right));
1018
- return places > 22 && integer !== 0 ? Number(`${integer}e-${places}`) : integer / 10 ** places;
1019
- }
1020
- /** `a + b` at the larger operand's decimal places: `decimalAdd(0.1, 0.2)` is 0.3. */
1021
- function decimalAdd(a, b) {
1022
- const places = Math.max(decimalPlaces(a), decimalPlaces(b));
1023
- return decimalResult(a + b, a, b, places, places, places, (x, y) => x + y);
1024
- }
1025
- /** `a - b` at the larger operand's decimal places: `decimalSubtract(0.3, 0.1)` is 0.2. */
1026
- function decimalSubtract(a, b) {
1027
- const places = Math.max(decimalPlaces(a), decimalPlaces(b));
1028
- return decimalResult(a - b, a, b, places, places, places, (x, y) => x - y);
1029
- }
1030
- /** `a * b` at the sum of the operands' decimal places: `decimalMultiply(0.1, 0.2)` is 0.02. */
1031
- function decimalMultiply(a, b) {
1032
- const left = decimalPlaces(a);
1033
- const right = decimalPlaces(b);
1034
- return decimalResult(a * b, a, b, left, right, left + right, (x, y) => x * y);
1035
- }
1036
- function createFormatValue() {
1037
- const cache = /* @__PURE__ */ new Map();
1038
- function formatterFor(name, locale, options) {
1039
- const constructor = Reflect.get(Intl, name);
1040
- if (name === "DateTimeFormat" && options.timeZone === void 0) return new constructor(locale, options);
1041
- const entries = [];
1042
- for (const key of Object.keys(options).sort()) {
1043
- const value = options[key];
1044
- if (value === void 0) continue;
1045
- if (value !== null && typeof value !== "string" && typeof value !== "boolean" && typeof value !== "number" || typeof value === "number" && !Number.isFinite(value)) return new constructor(locale, options);
1046
- entries.push([
1047
- key,
1048
- typeof value,
1049
- Object.is(value, -0) ? "-0" : value
1050
- ]);
1051
- }
1052
- const language = locale === void 0 && typeof navigator !== "undefined" ? navigator.language : void 0;
1053
- const key = JSON.stringify([
1054
- name,
1055
- locale,
1056
- language,
1057
- entries
1058
- ]);
1059
- if (key.length > 4096) return new constructor(locale, options);
1060
- const cached = cache.get(key);
1061
- if (cached !== void 0 && cached.constructor === constructor) return cached.value;
1062
- const value = new constructor(locale, options);
1063
- if (cache.size >= 128 && !cache.has(key)) cache.delete(cache.keys().next().value);
1064
- cache.set(key, {
1065
- constructor,
1066
- value
1067
- });
1068
- return value;
1069
- }
1070
- /**
1071
- * The native Intl adapter. Self-contained so converters emit this same implementation only when
1072
- * authored expressions use formatting, without importing the live parser or interpreter.
1073
- * undefined is absence; the shared invalid-result symbol tells each target to retain its output.
1074
- */
1075
- return function formatValue(value, inputType, operation, ...args) {
1076
- const invalid = Symbol.for("html-next.invalid-result");
1077
- if (value === invalid || args.includes(invalid)) return invalid;
1078
- if (value === void 0 || value === null || args.some((arg) => arg === void 0)) return;
1079
- const end = operation === "formatRange" ? args.shift() : void 0;
1080
- if (operation === "formatRange" && (end === null || end === void 0)) return;
1081
- const format = typeof args[0] === "string" ? args.shift() : Reflect.get({
1082
- number: "number",
1083
- integer: "number",
1084
- percentage: "percent",
1085
- date: "date",
1086
- time: "time",
1087
- datetime: "dateTime",
1088
- "datetime-local": "dateTime",
1089
- duration: "duration",
1090
- list: "list"
1091
- }, inputType ?? "");
1092
- const options = args.length > 0 ? args.shift() : {};
1093
- const locale = args.shift();
1094
- if (args.length > 0 || !format || options === null || typeof options !== "object" || Array.isArray(options) || locale !== void 0 && typeof locale !== "string") return invalid;
1095
- try {
1096
- const durationFields = [
1097
- "years",
1098
- "months",
1099
- "weeks",
1100
- "days",
1101
- "hours",
1102
- "minutes",
1103
- "seconds",
1104
- "milliseconds",
1105
- "microseconds",
1106
- "nanoseconds"
1107
- ];
1108
- const settings = { ...options };
1109
- let formatter;
1110
- let input = value;
1111
- let last = end;
1112
- let zoneFree = false;
1113
- if ([
1114
- "number",
1115
- "currency",
1116
- "percent",
1117
- "unit"
1118
- ].includes(format)) {
1119
- if (format !== "number") {
1120
- if (settings.style !== void 0 && settings.style !== format) return invalid;
1121
- settings.style = format;
1122
- }
1123
- const quantity = (candidate) => {
1124
- if (inputType === "percentage" && typeof candidate === "string" && /^-?(?:\d+(?:\.\d+)?|\.\d+)%$/.test(candidate)) return Number(candidate.slice(0, -1)) / 100;
1125
- return candidate;
1126
- };
1127
- input = quantity(input);
1128
- last = quantity(last);
1129
- if (typeof input !== "number" || !Number.isFinite(input) || operation === "formatRange" && (typeof last !== "number" || !Number.isFinite(last))) return invalid;
1130
- formatter = formatterFor("NumberFormat", locale, settings);
1131
- } else if ([
1132
- "date",
1133
- "time",
1134
- "dateTime"
1135
- ].includes(format)) {
1136
- const civil = inputType === "date" || inputType === "time" || inputType === "datetime-local" || typeof input === "string" && !/(?:Z|[+-]\d\d:\d\d)$/.test(input);
1137
- zoneFree = civil;
1138
- if (civil && (settings.timeZone !== void 0 || settings.timeZoneName !== void 0)) return invalid;
1139
- if (format === "date" && (settings.timeStyle !== void 0 || [
1140
- "hour",
1141
- "minute",
1142
- "second",
1143
- "dayPeriod",
1144
- "fractionalSecondDigits"
1145
- ].some((key) => settings[key] !== void 0)) || format === "time" && (settings.dateStyle !== void 0 || [
1146
- "year",
1147
- "month",
1148
- "day",
1149
- "weekday",
1150
- "era"
1151
- ].some((key) => settings[key] !== void 0))) return invalid;
1152
- if (settings.dateStyle === void 0 && settings.timeStyle === void 0 && ![
1153
- "year",
1154
- "month",
1155
- "day",
1156
- "weekday",
1157
- "era",
1158
- "hour",
1159
- "minute",
1160
- "second",
1161
- "dayPeriod",
1162
- "fractionalSecondDigits"
1163
- ].some((key) => settings[key] !== void 0)) {
1164
- if (format !== "time") settings.dateStyle = "medium";
1165
- if (format !== "date") settings.timeStyle = "medium";
1166
- }
1167
- if (civil) settings.timeZone = "UTC";
1168
- const asDate = (candidate) => {
1169
- if (typeof candidate === "number" && Number.isFinite(candidate)) return new Date(candidate);
1170
- if (typeof candidate !== "string") return;
1171
- let written = candidate.replace(" ", "T");
1172
- if (/^\d\d:\d\d(?::\d\d(?:\.\d{1,3})?)?$/.test(written)) {
1173
- if (format !== "time") return;
1174
- written = "1970-01-01T" + written + "Z";
1175
- } else if (/^\d{4,}-\d\d-\d\d$/.test(written)) {
1176
- if (format !== "date") return;
1177
- written += "T00:00:00Z";
1178
- } else if (/^\d{4,}-\d\d-\d\dT\d\d:\d\d(?::\d\d(?:\.\d{1,3})?)?$/.test(written)) written += "Z";
1179
- else if (!/^\d{4,}-\d\d-\d\dT\d\d:\d\d(?::\d\d(?:\.\d{1,3})?)?(?:Z|[+-]\d\d:\d\d)$/.test(written)) return;
1180
- const date = new Date(written.replace(/^(\d{5,})-/, (_match, year) => "+" + year.padStart(6, "0") + "-"));
1181
- if (!Number.isFinite(date.getTime())) return;
1182
- const match = /^(\d{4,})-(\d\d)-(\d\d)T(\d\d):(\d\d)(?::(\d\d))?/.exec(written);
1183
- if (!match) return;
1184
- const probe = /* @__PURE__ */ new Date(0);
1185
- probe.setUTCFullYear(Number(match[1]), Number(match[2]) - 1, Number(match[3]));
1186
- if (Number(match[1]) === 0 || probe.getUTCMonth() !== Number(match[2]) - 1 || probe.getUTCDate() !== Number(match[3]) || Number(match[4]) > 23 || Number(match[5]) > 59 || Number(match[6] ?? 0) > 59) return;
1187
- return date;
1188
- };
1189
- input = asDate(input);
1190
- last = operation === "formatRange" ? asDate(last) : void 0;
1191
- if (!input || operation === "formatRange" && !last) return invalid;
1192
- formatter = formatterFor("DateTimeFormat", locale, settings);
1193
- } else {
1194
- if (operation === "formatRange") return invalid;
1195
- if (format === "relativeTime") {
1196
- if (typeof input !== "number" || !Number.isFinite(input) || typeof settings.unit !== "string") return invalid;
1197
- const unit = settings.unit;
1198
- delete settings.unit;
1199
- formatter = formatterFor("RelativeTimeFormat", locale, settings);
1200
- return operation === "formatParts" ? formatter.formatToParts(input, unit) : formatter.format(input, unit);
1201
- }
1202
- if (format === "list") {
1203
- if (!Array.isArray(input) || input.some((item) => typeof item !== "string")) return invalid;
1204
- formatter = formatterFor("ListFormat", locale, settings);
1205
- } else if (format === "duration") {
1206
- if (inputType === "duration" && typeof input === "string") {
1207
- const match = /^(-?(?:\d+(?:\.\d+)?|\.\d+))(ms|s)$/.exec(input);
1208
- if (!match) return invalid;
1209
- const milliseconds = Number(match[1]) * (match[2] === "s" ? 1e3 : 1);
1210
- if (!Number.isFinite(milliseconds)) return invalid;
1211
- input = {
1212
- hours: Math.trunc(milliseconds / 36e5),
1213
- minutes: Math.trunc(milliseconds % 36e5 / 6e4),
1214
- seconds: Math.trunc(milliseconds % 6e4 / 1e3),
1215
- milliseconds: Math.trunc(milliseconds % 1e3),
1216
- microseconds: Math.trunc((milliseconds - Math.trunc(milliseconds)) * 1e3),
1217
- nanoseconds: Math.round((milliseconds * 1e3 - Math.trunc(milliseconds * 1e3)) * 1e3)
1218
- };
1219
- }
1220
- if (input === null || typeof input !== "object" || Array.isArray(input) || Object.keys(input).some((key) => !durationFields.includes(key))) return invalid;
1221
- if (!Reflect.get(Intl, "DurationFormat")) return invalid;
1222
- formatter = formatterFor("DurationFormat", locale, settings);
1223
- } else if (format === "displayName") {
1224
- if (typeof input !== "string" || operation === "formatParts") return invalid;
1225
- return formatterFor("DisplayNames", locale, settings).of(input);
1226
- } else if (format === "plural") {
1227
- if (typeof input !== "number" || !Number.isFinite(input) || operation === "formatParts") return invalid;
1228
- const forms = settings.forms;
1229
- if (!forms || typeof forms !== "object" || Array.isArray(forms) || typeof forms.other !== "string" || Object.entries(forms).some(([key, entry]) => ![
1230
- "zero",
1231
- "one",
1232
- "two",
1233
- "few",
1234
- "many",
1235
- "other"
1236
- ].includes(key) || typeof entry !== "string")) return invalid;
1237
- delete settings.forms;
1238
- const message = forms[formatterFor("PluralRules", locale, settings).select(input)] ?? forms.other;
1239
- const numberOptions = { ...settings };
1240
- delete numberOptions.type;
1241
- delete numberOptions.forms;
1242
- const number = formatterFor("NumberFormat", locale, numberOptions).format(input);
1243
- return message.replace(/#/g, () => number);
1244
- }
1245
- }
1246
- if (!zoneFree && operation !== "formatParts") return operation === "formatRange" ? formatter.formatRange(input, last) : formatter.format(input);
1247
- const parts = operation === "formatRange" ? formatter.formatRangeToParts(input, last) : formatter.formatToParts(input);
1248
- if (zoneFree && operation !== "formatParts" && !parts.some((part) => part.type === "timeZoneName")) return operation === "formatRange" ? formatter.formatRange(input, last) : formatter.format(input);
1249
- const visible = zoneFree ? parts.filter((part, index) => part.type !== "timeZoneName" && !(part.type === "literal" && /^[\s(),]*$/.test(part.value) && (parts[index - 1]?.type === "timeZoneName" || parts[index + 1]?.type === "timeZoneName"))) : parts;
1250
- return operation === "formatParts" ? visible : visible.map((part) => part.value).join("");
1251
- } catch {
1252
- return invalid;
1253
- }
1254
- };
1255
- }
1256
- var formatValue = /* @__PURE__ */ createFormatValue();
1257
- //#endregion
1258
- //#region \0plugin-vue:export-helper
1259
- var _plugin_vue_export_helper_default = (sfc, props) => {
1260
- const target = sfc.__vccOpts || sfc;
1261
- for (const [key, val] of props) target[key] = val;
1262
- return target;
1263
- };
1264
- //#endregion
1265
- export { useReflectedProp as C, useComponentHost as S, warnUnless as T, nativeAttrs as _, checkHydratedRoot as a, text as b, cycleCheckedComputed as c, decimalSubtract as d, formatValue as f, math as g, list as h, attribute as i, decimalAdd as l, inlineTextSegment as m, KeyedBoundary as n, concat as o, initializedState as p, RetainedInlineText as r, createDispatch as s, _plugin_vue_export_helper_default as t, decimalMultiply as u, number as v, useScopedSlotName as w, uniqueKeys as x, preserveRootFocus as y };