@threadlabs/looma 0.1.22 → 0.1.24

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 (326) hide show
  1. package/dist/chunk-HNFCGIBP.js +8 -0
  2. package/dist/{chunk-NIPNHZ5W.js → chunk-IMHSPETJ.js} +65 -31
  3. package/dist/chunk-NB6DBRXQ.js +323 -0
  4. package/dist/{chunk-SZJQ3NPX.js → chunk-TL4FIE7X.js} +4 -8
  5. package/dist/cjs/controlled-state-BFya8rAX.js +9 -0
  6. package/dist/cjs/icons-BAdjrnhS.js +680 -0
  7. package/dist/cjs/{index-D07f6BOw.js → index-BHG9Rpil.js} +33 -0
  8. package/dist/cjs/loader.cjs.js +2 -2
  9. package/dist/cjs/looma.cjs.js +2 -2
  10. package/dist/cjs/{manager-C9j3HZay.js → manager-Ce25WRtl.js} +6 -7
  11. package/dist/cjs/ui-affordance-scope.cjs.entry.js +2 -2
  12. package/dist/cjs/ui-avatar-group.cjs.entry.js +10 -18
  13. package/dist/cjs/ui-avatar.cjs.entry.js +3 -3
  14. package/dist/cjs/ui-badge.cjs.entry.js +3 -3
  15. package/dist/cjs/ui-button.cjs.entry.js +16 -5
  16. package/dist/cjs/ui-callout.cjs.entry.js +27 -0
  17. package/dist/cjs/ui-checkbox.cjs.entry.js +14 -8
  18. package/dist/cjs/ui-chip.cjs.entry.js +19 -0
  19. package/dist/cjs/ui-combobox.cjs.entry.js +541 -0
  20. package/dist/cjs/ui-context-menu.cjs.entry.js +3 -3
  21. package/dist/cjs/ui-dialog.cjs.entry.js +46 -10
  22. package/dist/cjs/ui-disclosure.cjs.entry.js +10 -7
  23. package/dist/cjs/ui-floating-action-button.cjs.entry.js +2 -2
  24. package/dist/cjs/ui-form-field.cjs.entry.js +61 -6
  25. package/dist/cjs/ui-icon-button.cjs.entry.js +2 -2
  26. package/dist/cjs/ui-input.cjs.entry.js +11 -6
  27. package/dist/cjs/ui-menu-item.cjs.entry.js +3 -3
  28. package/dist/cjs/ui-menu.cjs.entry.js +16 -11
  29. package/dist/cjs/ui-popover.cjs.entry.js +12 -9
  30. package/dist/cjs/ui-radio-group.cjs.entry.js +2 -2
  31. package/dist/cjs/ui-radio.cjs.entry.js +18 -9
  32. package/dist/cjs/ui-search-result-row.cjs.entry.js +2 -2
  33. package/dist/cjs/ui-search-shell.cjs.entry.js +2 -2
  34. package/dist/cjs/ui-select.cjs.entry.js +15 -7
  35. package/dist/cjs/ui-switch.cjs.entry.js +20 -11
  36. package/dist/cjs/ui-tabs.cjs.entry.js +11 -10
  37. package/dist/cjs/ui-textarea.cjs.entry.js +10 -6
  38. package/dist/cjs/ui-toast-region.cjs.entry.js +31 -20
  39. package/dist/cjs/ui-tooltip.cjs.entry.js +63 -23
  40. package/dist/cjs/ui-top-bar.cjs.entry.js +2 -2
  41. package/dist/cjs/ui-tree-item.cjs.entry.js +57 -616
  42. package/dist/cjs/ui-tree.cjs.entry.js +198 -14
  43. package/dist/collection/collection-manifest.json +3 -0
  44. package/dist/collection/components/ui-affordance-scope/ui-affordance-scope.js +1 -1
  45. package/dist/collection/components/ui-avatar/ui-avatar.css +4 -4
  46. package/dist/collection/components/ui-avatar/ui-avatar.js +1 -1
  47. package/dist/collection/components/ui-avatar-group/ui-avatar-group.css +2 -2
  48. package/dist/collection/components/ui-avatar-group/ui-avatar-group.js +8 -16
  49. package/dist/collection/components/ui-badge/ui-badge.css +64 -48
  50. package/dist/collection/components/ui-badge/ui-badge.js +1 -1
  51. package/dist/collection/components/ui-button/ui-button.css +36 -26
  52. package/dist/collection/components/ui-button/ui-button.js +14 -3
  53. package/dist/collection/components/ui-callout/ui-callout.css +74 -0
  54. package/dist/collection/components/ui-callout/ui-callout.js +59 -0
  55. package/dist/collection/components/ui-checkbox/ui-checkbox.js +16 -11
  56. package/dist/collection/components/ui-chip/ui-chip.css +43 -0
  57. package/dist/collection/components/ui-chip/ui-chip.js +45 -0
  58. package/dist/collection/components/ui-combobox/ui-combobox.css +24 -0
  59. package/dist/collection/components/ui-combobox/ui-combobox.js +973 -0
  60. package/dist/collection/components/ui-context-menu/ui-context-menu.js +1 -1
  61. package/dist/collection/components/ui-dialog/ui-dialog.js +49 -13
  62. package/dist/collection/components/ui-disclosure/ui-disclosure.js +12 -10
  63. package/dist/collection/components/ui-floating-action-button/ui-floating-action-button.js +1 -1
  64. package/dist/collection/components/ui-form-field/ui-form-field.css +4 -0
  65. package/dist/collection/components/ui-form-field/ui-form-field.js +59 -4
  66. package/dist/collection/components/ui-icon-button/ui-icon-button.js +1 -1
  67. package/dist/collection/components/ui-input/ui-input.css +8 -6
  68. package/dist/collection/components/ui-input/ui-input.js +11 -7
  69. package/dist/collection/components/ui-menu/ui-menu.css +12 -23
  70. package/dist/collection/components/ui-menu/ui-menu.js +16 -12
  71. package/dist/collection/components/ui-menu-item/ui-menu-item.css +9 -3
  72. package/dist/collection/components/ui-menu-item/ui-menu-item.js +1 -1
  73. package/dist/collection/components/ui-popover/ui-popover.css +14 -5
  74. package/dist/collection/components/ui-popover/ui-popover.js +12 -10
  75. package/dist/collection/components/ui-radio/ui-radio.js +25 -12
  76. package/dist/collection/components/ui-radio-group/ui-radio-group.js +1 -1
  77. package/dist/collection/components/ui-search-result-row/ui-search-result-row.js +1 -1
  78. package/dist/collection/components/ui-search-shell/ui-search-shell.js +1 -1
  79. package/dist/collection/components/ui-select/ui-select.css +8 -6
  80. package/dist/collection/components/ui-select/ui-select.js +17 -11
  81. package/dist/collection/components/ui-switch/ui-switch.js +22 -14
  82. package/dist/collection/components/ui-tabs/ui-tabs.js +13 -13
  83. package/dist/collection/components/ui-textarea/ui-textarea.css +7 -6
  84. package/dist/collection/components/ui-textarea/ui-textarea.js +10 -7
  85. package/dist/collection/components/ui-toast-region/ui-toast-region.js +30 -19
  86. package/dist/collection/components/ui-tooltip/ui-tooltip.css +16 -7
  87. package/dist/collection/components/ui-tooltip/ui-tooltip.js +115 -25
  88. package/dist/collection/components/ui-top-bar/ui-top-bar.js +1 -1
  89. package/dist/collection/components/ui-tree/ui-tree.css +2 -1
  90. package/dist/collection/components/ui-tree/ui-tree.js +216 -12
  91. package/dist/collection/components/ui-tree-item/ui-tree-item.js +84 -25
  92. package/dist/collection/field/combobox.js +4 -0
  93. package/dist/collection/field/valibot.js +5 -0
  94. package/dist/collection/field/validation.js +62 -0
  95. package/dist/collection/icons.js +6 -1
  96. package/dist/collection/overlay/manager.js +6 -7
  97. package/dist/collection/utils/controlled-state.js +4 -0
  98. package/dist/components/index.d.ts +6 -0
  99. package/dist/components/index.js +1 -1
  100. package/dist/components/p-Bh_1GxOD.js +1 -0
  101. package/dist/components/p-Bk55QiUK.js +1 -0
  102. package/dist/components/p-BnGhGgTH.js +1 -0
  103. package/dist/components/p-C-0syqXZ.js +1 -0
  104. package/dist/components/p-CoFximGM.js +13 -0
  105. package/dist/components/p-DIGcRYAW.js +1 -0
  106. package/dist/components/ui-affordance-scope.js +1 -1
  107. package/dist/components/ui-avatar-group.js +1 -1
  108. package/dist/components/ui-avatar.js +1 -1
  109. package/dist/components/ui-badge.js +1 -1
  110. package/dist/components/ui-button.js +1 -1
  111. package/dist/components/ui-callout.d.ts +11 -0
  112. package/dist/components/ui-callout.js +1 -0
  113. package/dist/components/ui-checkbox.js +1 -1
  114. package/dist/components/ui-chip.d.ts +11 -0
  115. package/dist/components/ui-chip.js +1 -0
  116. package/dist/components/ui-combobox.d.ts +11 -0
  117. package/dist/components/ui-combobox.js +1 -0
  118. package/dist/components/ui-context-menu.js +1 -1
  119. package/dist/components/ui-dialog.js +1 -1
  120. package/dist/components/ui-disclosure.js +1 -1
  121. package/dist/components/ui-floating-action-button.js +1 -1
  122. package/dist/components/ui-form-field.js +1 -1
  123. package/dist/components/ui-icon-button.js +1 -1
  124. package/dist/components/ui-input.js +1 -1
  125. package/dist/components/ui-menu-item.js +1 -1
  126. package/dist/components/ui-menu.js +1 -1
  127. package/dist/components/ui-popover.js +1 -1
  128. package/dist/components/ui-radio-group.js +1 -1
  129. package/dist/components/ui-radio.js +1 -1
  130. package/dist/components/ui-search-result-row.js +1 -1
  131. package/dist/components/ui-search-shell.js +1 -1
  132. package/dist/components/ui-select.js +1 -1
  133. package/dist/components/ui-switch.js +1 -1
  134. package/dist/components/ui-tabs.js +1 -1
  135. package/dist/components/ui-textarea.js +1 -1
  136. package/dist/components/ui-toast-region.js +1 -1
  137. package/dist/components/ui-tooltip.js +1 -1
  138. package/dist/components/ui-top-bar.js +1 -1
  139. package/dist/components/ui-tree-item.js +1 -13
  140. package/dist/components/ui-tree.js +1 -1
  141. package/dist/esm/controlled-state-BnGhGgTH.js +6 -0
  142. package/dist/esm/icons-CoFximGM.js +678 -0
  143. package/dist/esm/{index-CEeiinfk.js → index-8BGiMGQ0.js} +33 -1
  144. package/dist/esm/loader.js +3 -3
  145. package/dist/esm/looma.js +3 -3
  146. package/dist/esm/{manager-PM9a74r7.js → manager-C-0syqXZ.js} +6 -7
  147. package/dist/esm/ui-affordance-scope.entry.js +2 -2
  148. package/dist/esm/ui-avatar-group.entry.js +10 -18
  149. package/dist/esm/ui-avatar.entry.js +3 -3
  150. package/dist/esm/ui-badge.entry.js +3 -3
  151. package/dist/esm/ui-button.entry.js +16 -5
  152. package/dist/esm/ui-callout.entry.js +25 -0
  153. package/dist/esm/ui-checkbox.entry.js +14 -8
  154. package/dist/esm/ui-chip.entry.js +17 -0
  155. package/dist/esm/ui-combobox.entry.js +539 -0
  156. package/dist/esm/ui-context-menu.entry.js +3 -3
  157. package/dist/esm/ui-dialog.entry.js +46 -10
  158. package/dist/esm/ui-disclosure.entry.js +10 -7
  159. package/dist/esm/ui-floating-action-button.entry.js +2 -2
  160. package/dist/esm/ui-form-field.entry.js +61 -6
  161. package/dist/esm/ui-icon-button.entry.js +2 -2
  162. package/dist/esm/ui-input.entry.js +11 -6
  163. package/dist/esm/ui-menu-item.entry.js +3 -3
  164. package/dist/esm/ui-menu.entry.js +16 -11
  165. package/dist/esm/ui-popover.entry.js +12 -9
  166. package/dist/esm/ui-radio-group.entry.js +2 -2
  167. package/dist/esm/ui-radio.entry.js +18 -9
  168. package/dist/esm/ui-search-result-row.entry.js +2 -2
  169. package/dist/esm/ui-search-shell.entry.js +2 -2
  170. package/dist/esm/ui-select.entry.js +15 -7
  171. package/dist/esm/ui-switch.entry.js +20 -11
  172. package/dist/esm/ui-tabs.entry.js +11 -10
  173. package/dist/esm/ui-textarea.entry.js +10 -6
  174. package/dist/esm/ui-toast-region.entry.js +31 -20
  175. package/dist/esm/ui-tooltip.entry.js +63 -23
  176. package/dist/esm/ui-top-bar.entry.js +2 -2
  177. package/dist/esm/ui-tree-item.entry.js +57 -616
  178. package/dist/esm/ui-tree.entry.js +198 -14
  179. package/dist/index.cjs +2012 -870
  180. package/dist/index.d.cts +109 -1
  181. package/dist/index.d.ts +109 -1
  182. package/dist/index.js +72 -8
  183. package/dist/looma/looma.esm.js +1 -1
  184. package/dist/looma/p-03f44c45.entry.js +1 -0
  185. package/dist/looma/p-08f80207.entry.js +1 -0
  186. package/dist/looma/p-13f8195a.entry.js +1 -0
  187. package/dist/looma/{p-d273b857.entry.js → p-25e18ad6.entry.js} +1 -1
  188. package/dist/looma/p-2c03fa73.entry.js +1 -0
  189. package/dist/looma/p-314d5c7c.entry.js +1 -0
  190. package/dist/looma/{p-2ed7e241.entry.js → p-3ef2a21b.entry.js} +1 -1
  191. package/dist/looma/{p-063f5a89.entry.js → p-5a900d89.entry.js} +1 -1
  192. package/dist/looma/p-5fdcee1d.entry.js +1 -0
  193. package/dist/looma/{p-0198bb21.entry.js → p-672e3d16.entry.js} +1 -1
  194. package/dist/looma/p-68430534.entry.js +1 -0
  195. package/dist/looma/{p-2e6f791e.entry.js → p-72338f53.entry.js} +1 -1
  196. package/dist/looma/p-7ab661ec.entry.js +1 -0
  197. package/dist/looma/p-7c4a225f.entry.js +1 -0
  198. package/dist/looma/p-82f2fa3d.entry.js +1 -0
  199. package/dist/looma/p-839faf55.entry.js +1 -0
  200. package/dist/looma/p-8BGiMGQ0.js +2 -0
  201. package/dist/looma/p-8e254bc4.entry.js +1 -0
  202. package/dist/looma/p-8e6b1001.entry.js +1 -0
  203. package/dist/looma/p-920656cf.entry.js +1 -0
  204. package/dist/looma/p-97e8cb0e.entry.js +1 -0
  205. package/dist/looma/p-9d2662ca.entry.js +1 -0
  206. package/dist/looma/p-9e1c4020.entry.js +1 -0
  207. package/dist/looma/p-BnGhGgTH.js +1 -0
  208. package/dist/looma/p-C-0syqXZ.js +1 -0
  209. package/dist/looma/p-CoFximGM.js +13 -0
  210. package/dist/looma/{p-051f578c.entry.js → p-a63e2561.entry.js} +1 -1
  211. package/dist/looma/p-add67e4c.entry.js +1 -0
  212. package/dist/looma/p-b63f6d4f.entry.js +1 -0
  213. package/dist/looma/p-bd00d4e8.entry.js +1 -0
  214. package/dist/looma/p-cc915913.entry.js +1 -0
  215. package/dist/looma/p-cfba8f7c.entry.js +1 -0
  216. package/dist/looma/p-d56571a2.entry.js +1 -0
  217. package/dist/looma/{p-7e94d90d.entry.js → p-e0f241ab.entry.js} +1 -1
  218. package/dist/looma/p-f1750fd7.entry.js +1 -0
  219. package/dist/looma/p-fd1e4d22.entry.js +1 -0
  220. package/dist/types/components/ui-avatar-group/ui-avatar-group.d.ts +1 -2
  221. package/dist/types/components/ui-callout/ui-callout.d.ts +6 -0
  222. package/dist/types/components/ui-checkbox/ui-checkbox.d.ts +2 -1
  223. package/dist/types/components/ui-chip/ui-chip.d.ts +6 -0
  224. package/dist/types/components/ui-combobox/ui-combobox.d.ts +93 -0
  225. package/dist/types/components/ui-dialog/ui-dialog.d.ts +7 -1
  226. package/dist/types/components/ui-disclosure/ui-disclosure.d.ts +2 -1
  227. package/dist/types/components/ui-form-field/ui-form-field.d.ts +8 -0
  228. package/dist/types/components/ui-input/ui-input.d.ts +1 -1
  229. package/dist/types/components/ui-menu/ui-menu.d.ts +2 -1
  230. package/dist/types/components/ui-popover/ui-popover.d.ts +2 -1
  231. package/dist/types/components/ui-radio/ui-radio.d.ts +4 -1
  232. package/dist/types/components/ui-select/ui-select.d.ts +3 -2
  233. package/dist/types/components/ui-switch/ui-switch.d.ts +2 -1
  234. package/dist/types/components/ui-tabs/ui-tabs.d.ts +2 -1
  235. package/dist/types/components/ui-textarea/ui-textarea.d.ts +1 -1
  236. package/dist/types/components/ui-toast-region/ui-toast-region.d.ts +3 -1
  237. package/dist/types/components/ui-tooltip/ui-tooltip.d.ts +20 -2
  238. package/dist/types/components/ui-tree/ui-tree.d.ts +21 -1
  239. package/dist/types/components/ui-tree-item/ui-tree-item.d.ts +13 -5
  240. package/dist/types/components.d.ts +366 -71
  241. package/dist/types/field/combobox.d.ts +46 -0
  242. package/dist/types/field/valibot.d.ts +7 -0
  243. package/dist/types/field/validation.d.ts +56 -0
  244. package/dist/types/icons.d.ts +5 -0
  245. package/dist/types/utils/controlled-state.d.ts +4 -0
  246. package/dist/{ui-affordance-scope.entry-L533MECG.js → ui-affordance-scope.entry-3TUZ6GLW.js} +2 -2
  247. package/dist/ui-avatar-group.entry-XGJKN25W.js +51 -0
  248. package/dist/{ui-avatar.entry-3INAY3XP.js → ui-avatar.entry-SN3G44HW.js} +3 -3
  249. package/dist/ui-badge.entry-B6WDCWJX.js +22 -0
  250. package/dist/ui-button.entry-AZYUELLV.js +80 -0
  251. package/dist/ui-callout.entry-QRPWRMPC.js +32 -0
  252. package/dist/{ui-checkbox.entry-2PTBHSCQ.js → ui-checkbox.entry-OB6GFC4M.js} +17 -8
  253. package/dist/ui-chip.entry-XSNPJXX3.js +22 -0
  254. package/dist/ui-combobox.entry-IIMMUJF7.js +553 -0
  255. package/dist/{ui-context-menu.entry-AYDDCIZS.js → ui-context-menu.entry-AIULIE5Y.js} +3 -3
  256. package/dist/{ui-dialog.entry-I2XI3ZTZ.js → ui-dialog.entry-QSYWYHLY.js} +48 -10
  257. package/dist/{ui-disclosure.entry-5LY2BT7B.js → ui-disclosure.entry-3BJEYU3U.js} +13 -7
  258. package/dist/{ui-floating-action-button.entry-EJAMR5AM.js → ui-floating-action-button.entry-JEVNV6FI.js} +2 -2
  259. package/dist/ui-form-field.entry-PKSY7UU4.js +120 -0
  260. package/dist/{ui-icon-button.entry-7SD2LVXE.js → ui-icon-button.entry-TPX7BE7R.js} +2 -2
  261. package/dist/{ui-input.entry-7MM7GEQW.js → ui-input.entry-6NCLNW4E.js} +8 -6
  262. package/dist/ui-menu-item.entry-KA2K3PKV.js +22 -0
  263. package/dist/{ui-menu.entry-R4WK5QSX.js → ui-menu.entry-7GDO5L2T.js} +19 -11
  264. package/dist/{ui-popover.entry-ZRJRTXA7.js → ui-popover.entry-FR6YRNK6.js} +15 -9
  265. package/dist/{ui-radio-group.entry-S6RXHFSN.js → ui-radio-group.entry-7QHXQSNO.js} +2 -2
  266. package/dist/{ui-radio.entry-B73QZK2M.js → ui-radio.entry-YNMXKLDW.js} +21 -9
  267. package/dist/{ui-search-result-row.entry-DR2Y5S7P.js → ui-search-result-row.entry-AHVVAAIO.js} +2 -2
  268. package/dist/{ui-search-shell.entry-ST5IKJBC.js → ui-search-shell.entry-CNBEAMEZ.js} +2 -2
  269. package/dist/{ui-select.entry-7GPRFV67.js → ui-select.entry-TUY6TCTC.js} +13 -7
  270. package/dist/{ui-switch.entry-XQ5IRJRH.js → ui-switch.entry-26LFI7B5.js} +23 -11
  271. package/dist/{ui-tabs.entry-HPW5L5CY.js → ui-tabs.entry-LXB62RJJ.js} +14 -10
  272. package/dist/{ui-textarea.entry-W2PSRYVS.js → ui-textarea.entry-JYGMGPX2.js} +8 -6
  273. package/dist/{ui-toast-region.entry-FJUHFXKZ.js → ui-toast-region.entry-TOW4KZLZ.js} +29 -20
  274. package/dist/{ui-tooltip.entry-G5WHQW7K.js → ui-tooltip.entry-SKFNYXPH.js} +68 -25
  275. package/dist/{ui-top-bar.entry-3NCHFC4Y.js → ui-top-bar.entry-S3YP52EA.js} +2 -2
  276. package/dist/ui-tree-item.entry-LWYIPYLC.js +145 -0
  277. package/dist/{ui-tree.entry-SZW4Q5PY.js → ui-tree.entry-LXKUQFRU.js} +184 -13
  278. package/dist/valibot.d.ts +52 -0
  279. package/dist/valibot.js +7 -0
  280. package/editor/{chunk-QCOYOVQL.js → chunk-B5WVJOPV.js} +113 -97
  281. package/editor/extensions/index.d.ts +14 -6
  282. package/editor/extensions/index.js +1 -1
  283. package/editor/index.js +1 -1
  284. package/editor.css +37 -20
  285. package/package.json +11 -3
  286. package/styles.css +46 -20
  287. package/theme-high-contrast.css +12 -0
  288. package/tokens.css +26 -0
  289. package/vue/{chunk-5KWCMTXB.js → chunk-D4AJULDE.js} +116 -17
  290. package/vue/editor/index.d.ts +5 -15
  291. package/vue/editor/index.js +1 -1
  292. package/vue/index.d.ts +447 -115
  293. package/vue/index.js +7 -1
  294. package/dist/components/p-CEYIKqYc.js +0 -1
  295. package/dist/components/p-CIA4RyEp.js +0 -1
  296. package/dist/components/p-PM9a74r7.js +0 -1
  297. package/dist/looma/p-0584a051.entry.js +0 -1
  298. package/dist/looma/p-078f9fb8.entry.js +0 -1
  299. package/dist/looma/p-0f45c5f0.entry.js +0 -1
  300. package/dist/looma/p-11083743.entry.js +0 -1
  301. package/dist/looma/p-1674cda4.entry.js +0 -1
  302. package/dist/looma/p-1681b218.entry.js +0 -1
  303. package/dist/looma/p-34417499.entry.js +0 -1
  304. package/dist/looma/p-4b422d40.entry.js +0 -1
  305. package/dist/looma/p-54722713.entry.js +0 -13
  306. package/dist/looma/p-54c41576.entry.js +0 -1
  307. package/dist/looma/p-5ba9d496.entry.js +0 -1
  308. package/dist/looma/p-5d4713a6.entry.js +0 -1
  309. package/dist/looma/p-624ba086.entry.js +0 -1
  310. package/dist/looma/p-8d5adb17.entry.js +0 -1
  311. package/dist/looma/p-9194a99d.entry.js +0 -1
  312. package/dist/looma/p-CEeiinfk.js +0 -2
  313. package/dist/looma/p-PM9a74r7.js +0 -1
  314. package/dist/looma/p-a33522a2.entry.js +0 -1
  315. package/dist/looma/p-a5127c7d.entry.js +0 -1
  316. package/dist/looma/p-a9f46811.entry.js +0 -1
  317. package/dist/looma/p-b7aa4488.entry.js +0 -1
  318. package/dist/looma/p-caa8fc7b.entry.js +0 -1
  319. package/dist/looma/p-e3f99a24.entry.js +0 -1
  320. package/dist/looma/p-ed5abf6d.entry.js +0 -1
  321. package/dist/ui-avatar-group.entry-BWS7E2CM.js +0 -59
  322. package/dist/ui-badge.entry-2WOBVOYP.js +0 -22
  323. package/dist/ui-button.entry-VCGSEONK.js +0 -71
  324. package/dist/ui-form-field.entry-SJ6NNFXB.js +0 -67
  325. package/dist/ui-menu-item.entry-V3HIMR75.js +0 -22
  326. package/dist/ui-tree-item.entry-45RR3CMP.js +0 -385
