@threadlabs/looma 0.29.0 → 0.29.2

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 (423) hide show
  1. package/components/ui-editor-code-language/ui-editor-code-language.html +1 -1
  2. package/components/ui-editor-image-toolbar/ui-editor-image-toolbar.html +1 -2
  3. package/components/ui-editor-link-form/ui-editor-link-form.html +2 -3
  4. package/components/ui-tooltip/ui-tooltip.html +5 -2
  5. package/dist/index.js +1 -1
  6. package/editor/chip-editing.d.ts +39 -0
  7. package/package.json +3 -3
  8. package/styles/ui-action-bar.css +1 -1
  9. package/styles/ui-affordance-scope.css +1 -1
  10. package/styles/ui-avatar-group.css +1 -1
  11. package/styles/ui-avatar.css +1 -1
  12. package/styles/ui-badge.css +1 -1
  13. package/styles/ui-breadcrumb-item.css +1 -1
  14. package/styles/ui-breadcrumbs.css +1 -1
  15. package/styles/ui-button.css +1 -1
  16. package/styles/ui-callout.css +1 -1
  17. package/styles/ui-card.css +1 -1
  18. package/styles/ui-checkbox.css +1 -1
  19. package/styles/ui-cluster.css +1 -1
  20. package/styles/ui-combobox.css +1 -1
  21. package/styles/ui-container.css +1 -1
  22. package/styles/ui-context-menu.css +1 -1
  23. package/styles/ui-cover.css +1 -1
  24. package/styles/ui-description-item.css +1 -1
  25. package/styles/ui-description-list.css +1 -1
  26. package/styles/ui-dialog.css +1 -1
  27. package/styles/ui-disclosure.css +1 -1
  28. package/styles/ui-editable.css +1 -1
  29. package/styles/ui-editor-block-actions.css +1 -1
  30. package/styles/ui-editor-chip-editor.css +1 -1
  31. package/styles/ui-editor-code-language.css +1 -1
  32. package/styles/ui-editor-image-toolbar.css +1 -1
  33. package/styles/ui-editor-insert-table-grid.css +1 -1
  34. package/styles/ui-editor-link-card.css +1 -1
  35. package/styles/ui-editor-link-form.css +1 -1
  36. package/styles/ui-editor-mention-menu-item.css +1 -1
  37. package/styles/ui-editor-mention-menu.css +1 -1
  38. package/styles/ui-editor-slash-menu-group.css +1 -1
  39. package/styles/ui-editor-slash-menu-item.css +1 -1
  40. package/styles/ui-editor-slash-menu.css +1 -1
  41. package/styles/ui-editor-surface.css +1 -1
  42. package/styles/ui-editor-table-context-menu.css +1 -1
  43. package/styles/ui-editor-table-overlay.css +1 -1
  44. package/styles/ui-editor-table-toolbar.css +1 -1
  45. package/styles/ui-editor-toolbar.css +1 -1
  46. package/styles/ui-floating-action-button.css +1 -1
  47. package/styles/ui-form-field.css +1 -1
  48. package/styles/ui-grid.css +1 -1
  49. package/styles/ui-icon-button.css +1 -1
  50. package/styles/ui-icon.css +1 -1
  51. package/styles/ui-image.css +1 -1
  52. package/styles/ui-input-group.css +1 -1
  53. package/styles/ui-input.css +1 -1
  54. package/styles/ui-list-item.css +1 -1
  55. package/styles/ui-list.css +1 -1
  56. package/styles/ui-listbox.css +1 -1
  57. package/styles/ui-menu-group.css +1 -1
  58. package/styles/ui-menu-item.css +1 -1
  59. package/styles/ui-menu.css +1 -1
  60. package/styles/ui-meter.css +1 -1
  61. package/styles/ui-nav-item.css +1 -1
  62. package/styles/ui-page-header.css +1 -1
  63. package/styles/ui-popover.css +1 -1
  64. package/styles/ui-radio-group.css +1 -1
  65. package/styles/ui-radio.css +1 -1
  66. package/styles/ui-reel.css +1 -1
  67. package/styles/ui-scroll-area.css +1 -1
  68. package/styles/ui-search-result-row.css +1 -1
  69. package/styles/ui-search-shell.css +1 -1
  70. package/styles/ui-section.css +1 -1
  71. package/styles/ui-select.css +1 -1
  72. package/styles/ui-separator.css +1 -1
  73. package/styles/ui-sidebar.css +1 -1
  74. package/styles/ui-spinner.css +1 -1
  75. package/styles/ui-stack.css +1 -1
  76. package/styles/ui-status-message.css +1 -1
  77. package/styles/ui-swatch.css +1 -1
  78. package/styles/ui-switch.css +1 -1
  79. package/styles/ui-switcher.css +1 -1
  80. package/styles/ui-table.css +1 -1
  81. package/styles/ui-tabs.css +1 -1
  82. package/styles/ui-text.css +1 -1
  83. package/styles/ui-textarea.css +1 -1
  84. package/styles/ui-toast-region.css +1 -1
  85. package/styles/ui-toast.css +1 -1
  86. package/styles/ui-tooltip.css +7 -2
  87. package/styles/ui-top-bar.css +1 -1
  88. package/styles/ui-tree-item.css +1 -1
  89. package/styles/ui-tree.css +1 -1
  90. package/vanilla/UiActionBar.d.ts +1 -1
  91. package/vanilla/UiActionBar.js +6 -6
  92. package/vanilla/UiAffordanceScope.d.ts +1 -1
  93. package/vanilla/UiAffordanceScope.js +1 -1
  94. package/vanilla/UiAvatar.d.ts +1 -1
  95. package/vanilla/UiAvatar.js +7 -7
  96. package/vanilla/UiAvatarGroup.d.ts +1 -1
  97. package/vanilla/UiAvatarGroup.js +4 -4
  98. package/vanilla/UiBadge.d.ts +1 -1
  99. package/vanilla/UiBadge.js +4 -4
  100. package/vanilla/UiBreadcrumbItem.d.ts +1 -1
  101. package/vanilla/UiBreadcrumbItem.js +3 -3
  102. package/vanilla/UiBreadcrumbs.d.ts +1 -1
  103. package/vanilla/UiBreadcrumbs.js +1 -1
  104. package/vanilla/UiButton.d.ts +1 -1
  105. package/vanilla/UiButton.js +17 -17
  106. package/vanilla/UiCallout.d.ts +1 -1
  107. package/vanilla/UiCallout.js +13 -13
  108. package/vanilla/UiCard.d.ts +1 -1
  109. package/vanilla/UiCard.js +1 -1
  110. package/vanilla/UiCheckbox.d.ts +1 -1
  111. package/vanilla/UiCheckbox.js +6 -6
  112. package/vanilla/UiCluster.d.ts +1 -1
  113. package/vanilla/UiCluster.js +1 -1
  114. package/vanilla/UiCombobox.d.ts +1 -1
  115. package/vanilla/UiCombobox.js +48 -48
  116. package/vanilla/UiContainer.d.ts +1 -1
  117. package/vanilla/UiContainer.js +1 -1
  118. package/vanilla/UiContextMenu.d.ts +1 -1
  119. package/vanilla/UiContextMenu.js +1 -1
  120. package/vanilla/UiCover.d.ts +1 -1
  121. package/vanilla/UiCover.js +1 -1
  122. package/vanilla/UiDescriptionItem.d.ts +1 -1
  123. package/vanilla/UiDescriptionItem.js +4 -4
  124. package/vanilla/UiDescriptionList.d.ts +1 -1
  125. package/vanilla/UiDescriptionList.js +1 -1
  126. package/vanilla/UiDialog.d.ts +1 -1
  127. package/vanilla/UiDialog.js +7 -7
  128. package/vanilla/UiDisclosure.d.ts +1 -1
  129. package/vanilla/UiDisclosure.js +8 -8
  130. package/vanilla/UiEditable.d.ts +1 -1
  131. package/vanilla/UiEditable.js +11 -11
  132. package/vanilla/UiEditorBlockActions.d.ts +1 -1
  133. package/vanilla/UiEditorBlockActions.js +3 -3
  134. package/vanilla/UiEditorChipEditor.d.ts +1 -1
  135. package/vanilla/UiEditorChipEditor.js +4 -4
  136. package/vanilla/UiEditorCodeLanguage.d.ts +1 -1
  137. package/vanilla/UiEditorCodeLanguage.js +7 -12
  138. package/vanilla/UiEditorImageToolbar.d.ts +1 -1
  139. package/vanilla/UiEditorImageToolbar.js +90 -95
  140. package/vanilla/UiEditorInsertTableGrid.d.ts +1 -1
  141. package/vanilla/UiEditorInsertTableGrid.js +7 -7
  142. package/vanilla/UiEditorLinkCard.d.ts +1 -1
  143. package/vanilla/UiEditorLinkCard.js +13 -13
  144. package/vanilla/UiEditorLinkForm.d.ts +1 -1
  145. package/vanilla/UiEditorLinkForm.js +32 -44
  146. package/vanilla/UiEditorMentionMenu.d.ts +1 -1
  147. package/vanilla/UiEditorMentionMenu.js +12 -12
  148. package/vanilla/UiEditorMentionMenuItem.d.ts +1 -1
  149. package/vanilla/UiEditorMentionMenuItem.js +4 -4
  150. package/vanilla/UiEditorSlashMenu.d.ts +1 -1
  151. package/vanilla/UiEditorSlashMenu.js +11 -11
  152. package/vanilla/UiEditorSlashMenuGroup.d.ts +1 -1
  153. package/vanilla/UiEditorSlashMenuGroup.js +5 -5
  154. package/vanilla/UiEditorSlashMenuItem.d.ts +1 -1
  155. package/vanilla/UiEditorSlashMenuItem.js +4 -4
  156. package/vanilla/UiEditorSurface.d.ts +1 -1
  157. package/vanilla/UiEditorSurface.js +1 -1
  158. package/vanilla/UiEditorTableContextMenu.d.ts +1 -1
  159. package/vanilla/UiEditorTableContextMenu.js +16 -16
  160. package/vanilla/UiEditorTableOverlay.d.ts +1 -1
  161. package/vanilla/UiEditorTableOverlay.js +18 -18
  162. package/vanilla/UiEditorTableToolbar.d.ts +1 -1
  163. package/vanilla/UiEditorTableToolbar.js +33 -33
  164. package/vanilla/UiEditorToolbar.d.ts +1 -1
  165. package/vanilla/UiEditorToolbar.js +1 -1
  166. package/vanilla/UiFloatingActionButton.d.ts +1 -1
  167. package/vanilla/UiFloatingActionButton.js +1 -1
  168. package/vanilla/UiFormField.d.ts +1 -1
  169. package/vanilla/UiFormField.js +8 -8
  170. package/vanilla/UiGrid.d.ts +1 -1
  171. package/vanilla/UiGrid.js +1 -1
  172. package/vanilla/UiIcon.d.ts +1 -1
  173. package/vanilla/UiIcon.js +4 -4
  174. package/vanilla/UiIconButton.d.ts +1 -1
  175. package/vanilla/UiIconButton.js +4 -4
  176. package/vanilla/UiImage.d.ts +1 -1
  177. package/vanilla/UiImage.js +6 -6
  178. package/vanilla/UiInput.d.ts +1 -1
  179. package/vanilla/UiInput.js +1 -1
  180. package/vanilla/UiInputGroup.d.ts +1 -1
  181. package/vanilla/UiInputGroup.js +6 -6
  182. package/vanilla/UiList.d.ts +1 -1
  183. package/vanilla/UiList.js +1 -1
  184. package/vanilla/UiListItem.d.ts +1 -1
  185. package/vanilla/UiListItem.js +7 -7
  186. package/vanilla/UiListbox.d.ts +1 -1
  187. package/vanilla/UiListbox.js +12 -12
  188. package/vanilla/UiMenu.d.ts +1 -1
  189. package/vanilla/UiMenu.js +1 -1
  190. package/vanilla/UiMenuGroup.d.ts +1 -1
  191. package/vanilla/UiMenuGroup.js +4 -4
  192. package/vanilla/UiMenuItem.d.ts +1 -1
  193. package/vanilla/UiMenuItem.js +11 -11
  194. package/vanilla/UiMeter.d.ts +1 -1
  195. package/vanilla/UiMeter.js +8 -8
  196. package/vanilla/UiNavItem.d.ts +1 -1
  197. package/vanilla/UiNavItem.js +13 -13
  198. package/vanilla/UiPageHeader.d.ts +1 -1
  199. package/vanilla/UiPageHeader.js +8 -8
  200. package/vanilla/UiPopover.d.ts +1 -1
  201. package/vanilla/UiPopover.js +1 -1
  202. package/vanilla/UiRadio.d.ts +1 -1
  203. package/vanilla/UiRadio.js +6 -6
  204. package/vanilla/UiRadioGroup.d.ts +1 -1
  205. package/vanilla/UiRadioGroup.js +4 -4
  206. package/vanilla/UiReel.d.ts +1 -1
  207. package/vanilla/UiReel.js +1 -1
  208. package/vanilla/UiScrollArea.d.ts +1 -1
  209. package/vanilla/UiScrollArea.js +1 -1
  210. package/vanilla/UiSearchResultRow.d.ts +1 -1
  211. package/vanilla/UiSearchResultRow.js +8 -8
  212. package/vanilla/UiSearchShell.d.ts +1 -1
  213. package/vanilla/UiSearchShell.js +8 -8
  214. package/vanilla/UiSection.d.ts +1 -1
  215. package/vanilla/UiSection.js +8 -8
  216. package/vanilla/UiSelect.d.ts +1 -1
  217. package/vanilla/UiSelect.js +1 -1
  218. package/vanilla/UiSeparator.d.ts +1 -1
  219. package/vanilla/UiSeparator.js +1 -1
  220. package/vanilla/UiSidebar.d.ts +1 -1
  221. package/vanilla/UiSidebar.js +4 -4
  222. package/vanilla/UiSpinner.d.ts +1 -1
  223. package/vanilla/UiSpinner.js +2 -2
  224. package/vanilla/UiStack.d.ts +1 -1
  225. package/vanilla/UiStack.js +1 -1
  226. package/vanilla/UiStatusMessage.d.ts +1 -1
  227. package/vanilla/UiStatusMessage.js +7 -7
  228. package/vanilla/UiSwatch.d.ts +1 -1
  229. package/vanilla/UiSwatch.js +1 -1
  230. package/vanilla/UiSwitch.d.ts +1 -1
  231. package/vanilla/UiSwitch.js +6 -6
  232. package/vanilla/UiSwitcher.d.ts +1 -1
  233. package/vanilla/UiSwitcher.js +1 -1
  234. package/vanilla/UiTable.d.ts +1 -1
  235. package/vanilla/UiTable.js +1 -1
  236. package/vanilla/UiTabs.d.ts +1 -1
  237. package/vanilla/UiTabs.js +7 -7
  238. package/vanilla/UiText.d.ts +1 -1
  239. package/vanilla/UiText.js +1 -1
  240. package/vanilla/UiTextarea.d.ts +1 -1
  241. package/vanilla/UiTextarea.js +1 -1
  242. package/vanilla/UiToast.d.ts +1 -1
  243. package/vanilla/UiToast.js +5 -5
  244. package/vanilla/UiToastRegion.d.ts +1 -1
  245. package/vanilla/UiToastRegion.js +8 -8
  246. package/vanilla/UiTooltip.d.ts +1 -1
  247. package/vanilla/UiTooltip.js +9 -8
  248. package/vanilla/UiTopBar.d.ts +1 -1
  249. package/vanilla/UiTopBar.js +6 -6
  250. package/vanilla/UiTree.d.ts +1 -1
  251. package/vanilla/UiTree.js +1 -1
  252. package/vanilla/UiTreeItem.d.ts +1 -1
  253. package/vanilla/UiTreeItem.js +13 -13
  254. package/vue/UiActionBar.vue +8 -5
  255. package/vue/UiAffordanceScope.vue +1 -1
  256. package/vue/UiAvatar.vue +10 -11
  257. package/vue/UiAvatarGroup.vue +2 -3
  258. package/vue/UiBadge.vue +5 -3
  259. package/vue/UiBreadcrumbItem.vue +2 -3
  260. package/vue/UiBreadcrumbs.vue +1 -1
  261. package/vue/UiButton.vue +15 -13
  262. package/vue/UiCallout.vue +8 -15
  263. package/vue/UiCard.vue +1 -1
  264. package/vue/UiCheckbox.vue +5 -4
  265. package/vue/UiCluster.vue +1 -1
  266. package/vue/UiCombobox.vue +25 -27
  267. package/vue/UiContainer.vue +1 -1
  268. package/vue/UiContextMenu.vue +1 -1
  269. package/vue/UiCover.vue +1 -1
  270. package/vue/UiDescriptionItem.vue +1 -1
  271. package/vue/UiDescriptionList.vue +1 -1
  272. package/vue/UiDialog.vue +4 -3
  273. package/vue/UiDisclosure.vue +9 -8
  274. package/vue/UiEditable.vue +13 -9
  275. package/vue/UiEditorBlockActions.vue +5 -4
  276. package/vue/UiEditorChipEditor.vue +7 -9
  277. package/vue/UiEditorCodeLanguage.vue +2 -2
  278. package/vue/UiEditorImageToolbar.vue +25 -32
  279. package/vue/UiEditorInsertTableGrid.vue +1 -1
  280. package/vue/UiEditorLinkCard.vue +17 -20
  281. package/vue/UiEditorLinkForm.vue +21 -23
  282. package/vue/UiEditorMentionMenu.vue +9 -7
  283. package/vue/UiEditorMentionMenuItem.vue +5 -6
  284. package/vue/UiEditorSlashMenu.vue +3 -5
  285. package/vue/UiEditorSlashMenuGroup.vue +1 -1
  286. package/vue/UiEditorSlashMenuItem.vue +5 -6
  287. package/vue/UiEditorSurface.vue +1 -1
  288. package/vue/UiEditorTableContextMenu.vue +4 -7
  289. package/vue/UiEditorTableOverlay.vue +26 -18
  290. package/vue/UiEditorTableToolbar.vue +23 -21
  291. package/vue/UiEditorToolbar.vue +1 -1
  292. package/vue/UiFloatingActionButton.vue +1 -1
  293. package/vue/UiFormField.vue +4 -3
  294. package/vue/UiGrid.vue +1 -1
  295. package/vue/UiIcon.vue +1 -1
  296. package/vue/UiIconButton.vue +4 -3
  297. package/vue/UiImage.vue +4 -7
  298. package/vue/UiInput.vue +1 -1
  299. package/vue/UiInputGroup.vue +7 -5
  300. package/vue/UiList.vue +1 -1
  301. package/vue/UiListItem.vue +10 -7
  302. package/vue/UiListbox.vue +3 -5
  303. package/vue/UiMenu.vue +1 -1
  304. package/vue/UiMenuGroup.vue +2 -3
  305. package/vue/UiMenuItem.vue +15 -10
  306. package/vue/UiMeter.vue +4 -5
  307. package/vue/UiNavItem.vue +19 -13
  308. package/vue/UiPageHeader.vue +8 -7
  309. package/vue/UiPopover.vue +1 -1
  310. package/vue/UiRadio.vue +10 -6
  311. package/vue/UiRadioGroup.vue +1 -1
  312. package/vue/UiReel.vue +1 -1
  313. package/vue/UiScrollArea.vue +1 -1
  314. package/vue/UiSearchResultRow.vue +11 -8
  315. package/vue/UiSearchShell.vue +1 -1
  316. package/vue/UiSection.vue +7 -4
  317. package/vue/UiSelect.vue +1 -1
  318. package/vue/UiSeparator.vue +1 -1
  319. package/vue/UiSidebar.vue +1 -1
  320. package/vue/UiSpinner.vue +1 -1
  321. package/vue/UiStack.vue +1 -1
  322. package/vue/UiStatusMessage.vue +10 -6
  323. package/vue/UiSwatch.vue +1 -1
  324. package/vue/UiSwitch.vue +10 -6
  325. package/vue/UiSwitcher.vue +1 -1
  326. package/vue/UiTable.vue +1 -1
  327. package/vue/UiTabs.vue +3 -3
  328. package/vue/UiText.vue +1 -1
  329. package/vue/UiTextarea.vue +1 -1
  330. package/vue/UiToast.vue +1 -1
  331. package/vue/UiToastRegion.vue +7 -5
  332. package/vue/UiTooltip.vue +10 -5
  333. package/vue/UiTopBar.vue +1 -1
  334. package/vue/UiTree.vue +1 -1
  335. package/vue/UiTreeItem.vue +14 -13
  336. package/vue/chunks/UiActionBar.js +4 -2
  337. package/vue/chunks/UiAffordanceScope.js +1 -1
  338. package/vue/chunks/UiAvatar.js +18 -12
  339. package/vue/chunks/UiAvatarGroup.js +15 -11
  340. package/vue/chunks/UiBadge.js +7 -3
  341. package/vue/chunks/UiBreadcrumbItem.js +10 -6
  342. package/vue/chunks/UiBreadcrumbs.js +1 -1
  343. package/vue/chunks/UiButton.js +10 -2
  344. package/vue/chunks/UiCallout.js +13 -3
  345. package/vue/chunks/UiCard.js +1 -1
  346. package/vue/chunks/UiCheckbox.js +35 -27
  347. package/vue/chunks/UiCluster.js +1 -1
  348. package/vue/chunks/UiCombobox.js +108 -74
  349. package/vue/chunks/UiContainer.js +1 -1
  350. package/vue/chunks/UiContextMenu.js +1 -1
  351. package/vue/chunks/UiCover.js +1 -1
  352. package/vue/chunks/UiDescriptionItem.js +1 -1
  353. package/vue/chunks/UiDescriptionList.js +1 -1
  354. package/vue/chunks/UiDialog.js +14 -10
  355. package/vue/chunks/UiDisclosure.js +3 -1
  356. package/vue/chunks/UiEditable.js +36 -24
  357. package/vue/chunks/UiEditorBlockActions.js +3 -1
  358. package/vue/chunks/UiEditorChipEditor.js +31 -22
  359. package/vue/chunks/UiEditorCodeLanguage.js +1 -1
  360. package/vue/chunks/UiEditorImageToolbar.js +45 -27
  361. package/vue/chunks/UiEditorInsertTableGrid.js +1 -1
  362. package/vue/chunks/UiEditorLinkCard.js +58 -42
  363. package/vue/chunks/UiEditorLinkForm.js +110 -90
  364. package/vue/chunks/UiEditorMentionMenu.js +23 -14
  365. package/vue/chunks/UiEditorMentionMenuItem.js +6 -2
  366. package/vue/chunks/UiEditorSlashMenu.js +24 -16
  367. package/vue/chunks/UiEditorSlashMenuGroup.js +1 -1
  368. package/vue/chunks/UiEditorSlashMenuItem.js +10 -6
  369. package/vue/chunks/UiEditorSurface.js +1 -1
  370. package/vue/chunks/UiEditorTableContextMenu.js +65 -53
  371. package/vue/chunks/UiEditorTableOverlay.js +60 -40
  372. package/vue/chunks/UiEditorTableToolbar.js +100 -74
  373. package/vue/chunks/UiEditorToolbar.js +1 -1
  374. package/vue/chunks/UiFloatingActionButton.js +1 -1
  375. package/vue/chunks/UiFormField.js +7 -3
  376. package/vue/chunks/UiGrid.js +1 -1
  377. package/vue/chunks/UiIcon.js +1 -1
  378. package/vue/chunks/UiIconButton.js +11 -7
  379. package/vue/chunks/UiImage.js +5 -2
  380. package/vue/chunks/UiInput.js +1 -1
  381. package/vue/chunks/UiInputGroup.js +5 -2
  382. package/vue/chunks/UiList.js +1 -1
  383. package/vue/chunks/UiListItem.js +9 -3
  384. package/vue/chunks/UiListbox.js +17 -11
  385. package/vue/chunks/UiMenu.js +1 -1
  386. package/vue/chunks/UiMenuGroup.js +7 -3
  387. package/vue/chunks/UiMenuItem.js +7 -2
  388. package/vue/chunks/UiMeter.js +28 -16
  389. package/vue/chunks/UiNavItem.js +20 -6
  390. package/vue/chunks/UiPageHeader.js +4 -2
  391. package/vue/chunks/UiPopover.js +1 -1
  392. package/vue/chunks/UiRadio.js +32 -24
  393. package/vue/chunks/UiRadioGroup.js +1 -1
  394. package/vue/chunks/UiReel.js +1 -1
  395. package/vue/chunks/UiScrollArea.js +1 -1
  396. package/vue/chunks/UiSearchResultRow.js +6 -2
  397. package/vue/chunks/UiSearchShell.js +1 -1
  398. package/vue/chunks/UiSection.js +15 -7
  399. package/vue/chunks/UiSelect.js +1 -1
  400. package/vue/chunks/UiSeparator.js +1 -1
  401. package/vue/chunks/UiSidebar.js +1 -1
  402. package/vue/chunks/UiSpinner.js +1 -1
  403. package/vue/chunks/UiStack.js +1 -1
  404. package/vue/chunks/UiStatusMessage.js +13 -7
  405. package/vue/chunks/UiSwatch.js +1 -1
  406. package/vue/chunks/UiSwitch.js +33 -25
  407. package/vue/chunks/UiSwitcher.js +1 -1
  408. package/vue/chunks/UiTable.js +1 -1
  409. package/vue/chunks/UiTabs.js +21 -17
  410. package/vue/chunks/UiText.js +1 -1
  411. package/vue/chunks/UiTextarea.js +1 -1
  412. package/vue/chunks/UiToast.js +1 -1
  413. package/vue/chunks/UiToastRegion.js +39 -31
  414. package/vue/chunks/UiTooltip.js +11 -3
  415. package/vue/chunks/UiTopBar.js +1 -1
  416. package/vue/chunks/UiTree.js +1 -1
  417. package/vue/chunks/UiTreeItem.js +25 -15
  418. package/vue/chunks/_plugin-vue_export-helper.js +1 -0
  419. package/vue/components.css +25 -21
  420. package/vue/editor/LoomaEditor.d.ts +2 -2
  421. package/vue/editor/compact/index.d.ts +2 -2
  422. package/vue/editor/index.js +241 -77
  423. package/vue/host.ts +4 -1
