@threadlabs/looma 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (318) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +21 -0
  3. package/dist/chunk-G53JEAQK.js +94 -0
  4. package/dist/chunk-OF57X5AR.js +10 -0
  5. package/dist/chunk-UL7UIUJZ.js +20 -0
  6. package/dist/chunk-YK4MTZGJ.js +1580 -0
  7. package/dist/cjs/app-globals-V2Kpy_OQ.js +5 -0
  8. package/dist/cjs/events-TcQIzpNv.js +19 -0
  9. package/dist/cjs/id-CYbKpaYr.js +9 -0
  10. package/dist/cjs/index-D07f6BOw.js +1569 -0
  11. package/dist/cjs/index.cjs.js +2 -0
  12. package/dist/cjs/loader.cjs.js +13 -0
  13. package/dist/cjs/looma.cjs.js +25 -0
  14. package/dist/cjs/manager-BOpVXb92.js +93 -0
  15. package/dist/cjs/ui-avatar-group.cjs.entry.js +51 -0
  16. package/dist/cjs/ui-avatar.cjs.entry.js +50 -0
  17. package/dist/cjs/ui-badge.cjs.entry.js +19 -0
  18. package/dist/cjs/ui-button.cjs.entry.js +62 -0
  19. package/dist/cjs/ui-checkbox.cjs.entry.js +91 -0
  20. package/dist/cjs/ui-context-menu.cjs.entry.js +201 -0
  21. package/dist/cjs/ui-dialog.cjs.entry.js +93 -0
  22. package/dist/cjs/ui-disclosure.cjs.entry.js +109 -0
  23. package/dist/cjs/ui-floating-action-button.cjs.entry.js +20 -0
  24. package/dist/cjs/ui-form-field.cjs.entry.js +59 -0
  25. package/dist/cjs/ui-icon-button.cjs.entry.js +21 -0
  26. package/dist/cjs/ui-input.cjs.entry.js +101 -0
  27. package/dist/cjs/ui-menu-item.cjs.entry.js +19 -0
  28. package/dist/cjs/ui-menu.cjs.entry.js +96 -0
  29. package/dist/cjs/ui-popover.cjs.entry.js +92 -0
  30. package/dist/cjs/ui-radio-group.cjs.entry.js +134 -0
  31. package/dist/cjs/ui-radio.cjs.entry.js +85 -0
  32. package/dist/cjs/ui-search-result-row.cjs.entry.js +47 -0
  33. package/dist/cjs/ui-search-shell.cjs.entry.js +39 -0
  34. package/dist/cjs/ui-select.cjs.entry.js +100 -0
  35. package/dist/cjs/ui-switch.cjs.entry.js +65 -0
  36. package/dist/cjs/ui-tabs.cjs.entry.js +117 -0
  37. package/dist/cjs/ui-textarea.cjs.entry.js +106 -0
  38. package/dist/cjs/ui-toast-region.cjs.entry.js +67 -0
  39. package/dist/cjs/ui-tooltip.cjs.entry.js +133 -0
  40. package/dist/cjs/ui-top-bar.cjs.entry.js +43 -0
  41. package/dist/collection/collection-manifest.json +38 -0
  42. package/dist/collection/components/ui-avatar/ui-avatar.css +35 -0
  43. package/dist/collection/components/ui-avatar/ui-avatar.js +130 -0
  44. package/dist/collection/components/ui-avatar-group/ui-avatar-group.css +32 -0
  45. package/dist/collection/components/ui-avatar-group/ui-avatar-group.js +103 -0
  46. package/dist/collection/components/ui-badge/ui-badge.css +74 -0
  47. package/dist/collection/components/ui-badge/ui-badge.js +62 -0
  48. package/dist/collection/components/ui-button/ui-button.css +101 -0
  49. package/dist/collection/components/ui-button/ui-button.js +127 -0
  50. package/dist/collection/components/ui-checkbox/ui-checkbox.css +24 -0
  51. package/dist/collection/components/ui-checkbox/ui-checkbox.js +223 -0
  52. package/dist/collection/components/ui-context-menu/ui-context-menu.css +17 -0
  53. package/dist/collection/components/ui-context-menu/ui-context-menu.js +272 -0
  54. package/dist/collection/components/ui-dialog/ui-dialog.css +65 -0
  55. package/dist/collection/components/ui-dialog/ui-dialog.js +185 -0
  56. package/dist/collection/components/ui-disclosure/ui-disclosure.css +7 -0
  57. package/dist/collection/components/ui-disclosure/ui-disclosure.js +182 -0
  58. package/dist/collection/components/ui-floating-action-button/ui-floating-action-button.css +70 -0
  59. package/dist/collection/components/ui-floating-action-button/ui-floating-action-button.js +85 -0
  60. package/dist/collection/components/ui-form-field/ui-form-field.css +21 -0
  61. package/dist/collection/components/ui-form-field/ui-form-field.js +125 -0
  62. package/dist/collection/components/ui-icon-button/ui-icon-button.css +92 -0
  63. package/dist/collection/components/ui-icon-button/ui-icon-button.js +106 -0
  64. package/dist/collection/components/ui-input/ui-input.css +46 -0
  65. package/dist/collection/components/ui-input/ui-input.js +213 -0
  66. package/dist/collection/components/ui-menu/ui-menu.css +37 -0
  67. package/dist/collection/components/ui-menu/ui-menu.js +149 -0
  68. package/dist/collection/components/ui-menu-item/ui-menu-item.css +26 -0
  69. package/dist/collection/components/ui-menu-item/ui-menu-item.js +64 -0
  70. package/dist/collection/components/ui-popover/ui-popover.css +8 -0
  71. package/dist/collection/components/ui-popover/ui-popover.js +144 -0
  72. package/dist/collection/components/ui-radio/ui-radio.css +22 -0
  73. package/dist/collection/components/ui-radio/ui-radio.js +213 -0
  74. package/dist/collection/components/ui-radio-group/ui-radio-group.css +10 -0
  75. package/dist/collection/components/ui-radio-group/ui-radio-group.js +247 -0
  76. package/dist/collection/components/ui-search-result-row/ui-search-result-row.css +80 -0
  77. package/dist/collection/components/ui-search-result-row/ui-search-result-row.js +100 -0
  78. package/dist/collection/components/ui-search-shell/ui-search-shell.css +61 -0
  79. package/dist/collection/components/ui-search-shell/ui-search-shell.js +46 -0
  80. package/dist/collection/components/ui-select/ui-select.css +62 -0
  81. package/dist/collection/components/ui-select/ui-select.js +212 -0
  82. package/dist/collection/components/ui-switch/ui-switch.css +63 -0
  83. package/dist/collection/components/ui-switch/ui-switch.js +177 -0
  84. package/dist/collection/components/ui-tabs/ui-tabs.css +65 -0
  85. package/dist/collection/components/ui-tabs/ui-tabs.js +190 -0
  86. package/dist/collection/components/ui-textarea/ui-textarea.css +48 -0
  87. package/dist/collection/components/ui-textarea/ui-textarea.js +238 -0
  88. package/dist/collection/components/ui-toast-region/ui-toast-region.css +52 -0
  89. package/dist/collection/components/ui-toast-region/ui-toast-region.js +100 -0
  90. package/dist/collection/components/ui-tooltip/ui-tooltip.css +14 -0
  91. package/dist/collection/components/ui-tooltip/ui-tooltip.js +205 -0
  92. package/dist/collection/components/ui-top-bar/ui-top-bar.css +43 -0
  93. package/dist/collection/components/ui-top-bar/ui-top-bar.js +52 -0
  94. package/dist/collection/overlay/manager.js +90 -0
  95. package/dist/collection/utils/events.js +13 -0
  96. package/dist/collection/utils/id.js +5 -0
  97. package/dist/collection/utils/initials.js +11 -0
  98. package/dist/components/index.d.ts +88 -0
  99. package/dist/components/index.js +1 -0
  100. package/dist/components/p-CIA4RyEp.js +1 -0
  101. package/dist/components/p-CR7f2MQC.js +1 -0
  102. package/dist/components/p-JwSoedEO.js +1 -0
  103. package/dist/components/p-WvL4iAhX.js +1 -0
  104. package/dist/components/p-hgBUJRDa.js +1 -0
  105. package/dist/components/ui-avatar-group.d.ts +11 -0
  106. package/dist/components/ui-avatar-group.js +1 -0
  107. package/dist/components/ui-avatar.d.ts +11 -0
  108. package/dist/components/ui-avatar.js +1 -0
  109. package/dist/components/ui-badge.d.ts +11 -0
  110. package/dist/components/ui-badge.js +1 -0
  111. package/dist/components/ui-button.d.ts +11 -0
  112. package/dist/components/ui-button.js +1 -0
  113. package/dist/components/ui-checkbox.d.ts +11 -0
  114. package/dist/components/ui-checkbox.js +1 -0
  115. package/dist/components/ui-context-menu.d.ts +11 -0
  116. package/dist/components/ui-context-menu.js +1 -0
  117. package/dist/components/ui-dialog.d.ts +11 -0
  118. package/dist/components/ui-dialog.js +1 -0
  119. package/dist/components/ui-disclosure.d.ts +11 -0
  120. package/dist/components/ui-disclosure.js +1 -0
  121. package/dist/components/ui-floating-action-button.d.ts +11 -0
  122. package/dist/components/ui-floating-action-button.js +1 -0
  123. package/dist/components/ui-form-field.d.ts +11 -0
  124. package/dist/components/ui-form-field.js +1 -0
  125. package/dist/components/ui-icon-button.d.ts +11 -0
  126. package/dist/components/ui-icon-button.js +1 -0
  127. package/dist/components/ui-input.d.ts +11 -0
  128. package/dist/components/ui-input.js +1 -0
  129. package/dist/components/ui-menu-item.d.ts +11 -0
  130. package/dist/components/ui-menu-item.js +1 -0
  131. package/dist/components/ui-menu.d.ts +11 -0
  132. package/dist/components/ui-menu.js +1 -0
  133. package/dist/components/ui-popover.d.ts +11 -0
  134. package/dist/components/ui-popover.js +1 -0
  135. package/dist/components/ui-radio-group.d.ts +11 -0
  136. package/dist/components/ui-radio-group.js +1 -0
  137. package/dist/components/ui-radio.d.ts +11 -0
  138. package/dist/components/ui-radio.js +1 -0
  139. package/dist/components/ui-search-result-row.d.ts +11 -0
  140. package/dist/components/ui-search-result-row.js +1 -0
  141. package/dist/components/ui-search-shell.d.ts +11 -0
  142. package/dist/components/ui-search-shell.js +1 -0
  143. package/dist/components/ui-select.d.ts +11 -0
  144. package/dist/components/ui-select.js +1 -0
  145. package/dist/components/ui-switch.d.ts +11 -0
  146. package/dist/components/ui-switch.js +1 -0
  147. package/dist/components/ui-tabs.d.ts +11 -0
  148. package/dist/components/ui-tabs.js +1 -0
  149. package/dist/components/ui-textarea.d.ts +11 -0
  150. package/dist/components/ui-textarea.js +1 -0
  151. package/dist/components/ui-toast-region.d.ts +11 -0
  152. package/dist/components/ui-toast-region.js +1 -0
  153. package/dist/components/ui-tooltip.d.ts +11 -0
  154. package/dist/components/ui-tooltip.js +1 -0
  155. package/dist/components/ui-top-bar.d.ts +11 -0
  156. package/dist/components/ui-top-bar.js +1 -0
  157. package/dist/esm/app-globals-DQuL1Twl.js +3 -0
  158. package/dist/esm/events-JwSoedEO.js +15 -0
  159. package/dist/esm/id-hgBUJRDa.js +7 -0
  160. package/dist/esm/index-CEeiinfk.js +1561 -0
  161. package/dist/esm/index.js +1 -0
  162. package/dist/esm/loader.js +11 -0
  163. package/dist/esm/looma.js +21 -0
  164. package/dist/esm/manager-CR7f2MQC.js +89 -0
  165. package/dist/esm/ui-avatar-group.entry.js +49 -0
  166. package/dist/esm/ui-avatar.entry.js +48 -0
  167. package/dist/esm/ui-badge.entry.js +17 -0
  168. package/dist/esm/ui-button.entry.js +60 -0
  169. package/dist/esm/ui-checkbox.entry.js +89 -0
  170. package/dist/esm/ui-context-menu.entry.js +199 -0
  171. package/dist/esm/ui-dialog.entry.js +91 -0
  172. package/dist/esm/ui-disclosure.entry.js +107 -0
  173. package/dist/esm/ui-floating-action-button.entry.js +18 -0
  174. package/dist/esm/ui-form-field.entry.js +57 -0
  175. package/dist/esm/ui-icon-button.entry.js +19 -0
  176. package/dist/esm/ui-input.entry.js +99 -0
  177. package/dist/esm/ui-menu-item.entry.js +17 -0
  178. package/dist/esm/ui-menu.entry.js +94 -0
  179. package/dist/esm/ui-popover.entry.js +90 -0
  180. package/dist/esm/ui-radio-group.entry.js +132 -0
  181. package/dist/esm/ui-radio.entry.js +83 -0
  182. package/dist/esm/ui-search-result-row.entry.js +45 -0
  183. package/dist/esm/ui-search-shell.entry.js +37 -0
  184. package/dist/esm/ui-select.entry.js +98 -0
  185. package/dist/esm/ui-switch.entry.js +63 -0
  186. package/dist/esm/ui-tabs.entry.js +115 -0
  187. package/dist/esm/ui-textarea.entry.js +104 -0
  188. package/dist/esm/ui-toast-region.entry.js +65 -0
  189. package/dist/esm/ui-tooltip.entry.js +131 -0
  190. package/dist/esm/ui-top-bar.entry.js +41 -0
  191. package/dist/index.cjs +4062 -0
  192. package/dist/index.cjs.js +1 -0
  193. package/dist/index.d.cts +16 -0
  194. package/dist/index.d.ts +16 -0
  195. package/dist/index.js +129 -0
  196. package/dist/looma/index.esm.js +0 -0
  197. package/dist/looma/looma.esm.js +1 -0
  198. package/dist/looma/p-03f0594b.entry.js +1 -0
  199. package/dist/looma/p-15e619fd.entry.js +1 -0
  200. package/dist/looma/p-201243dc.entry.js +1 -0
  201. package/dist/looma/p-24d7aa5b.entry.js +1 -0
  202. package/dist/looma/p-341ba64a.entry.js +1 -0
  203. package/dist/looma/p-41d62a83.entry.js +1 -0
  204. package/dist/looma/p-4742e6b4.entry.js +1 -0
  205. package/dist/looma/p-4c54d489.entry.js +1 -0
  206. package/dist/looma/p-52c537fa.entry.js +1 -0
  207. package/dist/looma/p-5a645647.entry.js +1 -0
  208. package/dist/looma/p-610b2eca.entry.js +1 -0
  209. package/dist/looma/p-649dad92.entry.js +1 -0
  210. package/dist/looma/p-66a203a1.entry.js +1 -0
  211. package/dist/looma/p-754cfff3.entry.js +1 -0
  212. package/dist/looma/p-93ce1c62.entry.js +1 -0
  213. package/dist/looma/p-955fb814.entry.js +1 -0
  214. package/dist/looma/p-96de71ad.entry.js +1 -0
  215. package/dist/looma/p-CEeiinfk.js +2 -0
  216. package/dist/looma/p-CR7f2MQC.js +1 -0
  217. package/dist/looma/p-DQuL1Twl.js +1 -0
  218. package/dist/looma/p-JwSoedEO.js +1 -0
  219. package/dist/looma/p-ab4151d5.entry.js +1 -0
  220. package/dist/looma/p-c14233bc.entry.js +1 -0
  221. package/dist/looma/p-dc857ed4.entry.js +1 -0
  222. package/dist/looma/p-dfcb2cca.entry.js +1 -0
  223. package/dist/looma/p-dff144bd.entry.js +1 -0
  224. package/dist/looma/p-ebb74106.entry.js +1 -0
  225. package/dist/looma/p-ecb5739b.entry.js +1 -0
  226. package/dist/looma/p-ee31c7b4.entry.js +1 -0
  227. package/dist/looma/p-fa4659c4.entry.js +1 -0
  228. package/dist/looma/p-hgBUJRDa.js +1 -0
  229. package/dist/types/components/ui-avatar/ui-avatar.d.ts +11 -0
  230. package/dist/types/components/ui-avatar-group/ui-avatar-group.d.ts +12 -0
  231. package/dist/types/components/ui-badge/ui-badge.d.ts +5 -0
  232. package/dist/types/components/ui-button/ui-button.d.ts +13 -0
  233. package/dist/types/components/ui-checkbox/ui-checkbox.d.ts +19 -0
  234. package/dist/types/components/ui-context-menu/ui-context-menu.d.ts +37 -0
  235. package/dist/types/components/ui-dialog/ui-dialog.d.ts +19 -0
  236. package/dist/types/components/ui-disclosure/ui-disclosure.d.ts +20 -0
  237. package/dist/types/components/ui-floating-action-button/ui-floating-action-button.d.ts +6 -0
  238. package/dist/types/components/ui-form-field/ui-form-field.d.ts +10 -0
  239. package/dist/types/components/ui-icon-button/ui-icon-button.d.ts +7 -0
  240. package/dist/types/components/ui-input/ui-input.d.ts +19 -0
  241. package/dist/types/components/ui-menu/ui-menu.d.ts +14 -0
  242. package/dist/types/components/ui-menu-item/ui-menu-item.d.ts +5 -0
  243. package/dist/types/components/ui-popover/ui-popover.d.ts +16 -0
  244. package/dist/types/components/ui-radio/ui-radio.d.ts +17 -0
  245. package/dist/types/components/ui-radio-group/ui-radio-group.d.ts +21 -0
  246. package/dist/types/components/ui-search-result-row/ui-search-result-row.d.ts +15 -0
  247. package/dist/types/components/ui-search-shell/ui-search-shell.d.ts +9 -0
  248. package/dist/types/components/ui-select/ui-select.d.ts +19 -0
  249. package/dist/types/components/ui-switch/ui-switch.d.ts +15 -0
  250. package/dist/types/components/ui-tabs/ui-tabs.d.ts +17 -0
  251. package/dist/types/components/ui-textarea/ui-textarea.d.ts +20 -0
  252. package/dist/types/components/ui-toast-region/ui-toast-region.d.ts +12 -0
  253. package/dist/types/components/ui-tooltip/ui-tooltip.d.ts +24 -0
  254. package/dist/types/components/ui-top-bar/ui-top-bar.d.ts +12 -0
  255. package/dist/types/components.d.ts +1148 -0
  256. package/dist/types/overlay/manager.d.ts +14 -0
  257. package/dist/types/stencil-public-runtime.d.ts +1860 -0
  258. package/dist/types/utils/events.d.ts +4 -0
  259. package/dist/types/utils/id.d.ts +1 -0
  260. package/dist/types/utils/initials.d.ts +1 -0
  261. package/dist/ui-avatar-group.entry-BZGXBOSE.js +59 -0
  262. package/dist/ui-avatar.entry-S2O2W5SA.js +51 -0
  263. package/dist/ui-badge.entry-CVJDISCR.js +22 -0
  264. package/dist/ui-button.entry-LNJBEJFE.js +72 -0
  265. package/dist/ui-checkbox.entry-5RA2CB43.js +102 -0
  266. package/dist/ui-context-menu.entry-UUOCT75F.js +211 -0
  267. package/dist/ui-dialog.entry-OEPJTEES.js +106 -0
  268. package/dist/ui-disclosure.entry-LRRISGUD.js +120 -0
  269. package/dist/ui-floating-action-button.entry-7TSAZRXP.js +23 -0
  270. package/dist/ui-form-field.entry-73YOVICF.js +67 -0
  271. package/dist/ui-icon-button.entry-MNXGPG36.js +24 -0
  272. package/dist/ui-input.entry-UWRVAOSW.js +112 -0
  273. package/dist/ui-menu-item.entry-5AOJO5MP.js +22 -0
  274. package/dist/ui-menu.entry-YDS6UMB5.js +98 -0
  275. package/dist/ui-popover.entry-PGWDCQIX.js +104 -0
  276. package/dist/ui-radio-group.entry-RHP5GNWU.js +142 -0
  277. package/dist/ui-radio.entry-5WRWPSTK.js +96 -0
  278. package/dist/ui-search-result-row.entry-IKJB2SJJ.js +50 -0
  279. package/dist/ui-search-shell.entry-ZIWF4ZHH.js +41 -0
  280. package/dist/ui-select.entry-N5TIKHR7.js +111 -0
  281. package/dist/ui-switch.entry-WUSZTXIR.js +75 -0
  282. package/dist/ui-tabs.entry-UFAVAQIF.js +124 -0
  283. package/dist/ui-textarea.entry-BYT47RAQ.js +117 -0
  284. package/dist/ui-toast-region.entry-6UYR3ZU2.js +78 -0
  285. package/dist/ui-tooltip.entry-YS7UX4FS.js +145 -0
  286. package/dist/ui-top-bar.entry-V27H6NFO.js +49 -0
  287. package/editor/chunk-JKRA4D4W.js +435 -0
  288. package/editor/chunk-NOOV344H.js +783 -0
  289. package/editor/extensions/index.d.ts +78 -0
  290. package/editor/extensions/index.js +28 -0
  291. package/editor/index.d.ts +7 -0
  292. package/editor/index.js +29 -0
  293. package/editor/table-overlay-DTr3KC9e.d.ts +12 -0
  294. package/editor/ui.d.ts +48 -0
  295. package/editor/ui.js +1 -0
  296. package/editor.css +662 -0
  297. package/layout/index.cjs +207 -0
  298. package/layout/index.css +166 -0
  299. package/layout/index.d.cts +3 -0
  300. package/layout/index.d.ts +3 -0
  301. package/layout/index.js +182 -0
  302. package/layout.css +124 -0
  303. package/loader/cdn.js +1 -0
  304. package/loader/index.cjs.js +1 -0
  305. package/loader/index.d.ts +24 -0
  306. package/loader/index.es2017.js +1 -0
  307. package/loader/index.js +2 -0
  308. package/package.json +244 -0
  309. package/styles.css +899 -0
  310. package/theme-dark.css +59 -0
  311. package/theme-high-contrast.css +21 -0
  312. package/theme-light.css +30 -0
  313. package/tokens.css +148 -0
  314. package/vue/chunk-J4UBEIIL.js +83 -0
  315. package/vue/editor/index.d.ts +89 -0
  316. package/vue/editor/index.js +125 -0
  317. package/vue/index.d.ts +167 -0
  318. package/vue/index.js +113 -0