@@ -6,7 +6,7 @@ import {
6
6
  getElement,
7
7
  h,
8
8
  registerInstance
9
- } from "./chunk-NIPNHZ5W.js";
9
+ } from "./chunk-IMHSPETJ.js";
10
10
 
11
11
  // dist/esm/ui-tree.entry.js
12
12
  function classifyDropPosition(rect, clientY, acceptsChildren) {
@@ -52,7 +52,7 @@ function createHoverIntent(delay, onIntent) {
52
52
  destroy: cancel
53
53
  };
54
54
  }
55
- var uiTreeCss = () => `:host{--ui-tree-indent:16px;display:block;min-inline-size:0;padding-inline-start:var(--ui-tree-gutter, 22px)}::slotted(ui-tree-item){--ui-tree-indent:inherit}`;
55
+ var uiTreeCss = () => `:host{--ui-tree-indent:16px;--ui-tree-gutter:0px;display:block;min-inline-size:0;padding-inline-start:var(--ui-tree-gutter)}::slotted(ui-tree-item){--ui-tree-indent:inherit}`;
56
56
  var UITree = class {
57
57
  constructor(hostRef) {
58
58
  registerInstance(this, hostRef);
@@ -62,10 +62,17 @@ var UITree = class {
62
62
  }
63
63
  label = "Tree";
64
64
  hoverExpandDelay = 700;
65
+ /** Maximum resulting item depth accepted by pointer reordering. Zero is unlimited. */
66
+ maxDepth = 0;
65
67
  source = null;
66
68
  target = null;
67
69
  position = null;
70
+ rejectedTarget = null;
71
+ rejectedPosition = null;
72
+ rejection = null;
68
73
  hoverIntent = null;
74
+ structureObserver = null;
75
+ tabStop = null;
69
76
  componentDidLoad() {
70
77
  this.hoverIntent = createHoverIntent(this.hoverExpandDelay, this.expandTarget);
71
78
  this.host.addEventListener("dragstart", this.onDragStart);
@@ -76,6 +83,11 @@ var UITree = class {
76
83
  this.host.addEventListener("drop", this.onDrop);
77
84
  this.host.addEventListener("dragend", this.onDragEnd);
78
85
  this.host.addEventListener("keydown", this.onKeyDown);
86
+ this.host.addEventListener("focusin", this.onFocusIn);
87
+ this.host.addEventListener("ui-tree-expansion-change", this.onExpansionChange);
88
+ this.syncStructuralLevels();
89
+ this.structureObserver = new MutationObserver(this.syncStructuralLevels);
90
+ this.structureObserver.observe(this.host, { childList: true, subtree: true });
79
91
  }
80
92
  disconnectedCallback() {
81
93
  this.hoverIntent?.destroy();
@@ -87,10 +99,40 @@ var UITree = class {
87
99
  this.host.removeEventListener("drop", this.onDrop);
88
100
  this.host.removeEventListener("dragend", this.onDragEnd);
89
101
  this.host.removeEventListener("keydown", this.onKeyDown);
102
+ this.host.removeEventListener("focusin", this.onFocusIn);
103
+ this.host.removeEventListener("ui-tree-expansion-change", this.onExpansionChange);
104
+ this.structureObserver?.disconnect();
105
+ this.structureObserver = null;
106
+ }
107
+ syncStructuralLevels = () => {
108
+ for (const item of Array.from(this.host.querySelectorAll("ui-tree-item"))) {
109
+ item.dispatchEvent(new CustomEvent("ui-tree-structure-sync"));
110
+ }
111
+ this.syncTabStop();
112
+ };
113
+ syncTabStop(preferred) {
114
+ const items = this.visibleItems();
115
+ const next = preferred && items.includes(preferred) ? preferred : this.tabStop && items.includes(this.tabStop) ? this.tabStop : items[0] ?? null;
116
+ this.tabStop = next;
117
+ for (const item of items) {
118
+ item.dispatchEvent(new CustomEvent("ui-tree-roving-tab-stop", {
119
+ detail: { active: item === next }
120
+ }));
121
+ }
90
122
  }
91
123
  itemFromEvent(event) {
92
124
  return event.composedPath().find((node) => node instanceof HTMLElement && node.localName === "ui-tree-item") ?? null;
93
125
  }
126
+ eventTargetsInteractiveContent(event) {
127
+ for (const node of event.composedPath()) {
128
+ if (node instanceof HTMLElement && node.localName === "ui-tree-item")
129
+ break;
130
+ if (node instanceof HTMLElement && node.matches('a, button, input, select, textarea, [role="button"], [role="link"]')) {
131
+ return true;
132
+ }
133
+ }
134
+ return false;
135
+ }
94
136
  itemId(item) {
95
137
  return item.itemId || item.getAttribute("item-id") || "";
96
138
  }
@@ -128,15 +170,51 @@ var UITree = class {
128
170
  accepts: (item.getAttribute("data-accepts") || item.getAttribute("accepts") || "").split(",").map((value) => value.trim()).filter(Boolean)
129
171
  };
130
172
  }
131
- permitsDrop(source, target, position) {
173
+ constraintDepth(item) {
174
+ if (item.dropDepth !== void 0)
175
+ return item.dropDepth;
176
+ const dropDepth = item.getAttribute("drop-depth");
177
+ if (dropDepth !== null)
178
+ return Number(dropDepth);
179
+ return Number(item.getAttribute("aria-level")) || 1;
180
+ }
181
+ subtreeDepth(item) {
182
+ if (item.subtreeDepth !== void 0)
183
+ return Math.max(0, Math.floor(item.subtreeDepth));
184
+ const override = item.getAttribute("subtree-depth");
185
+ if (override !== null)
186
+ return Math.max(0, Math.floor(Number(override)));
187
+ return Array.from(item.querySelectorAll("ui-tree-item")).reduce((deepest, descendant) => {
188
+ let nesting = 0;
189
+ let ancestor = descendant.parentElement?.closest("ui-tree-item") ?? null;
190
+ while (ancestor && ancestor !== item) {
191
+ nesting += 1;
192
+ ancestor = ancestor.parentElement?.closest("ui-tree-item") ?? null;
193
+ }
194
+ return ancestor === item ? Math.max(deepest, nesting + 1) : deepest;
195
+ }, 0);
196
+ }
197
+ dropRejection(source, target, position) {
132
198
  if (source.contains(target))
133
- return false;
199
+ return { reason: "descendant" };
134
200
  const sourceMeta = this.itemMetadata(source);
135
201
  const targetMeta = this.itemMetadata(target);
136
202
  if (position === "inside") {
137
- return this.acceptsChildren(target) && (targetMeta.accepts.length === 0 || targetMeta.accepts.includes(sourceMeta.type));
203
+ if (!this.acceptsChildren(target) || targetMeta.accepts.length > 0 && !targetMeta.accepts.includes(sourceMeta.type)) {
204
+ return { reason: "incompatible" };
205
+ }
206
+ } else if (sourceMeta.type !== targetMeta.type) {
207
+ return { reason: "incompatible" };
208
+ }
209
+ const maxDepth = Math.max(0, Math.floor(this.maxDepth));
210
+ if (maxDepth > 0) {
211
+ const targetDepth = Math.max(0, Math.floor(this.constraintDepth(target)));
212
+ const subtreeDepth = this.subtreeDepth(source);
213
+ const resultingDepth = targetDepth + (position === "inside" ? 1 : 0) + subtreeDepth;
214
+ if (resultingDepth > maxDepth)
215
+ return { reason: "max-depth", maxDepth, resultingDepth };
138
216
  }
139
- return sourceMeta.type === targetMeta.type;
217
+ return null;
140
218
  }
141
219
  clearTarget() {
142
220
  this.target?.removeAttribute("data-drop-position");
@@ -144,10 +222,16 @@ var UITree = class {
144
222
  this.position = null;
145
223
  this.hoverIntent?.cancel();
146
224
  }
225
+ clearRejection() {
226
+ this.rejectedTarget = null;
227
+ this.rejectedPosition = null;
228
+ this.rejection = null;
229
+ }
147
230
  finishDrag() {
148
231
  this.source?.removeAttribute("data-dragging");
149
232
  this.source = null;
150
233
  this.clearTarget();
234
+ this.clearRejection();
151
235
  }
152
236
  expandTarget = (itemId) => {
153
237
  const item = Array.from(this.host.querySelectorAll("ui-tree-item")).find((candidate) => this.itemId(candidate) === itemId);
@@ -183,18 +267,28 @@ var UITree = class {
183
267
  return false;
184
268
  if (!target || target === this.source) {
185
269
  this.clearTarget();
270
+ this.clearRejection();
186
271
  return false;
187
272
  }
188
273
  const row = this.rowFor(target);
189
274
  if (!row)
190
275
  return false;
191
276
  const position = classifyDropPosition(row.getBoundingClientRect(), clientY, this.acceptsChildren(target));
192
- if (!this.permitsDrop(this.source, target, position)) {
277
+ const rejection = this.dropRejection(this.source, target, position);
278
+ if (rejection) {
193
279
  if (dataTransfer)
194
280
  dataTransfer.dropEffect = "none";
195
281
  this.clearTarget();
282
+ if (rejection.reason === "max-depth") {
283
+ this.rejectedTarget = target;
284
+ this.rejectedPosition = position;
285
+ this.rejection = rejection;
286
+ } else {
287
+ this.clearRejection();
288
+ }
196
289
  return false;
197
290
  }
291
+ this.clearRejection();
198
292
  if (dataTransfer)
199
293
  dataTransfer.dropEffect = "move";
200
294
  if (this.target !== target || this.position !== position) {
@@ -231,12 +325,15 @@ var UITree = class {
231
325
  if (this.itemAtPoint(event.clientX, event.clientY))
232
326
  return;
233
327
  this.clearTarget();
328
+ this.clearRejection();
234
329
  };
235
330
  dispatchReorder(source, target, position) {
236
331
  const sourceId = this.itemId(source);
237
332
  const targetId = this.itemId(target);
238
333
  if (!sourceId || !targetId)
239
334
  return;
335
+ if (position === "inside")
336
+ this.expandTarget(targetId);
240
337
  const sourceMeta = this.itemMetadata(source);
241
338
  const targetMeta = this.itemMetadata(target);
242
339
  dispatchDetail(this.host, "reorder", {
@@ -250,6 +347,21 @@ var UITree = class {
250
347
  trigger: "pointer"
251
348
  });
252
349
  }
350
+ dispatchReorderRejected(source, target, position, rejection) {
351
+ const sourceId = this.itemId(source);
352
+ const targetId = this.itemId(target);
353
+ if (!sourceId || !targetId)
354
+ return;
355
+ dispatchDetail(this.host, "reorder-rejected", {
356
+ sourceId,
357
+ targetId,
358
+ position,
359
+ reason: "max-depth",
360
+ maxDepth: rejection.maxDepth,
361
+ resultingDepth: rejection.resultingDepth,
362
+ trigger: "pointer"
363
+ });
364
+ }
253
365
  onDrop = (event) => {
254
366
  if (!this.source || !this.target || !this.position)
255
367
  return;
@@ -259,13 +371,21 @@ var UITree = class {
259
371
  };
260
372
  onDragEnd = (event) => {
261
373
  if (this.source) {
374
+ if (this.rejectedTarget && this.rejectedPosition && this.rejection) {
375
+ this.dispatchReorderRejected(this.source, this.rejectedTarget, this.rejectedPosition, this.rejection);
376
+ this.finishDrag();
377
+ return;
378
+ }
262
379
  const target = this.itemAtPoint(event.clientX, event.clientY);
263
380
  if (target && target !== this.source) {
264
381
  const row = this.rowFor(target);
265
382
  if (row) {
266
383
  const position = classifyDropPosition(row.getBoundingClientRect(), event.clientY, this.acceptsChildren(target));
267
- if (this.permitsDrop(this.source, target, position)) {
384
+ const rejection = this.dropRejection(this.source, target, position);
385
+ if (!rejection) {
268
386
  this.dispatchReorder(this.source, target, position);
387
+ } else if (rejection.reason === "max-depth") {
388
+ this.dispatchReorderRejected(this.source, target, position, rejection);
269
389
  }
270
390
  }
271
391
  }
@@ -275,7 +395,35 @@ var UITree = class {
275
395
  visibleItems() {
276
396
  return Array.from(this.host.querySelectorAll("ui-tree-item")).filter((item) => item.getClientRects().length > 0 && !item.hasAttribute("disabled"));
277
397
  }
398
+ parentItem(item) {
399
+ const parent = item.parentElement?.closest("ui-tree-item") ?? null;
400
+ return parent && this.host.contains(parent) ? parent : null;
401
+ }
402
+ firstVisibleChild(item, items) {
403
+ return items.find((candidate) => this.parentItem(candidate) === item) ?? null;
404
+ }
405
+ focusItem(item) {
406
+ this.syncTabStop(item);
407
+ item.focus();
408
+ }
409
+ requestExpansion(item, expanded) {
410
+ item.dispatchEvent(new CustomEvent("ui-tree-request-expanded", {
411
+ detail: { expanded, trigger: "keyboard" }
412
+ }));
413
+ }
414
+ onFocusIn = (event) => {
415
+ if (this.eventTargetsInteractiveContent(event))
416
+ return;
417
+ const item = this.itemFromEvent(event);
418
+ if (item)
419
+ this.syncTabStop(item);
420
+ };
421
+ onExpansionChange = () => {
422
+ requestAnimationFrame(() => this.syncTabStop());
423
+ };
278
424
  onKeyDown = (event) => {
425
+ if (this.eventTargetsInteractiveContent(event))
426
+ return;
279
427
  const current = this.itemFromEvent(event);
280
428
  if (!current)
281
429
  return;
@@ -283,14 +431,37 @@ var UITree = class {
283
431
  const index = items.indexOf(current);
284
432
  if (index < 0)
285
433
  return;
286
- const next = event.key === "ArrowDown" ? items[index + 1] : event.key === "ArrowUp" ? items[index - 1] : null;
287
- if (!next)
434
+ const next = event.key === "ArrowDown" ? items[index + 1] : event.key === "ArrowUp" ? items[index - 1] : event.key === "Home" ? items[0] : event.key === "End" ? items.at(-1) : null;
435
+ if (next) {
436
+ event.preventDefault();
437
+ this.focusItem(next);
288
438
  return;
289
- event.preventDefault();
290
- next.focus();
439
+ }
440
+ if (event.key === "ArrowLeft") {
441
+ if (current.getAttribute("aria-expanded") === "true") {
442
+ event.preventDefault();
443
+ this.requestExpansion(current, false);
444
+ } else if (this.parentItem(current)) {
445
+ event.preventDefault();
446
+ this.focusItem(this.parentItem(current));
447
+ }
448
+ return;
449
+ }
450
+ if (event.key === "ArrowRight") {
451
+ if (current.getAttribute("aria-expanded") === "false") {
452
+ event.preventDefault();
453
+ this.requestExpansion(current, true);
454
+ } else if (current.getAttribute("aria-expanded") === "true") {
455
+ const child = this.firstVisibleChild(current, items);
456
+ if (child) {
457
+ event.preventDefault();
458
+ this.focusItem(child);
459
+ }
460
+ }
461
+ }
291
462
  };
292
463
  render() {
293
- return h(Host, { key: "7da064127eb199f5e2cfc59489a07204c9dac2f2", role: "tree", "aria-label": this.label || "Tree" }, h("slot", { key: "31a98a6774ab35e565dab65f1dd8202494432b32" }));
464
+ return h(Host, { key: "549c09abc67dc60b16bf2d6b7d6346f214e9d6ae", role: "tree", "aria-label": this.label || "Tree" }, h("slot", { key: "fea59bde97611bf384e32ce4fb2b3eec9aca784f" }));
294
465
  }
295
466
  };
296
467
  UITree.style = uiTreeCss();
@@ -0,0 +1,52 @@
1
+ import { GenericSchema, GenericSchemaAsync, InferOutput } from 'valibot';
2
+
3
+ /** Structural Standard Schema v1 boundary; no schema-library runtime dependency. */
4
+ interface FieldSchema<Output = unknown> {
5
+ readonly '~standard': {
6
+ readonly version: 1;
7
+ readonly vendor: string;
8
+ readonly validate: (value: unknown) => FieldSchemaResult<Output> | Promise<FieldSchemaResult<Output>>;
9
+ readonly types?: {
10
+ readonly input: unknown;
11
+ readonly output: Output;
12
+ };
13
+ };
14
+ }
15
+ interface FieldIssue {
16
+ readonly message: string;
17
+ readonly path?: ReadonlyArray<PropertyKey | {
18
+ readonly key: PropertyKey;
19
+ }>;
20
+ readonly severity?: 'error' | 'warning';
21
+ }
22
+ type FieldSchemaResult<T = unknown> = {
23
+ readonly value: T;
24
+ readonly issues?: undefined;
25
+ } | {
26
+ readonly issues: readonly FieldIssue[];
27
+ };
28
+ interface FieldRequest<Context = unknown> {
29
+ raw: string;
30
+ value: string | null;
31
+ context: Context;
32
+ signal: AbortSignal;
33
+ }
34
+ interface FieldResult<Output = unknown> {
35
+ output?: Output;
36
+ issues: readonly FieldIssue[];
37
+ }
38
+ interface FieldValidation {
39
+ schema?: FieldSchema;
40
+ parse?: (raw: string, request: FieldRequest) => unknown | Promise<unknown>;
41
+ normalize?: (value: unknown, request: FieldRequest) => unknown | Promise<unknown>;
42
+ validator?: (value: unknown, request: FieldRequest) => Partial<FieldResult> | Promise<Partial<FieldResult>>;
43
+ issues?: readonly FieldIssue[];
44
+ }
45
+
46
+ /** Valibot's Standard Schema implementation preserves async transforms and issue paths.
47
+ * Type-only Valibot imports keep the adapter free of a schema-library runtime. */
48
+ declare function valibotField<T extends GenericSchema | GenericSchemaAsync>(schema: T, options?: Omit<FieldValidation, 'schema'>): FieldValidation & {
49
+ schema: FieldSchema<InferOutput<T>>;
50
+ };
51
+
52
+ export { valibotField };
@@ -0,0 +1,7 @@
1
+ // src/field/valibot.ts
2
+ function valibotField(schema, options = {}) {
3
+ return { ...options, schema };
4
+ }
5
+ export {
6
+ valibotField
7
+ };