@@ -1,5 +1,5 @@
1
1
  import { computed, createApp, defineComponent, h, nextTick, onBeforeUnmount, onMounted, onUpdated, reactive, ref, shallowRef, useId, watch } from "vue";
2
- import { DEFAULT_MENTION_RESULT_LIMIT, LOOMA_ICONS, createLoomaMentionExtension, createLoomaSlashCommandExtension, getActiveTableUiState, getDefaultEditorExtensions, getDefaultSlashCommands, getTableOfContentsEntries, getVisualViewportRect, handleTableAction, handleTableOverlayAction, measureTableOverlayGeometry, normalizeActiveTableColumnWidths, normalizeLoomaChipColor, normalizeTableOfContentsConfig } from "@threadlabs/looma/editor";
2
+ import { DEFAULT_MENTION_RESULT_LIMIT, LOOMA_ICONS, createLoomaMentionExtension, createLoomaSlashCommandExtension, getActiveTableUiState, getDefaultEditorExtensions, getDefaultSlashCommands, getTableOfContentsEntries, getVisualViewportRect, handleTableAction, handleTableOverlayAction, measureTableOverlayGeometry, normalizeActiveTableColumnWidths, normalizeTableOfContentsConfig } from "@threadlabs/looma/editor";
3
3
  import { Button, Callout, Card, Checkbox, Cluster, Disclosure, EditorBlockActions, EditorChipEditor, EditorCodeLanguage, EditorImageToolbar, EditorInsertTableGrid, EditorLinkCard, EditorLinkForm, EditorMentionMenu, EditorMentionMenuItem, EditorSlashMenu, EditorSlashMenuGroup, EditorSlashMenuItem, EditorSurface, EditorTableContextMenu, EditorTableOverlay, EditorTableToolbar, EditorToolbar, FormField, Icon, IconButton, Image, Input, List, Menu, MenuItem, Popover, Separator, Stack, StatusMessage, Text, Tooltip } from "@threadlabs/looma/vue";
