@luzmo/lucero 1.0.1-alpha.17 → 1.0.1-alpha.19

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 (277) hide show
  1. package/components/NumberFormatter-DewVDY5w.cjs +18 -0
  2. package/components/NumberFormatter-DgOUVrge.js +136 -0
  3. package/components/NumberParser-Dik4a0h-.cjs +18 -0
  4. package/components/NumberParser-ci9J5EKv.js +173 -0
  5. package/components/accordion/index.cjs +6 -183
  6. package/components/accordion/index.js +88 -136
  7. package/components/action-bar/index.cjs +4 -85
  8. package/components/action-bar/index.js +50 -72
  9. package/components/action-button/index.cjs +3 -205
  10. package/components/action-button/index.js +93 -167
  11. package/components/action-group/index.cjs +1 -7
  12. package/components/action-group/index.js +8 -12
  13. package/components/action-group-C54IxNZk.cjs +20 -0
  14. package/components/action-group-C9dsPJg-.js +258 -0
  15. package/components/action-menu/index.cjs +11 -91
  16. package/components/action-menu/index.js +47 -66
  17. package/components/async-directive-BwIAw5tB.js +82 -0
  18. package/components/async-directive-DLz6JB0v.cjs +22 -0
  19. package/components/avatar/index.cjs +3 -63
  20. package/components/avatar/index.js +42 -54
  21. package/components/{focusable-selectors-D0t_5P7C.cjs → base-BjTwmyRF.cjs} +5 -16
  22. package/components/base-CFWO09N1.js +684 -0
  23. package/components/base-Cy0MQrPT.cjs +40 -0
  24. package/components/base-D76d76ww.js +26 -0
  25. package/components/button/index.cjs +2 -134
  26. package/components/button/index.js +72 -106
  27. package/components/button-base-B8bWcklV.js +144 -0
  28. package/components/button-base-tf95Lyl4.cjs +25 -0
  29. package/components/button-group/index.cjs +1 -45
  30. package/components/button-group/index.js +25 -37
  31. package/components/calendar/index.cjs +1 -632
  32. package/components/calendar/index.js +7 -637
  33. package/components/checkbox/index.cjs +4 -111
  34. package/components/checkbox/index.js +53 -98
  35. package/components/checkbox-mixin-BOTvuPEu.js +70 -0
  36. package/components/checkbox-mixin-BVPpXtsq.cjs +27 -0
  37. package/components/class-map-CGfNk3Ee.js +51 -0
  38. package/components/class-map-D-Y-hsN5.cjs +22 -0
  39. package/components/clear-button-CuPbWwZY.cjs +18 -0
  40. package/components/clear-button-DzZ5ulBW.js +53 -0
  41. package/components/close-button-BTo4yrFR.cjs +18 -0
  42. package/components/close-button-CuQdsez5.js +51 -0
  43. package/components/color-area/index.cjs +13 -440
  44. package/components/color-area/index.js +187 -322
  45. package/components/color-controller-B0uX6Zso.js +3230 -0
  46. package/components/color-controller-CoUL5f9K.cjs +18 -0
  47. package/components/color-field/index.cjs +2 -95
  48. package/components/color-field/index.js +41 -77
  49. package/components/color-handle/index.cjs +3 -64
  50. package/components/color-handle/index.js +37 -58
  51. package/components/color-loupe/index.cjs +1 -7
  52. package/components/color-loupe/index.js +8 -12
  53. package/components/color-loupe-CrM2DVY3.cjs +56 -0
  54. package/components/color-loupe-DmQe3SpP.js +81 -0
  55. package/components/color-menu/index.cjs +12 -217
  56. package/components/color-menu/index.js +93 -187
  57. package/components/color-palette/index.cjs +1 -89
  58. package/components/color-palette/index.js +51 -78
  59. package/components/color-palette-group/index.cjs +3 -259
  60. package/components/color-palette-group/index.js +105 -193
  61. package/components/color-picker/index.cjs +6 -114
  62. package/components/color-picker/index.js +72 -92
  63. package/components/color-slider/index.cjs +1 -585
  64. package/components/color-slider/index.js +7 -590
  65. package/components/condition-attribute-with-id-DrQYZzFS.cjs +18 -0
  66. package/components/condition-attribute-with-id-Dv4lSRbe.js +31 -0
  67. package/components/date-time-picker/index.cjs +31 -1357
  68. package/components/date-time-picker/index.js +637 -951
  69. package/components/{dependency-manger-XHpQjFgK.js → dependency-manger-CO-VPlqq.js} +14 -24
  70. package/components/dependency-manger-uthev62E.cjs +18 -0
  71. package/components/directive-C7oCP5Bh.cjs +22 -0
  72. package/components/directive-helpers-D4KMv2dC.js +62 -0
  73. package/components/directive-helpers-t-TVum7J.cjs +22 -0
  74. package/components/{slottable-request-event-CANixJnR.cjs → directive-oAbCiebi.js} +25 -14
  75. package/components/divider/index.cjs +1 -54
  76. package/components/divider/index.js +30 -49
  77. package/components/divider.module-DDvBo9zo.cjs +18 -0
  78. package/components/divider.module-DoQWQEIJ.js +21 -0
  79. package/components/element-resolution-BvRLGqIU.cjs +18 -0
  80. package/components/element-resolution-FCUT-wql.js +91 -0
  81. package/components/field-group/index.cjs +1 -7
  82. package/components/field-group/index.js +8 -12
  83. package/components/field-group-5WQMBOk4.cjs +23 -0
  84. package/components/field-group-D4B0IOdA.js +66 -0
  85. package/components/field-label/index.cjs +1 -7
  86. package/components/field-label/index.js +8 -12
  87. package/components/field-label-DxmPiC5p.js +106 -0
  88. package/components/field-label-Dz9kisdW.cjs +25 -0
  89. package/components/flow-D-0MTYCm.js +527 -0
  90. package/components/flow-DM3dNAKs.cjs +30 -0
  91. package/components/focus-group-DHeTq18L.js +218 -0
  92. package/components/focus-group-DnxZUBhQ.cjs +18 -0
  93. package/components/focus-visible-BvScGDCE.js +74 -0
  94. package/components/focus-visible-D4BXb5RB.cjs +18 -0
  95. package/components/focusable-B_KwfEec.cjs +18 -0
  96. package/components/focusable-C5JjRZmT.js +153 -0
  97. package/components/{focusable-selectors-IltOAOd9.js → focusable-selectors-B4YgbghQ.js} +4 -7
  98. package/components/focusable-selectors-BgFlyFcY.cjs +18 -0
  99. package/components/icon/index.cjs +1 -90
  100. package/components/icon/index.js +46 -74
  101. package/components/if-defined-DULpqYwi.js +27 -0
  102. package/components/if-defined-DaXWqfzc.cjs +22 -0
  103. package/components/index-CNK8wHXu.cjs +57 -0
  104. package/components/index-Cf6G4q52.js +1490 -0
  105. package/components/index-D3ICqC7S.js +1174 -0
  106. package/components/index-hqVbNKYy.cjs +113 -0
  107. package/components/index.cjs +1 -174
  108. package/components/index.js +172 -174
  109. package/components/infield-button/index.cjs +2 -46
  110. package/components/infield-button/index.js +30 -41
  111. package/components/label/index.cjs +1 -37
  112. package/components/label/index.js +24 -36
  113. package/components/{language-resolution-BSGJAWiQ.js → language-resolution-B-wjV5bb.js} +17 -21
  114. package/components/language-resolution-EUER43cg.cjs +18 -0
  115. package/components/like-anchor-Bu3pXbjT.cjs +32 -0
  116. package/components/like-anchor-DCFJN0LV.js +69 -0
  117. package/components/luzmo-icons-CiSek5iM.js +229 -0
  118. package/components/luzmo-icons-CtA-TJPd.cjs +29 -0
  119. package/components/manage-help-text-CHfMLzSa.js +92 -0
  120. package/components/manage-help-text-DNqdEkTA.cjs +30 -0
  121. package/components/menu/index.cjs +29 -1297
  122. package/components/menu/index.js +499 -954
  123. package/components/multi-language-field/index.cjs +2 -132
  124. package/components/multi-language-field/index.js +88 -118
  125. package/components/mutation-controller-DH7YOCyj.js +52 -0
  126. package/components/mutation-controller-DkOMCW-c.cjs +22 -0
  127. package/components/number-field/index.cjs +10 -613
  128. package/components/number-field/index.js +243 -442
  129. package/components/observe-slot-presence-CmVi0zTc.js +68 -0
  130. package/components/observe-slot-presence-bc9chhsi.cjs +18 -0
  131. package/components/observe-slot-text-C3moTjwy.js +87 -0
  132. package/components/observe-slot-text-D2VAEFSd.cjs +18 -0
  133. package/components/options/index.cjs +60 -693
  134. package/components/options/index.js +953 -519
  135. package/components/overlay/index.cjs +21 -367
  136. package/components/overlay/index.js +189 -273
  137. package/components/overlay-B3ajDLLq.cjs +47 -0
  138. package/components/overlay-CUKs69yr.js +2745 -0
  139. package/components/{pending-state-CXbe-Xul.js → pending-state-B2wWssTo.js} +13 -28
  140. package/components/pending-state-bJr-nEJl.cjs +26 -0
  141. package/components/picker/index.cjs +1 -9
  142. package/components/picker/index.js +11 -15
  143. package/components/picker-C0LvseZe.cjs +123 -0
  144. package/components/picker-W1qNmtsh.js +461 -0
  145. package/components/picker-button/index.cjs +4 -56
  146. package/components/picker-button/index.js +34 -45
  147. package/components/{condition-attribute-with-id-Cn815e9W.js → platform-BM-uMWpX.js} +49 -24
  148. package/components/platform-BiXhwqk3.cjs +18 -0
  149. package/components/popover/index.cjs +1 -7
  150. package/components/popover/index.js +8 -12
  151. package/components/popover-fwJeZHMQ.cjs +30 -0
  152. package/components/popover-iD8f5Jkp.js +67 -0
  153. package/components/progress-circle/index.cjs +1 -7
  154. package/components/progress-circle/index.js +8 -12
  155. package/components/progress-circle-DZxaMe8L.cjs +33 -0
  156. package/components/progress-circle-USIIU1up.js +97 -0
  157. package/components/query-BL-TJj7K.cjs +22 -0
  158. package/components/query-D_KR_GUc.js +51 -0
  159. package/components/query-assigned-elements-DjfhL1cl.js +36 -0
  160. package/components/query-assigned-elements-DsKsfk7G.cjs +22 -0
  161. package/components/query-assigned-nodes-BcKWmGzy.cjs +22 -0
  162. package/components/query-assigned-nodes-C76XVPWY.js +36 -0
  163. package/components/radio/index.cjs +2 -244
  164. package/components/radio/index.js +110 -192
  165. package/components/{random-id-BEc6QIUL.js → random-id-ByCz1xaq.js} +3 -3
  166. package/components/random-id-CqvckpWe.cjs +18 -0
  167. package/components/roving-tabindex-By_fCy_e.cjs +18 -0
  168. package/components/roving-tabindex-DOg4z6ZU.js +66 -0
  169. package/components/search/index.cjs +8 -115
  170. package/components/search/index.js +66 -96
  171. package/components/select/index.cjs +51 -720
  172. package/components/select/index.js +347 -563
  173. package/components/sized-mixin-CJbBHWRQ.js +63 -0
  174. package/components/sized-mixin-WPHH0a_D.cjs +18 -0
  175. package/components/slider/index.cjs +1 -119
  176. package/components/slider/index.js +1113 -100
  177. package/components/slottable-request-event-BfUUt1Mh.cjs +18 -0
  178. package/components/{slottable-request-event-D9WzrdWv.js → slottable-request-event-DggLA4Rx.js} +9 -12
  179. package/components/state-DwIwYPvt.js +29 -0
  180. package/components/state-vf0PJN3_.cjs +22 -0
  181. package/components/strategies-C6HsQpU2.cjs +18 -0
  182. package/components/strategies-CUMLHtQI.js +195 -0
  183. package/components/streaming-listener-BQ68fKMa.js +91 -0
  184. package/components/streaming-listener-DeGQYM-9.cjs +18 -0
  185. package/components/style-map-Bnhf_mVZ.js +53 -0
  186. package/components/style-map-DuMd5xlY.cjs +22 -0
  187. package/components/swatch/index.cjs +7 -436
  188. package/components/swatch/index.js +205 -350
  189. package/components/switch/index.cjs +2 -61
  190. package/components/switch/index.js +34 -51
  191. package/components/tabs/index.cjs +26 -693
  192. package/components/tabs/index.js +388 -521
  193. package/components/tags/index.cjs +4 -201
  194. package/components/tags/index.js +87 -152
  195. package/components/text-field/index.cjs +3 -49
  196. package/components/text-field/index.js +30 -44
  197. package/components/text-field-BkFPYo7S.cjs +85 -0
  198. package/components/text-field-C2n3rzCK.js +314 -0
  199. package/components/text-field.module-C2KVUJcX.js +21 -0
  200. package/components/text-field.module-DXhFA9G-.cjs +18 -0
  201. package/components/toast/index.cjs +12 -177
  202. package/components/toast/index.js +73 -145
  203. package/components/tooltip/index.cjs +6 -221
  204. package/components/tooltip/index.js +131 -155
  205. package/components/tooltip/tooltip.d.ts +12 -1
  206. package/components/unit-input/index.cjs +8 -232
  207. package/components/unit-input/index.js +108 -201
  208. package/components/utils.cjs +1 -25
  209. package/components/utils.js +22 -22
  210. package/components/{random-id-BE6HA503.cjs → when-CDK1Tt5Y.js} +10 -7
  211. package/components/when-CDZyJPvd.cjs +22 -0
  212. package/custom-elements.json +1 -1
  213. package/package.json +1 -1
  214. package/components/action-group-DHp8RHDf.js +0 -392
  215. package/components/action-group-MPf19RPV.cjs +0 -391
  216. package/components/base-COw9n7UR.cjs +0 -119
  217. package/components/base-DmeVy0cq.js +0 -120
  218. package/components/button-base-7Ak55xFd.cjs +0 -206
  219. package/components/button-base-C3kf6BTK.js +0 -207
  220. package/components/checkbox-mixin-8cL-vfDy.js +0 -84
  221. package/components/checkbox-mixin-CE7dJj3J.cjs +0 -83
  222. package/components/clear-button-Co6oKSgl.js +0 -59
  223. package/components/clear-button-X_HDY2eH.cjs +0 -58
  224. package/components/close-button-DPBK6Kpu.cjs +0 -59
  225. package/components/close-button-Miw9ZjoJ.js +0 -60
  226. package/components/color-controller-BjDZaxhX.js +0 -491
  227. package/components/color-controller-C3c_vb2P.cjs +0 -490
  228. package/components/color-loupe-BQqNR8YD.cjs +0 -88
  229. package/components/color-loupe-B_DDFv8l.js +0 -89
  230. package/components/condition-attribute-with-id-DEc2Yjne.cjs +0 -43
  231. package/components/dependency-manger-CcIE1uvQ.cjs +0 -63
  232. package/components/divider.module-Cm5LcDRV.cjs +0 -20
  233. package/components/divider.module-DauH6k2_.js +0 -21
  234. package/components/element-resolution-DCsrhGZO.cjs +0 -112
  235. package/components/element-resolution-nMlmW4Jy.js +0 -113
  236. package/components/field-group-DNmY8W9v.cjs +0 -86
  237. package/components/field-group-DVdAWCQF.js +0 -87
  238. package/components/field-label-CKH9EXpR.cjs +0 -156
  239. package/components/field-label-Dpsecoc6.js +0 -157
  240. package/components/focus-group-BqDAk9Is.js +0 -337
  241. package/components/focus-group-DFzOlalL.cjs +0 -336
  242. package/components/focus-visible-B-B8-P9R.cjs +0 -104
  243. package/components/focus-visible-BUPRWlsh.js +0 -105
  244. package/components/focusable-BPrTcZPd.cjs +0 -262
  245. package/components/focusable-ChCLg1k4.js +0 -263
  246. package/components/language-resolution-iN9EImbb.cjs +0 -57
  247. package/components/like-anchor-D62faRNG.cjs +0 -79
  248. package/components/like-anchor-v3cJ9RWM.js +0 -80
  249. package/components/manage-help-text-BYx84zZR.cjs +0 -125
  250. package/components/manage-help-text-DOuMTGht.js +0 -126
  251. package/components/observe-slot-presence-9AwLGUQ_.cjs +0 -78
  252. package/components/observe-slot-presence-DcMdoumP.js +0 -79
  253. package/components/observe-slot-text-CSofZeeF.cjs +0 -104
  254. package/components/observe-slot-text-CjnkkBPn.js +0 -105
  255. package/components/overlay-CN8ISP1F.js +0 -2485
  256. package/components/overlay-LViy9VWM.cjs +0 -2484
  257. package/components/pending-state-e4RbXe9u.cjs +0 -75
  258. package/components/picker-DNde3awt.cjs +0 -672
  259. package/components/picker-PfUAF05y.js +0 -673
  260. package/components/platform-CxDar3Dn.cjs +0 -68
  261. package/components/platform-Cxn0WbyT.js +0 -69
  262. package/components/popover-BkbYhl3i.js +0 -74
  263. package/components/popover-BkgUf0kL.cjs +0 -74
  264. package/components/progress-circle-Hu_ivPHf.js +0 -133
  265. package/components/progress-circle-_Etqsj9f.cjs +0 -132
  266. package/components/roving-tabindex-AsmAh2In.cjs +0 -95
  267. package/components/roving-tabindex-DPF9NmrH.js +0 -96
  268. package/components/sized-mixin-DmkrNdWB.js +0 -80
  269. package/components/sized-mixin-UaTVa-AE.cjs +0 -79
  270. package/components/strategies-DlMlaSJR.cjs +0 -317
  271. package/components/strategies-DlPQoTFE.js +0 -318
  272. package/components/streaming-listener-D4sHaMub.cjs +0 -145
  273. package/components/streaming-listener-cAz5zJyk.js +0 -146
  274. package/components/text-field-11tcnftU.cjs +0 -338
  275. package/components/text-field-Chi9J2Cz.js +0 -339
  276. package/components/text-field.module-CMBS0jSL.js +0 -21
  277. package/components/text-field.module-DIJdV_sA.cjs +0 -20