@@ -0,0 +1,92 @@
1
+ :host {
2
+ display: inline-flex;
3
+ color: var(--ui-text-secondary);
4
+ }
5
+
6
+ button {
7
+ appearance: none;
8
+ inline-size: var(--ui-icon-button-size, 2.5rem);
9
+ block-size: var(--ui-icon-button-size, 2.5rem);
10
+ min-inline-size: var(--ui-icon-button-size, 2.5rem);
11
+ min-block-size: var(--ui-icon-button-size, 2.5rem);
12
+ padding: 0;
13
+ margin: 0;
14
+ border: 1px solid transparent;
15
+ border-radius: var(--ui-icon-button-radius, var(--ui-radius-2));
16
+ background: var(--ui-icon-button-bg, transparent);
17
+ color: inherit;
18
+ display: inline-flex;
19
+ align-items: center;
20
+ justify-content: center;
21
+ cursor: pointer;
22
+ transition:
23
+ background-color var(--ui-motion-fast) var(--ui-motion-ease),
24
+ border-color var(--ui-motion-fast) var(--ui-motion-ease),
25
+ color var(--ui-motion-fast) var(--ui-motion-ease),
26
+ box-shadow var(--ui-motion-fast) var(--ui-motion-ease),
27
+ transform var(--ui-motion-fast) var(--ui-motion-ease);
28
+ }
29
+
30
+ :host([size='sm']) button {
31
+ inline-size: var(--ui-icon-button-size-sm, 2rem);
32
+ block-size: var(--ui-icon-button-size-sm, 2rem);
33
+ min-inline-size: var(--ui-icon-button-size-sm, 2rem);
34
+ min-block-size: var(--ui-icon-button-size-sm, 2rem);
35
+ }
36
+
37
+ :host([size='lg']) button {
38
+ inline-size: var(--ui-icon-button-size-lg, 2.75rem);
39
+ block-size: var(--ui-icon-button-size-lg, 2.75rem);
40
+ min-inline-size: var(--ui-icon-button-size-lg, 2.75rem);
41
+ min-block-size: var(--ui-icon-button-size-lg, 2.75rem);
42
+ }
43
+
44
+ :host([variant='outline']) button {
45
+ border-color: var(--ui-icon-button-border, var(--ui-border-default));
46
+ background: var(--ui-icon-button-outline-bg, var(--ui-surface-default));
47
+ color: var(--ui-icon-button-outline-color, var(--ui-text-primary));
48
+ }
49
+
50
+ :host([variant='solid']) button {
51
+ background: var(--ui-icon-button-solid-bg, var(--ui-accent-solid));
52
+ color: var(--ui-icon-button-solid-color, var(--ui-text-on-accent));
53
+ box-shadow: var(
54
+ --ui-icon-button-solid-shadow,
55
+ 0 1px 2px color-mix(in srgb, var(--ui-accent-solid) 18%, transparent)
56
+ );
57
+ }
58
+
59
+ button:hover:enabled {
60
+ background: var(--ui-icon-button-hover-bg, var(--ui-surface-muted));
61
+ color: var(--ui-icon-button-hover-color, var(--ui-text-primary));
62
+ }
63
+
64
+ :host([variant='outline']) button:hover:enabled {
65
+ border-color: var(--ui-icon-button-hover-border, var(--ui-border-strong));
66
+ }
67
+
68
+ :host([variant='solid']) button:hover:enabled {
69
+ background: var(--ui-icon-button-solid-hover-bg, var(--ui-accent-hover));
70
+ }
71
+
72
+ button:active:enabled {
73
+ transform: scale(var(--ui-icon-button-active-scale, 0.96));
74
+ }
75
+
76
+ button:focus-visible {
77
+ outline: 2px solid var(--ui-focus-ring);
78
+ outline-offset: 2px;
79
+ }
80
+
81
+ button:disabled,
82
+ :host([disabled]) {
83
+ opacity: 0.6;
84
+ cursor: not-allowed;
85
+ }
86
+
87
+ ::slotted(svg) {
88
+ inline-size: var(--ui-icon-button-icon-size, 1.125rem);
89
+ block-size: var(--ui-icon-button-icon-size, 1.125rem);
90
+ flex-shrink: 0;
91
+ stroke-width: var(--ui-icon-button-icon-stroke-width, 1.75);
92
+ }
@@ -0,0 +1,106 @@
1
+ import { Host, h } from "@stencil/core";
2
+ export class UIIconButton {
3
+ disabled = false;
4
+ label = '';
5
+ size = 'md';
6
+ variant = 'ghost';
7
+ render() {
8
+ return (h(Host, { key: '8f4c7271505fa061da954f1e989fc526dc980407', "data-disabled": this.disabled ? '' : undefined }, h("button", { key: 'c56009d4028a557cd6f7f19833b0af6412b90c1c', type: "button", "aria-label": this.label || undefined, disabled: this.disabled }, h("slot", { key: 'ac2f201b0fbedb23106f72135ff8c3b6f25fca60' }))));
9
+ }
10
+ static get is() { return "ui-icon-button"; }
11
+ static get encapsulation() { return "shadow"; }
12
+ static get originalStyleUrls() {
13
+ return {
14
+ "$": ["ui-icon-button.css"]
15
+ };
16
+ }
17
+ static get styleUrls() {
18
+ return {
19
+ "$": ["ui-icon-button.css"]
20
+ };
21
+ }
22
+ static get properties() {
23
+ return {
24
+ "disabled": {
25
+ "type": "boolean",
26
+ "mutable": false,
27
+ "complexType": {
28
+ "original": "boolean",
29
+ "resolved": "boolean",
30
+ "references": {}
31
+ },
32
+ "required": false,
33
+ "optional": false,
34
+ "docs": {
35
+ "tags": [],
36
+ "text": ""
37
+ },
38
+ "getter": false,
39
+ "setter": false,
40
+ "reflect": true,
41
+ "attribute": "disabled",
42
+ "defaultValue": "false"
43
+ },
44
+ "label": {
45
+ "type": "string",
46
+ "mutable": false,
47
+ "complexType": {
48
+ "original": "string",
49
+ "resolved": "string",
50
+ "references": {}
51
+ },
52
+ "required": false,
53
+ "optional": false,
54
+ "docs": {
55
+ "tags": [],
56
+ "text": ""
57
+ },
58
+ "getter": false,
59
+ "setter": false,
60
+ "reflect": false,
61
+ "attribute": "label",
62
+ "defaultValue": "''"
63
+ },
64
+ "size": {
65
+ "type": "string",
66
+ "mutable": false,
67
+ "complexType": {
68
+ "original": "'sm' | 'md' | 'lg'",
69
+ "resolved": "\"lg\" | \"md\" | \"sm\"",
70
+ "references": {}
71
+ },
72
+ "required": false,
73
+ "optional": false,
74
+ "docs": {
75
+ "tags": [],
76
+ "text": ""
77
+ },
78
+ "getter": false,
79
+ "setter": false,
80
+ "reflect": true,
81
+ "attribute": "size",
82
+ "defaultValue": "'md'"
83
+ },
84
+ "variant": {
85
+ "type": "string",
86
+ "mutable": false,
87
+ "complexType": {
88
+ "original": "'ghost' | 'outline' | 'solid'",
89
+ "resolved": "\"ghost\" | \"outline\" | \"solid\"",
90
+ "references": {}
91
+ },
92
+ "required": false,
93
+ "optional": false,
94
+ "docs": {
95
+ "tags": [],
96
+ "text": ""
97
+ },
98
+ "getter": false,
99
+ "setter": false,
100
+ "reflect": true,
101
+ "attribute": "variant",
102
+ "defaultValue": "'ghost'"
103
+ }
104
+ };
105
+ }
106
+ }
@@ -0,0 +1,46 @@
1
+ :host {
2
+ display: inline-flex;
3
+ color: var(--ui-text-primary);
4
+ }
5
+
6
+ ::slotted(input) {
7
+ width: 100%;
8
+ appearance: none;
9
+ border: 1px solid var(--ui-border-default);
10
+ border-radius: var(--ui-radius-2);
11
+ background: var(--ui-surface-default);
12
+ color: inherit;
13
+ font: inherit;
14
+ line-height: var(--ui-line-height-md);
15
+ padding: var(--ui-space-2) var(--ui-space-3);
16
+ margin: 0;
17
+ transition:
18
+ border-color var(--ui-motion-fast) var(--ui-motion-ease),
19
+ box-shadow var(--ui-motion-fast) var(--ui-motion-ease),
20
+ background-color var(--ui-motion-fast) var(--ui-motion-ease);
21
+ }
22
+
23
+ ::slotted(input:hover:not(:focus):not(:disabled)) {
24
+ border-color: var(--ui-border-strong);
25
+ }
26
+
27
+ ::slotted(input:focus) {
28
+ border-color: var(--ui-focus-ring);
29
+ box-shadow: 0 0 0 3px var(--ui-accent-soft);
30
+ }
31
+
32
+ :host([data-invalid='true'])::slotted(input),
33
+ ::slotted(input[aria-invalid='true']) {
34
+ border-color: var(--ui-accent-active);
35
+ }
36
+
37
+ ::slotted(input:disabled) {
38
+ background: var(--ui-surface-muted);
39
+ color: var(--ui-text-muted);
40
+ cursor: not-allowed;
41
+ }
42
+
43
+ ::slotted(input:focus-visible) {
44
+ outline: 2px solid var(--ui-focus-ring);
45
+ outline-offset: 2px;
46
+ }
@@ -0,0 +1,213 @@
1
+ import { Host, h } from "@stencil/core";
2
+ import { eventToTrigger, dispatchDetail } from "../../utils/events";
3
+ export class UIInput {
4
+ host;
5
+ value = '';
6
+ defaultValue = '';
7
+ disabled = false;
8
+ invalid = false;
9
+ readOnly = false;
10
+ internalValue = '';
11
+ slotRef;
12
+ syncFromProp() {
13
+ this.internalValue = this.value;
14
+ }
15
+ syncToInput() {
16
+ const input = this.getInput();
17
+ if (!input)
18
+ return;
19
+ this.host.dataset.invalid = this.invalid ? 'true' : '';
20
+ input.value = this.internalValue;
21
+ input.defaultValue = this.defaultValue;
22
+ input.disabled = this.disabled;
23
+ input.readOnly = this.readOnly;
24
+ input.setAttribute('aria-invalid', this.invalid ? 'true' : 'false');
25
+ }
26
+ componentDidLoad() {
27
+ this.syncFromProp();
28
+ this.slotRef?.addEventListener('slotchange', () => this.syncToInput());
29
+ this.syncToInput();
30
+ const input = this.getInput();
31
+ input?.addEventListener('input', this.onInput);
32
+ input?.addEventListener('change', this.onChange);
33
+ }
34
+ disconnectedCallback() {
35
+ const input = this.getInput();
36
+ input?.removeEventListener('input', this.onInput);
37
+ input?.removeEventListener('change', this.onChange);
38
+ }
39
+ componentDidUpdate() {
40
+ this.syncToInput();
41
+ }
42
+ getInput() {
43
+ const slot = this.host.shadowRoot?.querySelector('slot');
44
+ const nodes = slot?.assignedElements() ?? Array.from(this.host.children);
45
+ return nodes.find((el) => el.tagName === 'INPUT') ?? null;
46
+ }
47
+ onInput = (e) => {
48
+ const input = e.target;
49
+ if (!input)
50
+ return;
51
+ this.internalValue = input.value;
52
+ dispatchDetail(this.host, 'input', {
53
+ value: this.internalValue,
54
+ trigger: eventToTrigger(e),
55
+ });
56
+ };
57
+ onChange = (e) => {
58
+ const input = this.getInput();
59
+ if (!input)
60
+ return;
61
+ this.internalValue = input.value;
62
+ dispatchDetail(this.host, 'change', {
63
+ value: this.internalValue,
64
+ trigger: eventToTrigger(e),
65
+ });
66
+ };
67
+ render() {
68
+ return (h(Host, { key: '73f518c7f12fa483d592041d185498bd91f9bb8b', "data-invalid": this.invalid ? '' : undefined }, h("slot", { key: '7ef93ef7c5d36ccdfa66cfb4d14f08707e9ea790', ref: (el) => (this.slotRef = el) })));
69
+ }
70
+ static get is() { return "ui-input"; }
71
+ static get encapsulation() { return "shadow"; }
72
+ static get originalStyleUrls() {
73
+ return {
74
+ "$": ["ui-input.css"]
75
+ };
76
+ }
77
+ static get styleUrls() {
78
+ return {
79
+ "$": ["ui-input.css"]
80
+ };
81
+ }
82
+ static get properties() {
83
+ return {
84
+ "value": {
85
+ "type": "string",
86
+ "mutable": false,
87
+ "complexType": {
88
+ "original": "string",
89
+ "resolved": "string",
90
+ "references": {}
91
+ },
92
+ "required": false,
93
+ "optional": false,
94
+ "docs": {
95
+ "tags": [],
96
+ "text": ""
97
+ },
98
+ "getter": false,
99
+ "setter": false,
100
+ "reflect": false,
101
+ "attribute": "value",
102
+ "defaultValue": "''"
103
+ },
104
+ "defaultValue": {
105
+ "type": "string",
106
+ "mutable": false,
107
+ "complexType": {
108
+ "original": "string",
109
+ "resolved": "string",
110
+ "references": {}
111
+ },
112
+ "required": false,
113
+ "optional": false,
114
+ "docs": {
115
+ "tags": [],
116
+ "text": ""
117
+ },
118
+ "getter": false,
119
+ "setter": false,
120
+ "reflect": false,
121
+ "attribute": "default-value",
122
+ "defaultValue": "''"
123
+ },
124
+ "disabled": {
125
+ "type": "boolean",
126
+ "mutable": false,
127
+ "complexType": {
128
+ "original": "boolean",
129
+ "resolved": "boolean",
130
+ "references": {}
131
+ },
132
+ "required": false,
133
+ "optional": false,
134
+ "docs": {
135
+ "tags": [],
136
+ "text": ""
137
+ },
138
+ "getter": false,
139
+ "setter": false,
140
+ "reflect": false,
141
+ "attribute": "disabled",
142
+ "defaultValue": "false"
143
+ },
144
+ "invalid": {
145
+ "type": "boolean",
146
+ "mutable": false,
147
+ "complexType": {
148
+ "original": "boolean",
149
+ "resolved": "boolean",
150
+ "references": {}
151
+ },
152
+ "required": false,
153
+ "optional": false,
154
+ "docs": {
155
+ "tags": [],
156
+ "text": ""
157
+ },
158
+ "getter": false,
159
+ "setter": false,
160
+ "reflect": false,
161
+ "attribute": "invalid",
162
+ "defaultValue": "false"
163
+ },
164
+ "readOnly": {
165
+ "type": "boolean",
166
+ "mutable": false,
167
+ "complexType": {
168
+ "original": "boolean",
169
+ "resolved": "boolean",
170
+ "references": {}
171
+ },
172
+ "required": false,
173
+ "optional": false,
174
+ "docs": {
175
+ "tags": [],
176
+ "text": ""
177
+ },
178
+ "getter": false,
179
+ "setter": false,
180
+ "reflect": false,
181
+ "attribute": "readonly",
182
+ "defaultValue": "false"
183
+ }
184
+ };
185
+ }
186
+ static get states() {
187
+ return {
188
+ "internalValue": {}
189
+ };
190
+ }
191
+ static get elementRef() { return "host"; }
192
+ static get watchers() {
193
+ return [{
194
+ "propName": "value",
195
+ "methodName": "syncFromProp"
196
+ }, {
197
+ "propName": "internalValue",
198
+ "methodName": "syncToInput"
199
+ }, {
200
+ "propName": "defaultValue",
201
+ "methodName": "syncToInput"
202
+ }, {
203
+ "propName": "disabled",
204
+ "methodName": "syncToInput"
205
+ }, {
206
+ "propName": "invalid",
207
+ "methodName": "syncToInput"
208
+ }, {
209
+ "propName": "readOnly",
210
+ "methodName": "syncToInput"
211
+ }];
212
+ }
213
+ }
@@ -0,0 +1,37 @@
1
+ :host {
2
+ display: flex;
3
+ flex-direction: column;
4
+ min-width: 12rem;
5
+ padding: var(--ui-space-1);
6
+ background: var(--ui-surface-elevated);
7
+ border: 1px solid var(--ui-border-default);
8
+ border-radius: var(--ui-radius-3);
9
+ box-shadow: var(--ui-shadow-lg);
10
+ }
11
+
12
+ ::slotted(ui-menu-item) {
13
+ display: block;
14
+ width: 100%;
15
+ padding: var(--ui-space-2) var(--ui-space-3);
16
+ text-align: left;
17
+ background: none;
18
+ border: none;
19
+ border-radius: var(--ui-radius-2);
20
+ color: var(--ui-text-primary);
21
+ font-size: var(--ui-font-size-md);
22
+ font-weight: var(--ui-font-medium, 500);
23
+ cursor: pointer;
24
+ transition:
25
+ background-color var(--ui-motion-fast) var(--ui-motion-ease),
26
+ color var(--ui-motion-fast) var(--ui-motion-ease);
27
+ }
28
+
29
+ ::slotted(ui-menu-item:hover:not([aria-disabled='true']):not([disabled])) {
30
+ background: var(--ui-surface-subtle);
31
+ }
32
+
33
+ ::slotted(ui-menu-item[aria-disabled='true']),
34
+ ::slotted(ui-menu-item[disabled]) {
35
+ opacity: 0.6;
36
+ cursor: not-allowed;
37
+ }
@@ -0,0 +1,149 @@
1
+ import { Host, h } from "@stencil/core";
2
+ import { eventToTrigger } from "../../utils/events";
3
+ import { dispatchDetail } from "../../utils/events";
4
+ export class UIMenu {
5
+ host;
6
+ open = false;
7
+ defaultOpen = false;
8
+ internalOpen = false;
9
+ syncFromProp() {
10
+ this.internalOpen = this.open;
11
+ }
12
+ componentDidLoad() {
13
+ this.syncFromProp();
14
+ this.internalOpen = this.internalOpen || this.defaultOpen;
15
+ this.host.addEventListener('click', this.onItemClick);
16
+ this.host.addEventListener('keydown', this.onKeydown);
17
+ }
18
+ disconnectedCallback() {
19
+ this.host.removeEventListener('click', this.onItemClick);
20
+ this.host.removeEventListener('keydown', this.onKeydown);
21
+ }
22
+ getItems() {
23
+ return Array.from(this.host.querySelectorAll('ui-menu-item'));
24
+ }
25
+ isItemDisabled(item) {
26
+ return (item.getAttribute('aria-disabled') === 'true' ||
27
+ item.hasAttribute('disabled') ||
28
+ item.getAttribute('disabled') === 'true' ||
29
+ item.disabled === true);
30
+ }
31
+ onItemClick = (e) => {
32
+ const item = e.target.closest?.('ui-menu-item');
33
+ if (!item || item.getRootNode() !== this.host.getRootNode())
34
+ return;
35
+ if (this.isItemDisabled(item))
36
+ return;
37
+ const value = item.getAttribute('value') ?? item.getAttribute('data-value') ?? '';
38
+ dispatchDetail(this.host, 'select', { value, trigger: eventToTrigger(e) });
39
+ dispatchDetail(this.host, 'close', {
40
+ open: false,
41
+ reason: 'action',
42
+ trigger: eventToTrigger(e),
43
+ });
44
+ this.internalOpen = false;
45
+ };
46
+ onKeydown = (e) => {
47
+ const items = this.getItems().filter((i) => !this.isItemDisabled(i));
48
+ if (items.length === 0)
49
+ return;
50
+ const target = e.target.closest?.('ui-menu-item');
51
+ const currentIndex = target && target instanceof HTMLElement ? items.indexOf(target) : -1;
52
+ if (e.key === 'Enter' || e.key === ' ') {
53
+ e.preventDefault();
54
+ if (target && currentIndex >= 0) {
55
+ const value = target.getAttribute('value') ?? target.getAttribute('data-value') ?? '';
56
+ dispatchDetail(this.host, 'select', { value, trigger: 'keyboard' });
57
+ dispatchDetail(this.host, 'close', {
58
+ open: false,
59
+ reason: 'action',
60
+ trigger: 'keyboard',
61
+ });
62
+ this.internalOpen = false;
63
+ }
64
+ return;
65
+ }
66
+ if (e.key === 'ArrowDown' || e.key === 'ArrowUp') {
67
+ e.preventDefault();
68
+ const nextIndex = e.key === 'ArrowDown'
69
+ ? currentIndex < 0
70
+ ? 0
71
+ : Math.min(currentIndex + 1, items.length - 1)
72
+ : currentIndex <= 0
73
+ ? items.length - 1
74
+ : currentIndex - 1;
75
+ items[nextIndex].focus();
76
+ }
77
+ };
78
+ render() {
79
+ return (h(Host, { key: 'f06ad0f8c09060495757ced2da095817409720b7', role: "menu", "aria-orientation": "vertical", "data-open": this.internalOpen ? '' : undefined }, h("slot", { key: 'd504fd3c33894d0e464b957ce67c75fe8a24899c' })));
80
+ }
81
+ static get is() { return "ui-menu"; }
82
+ static get encapsulation() { return "shadow"; }
83
+ static get originalStyleUrls() {
84
+ return {
85
+ "$": ["ui-menu.css"]
86
+ };
87
+ }
88
+ static get styleUrls() {
89
+ return {
90
+ "$": ["ui-menu.css"]
91
+ };
92
+ }
93
+ static get properties() {
94
+ return {
95
+ "open": {
96
+ "type": "boolean",
97
+ "mutable": false,
98
+ "complexType": {
99
+ "original": "boolean",
100
+ "resolved": "boolean",
101
+ "references": {}
102
+ },
103
+ "required": false,
104
+ "optional": false,
105
+ "docs": {
106
+ "tags": [],
107
+ "text": ""
108
+ },
109
+ "getter": false,
110
+ "setter": false,
111
+ "reflect": false,
112
+ "attribute": "open",
113
+ "defaultValue": "false"
114
+ },
115
+ "defaultOpen": {
116
+ "type": "boolean",
117
+ "mutable": false,
118
+ "complexType": {
119
+ "original": "boolean",
120
+ "resolved": "boolean",
121
+ "references": {}
122
+ },
123
+ "required": false,
124
+ "optional": false,
125
+ "docs": {
126
+ "tags": [],
127
+ "text": ""
128
+ },
129
+ "getter": false,
130
+ "setter": false,
131
+ "reflect": false,
132
+ "attribute": "default-open",
133
+ "defaultValue": "false"
134
+ }
135
+ };
136
+ }
137
+ static get states() {
138
+ return {
139
+ "internalOpen": {}
140
+ };
141
+ }
142
+ static get elementRef() { return "host"; }
143
+ static get watchers() {
144
+ return [{
145
+ "propName": "open",
146
+ "methodName": "syncFromProp"
147
+ }];
148
+ }
149
+ }
@@ -0,0 +1,26 @@
1
+ :host {
2
+ display: block;
3
+ width: 100%;
4
+ padding: var(--ui-space-2) var(--ui-space-3);
5
+ text-align: left;
6
+ background: none;
7
+ border: none;
8
+ border-radius: var(--ui-radius-2);
9
+ color: var(--ui-text-primary);
10
+ font-size: var(--ui-font-size-md);
11
+ font-weight: var(--ui-font-medium, 500);
12
+ cursor: pointer;
13
+ transition:
14
+ background-color var(--ui-motion-fast) var(--ui-motion-ease),
15
+ color var(--ui-motion-fast) var(--ui-motion-ease);
16
+ }
17
+
18
+ :host(:hover:not([aria-disabled='true']):not([disabled])) {
19
+ background: var(--ui-surface-subtle);
20
+ }
21
+
22
+ :host([aria-disabled='true']),
23
+ :host([disabled]) {
24
+ opacity: 0.6;
25
+ cursor: not-allowed;
26
+ }