4
4
  import { Editor, Extension, Node as Node$1, getText, getTextSerializersFromSchema, isNodeSelection, mergeAttributes, nodeInputRule, posToDOMRect } from "@tiptap/core";
5
5
  import { Editor as Editor$1 } from "@tiptap/vue-3";
@@ -1224,7 +1224,7 @@ function createImageUploads(options) {
1224
1224
  };
1225
1225
  }
1226
1226
  //#endregion
1227
- //#region ../../node_modules/.pnpm/@nextwebwg+html-next@1.0.0-alpha.53/node_modules/@nextwebwg/html-next/dist/requests.js
1227
+ //#region ../../node_modules/.pnpm/@nextwebwg+html-next@1.0.0-alpha.54/node_modules/@nextwebwg/html-next/dist/requests.js
1228
1228
  /**
1229
1229
  * Requests: behavior a component asks its consumer for, answered through a native event's
1230
1230
  * `respondWith` (https://nextwebwg.org/declarative-components/javascript#requests).
@@ -1536,6 +1536,221 @@ function validLinkHref(value) {
1536
1536
  }
1537
1537
  }
1538
1538
  //#endregion
1539
+ //#region src/markdown/index.ts
1540
+ /**
1541
+ * Callout tones a document stores, in the order the editor offers them. The Callout component also
1542
+ * takes `neutral` and `success`, which Markdown and the editor store as `note`.
1543
+ */
1544
+ var LOOMA_CALLOUT_TONES = [
1545
+ "note",
1546
+ "tip",
1547
+ "info",
1548
+ "important",
1549
+ "warning",
1550
+ "danger"
1551
+ ];
1552
+ /** The hues chips and swatches take as their tone, written `:chip[Label]{tone=green}`. */
1553
+ var LOOMA_CHIP_TONES = [
1554
+ "neutral",
1555
+ "blue",
1556
+ "green",
1557
+ "yellow",
1558
+ "red",
1559
+ "purple"
1560
+ ];
1561
+ /**
1562
+ * Keeps a chip tone within the palette.
1563
+ * @failure Unknown values become `neutral`.
1564
+ */
1565
+ function normalizeLoomaChipTone(value) {
1566
+ return LOOMA_CHIP_TONES.includes(value) ? value : "neutral";
1567
+ }
1568
+ [...LOOMA_CALLOUT_TONES];
1569
+ /**
1570
+ * The anchor a heading's text derives: NFC, lowercase, keeping letters, numbers and combining
1571
+ * marks, with every other run of characters one hyphen.
1572
+ * @failure Text with no letters or numbers, such as only emoji, derives `heading`.
1573
+ */
1574
+ function loomaHeadingSlug(text) {
1575
+ return text.normalize("NFC").toLowerCase().replace(/[^\p{L}\p{N}\p{M}]+/gu, "-").replace(/^-+|-+$/g, "") || "heading";
1576
+ }
1577
+ /**
1578
+ * Gives every heading of a document its anchor, in document order.
1579
+ * @contract A custom ID is kept unless an earlier heading already has it. Any other heading takes
1580
+ * its slug, or the slug's first free suffix (`-1`, `-2`…), never one a later custom ID reserves.
1581
+ */
1582
+ function assignLoomaHeadingIds(headings) {
1583
+ const reserved = new Set(headings.map(({ id }) => id).filter((id) => Boolean(id)));
1584
+ const used = /* @__PURE__ */ new Set();
1585
+ return headings.map(({ text, id: custom }) => {
1586
+ let id = custom || loomaHeadingSlug(text);
1587
+ if (custom ? used.has(id) : used.has(id) || reserved.has(id)) {
1588
+ const stem = id;
1589
+ let suffix = 1;
1590
+ while (used.has(`${stem}-${suffix}`) || reserved.has(`${stem}-${suffix}`)) suffix++;
1591
+ id = `${stem}-${suffix}`;
1592
+ }
1593
+ used.add(id);
1594
+ return id;
1595
+ });
1596
+ }
1597
+ //#endregion
1598
+ //#region src/editor/extensions/chip.ts
1599
+ var CHIP_PLACEHOLDER = "Set a label";
1600
+ /** Keep imported or programmatic colors within the supported palette. */
1601
+ function normalizeLoomaChipColor(value) {
1602
+ return normalizeLoomaChipTone(value);
1603
+ }
1604
+ Node$1.create({
1605
+ name: "loomaChip",
1606
+ group: "inline",
1607
+ inline: true,
1608
+ atom: true,
1609
+ selectable: true,
1610
+ addAttributes() {
1611
+ return {
1612
+ label: {
1613
+ default: "",
1614
+ parseHTML: (element) => element.getAttribute("data-label") ?? (element.hasAttribute("data-placeholder") ? "" : element.textContent ?? "")
1615
+ },
1616
+ color: {
1617
+ default: "neutral",
1618
+ parseHTML: (element) => normalizeLoomaChipColor(element.getAttribute("data-color"))
1619
+ }
1620
+ };
1621
+ },
1622
+ parseHTML() {
1623
+ return [{ tag: "span[data-looma-chip]" }];
1624
+ },
1625
+ renderHTML({ node }) {
1626
+ const label = String(node.attrs.label ?? "");
1627
+ return [
1628
+ "span",
1629
+ {
1630
+ "data-looma-chip": "",
1631
+ "data-label": label,
1632
+ "data-color": normalizeLoomaChipColor(node.attrs.color),
1633
+ ...label ? {} : { "data-placeholder": "" }
1634
+ },
1635
+ label || CHIP_PLACEHOLDER
1636
+ ];
1637
+ },
1638
+ renderText({ node }) {
1639
+ return String(node.attrs.label ?? "");
1640
+ },
1641
+ addNodeView() {
1642
+ return ({ node, editor }) => {
1643
+ const dom = document.createElement("span");
1644
+ dom.dataset.loomaChip = "";
1645
+ dom.contentEditable = "false";
1646
+ dom.setAttribute("role", "button");
1647
+ dom.setAttribute("aria-disabled", String(!editor.isEditable));
1648
+ dom.tabIndex = 0;
1649
+ const update = (next) => {
1650
+ if (next.type !== node.type) return false;
1651
+ const label = String(next.attrs.label ?? "");
1652
+ if (dom.dataset.label !== label) {
1653
+ dom.dataset.label = label;
1654
+ dom.textContent = label || CHIP_PLACEHOLDER;
1655
+ dom.setAttribute("aria-label", label ? `Edit chip: ${label}` : "Set chip label");
1656
+ if (label) delete dom.dataset.placeholder;
1657
+ else dom.dataset.placeholder = "";
1658
+ }
1659
+ const color = normalizeLoomaChipColor(next.attrs.color);
1660
+ if (dom.dataset.color !== color) dom.dataset.color = color;
1661
+ return true;
1662
+ };
1663
+ update(node);
1664
+ return {
1665
+ dom,
1666
+ update,
1667
+ stopEvent: (event) => event.type === "click" || event.type === "keydown"
1668
+ };
1669
+ };
1670
+ },
1671
+ addCommands() {
1672
+ return { insertLoomaChip: (attributes = {}) => ({ commands, state }) => {
1673
+ const selection = state.selection;
1674
+ const label = attributes.label ?? state.doc.textBetween(selection.from, selection.to);
1675
+ return commands.insertContent({
1676
+ type: this.name,
1677
+ attrs: {
1678
+ label,
1679
+ color: normalizeLoomaChipColor(attributes.color)
1680
+ }
1681
+ });
1682
+ } };
1683
+ }
1684
+ });
1685
+ //#endregion
1686
+ //#region src/editor/chip-editing.ts
1687
+ var LOOMA_CHIP_EDITING_IDLE = Object.freeze({
1688
+ open: false,
1689
+ label: "",
1690
+ color: "neutral"
1691
+ });
1692
+ function createChipEditing(options) {
1693
+ const { editor } = options;
1694
+ const listeners = /* @__PURE__ */ new Set();
1695
+ let state = LOOMA_CHIP_EDITING_IDLE;
1696
+ let element = null;
1697
+ const set = (next) => {
1698
+ state = next;
1699
+ listeners.forEach((listener) => listener());
1700
+ };
1701
+ const close = () => {
1702
+ element = null;
1703
+ if (state.open) set({
1704
+ ...state,
1705
+ open: false
1706
+ });
1707
+ };
1708
+ const change = (changes) => {
1709
+ if (!element || editor.isDestroyed || !element.isConnected) return close();
1710
+ const position = editor.view.posAtDOM(element, 0);
1711
+ const node = editor.state.doc.nodeAt(position);
1712
+ if (node?.type.name !== "loomaChip") return close();
1713
+ set({
1714
+ ...state,
1715
+ ...changes
1716
+ });
1717
+ editor.view.dispatch(editor.state.tr.setNodeMarkup(position, void 0, {
1718
+ ...node.attrs,
1719
+ ...changes
1720
+ }));
1721
+ };
1722
+ return {
1723
+ get state() {
1724
+ return state;
1725
+ },
1726
+ get element() {
1727
+ return element;
1728
+ },
1729
+ subscribe(listener) {
1730
+ listeners.add(listener);
1731
+ return () => {
1732
+ listeners.delete(listener);
1733
+ };
1734
+ },
1735
+ open(position) {
1736
+ if (!options.isEditable() || editor.isDestroyed) return false;
1737
+ const node = editor.state.doc.nodeAt(position);
1738
+ const dom = editor.view.nodeDOM(position);
1739
+ if (node?.type.name !== "loomaChip" || !(dom instanceof HTMLElement)) return false;
1740
+ element = dom;
1741
+ set({
1742
+ open: true,
1743
+ label: String(node.attrs.label ?? ""),
1744
+ color: normalizeLoomaChipColor(node.attrs.color)
1745
+ });
1746
+ return true;
1747
+ },
1748
+ setLabel: (label) => change({ label }),
1749
+ setColor: (color) => change({ color }),
1750
+ close
1751
+ };
1752
+ }
1753
+ //#endregion
1539
1754
  //#region src/editor/extensions/relative-links.ts