@@ -1,95 +0,0 @@
1
- /*! * Lucero - The design system for Luzmo.
2
- *
3
- * Copyright © 2025 Luzmo
4
- * All rights reserved.
5
- * Lucero (“Luzmo Design System”) must be used according to the Luzmo Terms of Service.
6
- * This license allows users with a current active Luzmo account to use Lucero.
7
- * This license terminates automatically if a user no longer has an active Luzmo account.
8
- * Please view the Luzmo Terms of Service at: https://www.luzmo.com/information-pages/terms-of-use.
9
- *
10
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
11
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
12
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
13
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
14
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
15
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
16
- * SOFTWARE.
17
- * */
18
- "use strict";
19
- const focusGroup = require("./focus-group-DFzOlalL.cjs");
20
- class RovingTabindexController extends focusGroup.FocusGroupController {
21
- constructor() {
22
- super(...arguments);
23
- this.managed = true;
24
- this.manageIndexesAnimationFrame = 0;
25
- }
26
- set focused(focused) {
27
- if (focused === this.focused) {
28
- return;
29
- }
30
- super.focused = focused;
31
- this.manageTabindexes();
32
- }
33
- get focused() {
34
- return super.focused;
35
- }
36
- clearElementCache(offset = 0) {
37
- cancelAnimationFrame(this.manageIndexesAnimationFrame);
38
- super.clearElementCache(offset);
39
- if (!this.managed) {
40
- return;
41
- }
42
- this.manageIndexesAnimationFrame = requestAnimationFrame(
43
- () => this.manageTabindexes()
44
- );
45
- }
46
- manageTabindexes() {
47
- if (this.focused) {
48
- this.updateTabindexes(() => ({ tabIndex: -1 }));
49
- } else {
50
- this.updateTabindexes(
51
- (el) => ({
52
- removeTabIndex: el.contains(this.focusInElement) && el !== this.focusInElement,
53
- tabIndex: el === this.focusInElement ? 0 : -1
54
- })
55
- );
56
- }
57
- }
58
- updateTabindexes(getTabIndex) {
59
- this.elements.forEach((el) => {
60
- const { tabIndex, removeTabIndex } = getTabIndex(el);
61
- if (!removeTabIndex) {
62
- if (this.focused) {
63
- if (el !== this.elements[this.currentIndex]) {
64
- el.tabIndex = tabIndex;
65
- }
66
- } else {
67
- el.tabIndex = tabIndex;
68
- }
69
- return;
70
- }
71
- el.removeAttribute("tabindex");
72
- const updatable = el;
73
- if (updatable.requestUpdate) {
74
- updatable.requestUpdate();
75
- }
76
- });
77
- }
78
- manage() {
79
- this.managed = true;
80
- this.manageTabindexes();
81
- super.manage();
82
- }
83
- unmanage() {
84
- this.managed = false;
85
- this.updateTabindexes(() => ({ tabIndex: 0 }));
86
- super.unmanage();
87
- }
88
- hostUpdated() {
89
- super.hostUpdated();
90
- if (!this.host.hasUpdated) {
91
- this.manageTabindexes();
92
- }
93
- }
94
- }
95
- exports.RovingTabindexController = RovingTabindexController;
@@ -1,96 +0,0 @@
1
- /*! * Lucero - The design system for Luzmo.
2
- *
3
- * Copyright © 2025 Luzmo
4
- * All rights reserved.
5
- * Lucero (“Luzmo Design System”) must be used according to the Luzmo Terms of Service.
6
- * This license allows users with a current active Luzmo account to use Lucero.
7
- * This license terminates automatically if a user no longer has an active Luzmo account.
8
- * Please view the Luzmo Terms of Service at: https://www.luzmo.com/information-pages/terms-of-use.
9
- *
10
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
11
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
12
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
13
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
14
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
15
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
16
- * SOFTWARE.
17
- * */
18
- import { F as FocusGroupController } from "./focus-group-BqDAk9Is.js";
19
- class RovingTabindexController extends FocusGroupController {
20
- constructor() {
21
- super(...arguments);
22
- this.managed = true;
23
- this.manageIndexesAnimationFrame = 0;
24
- }
25
- set focused(focused) {
26
- if (focused === this.focused) {
27
- return;
28
- }
29
- super.focused = focused;
30
- this.manageTabindexes();
31
- }
32
- get focused() {
33
- return super.focused;
34
- }
35
- clearElementCache(offset = 0) {
36
- cancelAnimationFrame(this.manageIndexesAnimationFrame);
37
- super.clearElementCache(offset);
38
- if (!this.managed) {
39
- return;
40
- }
41
- this.manageIndexesAnimationFrame = requestAnimationFrame(
42
- () => this.manageTabindexes()
43
- );
44
- }
45
- manageTabindexes() {
46
- if (this.focused) {
47
- this.updateTabindexes(() => ({ tabIndex: -1 }));
48
- } else {
49
- this.updateTabindexes(
50
- (el) => ({
51
- removeTabIndex: el.contains(this.focusInElement) && el !== this.focusInElement,
52
- tabIndex: el === this.focusInElement ? 0 : -1
53
- })
54
- );
55
- }
56
- }
57
- updateTabindexes(getTabIndex) {
58
- this.elements.forEach((el) => {
59
- const { tabIndex, removeTabIndex } = getTabIndex(el);
60
- if (!removeTabIndex) {
61
- if (this.focused) {
62
- if (el !== this.elements[this.currentIndex]) {
63
- el.tabIndex = tabIndex;
64
- }
65
- } else {
66
- el.tabIndex = tabIndex;
67
- }
68
- return;
69
- }
70
- el.removeAttribute("tabindex");
71
- const updatable = el;
72
- if (updatable.requestUpdate) {
73
- updatable.requestUpdate();
74
- }
75
- });
76
- }
77
- manage() {
78
- this.managed = true;
79
- this.manageTabindexes();
80
- super.manage();
81
- }
82
- unmanage() {
83
- this.managed = false;
84
- this.updateTabindexes(() => ({ tabIndex: 0 }));
85
- super.unmanage();
86
- }
87
- hostUpdated() {
88
- super.hostUpdated();
89
- if (!this.host.hasUpdated) {
90
- this.manageTabindexes();
91
- }
92
- }
93
- }
94
- export {
95
- RovingTabindexController as R
96
- };
@@ -1,80 +0,0 @@
1
- /*! * Lucero - The design system for Luzmo.
2
- *
3
- * Copyright © 2025 Luzmo
4
- * All rights reserved.
5
- * Lucero (“Luzmo Design System”) must be used according to the Luzmo Terms of Service.
6
- * This license allows users with a current active Luzmo account to use Lucero.
7
- * This license terminates automatically if a user no longer has an active Luzmo account.
8
- * Please view the Luzmo Terms of Service at: https://www.luzmo.com/information-pages/terms-of-use.
9
- *
10
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
11
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
12
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
13
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
14
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
15
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
16
- * SOFTWARE.
17
- * */
18
- import { property } from "lit/decorators.js";
19
- var __defProp = Object.defineProperty;
20
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
21
- var __decorateClass = (decorators, target, key, kind) => {
22
- var result = __getOwnPropDesc(target, key);
23
- for (var i = decorators.length - 1, decorator; i >= 0; i--)
24
- if (decorator = decorators[i])
25
- result = decorator(target, key, result) || result;
26
- if (result) __defProp(target, key, result);
27
- return result;
28
- };
29
- const ElementSizes = {
30
- xxs: "xxs",
31
- xs: "xs",
32
- s: "s",
33
- m: "m",
34
- l: "l",
35
- xl: "xl",
36
- xxl: "xxl"
37
- };
38
- function SizedMixin(constructor, {
39
- validSizes = ["s", "m", "l", "xl"],
40
- noDefaultSize,
41
- defaultSize = "m"
42
- } = {}) {
43
- class SizedElement extends constructor {
44
- constructor() {
45
- super(...arguments);
46
- this._size = defaultSize;
47
- }
48
- get size() {
49
- return this._size || defaultSize;
50
- }
51
- set size(value) {
52
- const fallbackSize = noDefaultSize ? null : defaultSize;
53
- const size = value ? value.toLocaleLowerCase() : value;
54
- const validSize = validSizes.includes(size) ? size : fallbackSize;
55
- if (validSize) {
56
- this.setAttribute("size", validSize);
57
- }
58
- if (this._size === validSize) {
59
- return;
60
- }
61
- const oldSize = this._size;
62
- this._size = validSize;
63
- this.requestUpdate("size", oldSize);
64
- }
65
- update(changes) {
66
- if (!this.hasAttribute("size") && !noDefaultSize) {
67
- this.setAttribute("size", this.size);
68
- }
69
- super.update(changes);
70
- }
71
- }
72
- __decorateClass([
73
- property({ type: String })
74
- ], SizedElement.prototype, "size");
75
- return SizedElement;
76
- }
77
- export {
78
- ElementSizes as E,
79
- SizedMixin as S
80
- };
@@ -1,79 +0,0 @@
1
- /*! * Lucero - The design system for Luzmo.
2
- *
3
- * Copyright © 2025 Luzmo
4
- * All rights reserved.
5
- * Lucero (“Luzmo Design System”) must be used according to the Luzmo Terms of Service.
6
- * This license allows users with a current active Luzmo account to use Lucero.
7
- * This license terminates automatically if a user no longer has an active Luzmo account.
8
- * Please view the Luzmo Terms of Service at: https://www.luzmo.com/information-pages/terms-of-use.
9
- *
10
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
11
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
12
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
13
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
14
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
15
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
16
- * SOFTWARE.
17
- * */
18
- "use strict";
19
- const decorators_js = require("lit/decorators.js");
20
- var __defProp = Object.defineProperty;
21
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
22
- var __decorateClass = (decorators, target, key, kind) => {
23
- var result = __getOwnPropDesc(target, key);
24
- for (var i = decorators.length - 1, decorator; i >= 0; i--)
25
- if (decorator = decorators[i])
26
- result = decorator(target, key, result) || result;
27
- if (result) __defProp(target, key, result);
28
- return result;
29
- };
30
- const ElementSizes = {
31
- xxs: "xxs",
32
- xs: "xs",
33
- s: "s",
34
- m: "m",
35
- l: "l",
36
- xl: "xl",
37
- xxl: "xxl"
38
- };
39
- function SizedMixin(constructor, {
40
- validSizes = ["s", "m", "l", "xl"],
41
- noDefaultSize,
42
- defaultSize = "m"
43
- } = {}) {
44
- class SizedElement extends constructor {
45
- constructor() {
46
- super(...arguments);
47
- this._size = defaultSize;
48
- }
49
- get size() {
50
- return this._size || defaultSize;
51
- }
52
- set size(value) {
53
- const fallbackSize = noDefaultSize ? null : defaultSize;
54
- const size = value ? value.toLocaleLowerCase() : value;
55
- const validSize = validSizes.includes(size) ? size : fallbackSize;
56
- if (validSize) {
57
- this.setAttribute("size", validSize);
58
- }
59
- if (this._size === validSize) {
60
- return;
61
- }
62
- const oldSize = this._size;
63
- this._size = validSize;
64
- this.requestUpdate("size", oldSize);
65
- }
66
- update(changes) {
67
- if (!this.hasAttribute("size") && !noDefaultSize) {
68
- this.setAttribute("size", this.size);
69
- }
70
- super.update(changes);
71
- }
72
- }
73
- __decorateClass([
74
- decorators_js.property({ type: String })
75
- ], SizedElement.prototype, "size");
76
- return SizedElement;
77
- }
78
- exports.ElementSizes = ElementSizes;
79
- exports.SizedMixin = SizedMixin;
@@ -1,317 +0,0 @@
1
- /*! * Lucero - The design system for Luzmo.
2
- *
3
- * Copyright © 2025 Luzmo
4
- * All rights reserved.
5
- * Lucero (“Luzmo Design System”) must be used according to the Luzmo Terms of Service.
6
- * This license allows users with a current active Luzmo account to use Lucero.
7
- * This license terminates automatically if a user no longer has an active Luzmo account.
8
- * Please view the Luzmo Terms of Service at: https://www.luzmo.com/information-pages/terms-of-use.
9
- *
10
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
11
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
12
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
13
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
14
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
15
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
16
- * SOFTWARE.
17
- * */
18
- "use strict";
19
- const platform = require("./platform-CxDar3Dn.cjs");
20
- const IS_MOBILE = "(max-width: 743px) and (hover: none) and (pointer: coarse)";
21
- class MatchMediaController {
22
- constructor(host, query) {
23
- this.key = Symbol("match-media-key");
24
- this.matches = false;
25
- this.host = host;
26
- this.host.addController(this);
27
- if (typeof window === "undefined") {
28
- this.matches = false;
29
- } else {
30
- this.media = window.matchMedia(query);
31
- this.matches = this.media.matches;
32
- }
33
- this.onChange = this.onChange.bind(this);
34
- host.addController(this);
35
- }
36
- hostConnected() {
37
- var _a;
38
- (_a = this.media) == null ? void 0 : _a.addEventListener("change", this.onChange);
39
- }
40
- hostDisconnected() {
41
- var _a;
42
- (_a = this.media) == null ? void 0 : _a.removeEventListener("change", this.onChange);
43
- }
44
- onChange(event) {
45
- if (this.matches === event.matches) {
46
- return;
47
- }
48
- this.matches = event.matches;
49
- this.host.requestUpdate(this.key, !this.matches);
50
- }
51
- }
52
- var InteractionTypes = /* @__PURE__ */ ((InteractionTypes2) => {
53
- InteractionTypes2[InteractionTypes2["desktop"] = 0] = "desktop";
54
- InteractionTypes2[InteractionTypes2["mobile"] = 1] = "mobile";
55
- return InteractionTypes2;
56
- })(InteractionTypes || {});
57
- const SAFARI_FOCUS_RING_CLASS = "remove-focus-ring-safari-hack";
58
- class InteractionController {
59
- constructor(target, host) {
60
- this.target = target;
61
- this.host = host;
62
- this.preventNextToggle = "no";
63
- this.pointerdownState = false;
64
- this.enterKeydownOn = null;
65
- this._open = false;
66
- this.target = target;
67
- this.host = host;
68
- this.host.addController(this);
69
- this.init();
70
- }
71
- get activelyOpening() {
72
- return false;
73
- }
74
- get open() {
75
- return this._open;
76
- }
77
- /**
78
- * Set `open`
79
- */
80
- set open(open) {
81
- if (this._open === open) {
82
- return;
83
- }
84
- this._open = open;
85
- if (this.overlay) {
86
- this.host.open = open;
87
- return;
88
- }
89
- customElements.whenDefined("luzmo-overlay").then(async () => {
90
- const { LuzmoOverlay: LuzmoOverlay2 } = await Promise.resolve().then(() => require("./overlay/index.cjs"));
91
- this.overlay = new LuzmoOverlay2();
92
- this.host.open = true;
93
- this.host.requestUpdate();
94
- });
95
- Promise.resolve().then(() => require("./overlay/index.cjs"));
96
- }
97
- get overlay() {
98
- return this._overlay;
99
- }
100
- set overlay(overlay) {
101
- if (!overlay) {
102
- return;
103
- }
104
- if (this.overlay === overlay) {
105
- return;
106
- }
107
- this._overlay = overlay;
108
- this.initOverlay();
109
- }
110
- releaseDescription() {
111
- }
112
- handleBeforetoggle(event) {
113
- var _a, _b;
114
- if (event.composedPath()[0] !== event.target) {
115
- return;
116
- }
117
- if (event.newState === "closed") {
118
- if (this.preventNextToggle === "no") {
119
- this.open = false;
120
- } else if (!this.pointerdownState) {
121
- (_a = this.overlay) == null ? void 0 : _a.manuallyKeepOpen();
122
- }
123
- }
124
- if (!this.open) {
125
- this.host.optionsMenu.updateSelectedItemIndex();
126
- if (
127
- // pickers can have submenus, selects can not
128
- typeof ((_b = this.host.optionsMenu) == null ? void 0 : _b.closeDescendentOverlays) === "function"
129
- ) {
130
- this.host.optionsMenu.closeDescendentOverlays();
131
- }
132
- }
133
- }
134
- initOverlay() {
135
- if (this.overlay) {
136
- this.overlay.addEventListener("beforetoggle", (event) => {
137
- this.handleBeforetoggle(
138
- event
139
- );
140
- });
141
- this.overlay.type = this.host.isMobile.matches ? "modal" : "auto";
142
- this.overlay.triggerElement = this.host;
143
- this.overlay.placement = this.host.isMobile.matches ? void 0 : this.host.placement;
144
- this.overlay.receivesFocus = "true";
145
- this.overlay.willPreventClose = this.preventNextToggle !== "no" && this.open;
146
- this.overlay.addEventListener(
147
- "slottable-request",
148
- this.host.handleSlottableRequest
149
- );
150
- }
151
- }
152
- handlePointerdown(_event) {
153
- }
154
- handleButtonFocus(event) {
155
- if (this.preventNextToggle === "maybe" && event.relatedTarget === this.host.optionsMenu) {
156
- this.preventNextToggle = "yes";
157
- }
158
- }
159
- handleActivate(_event) {
160
- }
161
- /* c8 ignore next 3 */
162
- init() {
163
- }
164
- abort() {
165
- var _a;
166
- this.releaseDescription();
167
- (_a = this.abortController) == null ? void 0 : _a.abort();
168
- }
169
- hostConnected() {
170
- this.init();
171
- }
172
- hostDisconnected() {
173
- var _a;
174
- (_a = this.abortController) == null ? void 0 : _a.abort();
175
- }
176
- hostUpdated() {
177
- if (this.overlay && this.host.dependencyManager.loaded && this.host.open !== this.overlay.open) {
178
- this.overlay.willPreventClose = this.preventNextToggle !== "no";
179
- this.overlay.open = this.host.open;
180
- }
181
- }
182
- }
183
- class DesktopController extends InteractionController {
184
- constructor() {
185
- super(...arguments);
186
- this.type = InteractionTypes.desktop;
187
- }
188
- handlePointerdown(event) {
189
- const target = event.target;
190
- const clearButton = target.closest(".clear-icon");
191
- if (clearButton) {
192
- return;
193
- }
194
- if (event.button !== 0 || event.pointerType === "touch") {
195
- return;
196
- }
197
- this.pointerdownState = this.open;
198
- this.preventNextToggle = "maybe";
199
- let cleanupAction = 0;
200
- const cleanup = () => {
201
- cancelAnimationFrame(cleanupAction);
202
- cleanupAction = requestAnimationFrame(() => {
203
- document.removeEventListener("pointerup", cleanup);
204
- document.removeEventListener("pointercancel", cleanup);
205
- this.target.removeEventListener("click", cleanup);
206
- requestAnimationFrame(() => {
207
- this.preventNextToggle = "no";
208
- });
209
- });
210
- };
211
- document.addEventListener("pointerup", cleanup);
212
- document.addEventListener("pointercancel", cleanup);
213
- this.target.addEventListener("click", cleanup);
214
- this.handleActivate();
215
- }
216
- handleActivate(event) {
217
- if (this.enterKeydownOn && this.enterKeydownOn !== this.target) {
218
- return;
219
- }
220
- if (this.preventNextToggle === "yes") {
221
- return;
222
- }
223
- if ((event == null ? void 0 : event.type) === "click" && this.open !== this.pointerdownState) {
224
- return;
225
- }
226
- this.host.toggle();
227
- }
228
- init() {
229
- var _a;
230
- (_a = this.abortController) == null ? void 0 : _a.abort();
231
- this.abortController = new AbortController();
232
- const { signal } = this.abortController;
233
- this.target.addEventListener(
234
- "click",
235
- (event) => this.handleActivate(event),
236
- {
237
- signal
238
- }
239
- );
240
- this.target.addEventListener(
241
- "pointerdown",
242
- (event) => this.handlePointerdown(event),
243
- { signal }
244
- );
245
- this.target.addEventListener(
246
- "focus",
247
- (event) => this.handleButtonFocus(event),
248
- {
249
- signal
250
- }
251
- );
252
- }
253
- }
254
- class MobileController extends InteractionController {
255
- constructor() {
256
- super(...arguments);
257
- this.type = InteractionTypes.mobile;
258
- }
259
- handleClick(event) {
260
- const target = event.target;
261
- const clearButton = target.closest(".clear-button");
262
- if (!clearButton) {
263
- return;
264
- }
265
- if (this.preventNextToggle === "no") {
266
- this.open = !this.open;
267
- }
268
- this.preventNextToggle = "no";
269
- }
270
- handlePointerdown(event) {
271
- const target = event.target;
272
- const clearButton = target.closest(".clear-button");
273
- if (!clearButton) {
274
- return;
275
- }
276
- this.preventNextToggle = this.open ? "yes" : "no";
277
- if (platform.isWebKit()) {
278
- this.target.classList.add(SAFARI_FOCUS_RING_CLASS);
279
- }
280
- }
281
- handleFocusOut() {
282
- if (this.host.open) {
283
- return;
284
- }
285
- if (platform.isWebKit() && this.target.classList.contains(SAFARI_FOCUS_RING_CLASS)) {
286
- this.target.classList.remove(SAFARI_FOCUS_RING_CLASS);
287
- }
288
- }
289
- init() {
290
- var _a;
291
- (_a = this.abortController) == null ? void 0 : _a.abort();
292
- this.abortController = new AbortController();
293
- const { signal } = this.abortController;
294
- this.target.addEventListener(
295
- "click",
296
- (event) => this.handleClick(event),
297
- {
298
- signal
299
- }
300
- );
301
- this.target.addEventListener(
302
- "pointerdown",
303
- (event) => this.handlePointerdown(event),
304
- { signal }
305
- );
306
- this.target.addEventListener("focusout", () => this.handleFocusOut(), {
307
- signal
308
- });
309
- }
310
- }
311
- const strategies = {
312
- desktop: DesktopController,
313
- mobile: MobileController
314
- };
315
- exports.IS_MOBILE = IS_MOBILE;
316
- exports.MatchMediaController = MatchMediaController;
317
- exports.strategies = strategies;