@threadlabs/looma 0.2.4 → 0.2.6

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 (428) hide show
  1. package/dist/chunk-3K45IWIJ.js +4733 -0
  2. package/dist/chunk-MLKGABMK.js +9 -0
  3. package/dist/chunk-UHHA4WT5.js +2916 -0
  4. package/dist/declarative-generated.cjs +135 -0
  5. package/dist/declarative-generated.d.cts +10 -0
  6. package/dist/declarative-generated.d.ts +10 -0
  7. package/dist/declarative-generated.js +111 -0
  8. package/dist/declarative.cjs +2944 -0
  9. package/dist/declarative.d.cts +27 -0
  10. package/dist/declarative.d.ts +27 -0
  11. package/dist/declarative.js +13 -0
  12. package/dist/index.cjs +7480 -6457
  13. package/dist/index.d.cts +4 -58
  14. package/dist/index.d.ts +4 -58
  15. package/dist/index.js +15 -27
  16. package/dist/loader.cjs +7654 -0
  17. package/dist/loader.d.cts +4 -0
  18. package/dist/loader.d.ts +4 -0
  19. package/dist/loader.js +16 -0
  20. package/dist/valibot.cjs +31 -0
  21. package/dist/valibot.d.cts +10 -0
  22. package/dist/valibot.d.ts +1 -43
  23. package/dist/valibot.js +2 -0
  24. package/dist/{types/field/validation.d.ts → validation-bxcou-l-.d.cts} +13 -11
  25. package/dist/validation-bxcou-l-.d.ts +58 -0
  26. package/editor/{chunk-B5WVJOPV.js → chunk-BXICJBWS.js} +118 -8
  27. package/editor/{chunk-ZOUKEZ77.js → chunk-JK53ENSG.js} +8 -21
  28. package/editor/chunk-WI7ZA44X.js +2558 -0
  29. package/editor/extensions/index.d.ts +11 -2
  30. package/editor/extensions/index.js +9 -7
  31. package/editor/index.d.ts +1 -1
  32. package/editor/index.js +10 -8
  33. package/editor/ui.js +2 -2
  34. package/editor.css +32 -0
  35. package/layout/index.cjs +466 -400
  36. package/layout/index.d.cts +1 -2
  37. package/layout/index.d.ts +1 -2
  38. package/layout/index.js +471 -395
  39. package/package.json +14 -5
  40. package/styles.css +8 -8
  41. package/vue/chunk-4DPYH3IT.js +3538 -0
  42. package/vue/editor/index.d.ts +17 -7
  43. package/vue/editor/index.js +53 -35
  44. package/vue/index.d.ts +48 -31
  45. package/vue/index.js +1 -1
  46. package/dist/chunk-24OTMNIU.js +0 -1617
  47. package/dist/chunk-D5WRORG6.js +0 -366
  48. package/dist/chunk-HNFCGIBP.js +0 -8
  49. package/dist/chunk-NB6DBRXQ.js +0 -323
  50. package/dist/chunk-OF57X5AR.js +0 -10
  51. package/dist/chunk-TL4FIE7X.js +0 -93
  52. package/dist/chunk-UL7UIUJZ.js +0 -20
  53. package/dist/cjs/app-globals-V2Kpy_OQ.js +0 -5
  54. package/dist/cjs/controlled-state-BFya8rAX.js +0 -9
  55. package/dist/cjs/events-TcQIzpNv.js +0 -19
  56. package/dist/cjs/icons-BAdjrnhS.js +0 -680
  57. package/dist/cjs/id-CYbKpaYr.js +0 -9
  58. package/dist/cjs/index-BHG9Rpil.js +0 -1602
  59. package/dist/cjs/index.cjs.js +0 -2
  60. package/dist/cjs/loader.cjs.js +0 -13
  61. package/dist/cjs/looma.cjs.js +0 -25
  62. package/dist/cjs/manager-Ce25WRtl.js +0 -95
  63. package/dist/cjs/positioning-CCR6ifPj.js +0 -426
  64. package/dist/cjs/ui-affordance-scope.cjs.entry.js +0 -43
  65. package/dist/cjs/ui-avatar-group.cjs.entry.js +0 -43
  66. package/dist/cjs/ui-avatar.cjs.entry.js +0 -50
  67. package/dist/cjs/ui-badge.cjs.entry.js +0 -19
  68. package/dist/cjs/ui-button.cjs.entry.js +0 -75
  69. package/dist/cjs/ui-callout.cjs.entry.js +0 -27
  70. package/dist/cjs/ui-checkbox.cjs.entry.js +0 -97
  71. package/dist/cjs/ui-chip_2.cjs.entry.js +0 -258
  72. package/dist/cjs/ui-combobox.cjs.entry.js +0 -708
  73. package/dist/cjs/ui-context-menu.cjs.entry.js +0 -239
  74. package/dist/cjs/ui-dialog.cjs.entry.js +0 -131
  75. package/dist/cjs/ui-disclosure.cjs.entry.js +0 -112
  76. package/dist/cjs/ui-editable.cjs.entry.js +0 -100
  77. package/dist/cjs/ui-floating-action-button.cjs.entry.js +0 -20
  78. package/dist/cjs/ui-form-field.cjs.entry.js +0 -114
  79. package/dist/cjs/ui-icon-button.cjs.entry.js +0 -23
  80. package/dist/cjs/ui-input.cjs.entry.js +0 -106
  81. package/dist/cjs/ui-menu-item.cjs.entry.js +0 -19
  82. package/dist/cjs/ui-menu.cjs.entry.js +0 -182
  83. package/dist/cjs/ui-popover.cjs.entry.js +0 -135
  84. package/dist/cjs/ui-radio-group.cjs.entry.js +0 -134
  85. package/dist/cjs/ui-radio.cjs.entry.js +0 -94
  86. package/dist/cjs/ui-search-result-row.cjs.entry.js +0 -47
  87. package/dist/cjs/ui-search-shell.cjs.entry.js +0 -39
  88. package/dist/cjs/ui-select.cjs.entry.js +0 -108
  89. package/dist/cjs/ui-switch.cjs.entry.js +0 -74
  90. package/dist/cjs/ui-tabs.cjs.entry.js +0 -118
  91. package/dist/cjs/ui-textarea.cjs.entry.js +0 -110
  92. package/dist/cjs/ui-toast-region.cjs.entry.js +0 -93
  93. package/dist/cjs/ui-top-bar.cjs.entry.js +0 -43
  94. package/dist/cjs/ui-tree-item.cjs.entry.js +0 -135
  95. package/dist/cjs/ui-tree.cjs.entry.js +0 -500
  96. package/dist/collection/collection-manifest.json +0 -45
  97. package/dist/collection/components/ui-affordance-scope/ui-affordance-scope.css +0 -8
  98. package/dist/collection/components/ui-affordance-scope/ui-affordance-scope.js +0 -70
  99. package/dist/collection/components/ui-avatar/ui-avatar.css +0 -35
  100. package/dist/collection/components/ui-avatar/ui-avatar.js +0 -130
  101. package/dist/collection/components/ui-avatar-group/ui-avatar-group.css +0 -32
  102. package/dist/collection/components/ui-avatar-group/ui-avatar-group.js +0 -95
  103. package/dist/collection/components/ui-badge/ui-badge.css +0 -90
  104. package/dist/collection/components/ui-badge/ui-badge.js +0 -62
  105. package/dist/collection/components/ui-button/ui-button.css +0 -121
  106. package/dist/collection/components/ui-button/ui-button.js +0 -141
  107. package/dist/collection/components/ui-callout/ui-callout.css +0 -74
  108. package/dist/collection/components/ui-callout/ui-callout.js +0 -59
  109. package/dist/collection/components/ui-checkbox/ui-checkbox.css +0 -24
  110. package/dist/collection/components/ui-checkbox/ui-checkbox.js +0 -228
  111. package/dist/collection/components/ui-chip/ui-chip.css +0 -57
  112. package/dist/collection/components/ui-chip/ui-chip.js +0 -67
  113. package/dist/collection/components/ui-combobox/ui-combobox.css +0 -47
  114. package/dist/collection/components/ui-combobox/ui-combobox.js +0 -1295
  115. package/dist/collection/components/ui-context-menu/ui-context-menu.css +0 -34
  116. package/dist/collection/components/ui-context-menu/ui-context-menu.js +0 -311
  117. package/dist/collection/components/ui-dialog/ui-dialog.css +0 -72
  118. package/dist/collection/components/ui-dialog/ui-dialog.js +0 -242
  119. package/dist/collection/components/ui-disclosure/ui-disclosure.css +0 -7
  120. package/dist/collection/components/ui-disclosure/ui-disclosure.js +0 -184
  121. package/dist/collection/components/ui-editable/ui-editable.css +0 -2
  122. package/dist/collection/components/ui-editable/ui-editable.js +0 -196
  123. package/dist/collection/components/ui-floating-action-button/ui-floating-action-button.css +0 -73
  124. package/dist/collection/components/ui-floating-action-button/ui-floating-action-button.js +0 -85
  125. package/dist/collection/components/ui-form-field/ui-form-field.css +0 -25
  126. package/dist/collection/components/ui-form-field/ui-form-field.js +0 -180
  127. package/dist/collection/components/ui-icon-button/ui-icon-button.css +0 -145
  128. package/dist/collection/components/ui-icon-button/ui-icon-button.js +0 -128
  129. package/dist/collection/components/ui-input/ui-input.css +0 -48
  130. package/dist/collection/components/ui-input/ui-input.js +0 -217
  131. package/dist/collection/components/ui-menu/ui-menu.css +0 -73
  132. package/dist/collection/components/ui-menu/ui-menu.js +0 -280
  133. package/dist/collection/components/ui-menu-item/ui-menu-item.css +0 -32
  134. package/dist/collection/components/ui-menu-item/ui-menu-item.js +0 -64
  135. package/dist/collection/components/ui-popover/ui-popover.css +0 -58
  136. package/dist/collection/components/ui-popover/ui-popover.js +0 -232
  137. package/dist/collection/components/ui-radio/ui-radio.css +0 -22
  138. package/dist/collection/components/ui-radio/ui-radio.js +0 -226
  139. package/dist/collection/components/ui-radio-group/ui-radio-group.css +0 -10
  140. package/dist/collection/components/ui-radio-group/ui-radio-group.js +0 -247
  141. package/dist/collection/components/ui-search-result-row/ui-search-result-row.css +0 -80
  142. package/dist/collection/components/ui-search-result-row/ui-search-result-row.js +0 -100
  143. package/dist/collection/components/ui-search-shell/ui-search-shell.css +0 -63
  144. package/dist/collection/components/ui-search-shell/ui-search-shell.js +0 -46
  145. package/dist/collection/components/ui-select/ui-select.css +0 -64
  146. package/dist/collection/components/ui-select/ui-select.js +0 -218
  147. package/dist/collection/components/ui-switch/ui-switch.css +0 -63
  148. package/dist/collection/components/ui-switch/ui-switch.js +0 -185
  149. package/dist/collection/components/ui-tabs/ui-tabs.css +0 -68
  150. package/dist/collection/components/ui-tabs/ui-tabs.js +0 -190
  151. package/dist/collection/components/ui-textarea/ui-textarea.css +0 -49
  152. package/dist/collection/components/ui-textarea/ui-textarea.js +0 -241
  153. package/dist/collection/components/ui-toast-region/ui-toast-region.css +0 -59
  154. package/dist/collection/components/ui-toast-region/ui-toast-region.js +0 -126
  155. package/dist/collection/components/ui-tooltip/ui-tooltip.css +0 -43
  156. package/dist/collection/components/ui-tooltip/ui-tooltip.js +0 -430
  157. package/dist/collection/components/ui-top-bar/ui-top-bar.css +0 -51
  158. package/dist/collection/components/ui-top-bar/ui-top-bar.js +0 -52
  159. package/dist/collection/components/ui-tree/ui-tree.css +0 -12
  160. package/dist/collection/components/ui-tree/ui-tree.js +0 -515
  161. package/dist/collection/components/ui-tree-item/ui-tree-item.css +0 -217
  162. package/dist/collection/components/ui-tree-item/ui-tree-item.js +0 -406
  163. package/dist/collection/field/combobox.js +0 -4
  164. package/dist/collection/field/editable.js +0 -1
  165. package/dist/collection/field/multi-combobox.js +0 -1
  166. package/dist/collection/field/valibot.js +0 -5
  167. package/dist/collection/field/validation.js +0 -62
  168. package/dist/collection/icons.js +0 -71
  169. package/dist/collection/input-modality.js +0 -24
  170. package/dist/collection/overlay/manager.js +0 -92
  171. package/dist/collection/overlay/positioning.js +0 -424
  172. package/dist/collection/utils/controlled-state.js +0 -4
  173. package/dist/collection/utils/drag-drop.js +0 -51
  174. package/dist/collection/utils/events.js +0 -13
  175. package/dist/collection/utils/id.js +0 -5
  176. package/dist/collection/utils/initials.js +0 -11
  177. package/dist/components/index.d.ts +0 -102
  178. package/dist/components/index.js +0 -1
  179. package/dist/components/p-6SWSrfmW.js +0 -1
  180. package/dist/components/p-B_DaIVEY.js +0 -1
  181. package/dist/components/p-Bh_1GxOD.js +0 -1
  182. package/dist/components/p-BnGhGgTH.js +0 -1
  183. package/dist/components/p-BzaB_bXo.js +0 -1
  184. package/dist/components/p-C-0syqXZ.js +0 -1
  185. package/dist/components/p-CoFximGM.js +0 -13
  186. package/dist/components/p-JwSoedEO.js +0 -1
  187. package/dist/components/p-Vc4ExHFc.js +0 -1
  188. package/dist/components/p-hgBUJRDa.js +0 -1
  189. package/dist/components/ui-affordance-scope.d.ts +0 -11
  190. package/dist/components/ui-affordance-scope.js +0 -1
  191. package/dist/components/ui-avatar-group.d.ts +0 -11
  192. package/dist/components/ui-avatar-group.js +0 -1
  193. package/dist/components/ui-avatar.d.ts +0 -11
  194. package/dist/components/ui-avatar.js +0 -1
  195. package/dist/components/ui-badge.d.ts +0 -11
  196. package/dist/components/ui-badge.js +0 -1
  197. package/dist/components/ui-button.d.ts +0 -11
  198. package/dist/components/ui-button.js +0 -1
  199. package/dist/components/ui-callout.d.ts +0 -11
  200. package/dist/components/ui-callout.js +0 -1
  201. package/dist/components/ui-checkbox.d.ts +0 -11
  202. package/dist/components/ui-checkbox.js +0 -1
  203. package/dist/components/ui-chip.d.ts +0 -11
  204. package/dist/components/ui-chip.js +0 -1
  205. package/dist/components/ui-combobox.d.ts +0 -11
  206. package/dist/components/ui-combobox.js +0 -1
  207. package/dist/components/ui-context-menu.d.ts +0 -11
  208. package/dist/components/ui-context-menu.js +0 -1
  209. package/dist/components/ui-dialog.d.ts +0 -11
  210. package/dist/components/ui-dialog.js +0 -1
  211. package/dist/components/ui-disclosure.d.ts +0 -11
  212. package/dist/components/ui-disclosure.js +0 -1
  213. package/dist/components/ui-editable.d.ts +0 -11
  214. package/dist/components/ui-editable.js +0 -1
  215. package/dist/components/ui-floating-action-button.d.ts +0 -11
  216. package/dist/components/ui-floating-action-button.js +0 -1
  217. package/dist/components/ui-form-field.d.ts +0 -11
  218. package/dist/components/ui-form-field.js +0 -1
  219. package/dist/components/ui-icon-button.d.ts +0 -11
  220. package/dist/components/ui-icon-button.js +0 -1
  221. package/dist/components/ui-input.d.ts +0 -11
  222. package/dist/components/ui-input.js +0 -1
  223. package/dist/components/ui-menu-item.d.ts +0 -11
  224. package/dist/components/ui-menu-item.js +0 -1
  225. package/dist/components/ui-menu.d.ts +0 -11
  226. package/dist/components/ui-menu.js +0 -1
  227. package/dist/components/ui-popover.d.ts +0 -11
  228. package/dist/components/ui-popover.js +0 -1
  229. package/dist/components/ui-radio-group.d.ts +0 -11
  230. package/dist/components/ui-radio-group.js +0 -1
  231. package/dist/components/ui-radio.d.ts +0 -11
  232. package/dist/components/ui-radio.js +0 -1
  233. package/dist/components/ui-search-result-row.d.ts +0 -11
  234. package/dist/components/ui-search-result-row.js +0 -1
  235. package/dist/components/ui-search-shell.d.ts +0 -11
  236. package/dist/components/ui-search-shell.js +0 -1
  237. package/dist/components/ui-select.d.ts +0 -11
  238. package/dist/components/ui-select.js +0 -1
  239. package/dist/components/ui-switch.d.ts +0 -11
  240. package/dist/components/ui-switch.js +0 -1
  241. package/dist/components/ui-tabs.d.ts +0 -11
  242. package/dist/components/ui-tabs.js +0 -1
  243. package/dist/components/ui-textarea.d.ts +0 -11
  244. package/dist/components/ui-textarea.js +0 -1
  245. package/dist/components/ui-toast-region.d.ts +0 -11
  246. package/dist/components/ui-toast-region.js +0 -1
  247. package/dist/components/ui-tooltip.d.ts +0 -11
  248. package/dist/components/ui-tooltip.js +0 -1
  249. package/dist/components/ui-top-bar.d.ts +0 -11
  250. package/dist/components/ui-top-bar.js +0 -1
  251. package/dist/components/ui-tree-item.d.ts +0 -11
  252. package/dist/components/ui-tree-item.js +0 -1
  253. package/dist/components/ui-tree.d.ts +0 -11
  254. package/dist/components/ui-tree.js +0 -1
  255. package/dist/esm/app-globals-DQuL1Twl.js +0 -3
  256. package/dist/esm/controlled-state-BnGhGgTH.js +0 -6
  257. package/dist/esm/events-JwSoedEO.js +0 -15
  258. package/dist/esm/icons-CoFximGM.js +0 -678
  259. package/dist/esm/id-hgBUJRDa.js +0 -7
  260. package/dist/esm/index-8BGiMGQ0.js +0 -1593
  261. package/dist/esm/index.js +0 -1
  262. package/dist/esm/loader.js +0 -11
  263. package/dist/esm/looma.js +0 -21
  264. package/dist/esm/manager-C-0syqXZ.js +0 -91
  265. package/dist/esm/positioning-ZOr-2PSe.js +0 -421
  266. package/dist/esm/ui-affordance-scope.entry.js +0 -41
  267. package/dist/esm/ui-avatar-group.entry.js +0 -41
  268. package/dist/esm/ui-avatar.entry.js +0 -48
  269. package/dist/esm/ui-badge.entry.js +0 -17
  270. package/dist/esm/ui-button.entry.js +0 -73
  271. package/dist/esm/ui-callout.entry.js +0 -25
  272. package/dist/esm/ui-checkbox.entry.js +0 -95
  273. package/dist/esm/ui-chip_2.entry.js +0 -255
  274. package/dist/esm/ui-combobox.entry.js +0 -706
  275. package/dist/esm/ui-context-menu.entry.js +0 -237
  276. package/dist/esm/ui-dialog.entry.js +0 -129
  277. package/dist/esm/ui-disclosure.entry.js +0 -110
  278. package/dist/esm/ui-editable.entry.js +0 -98
  279. package/dist/esm/ui-floating-action-button.entry.js +0 -18
  280. package/dist/esm/ui-form-field.entry.js +0 -112
  281. package/dist/esm/ui-icon-button.entry.js +0 -21
  282. package/dist/esm/ui-input.entry.js +0 -104
  283. package/dist/esm/ui-menu-item.entry.js +0 -17
  284. package/dist/esm/ui-menu.entry.js +0 -180
  285. package/dist/esm/ui-popover.entry.js +0 -133
  286. package/dist/esm/ui-radio-group.entry.js +0 -132
  287. package/dist/esm/ui-radio.entry.js +0 -92
  288. package/dist/esm/ui-search-result-row.entry.js +0 -45
  289. package/dist/esm/ui-search-shell.entry.js +0 -37
  290. package/dist/esm/ui-select.entry.js +0 -106
  291. package/dist/esm/ui-switch.entry.js +0 -72
  292. package/dist/esm/ui-tabs.entry.js +0 -116
  293. package/dist/esm/ui-textarea.entry.js +0 -108
  294. package/dist/esm/ui-toast-region.entry.js +0 -91
  295. package/dist/esm/ui-top-bar.entry.js +0 -41
  296. package/dist/esm/ui-tree-item.entry.js +0 -133
  297. package/dist/esm/ui-tree.entry.js +0 -498
  298. package/dist/index.cjs.js +0 -1
  299. package/dist/looma/index.esm.js +0 -0
  300. package/dist/looma/looma.esm.js +0 -1
  301. package/dist/looma/p-08f80207.entry.js +0 -1
  302. package/dist/looma/p-0b5b8d9e.entry.js +0 -1
  303. package/dist/looma/p-1249a806.entry.js +0 -1
  304. package/dist/looma/p-16e0669d.entry.js +0 -1
  305. package/dist/looma/p-1c00670f.entry.js +0 -1
  306. package/dist/looma/p-1c5a7522.entry.js +0 -1
  307. package/dist/looma/p-22842f8c.entry.js +0 -1
  308. package/dist/looma/p-2915d5c0.entry.js +0 -1
  309. package/dist/looma/p-3b2961a6.entry.js +0 -1
  310. package/dist/looma/p-3f60f4c8.entry.js +0 -1
  311. package/dist/looma/p-424d6719.entry.js +0 -1
  312. package/dist/looma/p-4caccfce.entry.js +0 -1
  313. package/dist/looma/p-5fdcee1d.entry.js +0 -1
  314. package/dist/looma/p-6d8b99ee.entry.js +0 -1
  315. package/dist/looma/p-6f20d470.entry.js +0 -1
  316. package/dist/looma/p-7c0b5364.entry.js +0 -1
  317. package/dist/looma/p-8BGiMGQ0.js +0 -2
  318. package/dist/looma/p-8bdd9495.entry.js +0 -1
  319. package/dist/looma/p-99116a72.entry.js +0 -1
  320. package/dist/looma/p-9cfbf722.entry.js +0 -1
  321. package/dist/looma/p-9d2662ca.entry.js +0 -1
  322. package/dist/looma/p-9ff2fa19.entry.js +0 -1
  323. package/dist/looma/p-BnGhGgTH.js +0 -1
  324. package/dist/looma/p-C-0syqXZ.js +0 -1
  325. package/dist/looma/p-CoFximGM.js +0 -13
  326. package/dist/looma/p-DQuL1Twl.js +0 -1
  327. package/dist/looma/p-JwSoedEO.js +0 -1
  328. package/dist/looma/p-ZOr-2PSe.js +0 -1
  329. package/dist/looma/p-a2dd4c6c.entry.js +0 -1
  330. package/dist/looma/p-add67e4c.entry.js +0 -1
  331. package/dist/looma/p-b6ede6bb.entry.js +0 -1
  332. package/dist/looma/p-b76e2111.entry.js +0 -1
  333. package/dist/looma/p-ca2a54fd.entry.js +0 -1
  334. package/dist/looma/p-d372b0db.entry.js +0 -1
  335. package/dist/looma/p-d4825822.entry.js +0 -1
  336. package/dist/looma/p-d56571a2.entry.js +0 -1
  337. package/dist/looma/p-d5c3954f.entry.js +0 -1
  338. package/dist/looma/p-e604e906.entry.js +0 -1
  339. package/dist/looma/p-f1f7c5cb.entry.js +0 -1
  340. package/dist/looma/p-hgBUJRDa.js +0 -1
  341. package/dist/types/components/ui-affordance-scope/ui-affordance-scope.d.ts +0 -11
  342. package/dist/types/components/ui-avatar/ui-avatar.d.ts +0 -11
  343. package/dist/types/components/ui-avatar-group/ui-avatar-group.d.ts +0 -11
  344. package/dist/types/components/ui-badge/ui-badge.d.ts +0 -5
  345. package/dist/types/components/ui-button/ui-button.d.ts +0 -13
  346. package/dist/types/components/ui-callout/ui-callout.d.ts +0 -6
  347. package/dist/types/components/ui-checkbox/ui-checkbox.d.ts +0 -20
  348. package/dist/types/components/ui-chip/ui-chip.d.ts +0 -8
  349. package/dist/types/components/ui-combobox/ui-combobox.d.ts +0 -128
  350. package/dist/types/components/ui-context-menu/ui-context-menu.d.ts +0 -43
  351. package/dist/types/components/ui-dialog/ui-dialog.d.ts +0 -27
  352. package/dist/types/components/ui-disclosure/ui-disclosure.d.ts +0 -21
  353. package/dist/types/components/ui-editable/ui-editable.d.ts +0 -24
  354. package/dist/types/components/ui-floating-action-button/ui-floating-action-button.d.ts +0 -6
  355. package/dist/types/components/ui-form-field/ui-form-field.d.ts +0 -18
  356. package/dist/types/components/ui-icon-button/ui-icon-button.d.ts +0 -9
  357. package/dist/types/components/ui-input/ui-input.d.ts +0 -19
  358. package/dist/types/components/ui-menu/ui-menu.d.ts +0 -28
  359. package/dist/types/components/ui-menu-item/ui-menu-item.d.ts +0 -5
  360. package/dist/types/components/ui-popover/ui-popover.d.ts +0 -26
  361. package/dist/types/components/ui-radio/ui-radio.d.ts +0 -20
  362. package/dist/types/components/ui-radio-group/ui-radio-group.d.ts +0 -21
  363. package/dist/types/components/ui-search-result-row/ui-search-result-row.d.ts +0 -15
  364. package/dist/types/components/ui-search-shell/ui-search-shell.d.ts +0 -9
  365. package/dist/types/components/ui-select/ui-select.d.ts +0 -20
  366. package/dist/types/components/ui-switch/ui-switch.d.ts +0 -16
  367. package/dist/types/components/ui-tabs/ui-tabs.d.ts +0 -18
  368. package/dist/types/components/ui-textarea/ui-textarea.d.ts +0 -20
  369. package/dist/types/components/ui-toast-region/ui-toast-region.d.ts +0 -16
  370. package/dist/types/components/ui-tooltip/ui-tooltip.d.ts +0 -57
  371. package/dist/types/components/ui-top-bar/ui-top-bar.d.ts +0 -12
  372. package/dist/types/components/ui-tree/ui-tree.d.ts +0 -53
  373. package/dist/types/components/ui-tree-item/ui-tree-item.d.ts +0 -44
  374. package/dist/types/components.d.ts +0 -1889
  375. package/dist/types/field/combobox.d.ts +0 -46
  376. package/dist/types/field/editable.d.ts +0 -5
  377. package/dist/types/field/multi-combobox.d.ts +0 -11
  378. package/dist/types/field/valibot.d.ts +0 -7
  379. package/dist/types/icons.d.ts +0 -53
  380. package/dist/types/input-modality.d.ts +0 -6
  381. package/dist/types/overlay/manager.d.ts +0 -17
  382. package/dist/types/overlay/positioning.d.ts +0 -74
  383. package/dist/types/stencil-public-runtime.d.ts +0 -1860
  384. package/dist/types/utils/controlled-state.d.ts +0 -4
  385. package/dist/types/utils/drag-drop.d.ts +0 -15
  386. package/dist/types/utils/events.d.ts +0 -4
  387. package/dist/types/utils/id.d.ts +0 -1
  388. package/dist/types/utils/initials.d.ts +0 -1
  389. package/dist/ui-affordance-scope.entry-L6TIXYOP.js +0 -54
  390. package/dist/ui-avatar-group.entry-TCAA6P72.js +0 -51
  391. package/dist/ui-avatar.entry-52DQ7VXA.js +0 -51
  392. package/dist/ui-badge.entry-2XCAA6LL.js +0 -22
  393. package/dist/ui-button.entry-MNFBMNSX.js +0 -83
  394. package/dist/ui-callout.entry-SSHT5TH2.js +0 -32
  395. package/dist/ui-checkbox.entry-LOWIWIWI.js +0 -111
  396. package/dist/ui-chip_2.entry-BIMTSF6C.js +0 -272
  397. package/dist/ui-combobox.entry-25Z4MN7N.js +0 -717
  398. package/dist/ui-context-menu.entry-YZDL5Y4M.js +0 -248
  399. package/dist/ui-dialog.entry-HIXZX5AB.js +0 -146
  400. package/dist/ui-disclosure.entry-2JZHZNDQ.js +0 -126
  401. package/dist/ui-editable.entry-U3VR3XPT.js +0 -110
  402. package/dist/ui-floating-action-button.entry-6S3QN3KJ.js +0 -23
  403. package/dist/ui-form-field.entry-GQOSMLHT.js +0 -120
  404. package/dist/ui-icon-button.entry-QJXKVDM6.js +0 -26
  405. package/dist/ui-input.entry-UWMQ6JMP.js +0 -114
  406. package/dist/ui-menu-item.entry-NHNZKKJS.js +0 -22
  407. package/dist/ui-menu.entry-D53RUJND.js +0 -192
  408. package/dist/ui-popover.entry-7ZSIWCFQ.js +0 -152
  409. package/dist/ui-radio-group.entry-37MSYIH4.js +0 -142
  410. package/dist/ui-radio.entry-7YGCDHXT.js +0 -108
  411. package/dist/ui-search-result-row.entry-6FCCLGAS.js +0 -50
  412. package/dist/ui-search-shell.entry-HSBEXPER.js +0 -41
  413. package/dist/ui-select.entry-GIDIAYRD.js +0 -117
  414. package/dist/ui-switch.entry-MYAL6XPC.js +0 -87
  415. package/dist/ui-tabs.entry-R4TEXQSD.js +0 -128
  416. package/dist/ui-textarea.entry-FW32JNDV.js +0 -119
  417. package/dist/ui-toast-region.entry-BTMFPKZF.js +0 -104
  418. package/dist/ui-top-bar.entry-5DQGJF3B.js +0 -49
  419. package/dist/ui-tree-item.entry-ADT7DSOS.js +0 -145
  420. package/dist/ui-tree.entry-7PYQ5RIN.js +0 -470
  421. package/editor/chunk-64GLF274.js +0 -1271
  422. package/layout/index.css +0 -387
  423. package/loader/cdn.js +0 -1
  424. package/loader/index.cjs.js +0 -1
  425. package/loader/index.d.ts +0 -24
  426. package/loader/index.es2017.js +0 -1
  427. package/loader/index.js +0 -2
  428. package/vue/chunk-ROMBQS2L.js +0 -352