1540
1755
  /** Keep other origins and non-web schemes intact; same-origin links retain path, query, and fragment. */
1541
1756
  function siteRelativeHref(href, baseUrl) {
@@ -2056,34 +2271,6 @@ function formatEditorShortcut(keys, apple) {
2056
2271
  ].filter(Boolean).join("+");
2057
2272
  }
2058
2273
  var isApplePlatform = () => typeof navigator !== "undefined" && /mac|iphone|ipad|ipod/i.test(navigator.userAgentData?.platform || navigator.platform || navigator.userAgent);
2059
- /**
2060
- * The anchor a heading's text derives: NFC, lowercase, keeping letters, numbers and combining
2061
- * marks, with every other run of characters one hyphen.
2062
- * @failure Text with no letters or numbers, such as only emoji, derives `heading`.
2063
- */
2064
- function loomaHeadingSlug(text) {
2065
- return text.normalize("NFC").toLowerCase().replace(/[^\p{L}\p{N}\p{M}]+/gu, "-").replace(/^-+|-+$/g, "") || "heading";
2066
- }
2067
- /**
2068
- * Gives every heading of a document its anchor, in document order.
2069
- * @contract A custom ID is kept unless an earlier heading already has it. Any other heading takes
2070
- * its slug, or the slug's first free suffix (`-1`, `-2`…), never one a later custom ID reserves.
2071
- */
2072
- function assignLoomaHeadingIds(headings) {
2073
- const reserved = new Set(headings.map(({ id }) => id).filter((id) => Boolean(id)));
2074
- const used = /* @__PURE__ */ new Set();
2075
- return headings.map(({ text, id: custom }) => {
2076
- let id = custom || loomaHeadingSlug(text);
2077
- if (custom ? used.has(id) : used.has(id) || reserved.has(id)) {
2078
- const stem = id;
2079
- let suffix = 1;
2080
- while (used.has(`${stem}-${suffix}`) || reserved.has(`${stem}-${suffix}`)) suffix++;
2081
- id = `${stem}-${suffix}`;
2082
- }
2083
- used.add(id);
2084
- return id;
2085
- });
2086
- }
2087
2274
  //#endregion
2088
2275
  //#region src/editor/extensions/expand.ts
2089
2276
  /**
@@ -3215,9 +3402,8 @@ var LoomaEditor = defineComponent({
3215
3402
  chipEditorRoot.value = element instanceof HTMLElement ? element : null;
3216
3403
  };
3217
3404
  const chipInput = () => chipEditorRoot.value?.querySelector("[data-chip-label]");
3218
- const chipOpen = ref(false);
3219
- const chipLabel = ref("");
3220
- const chipColor = ref("neutral");
3405
+ let chipEditing;
3406
+ const chipState = shallowRef(LOOMA_CHIP_EDITING_IDLE);
3221
3407
  const toolbarScope = `looma-editor-tool-${useId().replace(/[^a-zA-Z0-9_-]/g, "")}`;
3222
3408
  const tooltipFor = ref("");
3223
3409
  const tooltipLabel = ref("");
@@ -3320,39 +3506,16 @@ var LoomaEditor = defineComponent({
3320
3506
  menuStyle: {},
3321
3507
  capabilities: { ...EMPTY_CAPABILITIES }
3322
3508
  });
3323
- const openChipEditor = (instance, position) => {
3324
- if (!props.editable) return;
3325
- const node = instance.state.doc.nodeAt(position);
3326
- const element = instance.view.nodeDOM(position);
3327
- if (node?.type.name !== "loomaChip" || !(element instanceof HTMLElement)) return;
3509
+ const openChipEditor = (_instance, position) => {
3510
+ if (!chipEditing?.open(position)) return;
3328
3511
  root.value?.querySelector(`#${chipAnchorId}`)?.removeAttribute("id");
3329
- element.id = chipAnchorId;
3330
- chipLabel.value = String(node.attrs.label ?? "");
3331
- chipColor.value = normalizeLoomaChipColor(node.attrs.color);
3332
- chipOpen.value = true;
3512
+ chipEditing.element.id = chipAnchorId;
3333
3513
  nextTick(() => chipInput()?.focus());
3334
3514
  };
3335
- const changeChip = (changes) => {
3336
- const instance = editor.value;
3337
- const element = root.value?.querySelector(`#${chipAnchorId}`);
3338
- if (!instance || !element) {
3339
- chipOpen.value = false;
3340
- return;
3341
- }
3342
- const position = instance.view.posAtDOM(element, 0);
3343
- const node = instance.state.doc.nodeAt(position);
3344
- if (node?.type.name !== "loomaChip") {
3345
- chipOpen.value = false;
3346
- return;
3347
- }
3348
- instance.view.dispatch(instance.state.tr.setNodeMarkup(position, void 0, {
3349
- ...node.attrs,
3350
- ...changes
3351
- }));
3352
- };
3353
3515
  const closeChip = (focusChip = false) => {
3354
- chipOpen.value = false;
3355
- if (focusChip) root.value?.querySelector(`#${chipAnchorId}`)?.focus();
3516
+ const element = chipEditing?.element;
3517
+ chipEditing?.close();
3518
+ if (focusChip) element?.focus();
3356
3519
  };
3357
3520
  const found = reactive(/* @__PURE__ */ new Set());