package/layout/index.js CHANGED
@@ -1,408 +1,484 @@
1
- // src/index.ts
2
- var ORIENTATION_HORIZONTAL = "horizontal";
3
- var ORIENTATION_VERTICAL = "vertical";
4
- function normalizeOrientation(value) {
5
- return value === ORIENTATION_VERTICAL ? ORIENTATION_VERTICAL : ORIENTATION_HORIZONTAL;
1
+ var __defProp = Object.defineProperty;
2
+ var __export = (target, all) => {
3
+ for (var name in all)
4
+ __defProp(target, name, { get: all[name], enumerable: true });
5
+ };
6
+
7
+ // src/declarative-index.ts
8
+ import { registerLoomaPackage } from "@threadlabs/looma/core/declarative";
9
+
10
+ // ../../tools/migrate-html-next/generated/layout/components/controllers/ui-reel.js
11
+ var ui_reel_exports = {};
12
+ __export(ui_reel_exports, {
13
+ default: () => controller
14
+ });
15
+ function controller(host) {
16
+ const element = host.element;
17
+ if (!element.hasAttribute("role")) element.setAttribute("role", "region");
18
+ if (!element.hasAttribute("tabindex")) element.setAttribute("tabindex", "0");
6
19
  }
7
- if (typeof HTMLElement !== "undefined") {
8
- class UILayoutElement extends HTMLElement {
9
- getPrimitiveAttribute(name) {
10
- return this.getAttribute(name) ?? "";
11
- }
12
- setPrimitiveAttribute(name, value) {
13
- const normalizedValue = value.trim();
14
- if (normalizedValue.length === 0) {
15
- this.removeAttribute(name);
16
- return;
17
- }
18
- this.setAttribute(name, normalizedValue);
19
- }
20
+
21
+ // ../../tools/migrate-html-next/generated/layout/components/controllers/ui-separator.js
22
+ var ui_separator_exports = {};
23
+ __export(ui_separator_exports, {
24
+ default: () => controller2
25
+ });
26
+ function controller2(host) {
27
+ const element = host.element;
28
+ const sync = () => {
29
+ if (!element.hasAttribute("role")) element.setAttribute("role", "separator");
30
+ if (element.getAttribute("role") === "separator") {
31
+ element.setAttribute("aria-orientation", host.state.orientation === "vertical" ? "vertical" : "horizontal");
32
+ } else {
33
+ element.removeAttribute("aria-orientation");
34
+ }
35
+ };
36
+ const stop = host.effect(sync);
37
+ const observer = new MutationObserver(sync);
38
+ observer.observe(element, { attributes: true, attributeFilter: ["role"] });
39
+ sync();
40
+ return () => {
41
+ stop();
42
+ observer.disconnect();
43
+ };
44
+ }
45
+
46
+ // ../../tools/migrate-html-next/generated/layout/components/controllers/ui-sidebar.js
47
+ var ui_sidebar_exports = {};
48
+ __export(ui_sidebar_exports, {
49
+ default: () => controller3
50
+ });
51
+ function positive(value, fallback) {
52
+ const number = Number(value);
53
+ return Number.isFinite(number) && number > 0 ? number : fallback;
54
+ }
55
+ function controller3(host) {
56
+ const element = host.element;
57
+ let resizeHandle;
58
+ let pointerAbort;
59
+ const bounds = () => {
60
+ const min = positive(host.state.minWidth, 176);
61
+ return { min, max: Math.max(min, positive(host.state.maxWidth, 480)), step: positive(host.state.resizeStep, 16) };
62
+ };
63
+ const defaultWidth = () => host.state.width === "narrow" ? 224 : host.state.width === "wide" ? 384 : 288;
64
+ const storageId = () => {
65
+ const key = String(host.state.storageKey ?? "").trim();
66
+ return key ? `looma:sidebar-width:${key}` : null;
67
+ };
68
+ const readStoredWidth = () => {
69
+ const key = storageId();
70
+ if (!key || typeof localStorage === "undefined") return null;
71
+ try {
72
+ const value = Number(localStorage.getItem(key));
73
+ return Number.isFinite(value) && value > 0 ? value : null;
74
+ } catch {
75
+ return null;
76
+ }
77
+ };
78
+ const persistWidth = (width) => {
79
+ const key = storageId();
80
+ if (!key || typeof localStorage === "undefined") return;
81
+ try {
82
+ localStorage.setItem(key, String(width));
83
+ } catch {
84
+ }
85
+ };
86
+ const currentWidth = () => {
87
+ const inline = Number.parseFloat(element.style.getPropertyValue("--ui-sidebar-width"));
88
+ if (Number.isFinite(inline)) return inline;
89
+ const children = [...element.children].filter((child) => !child.hasAttribute("data-ui-sidebar-resizer"));
90
+ const region = host.state.side === "end" ? children.at(-1) : children[0];
91
+ return region?.getBoundingClientRect().width || defaultWidth();
92
+ };
93
+ const setWidth = (value, persist = false, trigger = "programmatic") => {
94
+ const { min, max } = bounds();
95
+ const width = Math.round(Math.max(min, Math.min(max, value)));
96
+ const previous = Number.parseFloat(element.style.getPropertyValue("--ui-sidebar-width"));
97
+ element.style.setProperty("--ui-sidebar-width", `${width}px`);
98
+ resizeHandle?.setAttribute("aria-valuemin", String(min));
99
+ resizeHandle?.setAttribute("aria-valuemax", String(max));
100
+ resizeHandle?.setAttribute("aria-valuenow", String(width));
101
+ if (persist && previous !== width) persistWidth(width);
102
+ if (!Number.isFinite(previous) || previous !== width) host.dispatch("resize", { width, trigger });
103
+ };
104
+ const onKeydown = (event) => {
105
+ const { min, max, step } = bounds();
106
+ let next = null;
107
+ if (event.key === "Home") next = min;
108
+ if (event.key === "End") next = max;
109
+ if (event.key === "ArrowLeft" || event.key === "ArrowRight") {
110
+ const delta = event.key === "ArrowRight" ? step : -step;
111
+ next = currentWidth() + (host.state.side === "end" ? -delta : delta);
112
+ }
113
+ if (next === null) return;
114
+ event.preventDefault();
115
+ setWidth(next, true, "keyboard");
116
+ };
117
+ const onPointerdown = (event) => {
118
+ if (event.button !== 0 || pointerAbort) return;
119
+ event.preventDefault();
120
+ const startX = event.clientX;
121
+ const startWidth = currentWidth();
122
+ const multiplier = host.state.side === "end" ? -1 : 1;
123
+ pointerAbort = new AbortController();
124
+ const signal = pointerAbort.signal;
125
+ const finish = () => {
126
+ persistWidth(currentWidth());
127
+ pointerAbort?.abort();
128
+ pointerAbort = void 0;
129
+ };
130
+ window.addEventListener("pointermove", (move) => {
131
+ setWidth(startWidth + (move.clientX - startX) * multiplier, false, "pointer");
132
+ }, { signal });
133
+ window.addEventListener("pointerup", finish, { once: true, signal });
134
+ window.addEventListener("pointercancel", finish, { once: true, signal });
135
+ };
136
+ const removeHandle = () => {
137
+ pointerAbort?.abort();
138
+ pointerAbort = void 0;
139
+ resizeHandle?.remove();
140
+ resizeHandle = void 0;
141
+ };
142
+ const sync = () => {
143
+ if (!host.state.resizable) {
144
+ removeHandle();
145
+ return;
146
+ }
147
+ if (!resizeHandle) {
148
+ resizeHandle = document.createElement("div");
149
+ resizeHandle.setAttribute("data-ui-sidebar-resizer", "");
150
+ resizeHandle.setAttribute("data-ui-affordance", "resize");
151
+ resizeHandle.setAttribute("role", "separator");
152
+ resizeHandle.setAttribute("aria-orientation", "vertical");
153
+ resizeHandle.setAttribute("tabindex", "0");
154
+ const guide = document.createElement("span");
155
+ guide.setAttribute("data-ui-guide", "");
156
+ guide.setAttribute("aria-hidden", "true");
157
+ resizeHandle.append(guide);
158
+ resizeHandle.addEventListener("keydown", onKeydown);
159
+ resizeHandle.addEventListener("pointerdown", onPointerdown);
160
+ resizeHandle.addEventListener("dblclick", () => setWidth(defaultWidth(), true, "pointer"));
161
+ element.append(resizeHandle);
162
+ setWidth(readStoredWidth() ?? currentWidth());
163
+ }
164
+ resizeHandle.setAttribute("aria-label", String(host.state.resizeLabel || "Resize sidebar"));
165
+ setWidth(currentWidth());
166
+ };
167
+ const stop = host.effect(sync);
168
+ sync();
169
+ return () => {
170
+ stop();
171
+ removeHandle();
172
+ };
173
+ }
174
+
175
+ // ../../tools/migrate-html-next/generated/adoption/layout/registry.js
176
+ var records = [
177
+ { tag: "ui-center", source: '<template component="ui-center" status="early" summary="Looma ui-center layout primitive.">\n <defs>\n <prop name="measure" type="narrow | wide">measure token.</prop>\n <prop name="gutters" type="s | m | l">gutters token.</prop>\n </defs>\n <div><slot></slot></div>\n</template>\n', controller: void 0 },
178
+ { tag: "ui-cluster", source: '<template component="ui-cluster" status="early" summary="Looma ui-cluster layout primitive.">\n <defs>\n <prop name="gap" type="xs | s | m | l | xl">gap token.</prop>\n <prop name="align" type="start | center | end | stretch">align token.</prop>\n <prop name="justify" type="start | center | end | between">justify token.</prop>\n </defs>\n <div><slot></slot></div>\n</template>\n', controller: void 0 },
179
+ { tag: "ui-grid", source: '<template component="ui-grid" status="early" summary="Looma ui-grid layout primitive.">\n <defs>\n <prop name="gap" type="xs | s | m | l | xl">gap token.</prop>\n <prop name="min" type="sm | md | lg">min token.</prop>\n </defs>\n <div><slot></slot></div>\n</template>\n', controller: void 0 },
180
+ { tag: "ui-inline", source: '<template component="ui-inline" status="early" summary="Looma ui-inline layout primitive.">\n <defs>\n <prop name="gap" type="xs | s | m | l | xl">gap token.</prop>\n <prop name="align" type="start | center | end | stretch">align token.</prop>\n <prop name="justify" type="start | center | end | between">justify token.</prop>\n <prop name="wrap" type="wrap | nowrap">wrap token.</prop>\n </defs>\n <div><slot></slot></div>\n</template>\n', controller: void 0 },
181
+ { tag: "ui-reel", source: '<template component="ui-reel" status="early" summary="Looma ui-reel layout primitive." controller="./controllers/ui-reel.js">\n <defs>\n <prop name="gap" type="xs | s | m | l | xl">gap token.</prop>\n <prop name="itemWidth" type="sm | md | lg">itemWidth token.</prop>\n <prop name="snap" type="start | center">snap token.</prop>\n </defs>\n <div><slot></slot></div>\n</template>\n', controller: ui_reel_exports },
182
+ { tag: "ui-separator", source: '<template component="ui-separator" status="early" summary="Looma ui-separator layout primitive." controller="./controllers/ui-separator.js">\n <defs>\n <prop name="orientation" type="horizontal | vertical" default="horizontal">orientation token.</prop>\n </defs>\n <div><slot></slot></div>\n</template>\n', controller: ui_separator_exports },
183
+ { tag: "ui-sidebar", source: '<template component="ui-sidebar" status="early" summary="Looma ui-sidebar layout primitive." controller="./controllers/ui-sidebar.js">\n <defs>\n <prop name="gap" type="xs | s | m | l | xl">gap token.</prop>\n <prop name="side" type="start | end" default="start">side token.</prop>\n <prop name="width" type="narrow | default | wide" default="default">width token.</prop>\n <prop name="align" type="start | center | end | stretch">align token.</prop>\n <prop name="resizable" type="boolean" default="false">resizable token.</prop>\n <prop name="storageKey" type="string">storageKey token.</prop>\n <prop name="minWidth" type="number" default="176">minWidth token.</prop>\n <prop name="maxWidth" type="number" default="480">maxWidth token.</prop>\n <prop name="resizeStep" type="number" default="16">resizeStep token.</prop>\n <prop name="resizeLabel" type="string" default="Resize sidebar">resizeLabel token.</prop>\n <event name="resize" type="object({ width: number, trigger: keyboard | pointer | programmatic })"></event>\n </defs>\n <div><slot></slot></div>\n</template>\n', controller: ui_sidebar_exports },
184
+ { tag: "ui-stack", source: '<template component="ui-stack" status="early" summary="Looma ui-stack layout primitive.">\n <defs>\n <prop name="gap" type="xs | s | m | l | xl">gap token.</prop>\n <prop name="align" type="start | center | end | stretch">align token.</prop>\n <prop name="justify" type="start | center | end | between">justify token.</prop>\n </defs>\n <div><slot></slot></div>\n</template>\n', controller: void 0 },
185
+ { tag: "ui-switcher", source: '<template component="ui-switcher" status="early" summary="Looma ui-switcher layout primitive.">\n <defs>\n <prop name="gap" type="xs | s | m | l | xl">gap token.</prop>\n <prop name="threshold" type="xs | sm | md | lg">threshold token.</prop>\n <prop name="align" type="start | center | end | stretch">align token.</prop>\n </defs>\n <div><slot></slot></div>\n</template>\n', controller: void 0 }
186
+ ];
187
+ var styles = `/* Unlayered: box-model guarantees that remain safe for host composition. */
188
+ :where([data-component-root~="ui-stack"], [data-component-root~="ui-inline"], [data-component-root~="ui-cluster"], [data-component-root~="ui-grid"], [data-component-root~="ui-center"], [data-component-root~="ui-switcher"], [data-component-root~="ui-sidebar"], [data-component-root~="ui-reel"], [data-component-root~="ui-separator"]),
189
+ :where([data-component-root~="ui-stack"], [data-component-root~="ui-inline"], [data-component-root~="ui-cluster"], [data-component-root~="ui-grid"], [data-component-root~="ui-center"], [data-component-root~="ui-switcher"], [data-component-root~="ui-sidebar"], [data-component-root~="ui-reel"], [data-component-root~="ui-separator"]) *,
190
+ :where([data-component-root~="ui-stack"], [data-component-root~="ui-inline"], [data-component-root~="ui-cluster"], [data-component-root~="ui-grid"], [data-component-root~="ui-center"], [data-component-root~="ui-switcher"], [data-component-root~="ui-sidebar"], [data-component-root~="ui-reel"], [data-component-root~="ui-separator"]) *::before,
191
+ :where([data-component-root~="ui-stack"], [data-component-root~="ui-inline"], [data-component-root~="ui-cluster"], [data-component-root~="ui-grid"], [data-component-root~="ui-center"], [data-component-root~="ui-switcher"], [data-component-root~="ui-sidebar"], [data-component-root~="ui-reel"], [data-component-root~="ui-separator"]) *::after {
192
+ box-sizing: border-box;
193
+ }
194
+
195
+ :where([data-component-root~="ui-stack"], [data-component-root~="ui-inline"], [data-component-root~="ui-cluster"], [data-component-root~="ui-grid"], [data-component-root~="ui-center"], [data-component-root~="ui-switcher"], [data-component-root~="ui-sidebar"], [data-component-root~="ui-reel"], [data-component-root~="ui-separator"]) {
196
+ /* Reveal Looma's component layer instead of reverting past it. */
197
+ all: revert-layer;
198
+ box-sizing: border-box;
199
+ font-family: var(--ui-font-family-sans);
200
+ font-size: var(--ui-font-size-md);
201
+ line-height: var(--ui-line-height-md);
202
+ color: var(--ui-text-primary);
203
+ }
204
+
205
+ :where([data-component-root~="ui-stack"], [data-component-root~="ui-inline"], [data-component-root~="ui-cluster"], [data-component-root~="ui-grid"], [data-component-root~="ui-center"], [data-component-root~="ui-switcher"], [data-component-root~="ui-sidebar"], [data-component-root~="ui-reel"], [data-component-root~="ui-separator"])[data-ui-inherit-typography] {
206
+ font-family: inherit;
207
+ font-size: inherit;
208
+ line-height: inherit;
209
+ font-weight: inherit;
210
+ color: inherit;
211
+ direction: inherit;
212
+ writing-mode: inherit;
213
+ text-orientation: inherit;
214
+ text-rendering: inherit;
215
+ font-feature-settings: inherit;
216
+ font-variation-settings: inherit;
217
+ }
218
+
219
+ @layer components {
220
+ :where([data-component-root~="ui-stack"], [data-component-root~="ui-inline"], [data-component-root~="ui-cluster"], [data-component-root~="ui-grid"], [data-component-root~="ui-center"], [data-component-root~="ui-switcher"], [data-component-root~="ui-sidebar"], [data-component-root~="ui-reel"], [data-component-root~="ui-separator"]) {
221
+ min-inline-size: 0;
222
+ max-inline-size: 100%;
223
+ margin: 0;
20
224
  }
21
- class UIStackElement extends UILayoutElement {
22
- static get observedAttributes() {
23
- return ["gap", "align", "justify"];
24
- }
25
- get gap() {
26
- return this.getPrimitiveAttribute("gap");
27
- }
28
- set gap(value) {
29
- this.setPrimitiveAttribute("gap", value);
30
- }
31
- get align() {
32
- return this.getPrimitiveAttribute("align");
33
- }
34
- set align(value) {
35
- this.setPrimitiveAttribute("align", value);
36
- }
37
- get justify() {
38
- return this.getPrimitiveAttribute("justify");
39
- }
40
- set justify(value) {
41
- this.setPrimitiveAttribute("justify", value);
42
- }
225
+
226
+ [data-component-root~="ui-stack"] {
227
+ --ui-layout-gap: var(--ui-space-4, 1rem);
228
+ --ui-layout-align: stretch;
229
+ --ui-layout-justify: flex-start;
230
+ display: flex;
231
+ flex-direction: column;
232
+ gap: var(--ui-layout-gap);
233
+ align-items: var(--ui-layout-align);
234
+ justify-content: var(--ui-layout-justify);
43
235
  }
44
- class UIInlineElement extends UILayoutElement {
45
- static get observedAttributes() {
46
- return ["gap", "align", "justify", "wrap"];
47
- }
48
- get gap() {
49
- return this.getPrimitiveAttribute("gap");
50
- }
51
- set gap(value) {
52
- this.setPrimitiveAttribute("gap", value);
53
- }
54
- get align() {
55
- return this.getPrimitiveAttribute("align");
56
- }
57
- set align(value) {
58
- this.setPrimitiveAttribute("align", value);
59
- }
60
- get justify() {
61
- return this.getPrimitiveAttribute("justify");
62
- }
63
- set justify(value) {
64
- this.setPrimitiveAttribute("justify", value);
65
- }
66
- get wrap() {
67
- return this.getPrimitiveAttribute("wrap");
68
- }
69
- set wrap(value) {
70
- this.setPrimitiveAttribute("wrap", value);
71
- }
236
+
237
+ [data-component-root~="ui-stack"][data-gap="xs"] { --ui-layout-gap: var(--ui-space-2, 0.5rem); }
238
+ [data-component-root~="ui-stack"][data-gap="s"] { --ui-layout-gap: var(--ui-space-3, 0.75rem); }
239
+ [data-component-root~="ui-stack"][data-gap="m"] { --ui-layout-gap: var(--ui-space-4, 1rem); }
240
+ [data-component-root~="ui-stack"][data-gap="l"] { --ui-layout-gap: var(--ui-space-5, 1.5rem); }
241
+ [data-component-root~="ui-stack"][data-gap="xl"] { --ui-layout-gap: var(--ui-space-6, 2rem); }
242
+ [data-component-root~="ui-stack"][data-align="start"] { --ui-layout-align: flex-start; }
243
+ [data-component-root~="ui-stack"][data-align="center"] { --ui-layout-align: center; }
244
+ [data-component-root~="ui-stack"][data-align="end"] { --ui-layout-align: flex-end; }
245
+ [data-component-root~="ui-stack"][data-justify="center"] { --ui-layout-justify: center; }
246
+ [data-component-root~="ui-stack"][data-justify="end"] { --ui-layout-justify: flex-end; }
247
+ [data-component-root~="ui-stack"][data-justify="between"] { --ui-layout-justify: space-between; }
248
+
249
+ [data-component-root~="ui-inline"],
250
+ [data-component-root~="ui-cluster"] {
251
+ --ui-layout-gap: var(--ui-space-3, 0.75rem);
252
+ --ui-layout-align: center;
253
+ --ui-layout-justify: flex-start;
254
+ display: flex;
255
+ flex-wrap: wrap;
256
+ align-items: var(--ui-layout-align);
257
+ justify-content: var(--ui-layout-justify);
258
+ gap: var(--ui-layout-gap);
72
259
  }
73
- class UIClusterElement extends UILayoutElement {
74
- static get observedAttributes() {
75
- return ["gap", "align", "justify"];
76
- }
77
- get gap() {
78
- return this.getPrimitiveAttribute("gap");
79
- }
80
- set gap(value) {
81
- this.setPrimitiveAttribute("gap", value);
82
- }
83
- get align() {
84
- return this.getPrimitiveAttribute("align");
85
- }
86
- set align(value) {
87
- this.setPrimitiveAttribute("align", value);
88
- }
89
- get justify() {
90
- return this.getPrimitiveAttribute("justify");
91
- }
92
- set justify(value) {
93
- this.setPrimitiveAttribute("justify", value);
94
- }
260
+
261
+ [data-component-root~="ui-inline"][data-wrap="nowrap"] { flex-wrap: nowrap; }
262
+ [data-component-root~="ui-inline"][data-gap="xs"],
263
+ [data-component-root~="ui-cluster"][data-gap="xs"] { --ui-layout-gap: var(--ui-space-2, 0.5rem); }
264
+ [data-component-root~="ui-inline"][data-gap="s"],
265
+ [data-component-root~="ui-cluster"][data-gap="s"] { --ui-layout-gap: var(--ui-space-3, 0.75rem); }
266
+ [data-component-root~="ui-inline"][data-gap="m"],
267
+ [data-component-root~="ui-cluster"][data-gap="m"] { --ui-layout-gap: var(--ui-space-4, 1rem); }
268
+
269
+ [data-component-root~="ui-grid"] {
270
+ --ui-grid-gap: var(--ui-space-4, 1rem);
271
+ --ui-grid-min: 16rem;
272
+ display: grid;
273
+ gap: var(--ui-grid-gap);
274
+ grid-template-columns: repeat(auto-fit, minmax(min(var(--ui-grid-min), 100%), 1fr));
95
275
  }
96
- class UIGridElement extends UILayoutElement {
97
- static get observedAttributes() {
98
- return ["gap", "min"];
99
- }
100
- get gap() {
101
- return this.getPrimitiveAttribute("gap");
102
- }
103
- set gap(value) {
104
- this.setPrimitiveAttribute("gap", value);
105
- }
106
- get min() {
107
- return this.getPrimitiveAttribute("min");
108
- }
109
- set min(value) {
110
- this.setPrimitiveAttribute("min", value);
111
- }
276
+
277
+ [data-component-root~="ui-grid"][data-gap="xs"] { --ui-grid-gap: var(--ui-space-2, 0.5rem); }
278
+ [data-component-root~="ui-grid"][data-gap="s"] { --ui-grid-gap: var(--ui-space-3, 0.75rem); }
279
+ [data-component-root~="ui-grid"][data-gap="m"] { --ui-grid-gap: var(--ui-space-4, 1rem); }
280
+ [data-component-root~="ui-grid"][data-gap="l"] { --ui-grid-gap: var(--ui-space-5, 1.5rem); }
281
+ [data-component-root~="ui-grid"][data-min="sm"] { --ui-grid-min: 12rem; }
282
+ [data-component-root~="ui-grid"][data-min="md"] { --ui-grid-min: 16rem; }
283
+ [data-component-root~="ui-grid"][data-min="lg"] { --ui-grid-min: 20rem; }
284
+
285
+ [data-component-root~="ui-center"] {
286
+ --ui-center-measure: 65ch;
287
+ --ui-center-gutters: var(--ui-space-4, 1rem);
288
+ display: block;
289
+ inline-size: 100%;
290
+ max-inline-size: var(--ui-center-measure);
291
+ margin-inline: auto;
292
+ padding-inline: var(--ui-center-gutters);
112
293
  }
113
- class UICenterElement extends UILayoutElement {
114
- static get observedAttributes() {
115
- return ["measure", "gutters"];
116
- }
117
- get measure() {
118
- return this.getPrimitiveAttribute("measure");
119
- }
120
- set measure(value) {
121
- this.setPrimitiveAttribute("measure", value);
122
- }
123
- get gutters() {
124
- return this.getPrimitiveAttribute("gutters");
125
- }
126
- set gutters(value) {
127
- this.setPrimitiveAttribute("gutters", value);
128
- }
294
+
295
+ [data-component-root~="ui-center"][data-measure="narrow"] { --ui-center-measure: 45ch; }
296
+ [data-component-root~="ui-center"][data-measure="wide"] { --ui-center-measure: 80ch; }
297
+ [data-component-root~="ui-center"][data-gutters="s"] { --ui-center-gutters: var(--ui-space-3, 0.75rem); }
298
+ [data-component-root~="ui-center"][data-gutters="m"] { --ui-center-gutters: var(--ui-space-4, 1rem); }
299
+ [data-component-root~="ui-center"][data-gutters="l"] { --ui-center-gutters: var(--ui-space-5, 1.5rem); }
300
+
301
+ [data-component-root~="ui-switcher"] {
302
+ --ui-switcher-gap: var(--ui-space-4, 1rem);
303
+ --ui-switcher-threshold: 30rem;
304
+ --ui-switcher-align: stretch;
305
+ display: flex;
306
+ flex-wrap: wrap;
307
+ gap: var(--ui-switcher-gap);
308
+ align-items: var(--ui-switcher-align);
129
309
  }
130
- class UISwitcherElement extends UILayoutElement {
131
- static get observedAttributes() {
132
- return ["gap", "threshold", "align"];
133
- }
134
- get gap() {
135
- return this.getPrimitiveAttribute("gap");
136
- }
137
- set gap(value) {
138
- this.setPrimitiveAttribute("gap", value);
139
- }
140
- get threshold() {
141
- return this.getPrimitiveAttribute("threshold");
142
- }
143
- set threshold(value) {
144
- this.setPrimitiveAttribute("threshold", value);
145
- }
146
- get align() {
147
- return this.getPrimitiveAttribute("align");
148
- }
149
- set align(value) {
150
- this.setPrimitiveAttribute("align", value);
151
- }
310
+
311
+ [data-component-root~="ui-switcher"] > * {
312
+ min-inline-size: 0;
313
+ flex-grow: 1;
314
+ flex-basis: calc((var(--ui-switcher-threshold) - 100%) * 999);
152
315
  }
153
- class UISidebarElement extends UILayoutElement {
154
- static get observedAttributes() {
155
- return ["gap", "side", "width", "align", "resizable", "storage-key", "min-width", "max-width", "resize-step", "resize-label"];
156
- }
157
- resizeHandle = null;
158
- resizeAbort = null;
159
- pointerAbort = null;
160
- connectedCallback() {
161
- this.syncResizable();
162
- }
163
- disconnectedCallback() {
164
- this.resizeAbort?.abort();
165
- this.resizeAbort = null;
166
- this.pointerAbort?.abort();
167
- this.pointerAbort = null;
168
- }
169
- attributeChangedCallback(name) {
170
- if (["resizable", "storage-key", "min-width", "max-width", "resize-step", "resize-label", "side", "width"].includes(name)) {
171
- this.syncResizable();
172
- }
173
- }
174
- get gap() {
175
- return this.getPrimitiveAttribute("gap");
176
- }
177
- set gap(value) {
178
- this.setPrimitiveAttribute("gap", value);
179
- }
180
- get side() {
181
- return this.getPrimitiveAttribute("side");
182
- }
183
- set side(value) {
184
- this.setPrimitiveAttribute("side", value);
185
- }
186
- get width() {
187
- return this.getPrimitiveAttribute("width");
188
- }
189
- set width(value) {
190
- this.setPrimitiveAttribute("width", value);
191
- }
192
- get align() {
193
- return this.getPrimitiveAttribute("align");
194
- }
195
- set align(value) {
196
- this.setPrimitiveAttribute("align", value);
197
- }
198
- get resizable() {
199
- return this.hasAttribute("resizable");
200
- }
201
- set resizable(value) {
202
- this.toggleAttribute("resizable", value);
203
- }
204
- numericAttribute(name, fallback) {
205
- const parsed = Number(this.getAttribute(name));
206
- return Number.isFinite(parsed) && parsed > 0 ? parsed : fallback;
207
- }
208
- bounds() {
209
- const min = this.numericAttribute("min-width", 176);
210
- const max = Math.max(min, this.numericAttribute("max-width", 480));
211
- return { min, max, step: this.numericAttribute("resize-step", 16) };
212
- }
213
- defaultWidth() {
214
- if (this.width === "narrow") return 224;
215
- if (this.width === "wide") return 384;
216
- return 288;
217
- }
218
- storageId() {
219
- const key = this.getAttribute("storage-key")?.trim();
220
- return key ? `looma:sidebar-width:${key}` : null;
221
- }
222
- readStoredWidth() {
223
- const key = this.storageId();
224
- if (!key || typeof localStorage === "undefined") return null;
225
- try {
226
- const parsed = Number(localStorage.getItem(key));
227
- return Number.isFinite(parsed) && parsed > 0 ? parsed : null;
228
- } catch {
229
- return null;
230
- }
231
- }
232
- persistWidth(width) {
233
- const key = this.storageId();
234
- if (!key || typeof localStorage === "undefined") return;
235
- try {
236
- localStorage.setItem(key, String(width));
237
- } catch {
238
- }
239
- }
240
- currentWidth() {
241
- const inline = Number.parseFloat(this.style.getPropertyValue("--ui-sidebar-width"));
242
- if (Number.isFinite(inline)) return inline;
243
- const sideRegion = this.getAttribute("side") === "end" ? this.querySelector(":scope > :last-child:not([data-ui-sidebar-resizer])") : this.querySelector(":scope > :first-child:not([data-ui-sidebar-resizer])");
244
- return sideRegion?.getBoundingClientRect().width || this.defaultWidth();
245
- }
246
- setWidth(value, persist = false, trigger = "programmatic") {
247
- const { min, max } = this.bounds();
248
- const width = Math.round(Math.max(min, Math.min(max, value)));
249
- const previous = Number.parseFloat(this.style.getPropertyValue("--ui-sidebar-width"));
250
- const changed = !Number.isFinite(previous) || previous !== width;
251
- this.style.setProperty("--ui-sidebar-width", `${width}px`);
252
- this.resizeHandle?.setAttribute("aria-valuemin", String(min));
253
- this.resizeHandle?.setAttribute("aria-valuemax", String(max));
254
- this.resizeHandle?.setAttribute("aria-valuenow", String(width));
255
- if (persist && changed) this.persistWidth(width);
256
- if (changed) {
257
- this.dispatchEvent(new CustomEvent("resize", { detail: { width, trigger }, bubbles: true }));
258
- }
259
- }
260
- syncResizable() {
261
- if (!this.isConnected) return;
262
- if (!this.resizable) {
263
- this.resizeAbort?.abort();
264
- this.resizeAbort = null;
265
- this.pointerAbort?.abort();
266
- this.pointerAbort = null;
267
- this.resizeHandle?.remove();
268
- this.resizeHandle = null;
269
- return;
270
- }
271
- if (!this.resizeHandle) {
272
- this.resizeHandle = document.createElement("div");
273
- this.resizeHandle.setAttribute("data-ui-sidebar-resizer", "");
274
- this.resizeHandle.setAttribute("data-ui-affordance", "resize");
275
- this.resizeHandle.setAttribute("role", "separator");
276
- this.resizeHandle.setAttribute("aria-orientation", "vertical");
277
- this.resizeHandle.setAttribute("tabindex", "0");
278
- const guide = document.createElement("span");
279
- guide.setAttribute("data-ui-guide", "");
280
- guide.setAttribute("aria-hidden", "true");
281
- this.resizeHandle.append(guide);
282
- this.append(this.resizeHandle);
283
- }
284
- this.resizeHandle.setAttribute("aria-label", this.getAttribute("resize-label") || "Resize sidebar");
285
- this.resizeAbort?.abort();
286
- this.resizeAbort = new AbortController();
287
- const signal = this.resizeAbort.signal;
288
- this.resizeHandle.addEventListener("keydown", (event) => this.onResizeKey(event), { signal });
289
- this.resizeHandle.addEventListener("pointerdown", (event) => this.onResizePointer(event), { signal });
290
- this.resizeHandle.addEventListener("dblclick", () => this.setWidth(this.defaultWidth(), true, "pointer"), { signal });
291
- this.setWidth(this.readStoredWidth() ?? this.currentWidth());
292
- }
293
- onResizeKey(event) {
294
- const { min, max, step } = this.bounds();
295
- let next = null;
296
- if (event.key === "Home") next = min;
297
- if (event.key === "End") next = max;
298
- if (event.key === "ArrowLeft" || event.key === "ArrowRight") {
299
- const physicalDelta = event.key === "ArrowRight" ? step : -step;
300
- next = this.currentWidth() + (this.side === "end" ? -physicalDelta : physicalDelta);
301
- }
302
- if (next === null) return;
303
- event.preventDefault();
304
- this.setWidth(next, true, "keyboard");
305
- }
306
- onResizePointer(event) {
307
- if (event.button !== 0 || this.pointerAbort) return;
308
- event.preventDefault();
309
- const startX = event.clientX;
310
- const startWidth = this.currentWidth();
311
- const multiplier = this.side === "end" ? -1 : 1;
312
- const controller = new AbortController();
313
- this.pointerAbort = controller;
314
- const finish = () => {
315
- this.persistWidth(this.currentWidth());
316
- controller.abort();
317
- this.pointerAbort = null;
318
- };
319
- window.addEventListener("pointermove", (moveEvent) => {
320
- this.setWidth(startWidth + (moveEvent.clientX - startX) * multiplier, false, "pointer");
321
- }, { signal: controller.signal });
322
- window.addEventListener("pointerup", finish, { once: true, signal: controller.signal });
323
- window.addEventListener("pointercancel", finish, { once: true, signal: controller.signal });
324
- }
316
+
317
+ [data-component-root~="ui-switcher"][data-gap="xs"] { --ui-switcher-gap: var(--ui-space-2, 0.5rem); }
318
+ [data-component-root~="ui-switcher"][data-gap="s"] { --ui-switcher-gap: var(--ui-space-3, 0.75rem); }
319
+ [data-component-root~="ui-switcher"][data-gap="m"] { --ui-switcher-gap: var(--ui-space-4, 1rem); }
320
+ [data-component-root~="ui-switcher"][data-gap="l"] { --ui-switcher-gap: var(--ui-space-5, 1.5rem); }
321
+ [data-component-root~="ui-switcher"][data-threshold="xs"] { --ui-switcher-threshold: 20rem; }
322
+ [data-component-root~="ui-switcher"][data-threshold="sm"] { --ui-switcher-threshold: 30rem; }
323
+ [data-component-root~="ui-switcher"][data-threshold="md"] { --ui-switcher-threshold: 45rem; }
324
+ [data-component-root~="ui-switcher"][data-threshold="lg"] { --ui-switcher-threshold: 60rem; }
325
+ [data-component-root~="ui-switcher"][data-align="start"] { --ui-switcher-align: flex-start; }
326
+ [data-component-root~="ui-switcher"][data-align="center"] { --ui-switcher-align: center; }
327
+ [data-component-root~="ui-switcher"][data-align="end"] { --ui-switcher-align: flex-end; }
328
+
329
+ [data-component-root~="ui-sidebar"] {
330
+ --ui-sidebar-gap: var(--ui-space-4, 1rem);
331
+ --ui-sidebar-width: 18rem;
332
+ --ui-sidebar-content-min: 50%;
333
+ --ui-sidebar-align: stretch;
334
+ display: flex;
335
+ flex-wrap: wrap;
336
+ gap: var(--ui-sidebar-gap);
337
+ align-items: var(--ui-sidebar-align);
325
338
  }
326
- class UIReelElement extends UILayoutElement {
327
- static get observedAttributes() {
328
- return ["gap", "item-width", "snap"];
329
- }
330
- connectedCallback() {
331
- if (!this.hasAttribute("role")) this.setAttribute("role", "region");
332
- if (!this.hasAttribute("tabindex")) this.setAttribute("tabindex", "0");
333
- }
334
- get gap() {
335
- return this.getPrimitiveAttribute("gap");
336
- }
337
- set gap(value) {
338
- this.setPrimitiveAttribute("gap", value);
339
- }
340
- get itemWidth() {
341
- return this.getPrimitiveAttribute("item-width");
342
- }
343
- set itemWidth(value) {
344
- this.setPrimitiveAttribute("item-width", value);
345
- }
346
- get snap() {
347
- return this.getPrimitiveAttribute("snap");
348
- }
349
- set snap(value) {
350
- this.setPrimitiveAttribute("snap", value);
351
- }
339
+
340
+ [data-component-root~="ui-sidebar"] > :not([data-ui-sidebar-resizer]) { min-inline-size: 0; }
341
+ [data-component-root~="ui-sidebar"] > :first-child {
342
+ flex-basis: var(--ui-sidebar-width);
343
+ flex-grow: 1;
352
344
  }
353
- class UISeparatorElement extends UILayoutElement {
354
- static get observedAttributes() {
355
- return ["orientation", "role"];
356
- }
357
- connectedCallback() {
358
- this.ensureDefaults();
359
- }
360
- get orientation() {
361
- return normalizeOrientation(this.getAttribute("orientation"));
362
- }
363
- set orientation(value) {
364
- const normalizedValue = normalizeOrientation(value);
365
- this.setPrimitiveAttribute("orientation", normalizedValue);
366
- this.syncOrientationAria();
367
- }
368
- attributeChangedCallback(name) {
369
- if (name === "orientation" || name === "role") {
370
- this.syncOrientationAria();
371
- }
372
- }
373
- ensureDefaults() {
374
- if (!this.hasAttribute("role")) {
375
- this.setAttribute("role", "separator");
376
- }
377
- this.syncOrientationAria();
378
- }
379
- syncOrientationAria() {
380
- if (this.getAttribute("role") !== "separator") {
381
- this.removeAttribute("aria-orientation");
382
- return;
383
- }
384
- this.setAttribute("aria-orientation", this.orientation);
385
- }
345
+ [data-component-root~="ui-sidebar"] > :last-child:not([data-ui-sidebar-resizer]),
346
+ [data-component-root~="ui-sidebar"][data-resizable='true'] > :nth-last-child(2):not([data-ui-sidebar-resizer]) {
347
+ flex-basis: 0;
348
+ flex-grow: 999;
349
+ min-inline-size: min(var(--ui-sidebar-content-min), 100%);
386
350
  }
387
- const definitions = [
388
- ["ui-stack", UIStackElement],
389
- ["ui-inline", UIInlineElement],
390
- ["ui-cluster", UIClusterElement],
391
- ["ui-grid", UIGridElement],
392
- ["ui-center", UICenterElement],
393
- ["ui-switcher", UISwitcherElement],
394
- ["ui-sidebar", UISidebarElement],
395
- ["ui-reel", UIReelElement],
396
- ["ui-separator", UISeparatorElement]
397
- ];
398
- for (const [tag, constructor] of definitions) {
399
- if (!customElements.get(tag)) {
400
- customElements.define(tag, constructor);
401
- }
351
+ [data-component-root~="ui-sidebar"][data-side="end"] > :first-child {
352
+ flex-basis: 0;
353
+ flex-grow: 999;
354
+ min-inline-size: min(var(--ui-sidebar-content-min), 100%);
355
+ }
356
+ [data-component-root~="ui-sidebar"][data-side="end"] > :last-child:not([data-ui-sidebar-resizer]),
357
+ [data-component-root~="ui-sidebar"][data-side="end"][data-resizable='true'] > :nth-last-child(2):not([data-ui-sidebar-resizer]) {
358
+ flex-basis: var(--ui-sidebar-width);
359
+ flex-grow: 1;
360
+ min-inline-size: 0;
361
+ }
362
+ [data-component-root~="ui-sidebar"][data-gap="xs"] { --ui-sidebar-gap: var(--ui-space-2, 0.5rem); }
363
+ [data-component-root~="ui-sidebar"][data-gap="s"] { --ui-sidebar-gap: var(--ui-space-3, 0.75rem); }
364
+ [data-component-root~="ui-sidebar"][data-gap="m"] { --ui-sidebar-gap: var(--ui-space-4, 1rem); }
365
+ [data-component-root~="ui-sidebar"][data-gap="l"] { --ui-sidebar-gap: var(--ui-space-5, 1.5rem); }
366
+ [data-component-root~="ui-sidebar"][data-width="narrow"] { --ui-sidebar-width: 14rem; }
367
+ [data-component-root~="ui-sidebar"][data-width="wide"] { --ui-sidebar-width: 24rem; }
368
+ [data-component-root~="ui-sidebar"][data-align="start"] { --ui-sidebar-align: flex-start; }
369
+ [data-component-root~="ui-sidebar"][data-align="center"] { --ui-sidebar-align: center; }
370
+ [data-component-root~="ui-sidebar"][data-align="end"] { --ui-sidebar-align: flex-end; }
371
+ [data-component-root~="ui-sidebar"][data-resizable='true'] {
372
+ position: relative;
373
+ flex-wrap: nowrap;
374
+ }
375
+ [data-component-root~="ui-sidebar"][data-resizable='true'] > :first-child:not([data-ui-sidebar-resizer]) {
376
+ flex: 0 0 var(--ui-sidebar-width);
377
+ }
378
+ [data-component-root~="ui-sidebar"][data-side="end"][data-resizable='true'] > :first-child:not([data-ui-sidebar-resizer]) {
379
+ flex: 1 1 0;
380
+ }
381
+ [data-component-root~="ui-sidebar"][data-side="end"][data-resizable='true'] > :nth-last-child(2):not([data-ui-sidebar-resizer]) {
382
+ flex: 0 0 var(--ui-sidebar-width);
383
+ }
384
+ [data-component-root~="ui-sidebar"] > [data-ui-sidebar-resizer] {
385
+ position: absolute;
386
+ z-index: 1;
387
+ inset-block: 0;
388
+ inset-inline-start: var(--ui-sidebar-width);
389
+ inline-size: 8px;
390
+ min-inline-size: 8px;
391
+ transform: translateX(-50%);
392
+ cursor: col-resize;
393
+ touch-action: none;
394
+ outline: none;
395
+ }
396
+ [data-component-root~="ui-sidebar"][data-side="end"] > [data-ui-sidebar-resizer] {
397
+ inset-inline-start: auto;
398
+ inset-inline-end: var(--ui-sidebar-width);
399
+ transform: translateX(50%);
400
+ }
401
+ [data-component-root~="ui-sidebar"] > [data-ui-sidebar-resizer]::after {
402
+ content: "";
403
+ position: absolute;
404
+ inset-block: 0;
405
+ inset-inline-start: 3px;
406
+ inline-size: 2px;
407
+ background: color-mix(in srgb, var(--ui-affordance-guide-color, var(--ui-border-strong)) 45%, transparent);
408
+ opacity: var(--ui-affordance-guide-opacity, 0.42);
409
+ transition:
410
+ background-color var(--ui-affordance-motion, var(--ui-motion-fast, 120ms)) var(--ui-motion-ease, ease),
411
+ opacity var(--ui-affordance-motion, var(--ui-motion-fast, 120ms)) var(--ui-motion-ease, ease);
412
+ }
413
+ [data-component-root~="ui-sidebar"] > [data-ui-sidebar-resizer] > [data-ui-guide] {
414
+ position: absolute;
415
+ inset-block-start: 50%;
416
+ inset-inline-start: 50%;
417
+ inline-size: 6px;
418
+ block-size: 22px;
419
+ border: 1px solid var(--ui-border-strong, #c8c8c4);
420
+ border-radius: var(--ui-radius-round, 999px);
421
+ background: var(--ui-surface-elevated, #fff);
422
+ opacity: 0;
423
+ transform: translate(-50%, -50%);
424
+ transition: opacity var(--ui-affordance-motion, var(--ui-motion-fast, 120ms)) var(--ui-motion-ease, ease);
425
+ pointer-events: none;
426
+ }
427
+ [data-component-root~="ui-sidebar"] > [data-ui-sidebar-resizer]:hover::after,
428
+ [data-component-root~="ui-sidebar"] > [data-ui-sidebar-resizer]:focus-visible::after {
429
+ background: var(--ui-affordance-direct-color, var(--ui-accent-solid, var(--ui-color-focus, Highlight)));
430
+ opacity: 1;
431
+ }
432
+ [data-component-root~="ui-sidebar"] > [data-ui-sidebar-resizer]:is(:hover, :focus-visible) > [data-ui-guide] {
433
+ opacity: 1;
434
+ }
435
+
436
+ [data-component-root~="ui-reel"] {
437
+ --ui-reel-gap: var(--ui-space-4, 1rem);
438
+ --ui-reel-item-width: auto;
439
+ display: flex;
440
+ inline-size: 100%;
441
+ gap: var(--ui-reel-gap);
442
+ overflow-x: auto;
443
+ overflow-y: hidden;
444
+ overscroll-behavior-inline: contain;
445
+ -webkit-overflow-scrolling: touch;
446
+ }
447
+
448
+ [data-component-root~="ui-reel"] > * {
449
+ min-inline-size: 0;
450
+ flex: 0 0 var(--ui-reel-item-width);
451
+ }
452
+ [data-component-root~="ui-reel"][data-gap="xs"] { --ui-reel-gap: var(--ui-space-2, 0.5rem); }
453
+ [data-component-root~="ui-reel"][data-gap="s"] { --ui-reel-gap: var(--ui-space-3, 0.75rem); }
454
+ [data-component-root~="ui-reel"][data-gap="m"] { --ui-reel-gap: var(--ui-space-4, 1rem); }
455
+ [data-component-root~="ui-reel"][data-gap="l"] { --ui-reel-gap: var(--ui-space-5, 1.5rem); }
456
+ [data-component-root~="ui-reel"][data-item-width="sm"] { --ui-reel-item-width: 12rem; }
457
+ [data-component-root~="ui-reel"][data-item-width="md"] { --ui-reel-item-width: 16rem; }
458
+ [data-component-root~="ui-reel"][data-item-width="lg"] { --ui-reel-item-width: 20rem; }
459
+ [data-component-root~="ui-reel"][data-snap="start"],
460
+ [data-component-root~="ui-reel"][data-snap="center"] { scroll-snap-type: inline mandatory; }
461
+ [data-component-root~="ui-reel"][data-snap="start"] > * { scroll-snap-align: start; }
462
+ [data-component-root~="ui-reel"][data-snap="center"] > * { scroll-snap-align: center; }
463
+
464
+ [data-component-root~="ui-separator"] {
465
+ --ui-separator-color: var(--ui-border-default, #d0d5dd);
466
+ --ui-separator-space: var(--ui-space-4, 1rem);
467
+ display: block;
468
+ margin: 0;
469
+ border: 0;
470
+ border-block-start: 1px solid var(--ui-separator-color);
471
+ padding: 0;
472
+ }
473
+
474
+ [data-component-root~="ui-separator"][data-orientation="vertical"] {
475
+ inline-size: 1px;
476
+ block-size: 100%;
477
+ border-block-start: 0;
478
+ border-inline-start: 1px solid var(--ui-separator-color);
402
479
  }
403
480
  }
404
- function registerLayoutPrimitives() {
405
- }
406
- export {
407
- registerLayoutPrimitives
408
- };
481
+ `;
482
+
483
+ // src/declarative-index.ts
484
+ registerLoomaPackage("layout", records, styles);