3358
3521
  const answers = (name) => {
@@ -3565,6 +3728,14 @@ var LoomaEditor = defineComponent({
3565
3728
  linkState.value = engine.state;
3566
3729
  });
3567
3730
  linkEditing = engine;
3731
+ const chips = createChipEditing({
3732
+ editor: session.editor,
3733
+ isEditable: () => props.editable
3734
+ });
3735
+ chips.subscribe(() => {
3736
+ chipState.value = chips.state;
3737
+ });
3738
+ chipEditing = chips;
3568
3739
  const imageUploads = createImageUploads({
3569
3740
  editor: session.editor,
3570
3741
  upload: () => async (file, init) => {
@@ -3597,6 +3768,7 @@ var LoomaEditor = defineComponent({
3597
3768
  const previous = session;
3598
3769
  const content = edited ? previous.editor.getJSON() : props.modelValue;
3599
3770
  linkEditing?.destroy();
3771
+ chipEditing?.close();
3600
3772
  formatting?.destroy();
3601
3773
  uploads?.cancel();
3602
3774
  previous.destroy();
@@ -3721,7 +3893,7 @@ var LoomaEditor = defineComponent({
3721
3893
  root.value?.querySelectorAll("[data-looma-chip]").forEach((chip) => {
3722
3894
  chip.setAttribute("aria-disabled", String(!editable));
3723
3895
  });
3724
- if (!editable) chipOpen.value = false;
3896
+ if (!editable) chipEditing?.close();
3725
3897
  });
3726
3898
  watch([
3727
3899
  () => linkState.value.surface === "popover",
@@ -4691,24 +4863,16 @@ var LoomaEditor = defineComponent({
4691
4863
  }, [loomaIcon("image"), h("span", "Drop image to upload")]) : null,
4692
4864
  h(Popover, {
4693
4865
  class: "looma-editor__chip-popover",
4694
- open: chipOpen.value,
4866
+ open: chipState.value.open,
4695
4867
  for: chipAnchorId,
4696
4868
  placement: "bottom-start",
4697
- onClose: () => {
4698
- chipOpen.value = false;
4699
- }
4869
+ onClose: () => chipEditing?.close()
4700
4870
  }, () => h(EditorChipEditor, {
4701
4871
  ref: setChipEditorRoot,
4702
- label: chipLabel.value,
4703
- color: chipColor.value,
4704
- onLabel: (event) => {
4705
- chipLabel.value = event.detail.label;
4706
- changeChip({ label: chipLabel.value });
4707
- },
4708
- onColor: (event) => {
4709
- chipColor.value = event.detail.color;
4710
- changeChip({ color: event.detail.color });
4711
- },
4872
+ label: chipState.value.label,
4873
+ color: chipState.value.color,
4874
+ onLabel: (event) => chipEditing?.setLabel(event.detail.label),
4875
+ onColor: (event) => chipEditing?.setColor(event.detail.color),
4712
4876
  onDone: () => closeChip(true)
4713
4877
  })),
4714
4878
  h(Popover, {
package/vue/host.ts CHANGED
@@ -1,4 +1,4 @@
1
- // Generated by HTML Next 1.0.0-alpha.53 for Vue 3.5. Do not edit.
1
+ // Generated by HTML Next 1.0.0-alpha.54 for Vue 3.5. Do not edit.
2
2
  import {
3
3
  computed,
4
4
  createTextVNode,
@@ -535,6 +535,8 @@ export interface ComponentHostOptions {
535
535
  readonly data?: Readonly<Record<string, Readable<unknown>>>
536
536
  /** Values inherited through declared context, which a controller reads. */
537
537
  readonly context?: Readonly<Record<string, Readable<unknown>>>
538
+ /** Each named declared script, which a controller reads as `host.scripts`. */
539
+ readonly scripts?: Readonly<Record<string, unknown>>
538
540
  readonly acceptsState?: (name: string, keys: readonly string[], value: unknown) => boolean
539
541
  /** Asks one of the component's declared requests. */
540
542
  request?(
@@ -700,6 +702,7 @@ export function useComponentHost(
700
702
  ),
701
703
  ...(options.acceptsState === undefined ? {} : { acceptsState: options.acceptsState }),
702
704
  }, options.controllerSource?.definition ?? '<component>'),
705
+ scripts: options.scripts ?? Object.freeze({}),
703
706
  on(type: string, callback: (event: Event) => void | (() => void)): () => void {
704
707
  const entry: Subscription = {
705
708
  type,