@mhmo91/schmancy 0.7.5 → 0.7.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 (397) hide show
  1. package/ai/directives.md +214 -7
  2. package/ai/typewriter.md +151 -33
  3. package/dist/ai/directives.md +214 -7
  4. package/dist/ai/typewriter.md +151 -33
  5. package/dist/{animated-text-DnFenRS1.cjs → animated-text-1FDC-OTA.cjs} +2 -2
  6. package/dist/{animated-text-DnFenRS1.cjs.map → animated-text-1FDC-OTA.cjs.map} +1 -1
  7. package/dist/{animated-text-YBgWXuVJ.js → animated-text-1_latidd.js} +3 -3
  8. package/dist/{animated-text-YBgWXuVJ.js.map → animated-text-1_latidd.js.map} +1 -1
  9. package/dist/animated-text.cjs +1 -1
  10. package/dist/animated-text.js +1 -1
  11. package/dist/area.cjs +1 -1
  12. package/dist/{area.component-C_nUxyiY.js → area.component-CQq-Mh0Z.js} +47 -39
  13. package/dist/area.component-CQq-Mh0Z.js.map +1 -0
  14. package/dist/{area.component-BojFAcRk.cjs → area.component-Ciw7vGsx.cjs} +4 -4
  15. package/dist/area.component-Ciw7vGsx.cjs.map +1 -0
  16. package/dist/area.js +1 -1
  17. package/dist/{autocomplete-B-X_D8MC.js → autocomplete-DT9MFPEG.js} +5 -5
  18. package/dist/{autocomplete-B-X_D8MC.js.map → autocomplete-DT9MFPEG.js.map} +1 -1
  19. package/dist/{autocomplete-B8oOdRsV.cjs → autocomplete-auTO_M_w.cjs} +2 -2
  20. package/dist/{autocomplete-B8oOdRsV.cjs.map → autocomplete-auTO_M_w.cjs.map} +1 -1
  21. package/dist/autocomplete.cjs +1 -1
  22. package/dist/autocomplete.js +1 -1
  23. package/dist/{avatar-DBdyON6Y.cjs → avatar-Bo8kRnA-.cjs} +2 -2
  24. package/dist/{avatar-DBdyON6Y.cjs.map → avatar-Bo8kRnA-.cjs.map} +1 -1
  25. package/dist/{avatar-Cro3M4Lw.js → avatar-Dm_qg-n1.js} +52 -52
  26. package/dist/{avatar-Cro3M4Lw.js.map → avatar-Dm_qg-n1.js.map} +1 -1
  27. package/dist/badge.cjs +1 -1
  28. package/dist/badge.js +1 -1
  29. package/dist/boat-98He5-K8.cjs +97 -0
  30. package/dist/boat-98He5-K8.cjs.map +1 -0
  31. package/dist/boat-RNCKlx8b.js +301 -0
  32. package/dist/boat-RNCKlx8b.js.map +1 -0
  33. package/dist/boat.cjs +1 -1
  34. package/dist/boat.js +1 -1
  35. package/dist/busy.cjs +1 -1
  36. package/dist/busy.js +1 -1
  37. package/dist/button.cjs +1 -1
  38. package/dist/button.js +1 -1
  39. package/dist/card.cjs +1 -1
  40. package/dist/card.js +1 -1
  41. package/dist/{checkbox-BOmazo-k.js → checkbox-Bdn1_WJg.js} +2 -2
  42. package/dist/{checkbox-BOmazo-k.js.map → checkbox-Bdn1_WJg.js.map} +1 -1
  43. package/dist/{checkbox-DMfwDgYx.cjs → checkbox-Dj06r6MD.cjs} +2 -2
  44. package/dist/{checkbox-DMfwDgYx.cjs.map → checkbox-Dj06r6MD.cjs.map} +1 -1
  45. package/dist/checkbox.cjs +1 -1
  46. package/dist/checkbox.js +1 -1
  47. package/dist/chips.cjs +1 -1
  48. package/dist/chips.js +2 -2
  49. package/dist/code-highlight.cjs +1 -1
  50. package/dist/code-highlight.js +1 -1
  51. package/dist/{code-preview-DgyY3Jlw.js → code-preview-Br7zBkyM.js} +2 -2
  52. package/dist/{code-preview-DgyY3Jlw.js.map → code-preview-Br7zBkyM.js.map} +1 -1
  53. package/dist/{code-preview-CbZzYTk2.cjs → code-preview-ByxcwPma.cjs} +2 -2
  54. package/dist/{code-preview-CbZzYTk2.cjs.map → code-preview-ByxcwPma.cjs.map} +1 -1
  55. package/dist/components.cjs +1 -1
  56. package/dist/components.js +1 -1
  57. package/dist/content-drawer.cjs +1 -1
  58. package/dist/content-drawer.js +1 -1
  59. package/dist/{date-range-BV0479CW.js → date-range-VkIMcQdT.js} +3 -3
  60. package/dist/{date-range-BV0479CW.js.map → date-range-VkIMcQdT.js.map} +1 -1
  61. package/dist/{date-range-inline-HNDLTnYi.cjs → date-range-inline-kbokz03Z.cjs} +2 -2
  62. package/dist/{date-range-inline-HNDLTnYi.cjs.map → date-range-inline-kbokz03Z.cjs.map} +1 -1
  63. package/dist/{date-range-inline-GfLao0NN.js → date-range-inline-l2G48xTX.js} +3 -3
  64. package/dist/{date-range-inline-GfLao0NN.js.map → date-range-inline-l2G48xTX.js.map} +1 -1
  65. package/dist/date-range-inline.cjs +1 -1
  66. package/dist/date-range-inline.js +1 -1
  67. package/dist/{date-range-47SnbVM6.cjs → date-range-xYUr_KKx.cjs} +2 -2
  68. package/dist/{date-range-47SnbVM6.cjs.map → date-range-xYUr_KKx.cjs.map} +1 -1
  69. package/dist/date-range.cjs +1 -1
  70. package/dist/date-range.js +1 -1
  71. package/dist/{delay-Dr3Fr5YB.cjs → delay-CCreUpYu.cjs} +2 -2
  72. package/dist/{delay-Dr3Fr5YB.cjs.map → delay-CCreUpYu.cjs.map} +1 -1
  73. package/dist/{delay-B40l99jW.js → delay-Nu7RVtYd.js} +2 -2
  74. package/dist/{delay-B40l99jW.js.map → delay-Nu7RVtYd.js.map} +1 -1
  75. package/dist/delay.cjs +1 -1
  76. package/dist/delay.js +1 -1
  77. package/dist/details-CjQrqBli.cjs +98 -0
  78. package/dist/details-CjQrqBli.cjs.map +1 -0
  79. package/dist/details-DVIWpEsI.js +137 -0
  80. package/dist/details-DVIWpEsI.js.map +1 -0
  81. package/dist/details.cjs +1 -1
  82. package/dist/details.js +1 -1
  83. package/dist/{dialog-content-B_amCfq7.js → dialog-content-BgxKi73O.js} +3 -3
  84. package/dist/{dialog-content-B_amCfq7.js.map → dialog-content-BgxKi73O.js.map} +1 -1
  85. package/dist/{dialog-content-Emd7BLQA.cjs → dialog-content-CM3-RXQQ.cjs} +2 -2
  86. package/dist/{dialog-content-Emd7BLQA.cjs.map → dialog-content-CM3-RXQQ.cjs.map} +1 -1
  87. package/dist/dialog.cjs +1 -1
  88. package/dist/dialog.js +1 -1
  89. package/dist/directives.cjs +1 -1
  90. package/dist/directives.js +10 -6
  91. package/dist/divider-0yHQS8kR.cjs +58 -0
  92. package/dist/divider-0yHQS8kR.cjs.map +1 -0
  93. package/dist/divider-CqyzFfn1.js +84 -0
  94. package/dist/divider-CqyzFfn1.js.map +1 -0
  95. package/dist/divider.cjs +1 -1
  96. package/dist/divider.js +1 -1
  97. package/dist/{dropdown-content-BpJq8Q1u.cjs → dropdown-content-BmHQE5-P.cjs} +2 -2
  98. package/dist/{dropdown-content-BpJq8Q1u.cjs.map → dropdown-content-BmHQE5-P.cjs.map} +1 -1
  99. package/dist/{dropdown-content-Bw9jnfCR.js → dropdown-content-iFlLupVo.js} +3 -3
  100. package/dist/{dropdown-content-Bw9jnfCR.js.map → dropdown-content-iFlLupVo.js.map} +1 -1
  101. package/dist/dropdown.cjs +1 -1
  102. package/dist/dropdown.js +1 -1
  103. package/dist/{email-recipients-Bxvu6zi9.cjs → email-recipients-Cioc3U0Z.cjs} +2 -2
  104. package/dist/{email-recipients-Bxvu6zi9.cjs.map → email-recipients-Cioc3U0Z.cjs.map} +1 -1
  105. package/dist/{email-recipients-DZGMhyg4.js → email-recipients-CmAEJDMC.js} +6 -6
  106. package/dist/{email-recipients-DZGMhyg4.js.map → email-recipients-CmAEJDMC.js.map} +1 -1
  107. package/dist/extra.cjs +1 -1
  108. package/dist/extra.js +1 -1
  109. package/dist/{flex-DakK9gco.cjs → flex-BEB1yuMF.cjs} +2 -2
  110. package/dist/{flex-DakK9gco.cjs.map → flex-BEB1yuMF.cjs.map} +1 -1
  111. package/dist/{flex-DUgMxT_9.js → flex-BgcbHlPo.js} +2 -2
  112. package/dist/{flex-DUgMxT_9.js.map → flex-BgcbHlPo.js.map} +1 -1
  113. package/dist/{form-yZ1fh3h9.js → form-CxrvY530.js} +2 -2
  114. package/dist/{form-yZ1fh3h9.js.map → form-CxrvY530.js.map} +1 -1
  115. package/dist/{form-CPmMvWvE.cjs → form-DFDTspmH.cjs} +2 -2
  116. package/dist/{form-CPmMvWvE.cjs.map → form-DFDTspmH.cjs.map} +1 -1
  117. package/dist/form.cjs +1 -1
  118. package/dist/form.js +1 -1
  119. package/dist/{formField.mixin-D51klHq7.cjs → formField.mixin-C7H5DaEl.cjs} +2 -2
  120. package/dist/{formField.mixin-D51klHq7.cjs.map → formField.mixin-C7H5DaEl.cjs.map} +1 -1
  121. package/dist/{formField.mixin-Cmb9YpmX.js → formField.mixin-hZ2qP4iG.js} +2 -2
  122. package/dist/{formField.mixin-Cmb9YpmX.js.map → formField.mixin-hZ2qP4iG.js.map} +1 -1
  123. package/dist/{icon-DHT8YsE3.js → icon-D0FAI5uJ.js} +2 -2
  124. package/dist/{icon-DHT8YsE3.js.map → icon-D0FAI5uJ.js.map} +1 -1
  125. package/dist/{icon-Dsa_BddL.cjs → icon-DJnGMAQ2.cjs} +2 -2
  126. package/dist/{icon-Dsa_BddL.cjs.map → icon-DJnGMAQ2.cjs.map} +1 -1
  127. package/dist/{icon-button-BRcfLsJL.cjs → icon-button-CSZtSmOy.cjs} +8 -8
  128. package/dist/icon-button-CSZtSmOy.cjs.map +1 -0
  129. package/dist/{icon-button-PpRHFLCj.js → icon-button-CbgQp3AL.js} +19 -19
  130. package/dist/icon-button-CbgQp3AL.js.map +1 -0
  131. package/dist/icons.cjs +1 -1
  132. package/dist/icons.js +1 -1
  133. package/dist/index.cjs +1 -1
  134. package/dist/index.js +196 -192
  135. package/dist/{input-CYGSlByl.js → input-DLnKAj3B.js} +4 -4
  136. package/dist/{input-CYGSlByl.js.map → input-DLnKAj3B.js.map} +1 -1
  137. package/dist/{input-chip-CKYO8Lww.cjs → input-chip-C3EPsHcP.cjs} +2 -2
  138. package/dist/{input-chip-CKYO8Lww.cjs.map → input-chip-C3EPsHcP.cjs.map} +1 -1
  139. package/dist/{input-chip-CTKPIRVA.js → input-chip-dmqYCExV.js} +2 -2
  140. package/dist/{input-chip-CTKPIRVA.js.map → input-chip-dmqYCExV.js.map} +1 -1
  141. package/dist/input-wZ6ORWru.cjs +51 -0
  142. package/dist/{input-DB269a2X.cjs.map → input-wZ6ORWru.cjs.map} +1 -1
  143. package/dist/input.cjs +1 -1
  144. package/dist/input.js +1 -1
  145. package/dist/layout.cjs +1 -1
  146. package/dist/layout.js +1 -1
  147. package/dist/{list-BbzeVuby.js → list-BegNkhOn.js} +2 -2
  148. package/dist/{list-BbzeVuby.js.map → list-BegNkhOn.js.map} +1 -1
  149. package/dist/{list-BQVTFNkq.cjs → list-CLKiZ6lk.cjs} +2 -2
  150. package/dist/{list-BQVTFNkq.cjs.map → list-CLKiZ6lk.cjs.map} +1 -1
  151. package/dist/list.cjs +1 -1
  152. package/dist/list.js +1 -1
  153. package/dist/{litElement.mixin-DzCpXwcY.cjs → litElement.mixin-CPQYJnK_.cjs} +2 -2
  154. package/dist/{litElement.mixin-DzCpXwcY.cjs.map → litElement.mixin-CPQYJnK_.cjs.map} +1 -1
  155. package/dist/{litElement.mixin-BzbZQbxa.js → litElement.mixin-DWDPaNoc.js} +2 -2
  156. package/dist/{litElement.mixin-BzbZQbxa.js.map → litElement.mixin-DWDPaNoc.js.map} +1 -1
  157. package/dist/mailbox.cjs +1 -1
  158. package/dist/mailbox.js +1 -1
  159. package/dist/{map-CgwU5Px4.js → map-CUKZ6LrR.js} +2 -2
  160. package/dist/{map-CgwU5Px4.js.map → map-CUKZ6LrR.js.map} +1 -1
  161. package/dist/{map-DuTFI2lm.cjs → map-w4Kdtycx.cjs} +2 -2
  162. package/dist/{map-DuTFI2lm.cjs.map → map-w4Kdtycx.cjs.map} +1 -1
  163. package/dist/map.cjs +1 -1
  164. package/dist/map.js +1 -1
  165. package/dist/{media-BnktmFRW.js → media-CjdCchz8.js} +2 -2
  166. package/dist/{media-BnktmFRW.js.map → media-CjdCchz8.js.map} +1 -1
  167. package/dist/{media-gtpSHRFx.cjs → media-DDNmuoV0.cjs} +2 -2
  168. package/dist/{media-gtpSHRFx.cjs.map → media-DDNmuoV0.cjs.map} +1 -1
  169. package/dist/menu-D9-9vipn.cjs +26 -0
  170. package/dist/menu-D9-9vipn.cjs.map +1 -0
  171. package/dist/menu-ofiPDY2a.js +61 -0
  172. package/dist/menu-ofiPDY2a.js.map +1 -0
  173. package/dist/menu.cjs +1 -1
  174. package/dist/menu.js +1 -1
  175. package/dist/mixins.cjs +1 -1
  176. package/dist/mixins.js +3 -3
  177. package/dist/nav-drawer.cjs +1 -1
  178. package/dist/nav-drawer.js +1 -1
  179. package/dist/navigation-bar.cjs +1 -1
  180. package/dist/navigation-bar.js +1 -1
  181. package/dist/{navigation-rail-D8otIR2P.cjs → navigation-rail-CEDLJTrH.cjs} +2 -2
  182. package/dist/{navigation-rail-D8otIR2P.cjs.map → navigation-rail-CEDLJTrH.cjs.map} +1 -1
  183. package/dist/{navigation-rail-CUMNSz0h.js → navigation-rail-weSW6BCv.js} +3 -3
  184. package/dist/{navigation-rail-CUMNSz0h.js.map → navigation-rail-weSW6BCv.js.map} +1 -1
  185. package/dist/navigation-rail.cjs +1 -1
  186. package/dist/navigation-rail.js +1 -1
  187. package/dist/{notification-service-E16lPsiT.js → notification-service-B4nvP2Jc.js} +5 -5
  188. package/dist/{notification-service-E16lPsiT.js.map → notification-service-B4nvP2Jc.js.map} +1 -1
  189. package/dist/{notification-service-CP6kGXVL.cjs → notification-service-B_pa74hl.cjs} +2 -2
  190. package/dist/{notification-service-CP6kGXVL.cjs.map → notification-service-B_pa74hl.cjs.map} +1 -1
  191. package/dist/notification.cjs +1 -1
  192. package/dist/notification.js +2 -2
  193. package/dist/{notify-D865xIlu.js → notify-Ci0HrUIo.js} +2 -2
  194. package/dist/{notify-D865xIlu.js.map → notify-Ci0HrUIo.js.map} +1 -1
  195. package/dist/{notify-Czdp7BbG.cjs → notify-aasSKQGA.cjs} +2 -2
  196. package/dist/{notify-Czdp7BbG.cjs.map → notify-aasSKQGA.cjs.map} +1 -1
  197. package/dist/{option-cJ8fM5qJ.js → option-Cs4e3CzF.js} +2 -2
  198. package/dist/{option-cJ8fM5qJ.js.map → option-Cs4e3CzF.js.map} +1 -1
  199. package/dist/{option-B1r0hb3H.cjs → option-Uze_q9Ef.cjs} +2 -2
  200. package/dist/{option-B1r0hb3H.cjs.map → option-Uze_q9Ef.cjs.map} +1 -1
  201. package/dist/option.cjs +1 -1
  202. package/dist/option.js +1 -1
  203. package/dist/{payment-card-form-RBjpMc2m.js → payment-card-form-BLoUTYiB.js} +3 -3
  204. package/dist/{payment-card-form-RBjpMc2m.js.map → payment-card-form-BLoUTYiB.js.map} +1 -1
  205. package/dist/{payment-card-form-EO3auDS8.cjs → payment-card-form-rJCPUtWE.cjs} +2 -2
  206. package/dist/{payment-card-form-EO3auDS8.cjs.map → payment-card-form-rJCPUtWE.cjs.map} +1 -1
  207. package/dist/{progress-4v9FzvOT.js → progress-B1f3y-Mf.js} +2 -2
  208. package/dist/{progress-4v9FzvOT.js.map → progress-B1f3y-Mf.js.map} +1 -1
  209. package/dist/{progress-DnhvJMz_.cjs → progress-DdBHNIMT.cjs} +2 -2
  210. package/dist/{progress-DnhvJMz_.cjs.map → progress-DdBHNIMT.cjs.map} +1 -1
  211. package/dist/progress.cjs +1 -1
  212. package/dist/progress.js +1 -1
  213. package/dist/{radio-button-BVegeFKE.cjs → radio-button-BAS7gKmA.cjs} +2 -2
  214. package/dist/{radio-button-BVegeFKE.cjs.map → radio-button-BAS7gKmA.cjs.map} +1 -1
  215. package/dist/{radio-button-DDavzgCz.js → radio-button-CaDaw5VH.js} +3 -3
  216. package/dist/{radio-button-DDavzgCz.js.map → radio-button-CaDaw5VH.js.map} +1 -1
  217. package/dist/radio-group.cjs +1 -1
  218. package/dist/radio-group.js +1 -1
  219. package/dist/ripple-QoNZUUw_.js +148 -0
  220. package/dist/ripple-QoNZUUw_.js.map +1 -0
  221. package/dist/ripple-Ujq_REH4.cjs +16 -0
  222. package/dist/ripple-Ujq_REH4.cjs.map +1 -0
  223. package/dist/{schmancy-steps-container-DN9c-HeX.js → schmancy-steps-container-BInNput3.js} +2 -2
  224. package/dist/{schmancy-steps-container-DN9c-HeX.js.map → schmancy-steps-container-BInNput3.js.map} +1 -1
  225. package/dist/{schmancy-steps-container-s6kZWhcr.cjs → schmancy-steps-container-wQsksygx.cjs} +2 -2
  226. package/dist/{schmancy-steps-container-s6kZWhcr.cjs.map → schmancy-steps-container-wQsksygx.cjs.map} +1 -1
  227. package/dist/search-B1s7thB0.cjs +2 -0
  228. package/dist/search-B1s7thB0.cjs.map +1 -0
  229. package/dist/search-DxxnLa5u.js +95 -0
  230. package/dist/search-DxxnLa5u.js.map +1 -0
  231. package/dist/{select--D6l5ru7.js → select-ApLZefMf.js} +4 -4
  232. package/dist/{select--D6l5ru7.js.map → select-ApLZefMf.js.map} +1 -1
  233. package/dist/{select-DVT_kFNR.cjs → select-_2Ag_znm.cjs} +2 -2
  234. package/dist/{select-DVT_kFNR.cjs.map → select-_2Ag_znm.cjs.map} +1 -1
  235. package/dist/select.cjs +1 -1
  236. package/dist/select.js +1 -1
  237. package/dist/selector-hook-Cok22ifx.cjs +2 -0
  238. package/dist/selector-hook-Cok22ifx.cjs.map +1 -0
  239. package/dist/selector-hook-l2fe2UO5.js +319 -0
  240. package/dist/selector-hook-l2fe2UO5.js.map +1 -0
  241. package/dist/{sheet-CNn_huhz.js → sheet-DovyNsok.js} +14 -14
  242. package/dist/sheet-DovyNsok.js.map +1 -0
  243. package/dist/{sheet-Bza5jVS2.cjs → sheet-wjDOQ8Hs.cjs} +4 -4
  244. package/dist/sheet-wjDOQ8Hs.cjs.map +1 -0
  245. package/dist/sheet.cjs +1 -1
  246. package/dist/sheet.js +2 -2
  247. package/dist/{sheet.service-CmNDL4f6.js → sheet.service-BvOiOFMm.js} +2 -2
  248. package/dist/{sheet.service-CmNDL4f6.js.map → sheet.service-BvOiOFMm.js.map} +1 -1
  249. package/dist/{sheet.service--zUgftN3.cjs → sheet.service-DfHrOxyc.cjs} +2 -2
  250. package/dist/{sheet.service--zUgftN3.cjs.map → sheet.service-DfHrOxyc.cjs.map} +1 -1
  251. package/dist/{slider-Cf0pED-U.cjs → slider-BgJccHrg.cjs} +2 -2
  252. package/dist/{slider-Cf0pED-U.cjs.map → slider-BgJccHrg.cjs.map} +1 -1
  253. package/dist/{slider-DPxBmmFD.js → slider-CeVgx4pL.js} +3 -3
  254. package/dist/{slider-DPxBmmFD.js.map → slider-CeVgx4pL.js.map} +1 -1
  255. package/dist/slider.cjs +1 -1
  256. package/dist/slider.js +1 -1
  257. package/dist/{spinner-BDSDxr_W.cjs → spinner-BKeA2bdB.cjs} +3 -3
  258. package/dist/spinner-BKeA2bdB.cjs.map +1 -0
  259. package/dist/{spinner-Dyz6HBFa.js → spinner-Brq1TenP.js} +3 -3
  260. package/dist/spinner-Brq1TenP.js.map +1 -0
  261. package/dist/steps.cjs +1 -1
  262. package/dist/steps.js +1 -1
  263. package/dist/store.cjs +1 -1
  264. package/dist/store.js +1 -1
  265. package/dist/{suggestion-chip-CCW8g_3S.js → suggestion-chip-CWBSzu7C.js} +3 -3
  266. package/dist/{suggestion-chip-CCW8g_3S.js.map → suggestion-chip-CWBSzu7C.js.map} +1 -1
  267. package/dist/{suggestion-chip-B7COqb4l.cjs → suggestion-chip-dq20NKWy.cjs} +2 -2
  268. package/dist/{suggestion-chip-B7COqb4l.cjs.map → suggestion-chip-dq20NKWy.cjs.map} +1 -1
  269. package/dist/{surface-B4CxtF38.js → surface-Bf8pvmdG.js} +34 -10
  270. package/dist/{surface-B4CxtF38.js.map → surface-Bf8pvmdG.js.map} +1 -1
  271. package/dist/{surface-CkzbeSYN.cjs → surface-fEPJ-cuu.cjs} +27 -3
  272. package/dist/{surface-CkzbeSYN.cjs.map → surface-fEPJ-cuu.cjs.map} +1 -1
  273. package/dist/surface.cjs +1 -1
  274. package/dist/surface.js +1 -1
  275. package/dist/{table-D-g4ZBys.cjs → table-DEnB9_Rf.cjs} +4 -3
  276. package/dist/{table-D-g4ZBys.cjs.map → table-DEnB9_Rf.cjs.map} +1 -1
  277. package/dist/{table-KPNVMJtn.js → table-MLd3oXm6.js} +14 -10
  278. package/dist/{table-KPNVMJtn.js.map → table-MLd3oXm6.js.map} +1 -1
  279. package/dist/table.cjs +1 -1
  280. package/dist/table.js +1 -1
  281. package/dist/{tabs-compatibility-sMoQP12I.cjs → tabs-compatibility-CXVHOR5X.cjs} +2 -2
  282. package/dist/{tabs-compatibility-sMoQP12I.cjs.map → tabs-compatibility-CXVHOR5X.cjs.map} +1 -1
  283. package/dist/{tabs-compatibility-xUK4vD1M.js → tabs-compatibility-KWKzYolX.js} +2 -2
  284. package/dist/{tabs-compatibility-xUK4vD1M.js.map → tabs-compatibility-KWKzYolX.js.map} +1 -1
  285. package/dist/tabs.cjs +1 -1
  286. package/dist/tabs.js +1 -1
  287. package/dist/tailwind.mixin-3TPVvhYf.cjs +2 -0
  288. package/dist/{tailwind.mixin-scDxsqaX.cjs.map → tailwind.mixin-3TPVvhYf.cjs.map} +1 -1
  289. package/dist/tailwind.mixin-DIW0B_of.js +67 -0
  290. package/dist/{tailwind.mixin-xIIxrXd8.js.map → tailwind.mixin-DIW0B_of.js.map} +1 -1
  291. package/dist/teleport.cjs +1 -1
  292. package/dist/teleport.js +1 -1
  293. package/dist/{textarea-BSBYVs99.cjs → textarea-B7arkA7y.cjs} +2 -2
  294. package/dist/{textarea-BSBYVs99.cjs.map → textarea-B7arkA7y.cjs.map} +1 -1
  295. package/dist/{textarea-CFrirT5y.js → textarea-BK1m_CFR.js} +3 -3
  296. package/dist/{textarea-CFrirT5y.js.map → textarea-BK1m_CFR.js.map} +1 -1
  297. package/dist/textarea.cjs +1 -1
  298. package/dist/textarea.js +1 -1
  299. package/dist/{theme-button-B8Xqrz1M.cjs → theme-button-BTKwL3oC.cjs} +2 -2
  300. package/dist/{theme-button-B8Xqrz1M.cjs.map → theme-button-BTKwL3oC.cjs.map} +1 -1
  301. package/dist/{theme-button-D-LTPh88.js → theme-button-C6kk8bay.js} +2 -2
  302. package/dist/{theme-button-D-LTPh88.js.map → theme-button-C6kk8bay.js.map} +1 -1
  303. package/dist/theme-button.cjs +1 -1
  304. package/dist/theme-button.js +1 -1
  305. package/dist/{theme-controller-boat-BOddzVdU.js → theme-controller-boat-BK59LqH9.js} +3 -3
  306. package/dist/{theme-controller-boat-BOddzVdU.js.map → theme-controller-boat-BK59LqH9.js.map} +1 -1
  307. package/dist/{theme-controller-boat-C2F-qRyu.cjs → theme-controller-boat-Y5QXwJxW.cjs} +2 -2
  308. package/dist/{theme-controller-boat-C2F-qRyu.cjs.map → theme-controller-boat-Y5QXwJxW.cjs.map} +1 -1
  309. package/dist/theme.cjs +1 -1
  310. package/dist/theme.js +1 -1
  311. package/dist/{timezone-BvOWa9Nt.js → timezone-D_skWX6Z.js} +3 -3
  312. package/dist/{timezone-BvOWa9Nt.js.map → timezone-D_skWX6Z.js.map} +1 -1
  313. package/dist/{timezone-xHmnktrm.cjs → timezone-nbn0o5GC.cjs} +2 -2
  314. package/dist/{timezone-xHmnktrm.cjs.map → timezone-nbn0o5GC.cjs.map} +1 -1
  315. package/dist/{tooltip-D3ZZJEAk.js → tooltip-Btl0IKYC.js} +2 -2
  316. package/dist/{tooltip-D3ZZJEAk.js.map → tooltip-Btl0IKYC.js.map} +1 -1
  317. package/dist/{tooltip-D24v5bvM.cjs → tooltip-DyuMJEjL.cjs} +2 -2
  318. package/dist/{tooltip-D24v5bvM.cjs.map → tooltip-DyuMJEjL.cjs.map} +1 -1
  319. package/dist/tooltip.cjs +1 -1
  320. package/dist/tooltip.js +1 -1
  321. package/dist/{tree-CfVyhRIH.js → tree-B_2eIFQi.js} +2 -2
  322. package/dist/{tree-CfVyhRIH.js.map → tree-B_2eIFQi.js.map} +1 -1
  323. package/dist/{tree-DC_jbDRu.cjs → tree-N4Y6MoQe.cjs} +2 -2
  324. package/dist/{tree-DC_jbDRu.cjs.map → tree-N4Y6MoQe.cjs.map} +1 -1
  325. package/dist/tree.cjs +1 -1
  326. package/dist/tree.js +1 -1
  327. package/dist/{typewriter-By-3T0Jm.js → typewriter-Blyrk_4c.js} +247 -118
  328. package/dist/typewriter-Blyrk_4c.js.map +1 -0
  329. package/dist/typewriter-CFQAeOaw.cjs +124 -0
  330. package/dist/typewriter-CFQAeOaw.cjs.map +1 -0
  331. package/dist/typewriter.cjs +1 -1
  332. package/dist/typewriter.js +1 -1
  333. package/dist/{typography-B7kvO8iJ.js → typography-DjGWK58I.js} +2 -2
  334. package/dist/{typography-B7kvO8iJ.js.map → typography-DjGWK58I.js.map} +1 -1
  335. package/dist/{typography-9lVCjAbj.cjs → typography-DsIU0TGe.cjs} +2 -2
  336. package/dist/{typography-9lVCjAbj.cjs.map → typography-DsIU0TGe.cjs.map} +1 -1
  337. package/dist/typography.cjs +1 -1
  338. package/dist/typography.js +1 -1
  339. package/dist/utils.cjs +1 -1
  340. package/dist/utils.js +1 -1
  341. package/package.json +1 -1
  342. package/types/src/area/router.types.d.ts +1 -0
  343. package/types/src/boat/boat.d.ts +0 -1
  344. package/types/src/button/button.d.ts +8 -0
  345. package/types/src/details/details.d.ts +3 -11
  346. package/types/src/directives/drag.d.ts +30 -0
  347. package/types/src/directives/index.d.ts +1 -0
  348. package/types/src/divider/divider.d.ts +6 -1
  349. package/types/src/menu/menu-item.d.ts +0 -1
  350. package/types/src/store/filter-directive.d.ts +1 -1
  351. package/types/src/surface/surface.d.ts +2 -1
  352. package/types/src/types/surface.d.ts +1 -1
  353. package/types/src/typewriter/typewriter.d.ts +15 -0
  354. package/types/src/utils/index.d.ts +4 -4
  355. package/types/src/utils/search.d.ts +39 -1
  356. package/dist/area.component-BojFAcRk.cjs.map +0 -1
  357. package/dist/area.component-C_nUxyiY.js.map +0 -1
  358. package/dist/boat-B7AKN6Ge.js +0 -276
  359. package/dist/boat-B7AKN6Ge.js.map +0 -1
  360. package/dist/boat-BhAuteUk.cjs +0 -93
  361. package/dist/boat-BhAuteUk.cjs.map +0 -1
  362. package/dist/details-CQPpI_la.js +0 -211
  363. package/dist/details-CQPpI_la.js.map +0 -1
  364. package/dist/details-DydvHvfw.cjs +0 -143
  365. package/dist/details-DydvHvfw.cjs.map +0 -1
  366. package/dist/divider-BF9xljgI.cjs +0 -2
  367. package/dist/divider-BF9xljgI.cjs.map +0 -1
  368. package/dist/divider-BHruVdsE.js +0 -23
  369. package/dist/divider-BHruVdsE.js.map +0 -1
  370. package/dist/icon-button-BRcfLsJL.cjs.map +0 -1
  371. package/dist/icon-button-PpRHFLCj.js.map +0 -1
  372. package/dist/input-DB269a2X.cjs +0 -51
  373. package/dist/menu-DA2pO48m.cjs +0 -26
  374. package/dist/menu-DA2pO48m.cjs.map +0 -1
  375. package/dist/menu-DwFriXTu.js +0 -63
  376. package/dist/menu-DwFriXTu.js.map +0 -1
  377. package/dist/ripple-Cy-nvO8W.js +0 -80
  378. package/dist/ripple-Cy-nvO8W.js.map +0 -1
  379. package/dist/ripple-DqQrvaTe.cjs +0 -16
  380. package/dist/ripple-DqQrvaTe.cjs.map +0 -1
  381. package/dist/search-BeEqIiuO.js +0 -53
  382. package/dist/search-BeEqIiuO.js.map +0 -1
  383. package/dist/search-bfOHCuHZ.cjs +0 -2
  384. package/dist/search-bfOHCuHZ.cjs.map +0 -1
  385. package/dist/selector-hook-BG6g_IEN.cjs +0 -2
  386. package/dist/selector-hook-BG6g_IEN.cjs.map +0 -1
  387. package/dist/selector-hook-CrwQCPxL.js +0 -313
  388. package/dist/selector-hook-CrwQCPxL.js.map +0 -1
  389. package/dist/sheet-Bza5jVS2.cjs.map +0 -1
  390. package/dist/sheet-CNn_huhz.js.map +0 -1
  391. package/dist/spinner-BDSDxr_W.cjs.map +0 -1
  392. package/dist/spinner-Dyz6HBFa.js.map +0 -1
  393. package/dist/tailwind.mixin-scDxsqaX.cjs +0 -2
  394. package/dist/tailwind.mixin-xIIxrXd8.js +0 -67
  395. package/dist/typewriter-By-3T0Jm.js.map +0 -1
  396. package/dist/typewriter-vit0P1N1.cjs +0 -9
  397. package/dist/typewriter-vit0P1N1.cjs.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"input-DB269a2X.cjs","sources":["../src/input/input.ts"],"sourcesContent":["import { html, LitElement, nothing, PropertyValueMap } from 'lit'\nimport { customElement, property, query, state } from 'lit/decorators.js'\nimport { ifDefined } from 'lit/directives/if-defined.js'\nimport { createRef, ref } from 'lit/directives/ref.js'\nimport { when } from 'lit/directives/when.js'\nimport { distinctUntilChanged, filter, fromEvent, map, takeUntil } from 'rxjs'\n\nimport { SchmancyFormField } from '@mixins/index'\n\n// Import styles\nimport style from './input.scss?inline'\n\n// If you want to be form-associated, define the type on `ElementInternals`.\ndeclare global {\n\tinterface HTMLElementTagNameMap {\n\t\t'schmancy-input': SchmancyInput\n\t\t'sch-input': SchmancyInput\n\t}\n}\n\ntype EventDetails = {\n\tvalue: string\n}\n\n/**\n * Custom events the component may emit:\n * - 'input': on every keystroke\n * - 'change': on native blur/change\n * - 'enter': specifically when user presses Enter\n */\nexport type SchmancyInputInputEvent = CustomEvent<EventDetails>\nexport type SchmancyInputChangeEvent = CustomEvent<EventDetails>\nexport type SchmancyInputEnterEvent = CustomEvent<EventDetails>\n\n/**\n * Size variants for the input.\n * - sm: Small, compact input (40px height)\n * - md: Medium input (50px height, default)\n * - lg: Large, spacious input (60px height)\n */\nexport type InputSize = 'sm' | 'md' | 'lg'\n\n/**\n * Enhanced version of the SchmancyInput component with improved form integration\n * and compatibility with legacy API.\n *\n * This component uses the native form association API and maintains parity with\n * native input behaviors while providing a stylish, accessible interface.\n *\n * @prop {string} name - Name attribute for form submission (inherited from FormFieldMixin)\n * @prop {string} label - Label text for the form field (inherited from FormFieldMixin)\n * @prop {boolean} required - Whether the field is required (inherited from FormFieldMixin)\n * @prop {boolean} disabled - Whether the field is disabled (inherited from FormFieldMixin)\n * @prop {boolean} readonly - Whether the field is read-only (inherited from FormFieldMixin)\n * @prop {boolean} error - Whether the field is in an error state (inherited from FormFieldMixin)\n * @prop {string} validationMessage - The validation message to display (inherited from FormFieldMixin)\n * @prop {string} hint - Optional hint text to display below the field (inherited from FormFieldMixin)\n */\n@customElement('schmancy-input')\nexport default class SchmancyInput extends SchmancyFormField(style) {\n\t// ----------------------------\n\t// A) Public properties\n\t// ----------------------------\n\n\t/** Auto-incrementing counter for generating unique IDs */\n\tstatic _idCounter = 0\n\n\t/** Override value to be string only for input element */\n\t@property({ type: String, reflect: true })\n\tpublic override value = ''\n\n\n\t/**\n\t * The type of input. (e.g. 'text', 'password', 'email', etc.)\n\t */\n\t@property({ reflect: true })\n\tpublic type: HTMLInputElement['type'] = 'text'\n\n\n\t@property()\n\tpublic placeholder = ''\n\n\n\t/** Pattern validation attribute. */\n\t@property({ type: String, reflect: true })\n\tpublic pattern?: string\n\n\n\t/** If true, we visually show a pointer cursor even if readOnly. */\n\t@property({ type: Boolean, reflect: true }) public clickable = false\n\n\t/** Whether browser spellcheck is enabled. */\n\t@property({ type: Boolean, reflect: true })\n\tpublic spellcheck = false\n\n\t/**\n\t * Text alignment within the input.\n\t * - 'left' | 'center' | 'right'\n\t */\n\t@property({ type: String, reflect: true })\n\tpublic align: 'left' | 'center' | 'right' = 'left'\n\n\t/** inputmode attribute (affects on-screen keyboards in mobile). */\n\t@property()\n\tpublic inputmode?: 'none' | 'text' | 'decimal' | 'numeric' | 'tel' | 'search' | 'email' | 'url'\n\n\t@property({ type: Number, reflect: true })\n\tpublic minlength?: number\n\n\t@property({ type: Number })\n\tpublic maxlength?: number\n\n\t@property()\n\tpublic min?: string\n\n\t@property()\n\tpublic max?: string\n\n\t@property({ type: Number, reflect: true })\n\tpublic step?: number\n\n\t/** If true, auto-focus this input on first render. */\n\t@property({ type: Boolean })\n\tpublic autofocus = false\n\n\t/** Autocomplete/autofill hints. */\n\t@property({ type: String, reflect: true })\n\tpublic autocomplete: AutoFill = 'on'\n\n\t/**\n\t * tabIndex for focusing by tab key. Typically 0 or -1.\n\t */\n\t@property({ type: Number, reflect: true })\n\tpublic override tabIndex = 0\n\n\n\t/**\n\t * The size of the input.\n\t * - 'sm': Small, compact size\n\t * - 'md': Medium size (default)\n\t * - 'lg': Large size\n\t */\n\t@property({ type: String, reflect: true })\n\tpublic size: InputSize = 'md'\n\n\t/**\n\t * Controls when validation should show.\n\t * - 'always' - Always show validation\n\t * - 'touched' - Only show after field has been focused and then blurred\n\t * - 'dirty' - Only show after value has changed\n\t * - 'submitted' - Only show after form submission\n\t */\n\t@property({ type: String })\n\tpublic validateOn: 'always' | 'touched' | 'dirty' | 'submitted' = 'touched'\n\n\t/**\n\t * For datalist support\n\t */\n\t@property({ type: String })\n\tpublic list?: string\n\n\n\t// ----------------------------\n\t// B) Queries & Refs\n\t// ----------------------------\n\t@query('input') private inputElement!: HTMLInputElement\n\tprivate inputRef = createRef<HTMLInputElement>()\n\n\t// ----------------------------\n\t// C) Internal States\n\t// ----------------------------\n\n\t/**\n\t * For integration with browser's autofill support\n\t */\n\t@state()\n\tprivate isAutofilled = false\n\n\t/**\n\t * Track user interaction state for validation\n\t */\n\t@state()\n\tprivate touched = false\n\n\t@state()\n\tprivate dirty = false\n\n\t@state()\n\tprivate submitted = false\n\n\t/**\n\t * Store the default value for reset behavior\n\t */\n\t@state()\n\tprivate defaultValue = ''\n\n\t// ----------------------------\n\t// D) Form-associated logic\n\t// ----------------------------\n\tprotected static shadowRootOptions = {\n\t\t...LitElement.shadowRootOptions,\n\t\tdelegatesFocus: true, // so focus() goes to <input>\n\t}\n\n\tprivate formResetObserver?: MutationObserver\n\n\t/**\n\t * If user did not provide an ID, auto-generate one so <label for=\"...\">\n\t * and various aria-* attributes can reference it.\n\t */\n\tprotected override willUpdate(changedProps: PropertyValueMap<any> | Map<PropertyKey, unknown>) {\n\t\tif (!this.id) {\n\t\t\tthis.id = `sch-input-${SchmancyInput._idCounter++}`\n\t\t}\n\t\tsuper.willUpdate(changedProps)\n\t}\n\n\n\tprotected override updated(changedProps: Map<string, unknown>) {\n\t\tsuper.updated(changedProps)\n\n\t\t// Handle value changes\n\t\tif (changedProps.has('value')) {\n\t\t\t// If value changes from original default, mark as dirty\n\t\t\tif (this.value !== this.defaultValue) {\n\t\t\t\tthis.dirty = true\n\t\t\t}\n\n\t\t\t// Update validation state when value changes\n\t\t\tthis.validateInput()\n\t\t}\n\n\t\t// Store default value if this is the first update\n\t\tif (!this.hasUpdated && changedProps.has('value')) {\n\t\t\tthis.defaultValue = this.value\n\t\t}\n\t}\n\n\t/**\n\t * Connect to the closest form element and set up form integration\n\t */\n\tconnectedCallback() {\n\t\tsuper.connectedCallback()\n\n\t\t// Store initial default value for form reset\n\t\tthis.defaultValue = this.value\n\n\t\t// Set up form integration\n\t\tthis.setupFormIntegration()\n\n\t\t// Setup for external label association\n\t\tthis.setupExternalLabelAssociation()\n\t}\n\n\t/**\n\t * Set up form integration with ElementInternals\n\t */\n\tprivate setupFormIntegration() {\n\t\tif (this.form) {\n\t\t\t// Listen for form reset events\n\t\t\tthis.formResetObserver = new MutationObserver(mutations => {\n\t\t\t\tfor (const mutation of mutations) {\n\t\t\t\t\tif (mutation.type === 'attributes' && mutation.attributeName === 'reset') {\n\t\t\t\t\t\tthis.resetToDefault()\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t})\n\n\t\t\t// Observe the form for reset events\n\t\t\tthis.formResetObserver.observe(this.form, {\n\t\t\t\tattributes: true,\n\t\t\t\tchildList: false,\n\t\t\t\tsubtree: false,\n\t\t\t})\n\n\t\t\t// Use RxJS for form reset events\n\t\t\tfromEvent(this.form, 'reset')\n\t\t\t\t.pipe(takeUntil(this.disconnecting))\n\t\t\t\t.subscribe(() => {\n\t\t\t\t\tthis.resetToDefault()\n\t\t\t\t})\n\n\t\t\t// Use RxJS for form submit events to mark field as submitted\n\t\t\tfromEvent(this.form, 'submit')\n\t\t\t\t.pipe(takeUntil(this.disconnecting))\n\t\t\t\t.subscribe(() => {\n\t\t\t\t\tthis.submitted = true\n\t\t\t\t\t// Validate on form submission\n\t\t\t\t\tthis.validateInput(true)\n\t\t\t\t})\n\t\t}\n\t}\n\n\t/**\n\t * Set up external label association for native HTML label support\n\t */\n\tprivate setupExternalLabelAssociation() {\n\t\tif (this.id) {\n\t\t\tconst setupLabelClickListener = () => {\n\t\t\t\tconst labels = document.querySelectorAll(`label[for=\"${this.id}\"]`)\n\t\t\t\tlabels.forEach(label => {\n\t\t\t\t\t// Use RxJS for label click events\n\t\t\t\t\tfromEvent(label, 'click')\n\t\t\t\t\t\t.pipe(takeUntil(this.disconnecting))\n\t\t\t\t\t\t.subscribe(() => {\n\t\t\t\t\t\t\tthis.focus()\n\t\t\t\t\t\t})\n\t\t\t\t})\n\t\t\t}\n\n\t\t\t// Initialize after DOM is ready\n\t\t\tif (document.readyState === 'complete') {\n\t\t\t\tsetupLabelClickListener()\n\t\t\t} else {\n\t\t\t\t// Use RxJS for DOMContentLoaded event\n\t\t\t\tfromEvent(document, 'DOMContentLoaded')\n\t\t\t\t\t.pipe(takeUntil(this.disconnecting))\n\t\t\t\t\t.subscribe(setupLabelClickListener)\n\t\t\t}\n\t\t}\n\t}\n\n\tdisconnectedCallback() {\n\t\tsuper.disconnectedCallback()\n\n\t\t// Clean up the form observer\n\t\tif (this.formResetObserver) {\n\t\t\tthis.formResetObserver.disconnect()\n\t\t}\n\n\t\t// Note: RxJS subscriptions are automatically cleaned up via takeUntil(this.disconnecting)\n\t\t// No manual removeEventListener calls needed for RxJS-managed events\n\t}\n\n\t/**\n\t * Reset the input to its default state\n\t */\n\tprivate resetToDefault() {\n\t\tthis.value = this.defaultValue\n\t\tthis.touched = false\n\t\tthis.dirty = false\n\t\tthis.submitted = false\n\t\tthis.error = false\n\t\tthis.validationMessage = ''\n\t\tthis.dispatchEvent(new CustomEvent('reset', { bubbles: true }))\n\t}\n\n\t/**\n\t * Determines if validation errors should be shown based on current state\n\t * and validation strategy\n\t */\n\tprivate shouldShowValidation(forceValidation = false): boolean {\n\t\tif (forceValidation) return true\n\n\t\tswitch (this.validateOn) {\n\t\t\tcase 'always':\n\t\t\t\treturn true\n\t\t\tcase 'touched':\n\t\t\t\treturn this.touched\n\t\t\tcase 'dirty':\n\t\t\t\treturn this.dirty\n\t\t\tcase 'submitted':\n\t\t\t\treturn this.submitted\n\t\t\tdefault:\n\t\t\t\treturn this.touched\n\t\t}\n\t}\n\n\n\t/**\n\t * Validate input based on required, pattern, etc.\n\t * This mimics native validation behavior\n\t */\n\tprivate validateInput(forceValidation = false) {\n\t\t// Skip validation for disabled inputs\n\t\tif (this.disabled) return\n\n\t\t// Only show validation errors if we should based on the validation strategy\n\t\tconst shouldValidate = this.shouldShowValidation(forceValidation)\n\n\t\t// Get validity state from internal input if available\n\t\tconst validity: ValidityState = this.inputElement?.validity ?? {\n\t\t\tbadInput: false,\n\t\t\tcustomError: false,\n\t\t\tpatternMismatch: false,\n\t\t\trangeOverflow: false,\n\t\t\trangeUnderflow: false,\n\t\t\tstepMismatch: false,\n\t\t\ttooLong: false,\n\t\t\ttooShort: false,\n\t\t\ttypeMismatch: false,\n\t\t\tvalid: true,\n\t\t\tvalueMissing: false,\n\t\t}\n\n\t\t// Check if the input has an actual validation error (not a custom error)\n\t\tconst hasError = !validity.valid && !validity.customError\n\n\t\tif (shouldValidate && hasError) {\n\t\t\t// There's an error and we should show it\n\t\t\tthis.error = true\n\t\t\tthis.validationMessage = this.inputElement?.validationMessage || ''\n\t\t} else if (validity.valid) {\n\t\t\t// Input is valid, so clear the error state\n\t\t\tthis.error = false\n\n\t\t\t// Only clear validation message if there's no custom error\n\t\t\tif (!validity.customError) {\n\t\t\t\tthis.validationMessage = ''\n\t\t\t}\n\t\t} else if (!shouldValidate) {\n\t\t\t// We shouldn't show validation yet, so clear visual error state\n\t\t\tthis.error = false\n\t\t}\n\n\t\t// The mixin will handle updating internals based on error state\n\t}\n\n\t/**\n\t * Check validity without showing validation UI\n\t */\n\tpublic override checkValidity() {\n\t\t// Check internal input first\n\t\tconst inputValid = this.inputRef.value?.checkValidity() ?? true\n\n\t\t// Call parent implementation for basic validation\n\t\tconst parentValid = super.checkValidity()\n\n\t\treturn inputValid && parentValid\n\t}\n\n\t/**\n\t * Show validation UI and check validity\n\t */\n\tpublic override reportValidity() {\n\t\t// Mark as touched and submitted to show validation\n\t\tthis.touched = true\n\t\tthis.submitted = true\n\n\t\t// First check using native input\n\t\tconst inputValid = this.inputRef.value?.reportValidity() ?? true\n\n\t\t// Update our component's validation state with force=true\n\t\tthis.validateInput(true)\n\n\t\t// Call parent implementation\n\t\tconst parentValid = super.reportValidity()\n\n\t\treturn inputValid && parentValid\n\t}\n\n\t/**\n\t * Set a custom validation error message\n\t */\n\tpublic override setCustomValidity(message: string) {\n\t\t// Set on the native input\n\t\tif (this.inputRef.value) {\n\t\t\tthis.inputRef.value.setCustomValidity(message)\n\t\t}\n\n\t\t// Call parent implementation\n\t\tsuper.setCustomValidity(message)\n\t\t\n\t\t// Update error state based on validation strategy\n\t\tthis.error = message !== '' && this.shouldShowValidation()\n\t}\n\n\t// ----------------------------\n\t// E) Lifecycle Hooks & Event Handlers\n\t// ----------------------------\n\tfirstUpdated() {\n\t\t// Autofocus if desired\n\t\tif (this.autofocus) {\n\t\t\t// Use setTimeout to match browser behavior - autofocus happens after initial rendering\n\t\t\tsetTimeout(() => {\n\t\t\t\tthis.focus()\n\t\t\t}, 0)\n\t\t}\n\n\t\t// Subscribe to input events\n\t\tthis.setupInputEvents()\n\t\tthis.setupFocusBlurEvents()\n\t\tthis.setupAutofillDetection()\n\t\tthis.setupEnterKeyEvents()\n\t}\n\n\t/**\n\t * Set up input event handling for value changes\n\t */\n\tprivate setupInputEvents() {\n\t\tfromEvent<InputEvent>(this.inputElement, 'input')\n\t\t\t.pipe(\n\t\t\t\tmap(ev => {\n\t\t\t\t\t// Capture all input event properties for complete event forwarding\n\t\t\t\t\tconst inputEvent = ev as InputEvent\n\t\t\t\t\tconst target = ev.target as HTMLInputElement\n\t\t\t\t\treturn {\n\t\t\t\t\t\tvalue: target.value,\n\t\t\t\t\t\tinputType: inputEvent.inputType,\n\t\t\t\t\t\tdata: inputEvent.data,\n\t\t\t\t\t\tisComposing: inputEvent.isComposing,\n\t\t\t\t\t\toriginalEvent: ev,\n\t\t\t\t\t}\n\t\t\t\t}),\n\t\t\t\ttakeUntil(this.disconnecting),\n\t\t\t)\n\t\t\t.subscribe(eventData => {\n\t\t\t\t// Update component value\n\t\t\t\tthis.value = eventData.value\n\n\t\t\t\t// Mark as dirty when user types\n\t\t\t\tthis.dirty = this.value !== this.defaultValue\n\n\t\t\t\t// Fire custom 'input' event with extended details\n\t\t\t\tconst customEvent = new CustomEvent<EventDetails>('input', {\n\t\t\t\t\tdetail: { value: eventData.value },\n\t\t\t\t\tbubbles: true,\n\t\t\t\t\tcomposed: true,\n\t\t\t\t})\n\n\t\t\t\t// Add additional properties to match native events more closely\n\t\t\t\tObject.defineProperties(customEvent, {\n\t\t\t\t\tinputType: { value: eventData.inputType },\n\t\t\t\t\tdata: { value: eventData.data },\n\t\t\t\t\tisComposing: { value: eventData.isComposing },\n\t\t\t\t})\n\n\t\t\t\tthis.dispatchEvent(customEvent)\n\n\t\t\t\t// REMOVED: Duplicate change event dispatch that was here\n\t\t\t\t// Run validation like native inputs do on input, but respect the validation strategy\n\t\t\t\tthis.validateInput()\n\t\t\t})\n\n\t\t// Subscribe to native change events (usually on blur)\n\t\tfromEvent<Event>(this.inputElement, 'change')\n\t\t\t.pipe(\n\t\t\t\tmap(ev => (ev.target as HTMLInputElement).value),\n\t\t\t\tdistinctUntilChanged(),\n\t\t\t\ttakeUntil(this.disconnecting),\n\t\t\t)\n\t\t\t.subscribe(value => {\n\t\t\t\tthis.value = value\n\t\t\t\tthis.dirty = this.value !== this.defaultValue\n\n\t\t\t\t// Fire regular change event using mixin helper\n\t\t\t\tthis.emitChange({ value })\n\n\t\t\t\t// Run validation on change like native inputs\n\t\t\t\tthis.validateInput()\n\t\t\t})\n\t}\n\n\t/**\n\t * Set up focus/blur event handling\n\t */\n\tprivate setupFocusBlurEvents() {\n\t\tfromEvent<FocusEvent>(this.inputElement, 'focus')\n\t\t\t.pipe(takeUntil(this.disconnecting))\n\t\t\t.subscribe(ev => {\n\t\t\t\t// Create a custom focus event that includes standard props\n\t\t\t\tconst focusEvent = new CustomEvent('focus', {\n\t\t\t\t\tbubbles: ev.bubbles,\n\t\t\t\t\tcancelable: ev.cancelable,\n\t\t\t\t\tcomposed: ev.composed,\n\t\t\t\t})\n\n\t\t\t\t// Add focus-specific properties\n\t\t\t\tObject.defineProperties(focusEvent, {\n\t\t\t\t\trelatedTarget: { value: ev.relatedTarget },\n\t\t\t\t})\n\n\t\t\t\tthis.dispatchEvent(focusEvent)\n\t\t\t})\n\n\t\tfromEvent<FocusEvent>(this.inputElement, 'blur')\n\t\t\t.pipe(takeUntil(this.disconnecting))\n\t\t\t.subscribe(ev => {\n\t\t\t\t// Mark as touched when field loses focus\n\t\t\t\tthis.touched = true\n\n\t\t\t\t// Run validation on blur like native inputs, respecting validation strategy\n\t\t\t\tif (!this.disabled) {\n\t\t\t\t\tthis.validateInput()\n\t\t\t\t}\n\n\t\t\t\t// Create a custom blur event that includes standard props\n\t\t\t\tconst blurEvent = new CustomEvent('blur', {\n\t\t\t\t\tbubbles: ev.bubbles,\n\t\t\t\t\tcancelable: ev.cancelable,\n\t\t\t\t\tcomposed: ev.composed,\n\t\t\t\t})\n\n\t\t\t\t// Add blur-specific properties\n\t\t\t\tObject.defineProperties(blurEvent, {\n\t\t\t\t\trelatedTarget: { value: ev.relatedTarget },\n\t\t\t\t})\n\n\t\t\t\tthis.dispatchEvent(blurEvent)\n\t\t\t})\n\t}\n\n\t/**\n\t * Set up autofill detection\n\t */\n\tprivate setupAutofillDetection() {\n\t\t// Detect autofill animation (Chrome, etc.)\n\t\tfromEvent<AnimationEvent>(this.inputElement, 'animationstart')\n\t\t\t.pipe(\n\t\t\t\tfilter(ev => ev.animationName === 'onAutoFillStart'),\n\t\t\t\ttakeUntil(this.disconnecting),\n\t\t\t)\n\t\t\t.subscribe(ev => {\n\t\t\t\tconst { value } = ev.target as HTMLInputElement\n\t\t\t\tthis.value = value\n\t\t\t\tthis.isAutofilled = true\n\t\t\t\tthis.dirty = this.value !== this.defaultValue\n\n\t\t\t\t// Dispatch autofill event for integration with autofill systems\n\t\t\t\tthis.dispatchEvent(\n\t\t\t\t\tnew CustomEvent('autofill', {\n\t\t\t\t\t\tdetail: { value },\n\t\t\t\t\t\tbubbles: true,\n\t\t\t\t\t\tcomposed: true,\n\t\t\t\t\t}),\n\t\t\t\t)\n\n\t\t\t\t// Also propagate as a change event like browsers do\n\t\t\t\tthis.emitChange({ value })\n\t\t\t})\n\n\t\t// Detect end of autofill (Chrome)\n\t\tfromEvent<AnimationEvent>(this.inputElement, 'animationstart')\n\t\t\t.pipe(\n\t\t\t\tfilter(ev => ev.animationName === 'onAutoFillCancel'),\n\t\t\t\ttakeUntil(this.disconnecting),\n\t\t\t)\n\t\t\t.subscribe(() => {\n\t\t\t\tthis.isAutofilled = false\n\t\t\t})\n\t}\n\n\t/**\n\t * Set up enter key event handling\n\t */\n\tprivate setupEnterKeyEvents() {\n\t\t// Listen for Enter on keydown\n\t\tfromEvent<KeyboardEvent>(this.inputElement, 'keydown')\n\t\t\t.pipe(\n\t\t\t\tfilter(ev => ev.key === 'Enter'),\n\t\t\t\ttakeUntil(this.disconnecting),\n\t\t\t)\n\t\t\t.subscribe(ev => {\n\t\t\t\tconst { value } = ev.target as HTMLInputElement\n\t\t\t\t\n\t\t\t\t// Update value if changed\n\t\t\t\tif (this.value !== value) {\n\t\t\t\t\tthis.value = value\n\t\t\t\t\tthis.dirty = this.value !== this.defaultValue\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t// Blur the input to trigger change event naturally\n\t\t\t\t// This mimics what happens when you tab out of the field\n\t\t\t\tthis.inputElement.blur()\n\n\t\t\t\t// Dispatch enhanced enter event\n\t\t\t\tconst enterEvent = new CustomEvent<EventDetails>('enter', {\n\t\t\t\t\tdetail: { value: this.value },\n\t\t\t\t\tbubbles: true,\n\t\t\t\t\tcomposed: true,\n\t\t\t\t})\n\n\t\t\t\t// Add extra keyboard event props\n\t\t\t\tObject.defineProperties(enterEvent, {\n\t\t\t\t\tkey: { value: 'Enter' },\n\t\t\t\t\tcode: { value: 'Enter' },\n\t\t\t\t\tkeyCode: { value: 13 },\n\t\t\t\t\twhich: { value: 13 },\n\t\t\t\t})\n\n\t\t\t\tthis.dispatchEvent(enterEvent)\n\t\t\t})\n\t}\n\n\t// ----------------------------\n\t// F) Utility Methods\n\t// ----------------------------\n\t/** Selects all text within the input. */\n\tpublic select() {\n\t\treturn this.inputRef.value?.select()\n\t}\n\n\t/** Returns the native validity state of the inner <input>. */\n\tpublic getValidity(): ValidityState | undefined {\n\t\treturn this.inputRef.value?.validity\n\t}\n\n\t/**\n\t * Sets the selection range. Mirrors native input.setSelectionRange\n\t */\n\tpublic setSelectionRange(start: number, end: number, direction?: 'forward' | 'backward' | 'none') {\n\t\tthis.inputRef.value?.setSelectionRange(start, end, direction)\n\t}\n\n\t/**\n\t * Returns the selected text within the input (start position)\n\t */\n\tpublic get selectionStart(): number | null {\n\t\treturn this.inputRef.value?.selectionStart ?? null\n\t}\n\n\t/**\n\t * Returns the selected text within the input (end position)\n\t */\n\tpublic get selectionEnd(): number | null {\n\t\treturn this.inputRef.value?.selectionEnd ?? null\n\t}\n\n\t/**\n\t * Returns the direction of selection\n\t */\n\tpublic get selectionDirection(): 'forward' | 'backward' | 'none' | null {\n\t\treturn this.inputRef.value?.selectionDirection ?? null\n\t}\n\n\t/**\n\t * Sets the range of text to be selected.\n\t */\n\tpublic setRangeText(\n\t\treplacement: string,\n\t\tstart?: number,\n\t\tend?: number,\n\t\tselectMode?: 'select' | 'start' | 'end' | 'preserve',\n\t) {\n\t\tif (start !== undefined && end !== undefined) {\n\t\t\tthis.inputRef.value?.setRangeText(replacement, start, end, selectMode)\n\t\t} else {\n\t\t\tthis.inputRef.value?.setRangeText(replacement)\n\t\t}\n\t}\n\n\t/**\n\t * Override to forward focus to the internal <input>.\n\t * Also dispatch a 'focus' event for external listeners.\n\t */\n\tpublic override focus(options?: FocusOptions) {\n\t\tthis.inputRef.value?.focus(options)\n\t\tthis.dispatchEvent(new Event('focus'))\n\t}\n\n\t/**\n\t * Override to forward clicks to the internal <input>.\n\t * Also dispatch a 'click' event for external listeners.\n\t */\n\tpublic override click() {\n\t\tthis.inputRef.value?.click()\n\t\tthis.dispatchEvent(new Event('click'))\n\t}\n\n\t/** Forward blur to the internal <input>. */\n\tpublic override blur() {\n\t\tthis.inputRef.value?.blur()\n\t\tthis.dispatchEvent(new Event('blur'))\n\t}\n\n\t// ----------------------------\n\t// G) Rendering\n\t// ----------------------------\n\tprotected override render() {\n\t\t// Determine height and padding based on size\n\t\tconst getHeightAndPadding = () => {\n\t\t\tswitch (this.size) {\n\t\t\t\tcase 'sm':\n\t\t\t\t\treturn {\n\t\t\t\t\t\theight: '40px',\n\t\t\t\t\t\tpadding: '0 8px',\n\t\t\t\t\t\tfontSize: '0.875rem', // 14px\n\t\t\t\t\t}\n\t\t\t\tcase 'lg':\n\t\t\t\t\treturn {\n\t\t\t\t\t\theight: '60px',\n\t\t\t\t\t\tpadding: '0 20px',\n\t\t\t\t\t\tfontSize: '1.125rem', // 18px\n\t\t\t\t\t}\n\t\t\t\tcase 'md':\n\t\t\t\tdefault:\n\t\t\t\t\treturn {\n\t\t\t\t\t\theight: '50px',\n\t\t\t\t\t\tpadding: '0 16px',\n\t\t\t\t\t\tfontSize: '1rem', // 16px\n\t\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tconst { height, padding, fontSize } = getHeightAndPadding()\n\n\t\t// Check if it's a date-type input\n\t\tconst isDateType = ['date', 'datetime-local', 'time', 'month', 'week'].includes(this.type)\n\n\t\tconst inputClasses = {\n\t\t\t// Base styles\n\t\t\t'block w-full min-w-0 rounded-[8px] border-0 bg-surface-highest text-surface-on': true,\n\t\t\t// Focus styles\n\t\t\t'outline-secondary-default focus:outline-1': true,\n\t\t\t// Disabled styles\n\t\t\t'disabled:opacity-40 disabled:cursor-not-allowed': true,\n\t\t\t// Placeholder\n\t\t\t'placeholder:text-muted': true,\n\t\t\t// Ring styles\n\t\t\t'ring-0 ring-inset focus:ring-1 focus:ring-inset': true,\n\t\t\t// Ring colors based on error state\n\t\t\t'ring-secondary-default ring-outline focus:ring-secondary-default': !this.error,\n\t\t\t'ring-error-default focus:ring-error-default': this.error,\n\t\t\t// Readonly styles\n\t\t\t'caret-transparent focus:outline-hidden cursor-pointer select-none': this.readonly,\n\t\t\t'cursor-pointer': this.clickable,\n\t\t\t// Text alignment (date inputs always left-aligned)\n\t\t\t'text-left': this.align === 'left' || isDateType,\n\t\t\t'text-center': this.align === 'center' && !isDateType,\n\t\t\t'text-right': this.align === 'right' && !isDateType,\n\t\t\t// Autofill\n\t\t\tautofilled: this.isAutofilled,\n\t\t}\n\n\t\tconst labelClasses = {\n\t\t\t'block mb-1 font-medium': true,\n\t\t\t'opacity-40': this.disabled,\n\t\t\t'text-sm': this.size === 'sm',\n\t\t\t'text-base': this.size === 'md',\n\t\t\t'text-lg': this.size === 'lg',\n\t\t\t'text-primary-default': !this.error,\n\t\t\t'text-error-default': this.error,\n\t\t}\n\n\t\tconst styles = {\n\t\t\theight,\n\t\t\tpadding,\n\t\t\tfontSize,\n\t\t\t// Ensure vertical centering for all input types\n\t\t\tlineHeight: height,\n\t\t}\n\n\t\t/**\n\t\t * - If `this.label` is present, we render a proper `<label for=\"${this.id}\">`.\n\t\t * - If not, we add an aria-label to the <input> for better accessibility.\n\t\t * - If there's a `hint`, we reference it via aria-describedby.\n\t\t * - If there's an error, we set aria-invalid and could set aria-errormessage.\n\t\t */\n\t\treturn html`\n\t\t\t<div class=\"w-full min-w-0 ${isDateType ? 'date-input-container' : ''}\">\n\t\t\t\t${when(\n\t\t\t\t\tthis.label,\n\t\t\t\t\t() => html`\n\t\t\t\t\t\t<label\n\t\t\t\t\t\t\tfor=${this.id}\n\t\t\t\t\t\t\tclass=${this.classMap(labelClasses)}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t${this.label}\n\t\t\t\t\t\t</label>\n\t\t\t\t\t`,\n\t\t\t\t)}\n\n\t\t\t\t<input\n\t\t\t\t\t${ref(this.inputRef)}\n\t\t\t\t\tid=${this.id}\n\t\t\t\t\tname=${this.name}\n\t\t\t\t\tclass=${this.classMap(inputClasses)}\n\t\t\t\t\tstyle=${this.styleMap(styles)}\n\t\t\t\t\t.value=${this.value}\n\t\t\t\t\t.type=${this.type}\n\t\t\t\t\t.autocomplete=${this.autocomplete}\n\t\t\t\t\t.spellcheck=${this.spellcheck}\n\t\t\t\t\tplaceholder=${this.placeholder}\n\t\t\t\t\tinputmode=${ifDefined(this.inputmode)}\n\t\t\t\t\tpattern=${ifDefined(this.pattern)}\n\t\t\t\t\tstep=${ifDefined(this.step)}\n\t\t\t\t\tminlength=${ifDefined(this.minlength)}\n\t\t\t\t\tmaxlength=${ifDefined(this.maxlength)}\n\t\t\t\t\tmin=${ifDefined(this.min)}\n\t\t\t\t\tmax=${ifDefined(this.max)}\n\t\t\t\t\tlist=${ifDefined(this.list)}\n\t\t\t\t\t?required=${this.required}\n\t\t\t\t\t?disabled=${this.disabled}\n\t\t\t\t\t?readonly=${this.readonly}\n\t\t\t\t\taria-invalid=${this.error ? 'true' : 'false'}\n\t\t\t\t\taria-required=${this.required ? 'true' : 'false'}\n\t\t\t\t\taria-labelledby=${this.label ? `label-${this.id}` : nothing}\n\t\t\t\t\taria-describedby=${this.hint || this.validationMessage ? `hint-${this.id}` : nothing}\n\t\t\t\t\taria-label=${ifDefined(!this.label ? this.placeholder || 'Input' : undefined)}\n\t\t\t\t/>\n\n\t\t\t\t${when(\n\t\t\t\t\tthis.hint || (this.error && this.validationMessage),\n\t\t\t\t\t() => html`\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tid=\"hint-${this.id}\"\n\t\t\t\t\t\t\tclass=\"mt-1 text-sm ${this.error ? 'text-error-default' : 'text-surface-onVariant'}\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t${this.error && this.validationMessage ? this.validationMessage : this.hint}\n\t\t\t\t\t\t</div>\n\t\t\t\t\t`,\n\t\t\t\t)}\n\t\t\t</div>\n\t\t`\n\t}\n}\n\n/**\n * Register the component with the legacy tag name for backward compatibility\n * @prop {string} label - Label text for the form field (inherited from FormFieldMixin)\n * @prop {boolean} required - Whether the field is required (inherited from FormFieldMixin)\n * @prop {boolean} disabled - Whether the field is disabled (inherited from FormFieldMixin)\n * @prop {boolean} readonly - Whether the field is read-only (inherited from FormFieldMixin)\n * @prop {boolean} error - Whether the field is in an error state (inherited from FormFieldMixin)\n * @prop {string} validationMessage - The validation message to display (inherited from FormFieldMixin)\n * @prop {string} hint - Optional hint text to display below the field (inherited from FormFieldMixin)\n */\n@customElement('sch-input')\nexport class SchmancyInputCompat extends SchmancyInput {}\n"],"names":["SchmancyInput","SchmancyFormField","constructor","super","arguments","this","value","type","placeholder","clickable","spellcheck","align","autofocus","autocomplete","tabIndex","size","validateOn","inputRef","createRef","isAutofilled","touched","dirty","submitted","defaultValue","changedProps","id","_idCounter","willUpdate","updated","has","validateInput","hasUpdated","connectedCallback","setupFormIntegration","setupExternalLabelAssociation","form","formResetObserver","MutationObserver","mutations","mutation","attributeName","resetToDefault","observe","attributes","childList","subtree","fromEvent","pipe","takeUntil","disconnecting","subscribe","setupLabelClickListener","document","querySelectorAll","forEach","label","focus","readyState","disconnectedCallback","disconnect","error","validationMessage","dispatchEvent","CustomEvent","bubbles","forceValidation","disabled","shouldValidate","shouldShowValidation","validity","inputElement","customError","valid","hasError","checkValidity","inputValid","parentValid","reportValidity","message","setCustomValidity","firstUpdated","setTimeout","setupInputEvents","setupFocusBlurEvents","setupAutofillDetection","setupEnterKeyEvents","map","ev","inputEvent","target","inputType","data","isComposing","originalEvent","eventData","customEvent","detail","composed","Object","defineProperties","distinctUntilChanged","emitChange","focusEvent","cancelable","relatedTarget","blurEvent","filter","animationName","key","blur","enterEvent","code","keyCode","which","select","getValidity","start","end","direction","setSelectionRange","selectionStart","selectionEnd","selectionDirection","replacement","selectMode","setRangeText","options","Event","click","render","height","padding","fontSize","getHeightAndPadding","isDateType","includes","inputClasses","readonly","autofilled","labelClasses","styles","lineHeight","html","when","classMap","ref","name","styleMap","ifDefined","inputmode","pattern","step","minlength","maxlength","min","max","list","required","nothing","hint","shadowRootOptions","LitElement","delegatesFocus","__decorateClass","property","String","reflect","prototype","Boolean","Number","query","state","customElement","SchmancyInputCompat"],"mappings":"ykBA2DqBA,QAAAA,cAArB,cAA2CC,kqGAA3C,aAAAC,CAAAC,MAAAA,GAAAC,WAUCC,KAAgBC,MAAQ,GAOxBD,KAAOE,KAAiC,OAIxCF,KAAOG,YAAc,GASuBH,KAAOI,UAAAA,GAInDJ,KAAOK,WAAAA,GAOPL,KAAOM,MAAqC,OAuB5CN,KAAOO,UAAAA,GAIPP,KAAOQ,aAAyB,KAMhCR,KAAgBS,SAAW,EAU3BT,KAAOU,KAAkB,KAUzBV,KAAOW,WAA2D,UAalEX,KAAQY,SAAWC,cAUnBb,KAAQc,aAAAA,GAMRd,KAAQe,QAAAA,GAGRf,KAAQgB,SAGRhB,KAAQiB,UAAAA,GAMRjB,KAAQkB,aAAe,EAAA,CAgBJ,WAAWC,EAAAA,CACxBnB,KAAKoB,KACTpB,KAAKoB,GAAK,aAAazB,QAAAA,cAAc0B,cAEtCvB,MAAMwB,WAAWH,CAAAA,CAClB,CAGmB,QAAQA,GAC1BrB,MAAMyB,QAAQJ,CAAAA,EAGVA,EAAaK,IAAI,OAAA,IAEhBxB,KAAKC,QAAUD,KAAKkB,eACvBlB,KAAKgB,MAAAA,IAINhB,KAAKyB,cAAAA,GAAAA,CAIDzB,KAAK0B,YAAcP,EAAaK,IAAI,OAAA,IACxCxB,KAAKkB,aAAelB,KAAKC,MAE3B,CAKA,oBACCH,MAAM6B,kBAAAA,EAGN3B,KAAKkB,aAAelB,KAAKC,MAGzBD,KAAK4B,qBAAAA,EAGL5B,KAAK6B,8BAAAA,CACN,CAKQ,sBA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AAA,GAvIYvK,QAAAA,cAArBmK,EAAA,CADCS,EAAAA,cAAc,gBAAA,CAAA,EACM5K,uBA21BR6K,QAAAA,oBAAN,cAAkC7K,QAAAA,aAAAA,CAAAA,EAA5B6K,QAAAA,oBAANV,EAAA,CADNS,EAAAA,cAAc,cACFC"}
1
+ {"version":3,"file":"input-wZ6ORWru.cjs","sources":["../src/input/input.ts"],"sourcesContent":["import { html, LitElement, nothing, PropertyValueMap } from 'lit'\nimport { customElement, property, query, state } from 'lit/decorators.js'\nimport { ifDefined } from 'lit/directives/if-defined.js'\nimport { createRef, ref } from 'lit/directives/ref.js'\nimport { when } from 'lit/directives/when.js'\nimport { distinctUntilChanged, filter, fromEvent, map, takeUntil } from 'rxjs'\n\nimport { SchmancyFormField } from '@mixins/index'\n\n// Import styles\nimport style from './input.scss?inline'\n\n// If you want to be form-associated, define the type on `ElementInternals`.\ndeclare global {\n\tinterface HTMLElementTagNameMap {\n\t\t'schmancy-input': SchmancyInput\n\t\t'sch-input': SchmancyInput\n\t}\n}\n\ntype EventDetails = {\n\tvalue: string\n}\n\n/**\n * Custom events the component may emit:\n * - 'input': on every keystroke\n * - 'change': on native blur/change\n * - 'enter': specifically when user presses Enter\n */\nexport type SchmancyInputInputEvent = CustomEvent<EventDetails>\nexport type SchmancyInputChangeEvent = CustomEvent<EventDetails>\nexport type SchmancyInputEnterEvent = CustomEvent<EventDetails>\n\n/**\n * Size variants for the input.\n * - sm: Small, compact input (40px height)\n * - md: Medium input (50px height, default)\n * - lg: Large, spacious input (60px height)\n */\nexport type InputSize = 'sm' | 'md' | 'lg'\n\n/**\n * Enhanced version of the SchmancyInput component with improved form integration\n * and compatibility with legacy API.\n *\n * This component uses the native form association API and maintains parity with\n * native input behaviors while providing a stylish, accessible interface.\n *\n * @prop {string} name - Name attribute for form submission (inherited from FormFieldMixin)\n * @prop {string} label - Label text for the form field (inherited from FormFieldMixin)\n * @prop {boolean} required - Whether the field is required (inherited from FormFieldMixin)\n * @prop {boolean} disabled - Whether the field is disabled (inherited from FormFieldMixin)\n * @prop {boolean} readonly - Whether the field is read-only (inherited from FormFieldMixin)\n * @prop {boolean} error - Whether the field is in an error state (inherited from FormFieldMixin)\n * @prop {string} validationMessage - The validation message to display (inherited from FormFieldMixin)\n * @prop {string} hint - Optional hint text to display below the field (inherited from FormFieldMixin)\n */\n@customElement('schmancy-input')\nexport default class SchmancyInput extends SchmancyFormField(style) {\n\t// ----------------------------\n\t// A) Public properties\n\t// ----------------------------\n\n\t/** Auto-incrementing counter for generating unique IDs */\n\tstatic _idCounter = 0\n\n\t/** Override value to be string only for input element */\n\t@property({ type: String, reflect: true })\n\tpublic override value = ''\n\n\n\t/**\n\t * The type of input. (e.g. 'text', 'password', 'email', etc.)\n\t */\n\t@property({ reflect: true })\n\tpublic type: HTMLInputElement['type'] = 'text'\n\n\n\t@property()\n\tpublic placeholder = ''\n\n\n\t/** Pattern validation attribute. */\n\t@property({ type: String, reflect: true })\n\tpublic pattern?: string\n\n\n\t/** If true, we visually show a pointer cursor even if readOnly. */\n\t@property({ type: Boolean, reflect: true }) public clickable = false\n\n\t/** Whether browser spellcheck is enabled. */\n\t@property({ type: Boolean, reflect: true })\n\tpublic spellcheck = false\n\n\t/**\n\t * Text alignment within the input.\n\t * - 'left' | 'center' | 'right'\n\t */\n\t@property({ type: String, reflect: true })\n\tpublic align: 'left' | 'center' | 'right' = 'left'\n\n\t/** inputmode attribute (affects on-screen keyboards in mobile). */\n\t@property()\n\tpublic inputmode?: 'none' | 'text' | 'decimal' | 'numeric' | 'tel' | 'search' | 'email' | 'url'\n\n\t@property({ type: Number, reflect: true })\n\tpublic minlength?: number\n\n\t@property({ type: Number })\n\tpublic maxlength?: number\n\n\t@property()\n\tpublic min?: string\n\n\t@property()\n\tpublic max?: string\n\n\t@property({ type: Number, reflect: true })\n\tpublic step?: number\n\n\t/** If true, auto-focus this input on first render. */\n\t@property({ type: Boolean })\n\tpublic autofocus = false\n\n\t/** Autocomplete/autofill hints. */\n\t@property({ type: String, reflect: true })\n\tpublic autocomplete: AutoFill = 'on'\n\n\t/**\n\t * tabIndex for focusing by tab key. Typically 0 or -1.\n\t */\n\t@property({ type: Number, reflect: true })\n\tpublic override tabIndex = 0\n\n\n\t/**\n\t * The size of the input.\n\t * - 'sm': Small, compact size\n\t * - 'md': Medium size (default)\n\t * - 'lg': Large size\n\t */\n\t@property({ type: String, reflect: true })\n\tpublic size: InputSize = 'md'\n\n\t/**\n\t * Controls when validation should show.\n\t * - 'always' - Always show validation\n\t * - 'touched' - Only show after field has been focused and then blurred\n\t * - 'dirty' - Only show after value has changed\n\t * - 'submitted' - Only show after form submission\n\t */\n\t@property({ type: String })\n\tpublic validateOn: 'always' | 'touched' | 'dirty' | 'submitted' = 'touched'\n\n\t/**\n\t * For datalist support\n\t */\n\t@property({ type: String })\n\tpublic list?: string\n\n\n\t// ----------------------------\n\t// B) Queries & Refs\n\t// ----------------------------\n\t@query('input') private inputElement!: HTMLInputElement\n\tprivate inputRef = createRef<HTMLInputElement>()\n\n\t// ----------------------------\n\t// C) Internal States\n\t// ----------------------------\n\n\t/**\n\t * For integration with browser's autofill support\n\t */\n\t@state()\n\tprivate isAutofilled = false\n\n\t/**\n\t * Track user interaction state for validation\n\t */\n\t@state()\n\tprivate touched = false\n\n\t@state()\n\tprivate dirty = false\n\n\t@state()\n\tprivate submitted = false\n\n\t/**\n\t * Store the default value for reset behavior\n\t */\n\t@state()\n\tprivate defaultValue = ''\n\n\t// ----------------------------\n\t// D) Form-associated logic\n\t// ----------------------------\n\tprotected static shadowRootOptions = {\n\t\t...LitElement.shadowRootOptions,\n\t\tdelegatesFocus: true, // so focus() goes to <input>\n\t}\n\n\tprivate formResetObserver?: MutationObserver\n\n\t/**\n\t * If user did not provide an ID, auto-generate one so <label for=\"...\">\n\t * and various aria-* attributes can reference it.\n\t */\n\tprotected override willUpdate(changedProps: PropertyValueMap<any> | Map<PropertyKey, unknown>) {\n\t\tif (!this.id) {\n\t\t\tthis.id = `sch-input-${SchmancyInput._idCounter++}`\n\t\t}\n\t\tsuper.willUpdate(changedProps)\n\t}\n\n\n\tprotected override updated(changedProps: Map<string, unknown>) {\n\t\tsuper.updated(changedProps)\n\n\t\t// Handle value changes\n\t\tif (changedProps.has('value')) {\n\t\t\t// If value changes from original default, mark as dirty\n\t\t\tif (this.value !== this.defaultValue) {\n\t\t\t\tthis.dirty = true\n\t\t\t}\n\n\t\t\t// Update validation state when value changes\n\t\t\tthis.validateInput()\n\t\t}\n\n\t\t// Store default value if this is the first update\n\t\tif (!this.hasUpdated && changedProps.has('value')) {\n\t\t\tthis.defaultValue = this.value\n\t\t}\n\t}\n\n\t/**\n\t * Connect to the closest form element and set up form integration\n\t */\n\tconnectedCallback() {\n\t\tsuper.connectedCallback()\n\n\t\t// Store initial default value for form reset\n\t\tthis.defaultValue = this.value\n\n\t\t// Set up form integration\n\t\tthis.setupFormIntegration()\n\n\t\t// Setup for external label association\n\t\tthis.setupExternalLabelAssociation()\n\t}\n\n\t/**\n\t * Set up form integration with ElementInternals\n\t */\n\tprivate setupFormIntegration() {\n\t\tif (this.form) {\n\t\t\t// Listen for form reset events\n\t\t\tthis.formResetObserver = new MutationObserver(mutations => {\n\t\t\t\tfor (const mutation of mutations) {\n\t\t\t\t\tif (mutation.type === 'attributes' && mutation.attributeName === 'reset') {\n\t\t\t\t\t\tthis.resetToDefault()\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t})\n\n\t\t\t// Observe the form for reset events\n\t\t\tthis.formResetObserver.observe(this.form, {\n\t\t\t\tattributes: true,\n\t\t\t\tchildList: false,\n\t\t\t\tsubtree: false,\n\t\t\t})\n\n\t\t\t// Use RxJS for form reset events\n\t\t\tfromEvent(this.form, 'reset')\n\t\t\t\t.pipe(takeUntil(this.disconnecting))\n\t\t\t\t.subscribe(() => {\n\t\t\t\t\tthis.resetToDefault()\n\t\t\t\t})\n\n\t\t\t// Use RxJS for form submit events to mark field as submitted\n\t\t\tfromEvent(this.form, 'submit')\n\t\t\t\t.pipe(takeUntil(this.disconnecting))\n\t\t\t\t.subscribe(() => {\n\t\t\t\t\tthis.submitted = true\n\t\t\t\t\t// Validate on form submission\n\t\t\t\t\tthis.validateInput(true)\n\t\t\t\t})\n\t\t}\n\t}\n\n\t/**\n\t * Set up external label association for native HTML label support\n\t */\n\tprivate setupExternalLabelAssociation() {\n\t\tif (this.id) {\n\t\t\tconst setupLabelClickListener = () => {\n\t\t\t\tconst labels = document.querySelectorAll(`label[for=\"${this.id}\"]`)\n\t\t\t\tlabels.forEach(label => {\n\t\t\t\t\t// Use RxJS for label click events\n\t\t\t\t\tfromEvent(label, 'click')\n\t\t\t\t\t\t.pipe(takeUntil(this.disconnecting))\n\t\t\t\t\t\t.subscribe(() => {\n\t\t\t\t\t\t\tthis.focus()\n\t\t\t\t\t\t})\n\t\t\t\t})\n\t\t\t}\n\n\t\t\t// Initialize after DOM is ready\n\t\t\tif (document.readyState === 'complete') {\n\t\t\t\tsetupLabelClickListener()\n\t\t\t} else {\n\t\t\t\t// Use RxJS for DOMContentLoaded event\n\t\t\t\tfromEvent(document, 'DOMContentLoaded')\n\t\t\t\t\t.pipe(takeUntil(this.disconnecting))\n\t\t\t\t\t.subscribe(setupLabelClickListener)\n\t\t\t}\n\t\t}\n\t}\n\n\tdisconnectedCallback() {\n\t\tsuper.disconnectedCallback()\n\n\t\t// Clean up the form observer\n\t\tif (this.formResetObserver) {\n\t\t\tthis.formResetObserver.disconnect()\n\t\t}\n\n\t\t// Note: RxJS subscriptions are automatically cleaned up via takeUntil(this.disconnecting)\n\t\t// No manual removeEventListener calls needed for RxJS-managed events\n\t}\n\n\t/**\n\t * Reset the input to its default state\n\t */\n\tprivate resetToDefault() {\n\t\tthis.value = this.defaultValue\n\t\tthis.touched = false\n\t\tthis.dirty = false\n\t\tthis.submitted = false\n\t\tthis.error = false\n\t\tthis.validationMessage = ''\n\t\tthis.dispatchEvent(new CustomEvent('reset', { bubbles: true }))\n\t}\n\n\t/**\n\t * Determines if validation errors should be shown based on current state\n\t * and validation strategy\n\t */\n\tprivate shouldShowValidation(forceValidation = false): boolean {\n\t\tif (forceValidation) return true\n\n\t\tswitch (this.validateOn) {\n\t\t\tcase 'always':\n\t\t\t\treturn true\n\t\t\tcase 'touched':\n\t\t\t\treturn this.touched\n\t\t\tcase 'dirty':\n\t\t\t\treturn this.dirty\n\t\t\tcase 'submitted':\n\t\t\t\treturn this.submitted\n\t\t\tdefault:\n\t\t\t\treturn this.touched\n\t\t}\n\t}\n\n\n\t/**\n\t * Validate input based on required, pattern, etc.\n\t * This mimics native validation behavior\n\t */\n\tprivate validateInput(forceValidation = false) {\n\t\t// Skip validation for disabled inputs\n\t\tif (this.disabled) return\n\n\t\t// Only show validation errors if we should based on the validation strategy\n\t\tconst shouldValidate = this.shouldShowValidation(forceValidation)\n\n\t\t// Get validity state from internal input if available\n\t\tconst validity: ValidityState = this.inputElement?.validity ?? {\n\t\t\tbadInput: false,\n\t\t\tcustomError: false,\n\t\t\tpatternMismatch: false,\n\t\t\trangeOverflow: false,\n\t\t\trangeUnderflow: false,\n\t\t\tstepMismatch: false,\n\t\t\ttooLong: false,\n\t\t\ttooShort: false,\n\t\t\ttypeMismatch: false,\n\t\t\tvalid: true,\n\t\t\tvalueMissing: false,\n\t\t}\n\n\t\t// Check if the input has an actual validation error (not a custom error)\n\t\tconst hasError = !validity.valid && !validity.customError\n\n\t\tif (shouldValidate && hasError) {\n\t\t\t// There's an error and we should show it\n\t\t\tthis.error = true\n\t\t\tthis.validationMessage = this.inputElement?.validationMessage || ''\n\t\t} else if (validity.valid) {\n\t\t\t// Input is valid, so clear the error state\n\t\t\tthis.error = false\n\n\t\t\t// Only clear validation message if there's no custom error\n\t\t\tif (!validity.customError) {\n\t\t\t\tthis.validationMessage = ''\n\t\t\t}\n\t\t} else if (!shouldValidate) {\n\t\t\t// We shouldn't show validation yet, so clear visual error state\n\t\t\tthis.error = false\n\t\t}\n\n\t\t// The mixin will handle updating internals based on error state\n\t}\n\n\t/**\n\t * Check validity without showing validation UI\n\t */\n\tpublic override checkValidity() {\n\t\t// Check internal input first\n\t\tconst inputValid = this.inputRef.value?.checkValidity() ?? true\n\n\t\t// Call parent implementation for basic validation\n\t\tconst parentValid = super.checkValidity()\n\n\t\treturn inputValid && parentValid\n\t}\n\n\t/**\n\t * Show validation UI and check validity\n\t */\n\tpublic override reportValidity() {\n\t\t// Mark as touched and submitted to show validation\n\t\tthis.touched = true\n\t\tthis.submitted = true\n\n\t\t// First check using native input\n\t\tconst inputValid = this.inputRef.value?.reportValidity() ?? true\n\n\t\t// Update our component's validation state with force=true\n\t\tthis.validateInput(true)\n\n\t\t// Call parent implementation\n\t\tconst parentValid = super.reportValidity()\n\n\t\treturn inputValid && parentValid\n\t}\n\n\t/**\n\t * Set a custom validation error message\n\t */\n\tpublic override setCustomValidity(message: string) {\n\t\t// Set on the native input\n\t\tif (this.inputRef.value) {\n\t\t\tthis.inputRef.value.setCustomValidity(message)\n\t\t}\n\n\t\t// Call parent implementation\n\t\tsuper.setCustomValidity(message)\n\t\t\n\t\t// Update error state based on validation strategy\n\t\tthis.error = message !== '' && this.shouldShowValidation()\n\t}\n\n\t// ----------------------------\n\t// E) Lifecycle Hooks & Event Handlers\n\t// ----------------------------\n\tfirstUpdated() {\n\t\t// Autofocus if desired\n\t\tif (this.autofocus) {\n\t\t\t// Use setTimeout to match browser behavior - autofocus happens after initial rendering\n\t\t\tsetTimeout(() => {\n\t\t\t\tthis.focus()\n\t\t\t}, 0)\n\t\t}\n\n\t\t// Subscribe to input events\n\t\tthis.setupInputEvents()\n\t\tthis.setupFocusBlurEvents()\n\t\tthis.setupAutofillDetection()\n\t\tthis.setupEnterKeyEvents()\n\t}\n\n\t/**\n\t * Set up input event handling for value changes\n\t */\n\tprivate setupInputEvents() {\n\t\tfromEvent<InputEvent>(this.inputElement, 'input')\n\t\t\t.pipe(\n\t\t\t\tmap(ev => {\n\t\t\t\t\t// Capture all input event properties for complete event forwarding\n\t\t\t\t\tconst inputEvent = ev as InputEvent\n\t\t\t\t\tconst target = ev.target as HTMLInputElement\n\t\t\t\t\treturn {\n\t\t\t\t\t\tvalue: target.value,\n\t\t\t\t\t\tinputType: inputEvent.inputType,\n\t\t\t\t\t\tdata: inputEvent.data,\n\t\t\t\t\t\tisComposing: inputEvent.isComposing,\n\t\t\t\t\t\toriginalEvent: ev,\n\t\t\t\t\t}\n\t\t\t\t}),\n\t\t\t\ttakeUntil(this.disconnecting),\n\t\t\t)\n\t\t\t.subscribe(eventData => {\n\t\t\t\t// Update component value\n\t\t\t\tthis.value = eventData.value\n\n\t\t\t\t// Mark as dirty when user types\n\t\t\t\tthis.dirty = this.value !== this.defaultValue\n\n\t\t\t\t// Fire custom 'input' event with extended details\n\t\t\t\tconst customEvent = new CustomEvent<EventDetails>('input', {\n\t\t\t\t\tdetail: { value: eventData.value },\n\t\t\t\t\tbubbles: true,\n\t\t\t\t\tcomposed: true,\n\t\t\t\t})\n\n\t\t\t\t// Add additional properties to match native events more closely\n\t\t\t\tObject.defineProperties(customEvent, {\n\t\t\t\t\tinputType: { value: eventData.inputType },\n\t\t\t\t\tdata: { value: eventData.data },\n\t\t\t\t\tisComposing: { value: eventData.isComposing },\n\t\t\t\t})\n\n\t\t\t\tthis.dispatchEvent(customEvent)\n\n\t\t\t\t// REMOVED: Duplicate change event dispatch that was here\n\t\t\t\t// Run validation like native inputs do on input, but respect the validation strategy\n\t\t\t\tthis.validateInput()\n\t\t\t})\n\n\t\t// Subscribe to native change events (usually on blur)\n\t\tfromEvent<Event>(this.inputElement, 'change')\n\t\t\t.pipe(\n\t\t\t\tmap(ev => (ev.target as HTMLInputElement).value),\n\t\t\t\tdistinctUntilChanged(),\n\t\t\t\ttakeUntil(this.disconnecting),\n\t\t\t)\n\t\t\t.subscribe(value => {\n\t\t\t\tthis.value = value\n\t\t\t\tthis.dirty = this.value !== this.defaultValue\n\n\t\t\t\t// Fire regular change event using mixin helper\n\t\t\t\tthis.emitChange({ value })\n\n\t\t\t\t// Run validation on change like native inputs\n\t\t\t\tthis.validateInput()\n\t\t\t})\n\t}\n\n\t/**\n\t * Set up focus/blur event handling\n\t */\n\tprivate setupFocusBlurEvents() {\n\t\tfromEvent<FocusEvent>(this.inputElement, 'focus')\n\t\t\t.pipe(takeUntil(this.disconnecting))\n\t\t\t.subscribe(ev => {\n\t\t\t\t// Create a custom focus event that includes standard props\n\t\t\t\tconst focusEvent = new CustomEvent('focus', {\n\t\t\t\t\tbubbles: ev.bubbles,\n\t\t\t\t\tcancelable: ev.cancelable,\n\t\t\t\t\tcomposed: ev.composed,\n\t\t\t\t})\n\n\t\t\t\t// Add focus-specific properties\n\t\t\t\tObject.defineProperties(focusEvent, {\n\t\t\t\t\trelatedTarget: { value: ev.relatedTarget },\n\t\t\t\t})\n\n\t\t\t\tthis.dispatchEvent(focusEvent)\n\t\t\t})\n\n\t\tfromEvent<FocusEvent>(this.inputElement, 'blur')\n\t\t\t.pipe(takeUntil(this.disconnecting))\n\t\t\t.subscribe(ev => {\n\t\t\t\t// Mark as touched when field loses focus\n\t\t\t\tthis.touched = true\n\n\t\t\t\t// Run validation on blur like native inputs, respecting validation strategy\n\t\t\t\tif (!this.disabled) {\n\t\t\t\t\tthis.validateInput()\n\t\t\t\t}\n\n\t\t\t\t// Create a custom blur event that includes standard props\n\t\t\t\tconst blurEvent = new CustomEvent('blur', {\n\t\t\t\t\tbubbles: ev.bubbles,\n\t\t\t\t\tcancelable: ev.cancelable,\n\t\t\t\t\tcomposed: ev.composed,\n\t\t\t\t})\n\n\t\t\t\t// Add blur-specific properties\n\t\t\t\tObject.defineProperties(blurEvent, {\n\t\t\t\t\trelatedTarget: { value: ev.relatedTarget },\n\t\t\t\t})\n\n\t\t\t\tthis.dispatchEvent(blurEvent)\n\t\t\t})\n\t}\n\n\t/**\n\t * Set up autofill detection\n\t */\n\tprivate setupAutofillDetection() {\n\t\t// Detect autofill animation (Chrome, etc.)\n\t\tfromEvent<AnimationEvent>(this.inputElement, 'animationstart')\n\t\t\t.pipe(\n\t\t\t\tfilter(ev => ev.animationName === 'onAutoFillStart'),\n\t\t\t\ttakeUntil(this.disconnecting),\n\t\t\t)\n\t\t\t.subscribe(ev => {\n\t\t\t\tconst { value } = ev.target as HTMLInputElement\n\t\t\t\tthis.value = value\n\t\t\t\tthis.isAutofilled = true\n\t\t\t\tthis.dirty = this.value !== this.defaultValue\n\n\t\t\t\t// Dispatch autofill event for integration with autofill systems\n\t\t\t\tthis.dispatchEvent(\n\t\t\t\t\tnew CustomEvent('autofill', {\n\t\t\t\t\t\tdetail: { value },\n\t\t\t\t\t\tbubbles: true,\n\t\t\t\t\t\tcomposed: true,\n\t\t\t\t\t}),\n\t\t\t\t)\n\n\t\t\t\t// Also propagate as a change event like browsers do\n\t\t\t\tthis.emitChange({ value })\n\t\t\t})\n\n\t\t// Detect end of autofill (Chrome)\n\t\tfromEvent<AnimationEvent>(this.inputElement, 'animationstart')\n\t\t\t.pipe(\n\t\t\t\tfilter(ev => ev.animationName === 'onAutoFillCancel'),\n\t\t\t\ttakeUntil(this.disconnecting),\n\t\t\t)\n\t\t\t.subscribe(() => {\n\t\t\t\tthis.isAutofilled = false\n\t\t\t})\n\t}\n\n\t/**\n\t * Set up enter key event handling\n\t */\n\tprivate setupEnterKeyEvents() {\n\t\t// Listen for Enter on keydown\n\t\tfromEvent<KeyboardEvent>(this.inputElement, 'keydown')\n\t\t\t.pipe(\n\t\t\t\tfilter(ev => ev.key === 'Enter'),\n\t\t\t\ttakeUntil(this.disconnecting),\n\t\t\t)\n\t\t\t.subscribe(ev => {\n\t\t\t\tconst { value } = ev.target as HTMLInputElement\n\t\t\t\t\n\t\t\t\t// Update value if changed\n\t\t\t\tif (this.value !== value) {\n\t\t\t\t\tthis.value = value\n\t\t\t\t\tthis.dirty = this.value !== this.defaultValue\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t// Blur the input to trigger change event naturally\n\t\t\t\t// This mimics what happens when you tab out of the field\n\t\t\t\tthis.inputElement.blur()\n\n\t\t\t\t// Dispatch enhanced enter event\n\t\t\t\tconst enterEvent = new CustomEvent<EventDetails>('enter', {\n\t\t\t\t\tdetail: { value: this.value },\n\t\t\t\t\tbubbles: true,\n\t\t\t\t\tcomposed: true,\n\t\t\t\t})\n\n\t\t\t\t// Add extra keyboard event props\n\t\t\t\tObject.defineProperties(enterEvent, {\n\t\t\t\t\tkey: { value: 'Enter' },\n\t\t\t\t\tcode: { value: 'Enter' },\n\t\t\t\t\tkeyCode: { value: 13 },\n\t\t\t\t\twhich: { value: 13 },\n\t\t\t\t})\n\n\t\t\t\tthis.dispatchEvent(enterEvent)\n\t\t\t})\n\t}\n\n\t// ----------------------------\n\t// F) Utility Methods\n\t// ----------------------------\n\t/** Selects all text within the input. */\n\tpublic select() {\n\t\treturn this.inputRef.value?.select()\n\t}\n\n\t/** Returns the native validity state of the inner <input>. */\n\tpublic getValidity(): ValidityState | undefined {\n\t\treturn this.inputRef.value?.validity\n\t}\n\n\t/**\n\t * Sets the selection range. Mirrors native input.setSelectionRange\n\t */\n\tpublic setSelectionRange(start: number, end: number, direction?: 'forward' | 'backward' | 'none') {\n\t\tthis.inputRef.value?.setSelectionRange(start, end, direction)\n\t}\n\n\t/**\n\t * Returns the selected text within the input (start position)\n\t */\n\tpublic get selectionStart(): number | null {\n\t\treturn this.inputRef.value?.selectionStart ?? null\n\t}\n\n\t/**\n\t * Returns the selected text within the input (end position)\n\t */\n\tpublic get selectionEnd(): number | null {\n\t\treturn this.inputRef.value?.selectionEnd ?? null\n\t}\n\n\t/**\n\t * Returns the direction of selection\n\t */\n\tpublic get selectionDirection(): 'forward' | 'backward' | 'none' | null {\n\t\treturn this.inputRef.value?.selectionDirection ?? null\n\t}\n\n\t/**\n\t * Sets the range of text to be selected.\n\t */\n\tpublic setRangeText(\n\t\treplacement: string,\n\t\tstart?: number,\n\t\tend?: number,\n\t\tselectMode?: 'select' | 'start' | 'end' | 'preserve',\n\t) {\n\t\tif (start !== undefined && end !== undefined) {\n\t\t\tthis.inputRef.value?.setRangeText(replacement, start, end, selectMode)\n\t\t} else {\n\t\t\tthis.inputRef.value?.setRangeText(replacement)\n\t\t}\n\t}\n\n\t/**\n\t * Override to forward focus to the internal <input>.\n\t * Also dispatch a 'focus' event for external listeners.\n\t */\n\tpublic override focus(options?: FocusOptions) {\n\t\tthis.inputRef.value?.focus(options)\n\t\tthis.dispatchEvent(new Event('focus'))\n\t}\n\n\t/**\n\t * Override to forward clicks to the internal <input>.\n\t * Also dispatch a 'click' event for external listeners.\n\t */\n\tpublic override click() {\n\t\tthis.inputRef.value?.click()\n\t\tthis.dispatchEvent(new Event('click'))\n\t}\n\n\t/** Forward blur to the internal <input>. */\n\tpublic override blur() {\n\t\tthis.inputRef.value?.blur()\n\t\tthis.dispatchEvent(new Event('blur'))\n\t}\n\n\t// ----------------------------\n\t// G) Rendering\n\t// ----------------------------\n\tprotected override render() {\n\t\t// Determine height and padding based on size\n\t\tconst getHeightAndPadding = () => {\n\t\t\tswitch (this.size) {\n\t\t\t\tcase 'sm':\n\t\t\t\t\treturn {\n\t\t\t\t\t\theight: '40px',\n\t\t\t\t\t\tpadding: '0 8px',\n\t\t\t\t\t\tfontSize: '0.875rem', // 14px\n\t\t\t\t\t}\n\t\t\t\tcase 'lg':\n\t\t\t\t\treturn {\n\t\t\t\t\t\theight: '60px',\n\t\t\t\t\t\tpadding: '0 20px',\n\t\t\t\t\t\tfontSize: '1.125rem', // 18px\n\t\t\t\t\t}\n\t\t\t\tcase 'md':\n\t\t\t\tdefault:\n\t\t\t\t\treturn {\n\t\t\t\t\t\theight: '50px',\n\t\t\t\t\t\tpadding: '0 16px',\n\t\t\t\t\t\tfontSize: '1rem', // 16px\n\t\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tconst { height, padding, fontSize } = getHeightAndPadding()\n\n\t\t// Check if it's a date-type input\n\t\tconst isDateType = ['date', 'datetime-local', 'time', 'month', 'week'].includes(this.type)\n\n\t\tconst inputClasses = {\n\t\t\t// Base styles\n\t\t\t'block w-full min-w-0 rounded-[8px] border-0 bg-surface-highest text-surface-on': true,\n\t\t\t// Focus styles\n\t\t\t'outline-secondary-default focus:outline-1': true,\n\t\t\t// Disabled styles\n\t\t\t'disabled:opacity-40 disabled:cursor-not-allowed': true,\n\t\t\t// Placeholder\n\t\t\t'placeholder:text-muted': true,\n\t\t\t// Ring styles\n\t\t\t'ring-0 ring-inset focus:ring-1 focus:ring-inset': true,\n\t\t\t// Ring colors based on error state\n\t\t\t'ring-secondary-default ring-outline focus:ring-secondary-default': !this.error,\n\t\t\t'ring-error-default focus:ring-error-default': this.error,\n\t\t\t// Readonly styles\n\t\t\t'caret-transparent focus:outline-hidden cursor-pointer select-none': this.readonly,\n\t\t\t'cursor-pointer': this.clickable,\n\t\t\t// Text alignment (date inputs always left-aligned)\n\t\t\t'text-left': this.align === 'left' || isDateType,\n\t\t\t'text-center': this.align === 'center' && !isDateType,\n\t\t\t'text-right': this.align === 'right' && !isDateType,\n\t\t\t// Autofill\n\t\t\tautofilled: this.isAutofilled,\n\t\t}\n\n\t\tconst labelClasses = {\n\t\t\t'block mb-1 font-medium': true,\n\t\t\t'opacity-40': this.disabled,\n\t\t\t'text-sm': this.size === 'sm',\n\t\t\t'text-base': this.size === 'md',\n\t\t\t'text-lg': this.size === 'lg',\n\t\t\t'text-primary-default': !this.error,\n\t\t\t'text-error-default': this.error,\n\t\t}\n\n\t\tconst styles = {\n\t\t\theight,\n\t\t\tpadding,\n\t\t\tfontSize,\n\t\t\t// Ensure vertical centering for all input types\n\t\t\tlineHeight: height,\n\t\t}\n\n\t\t/**\n\t\t * - If `this.label` is present, we render a proper `<label for=\"${this.id}\">`.\n\t\t * - If not, we add an aria-label to the <input> for better accessibility.\n\t\t * - If there's a `hint`, we reference it via aria-describedby.\n\t\t * - If there's an error, we set aria-invalid and could set aria-errormessage.\n\t\t */\n\t\treturn html`\n\t\t\t<div class=\"w-full min-w-0 ${isDateType ? 'date-input-container' : ''}\">\n\t\t\t\t${when(\n\t\t\t\t\tthis.label,\n\t\t\t\t\t() => html`\n\t\t\t\t\t\t<label\n\t\t\t\t\t\t\tfor=${this.id}\n\t\t\t\t\t\t\tclass=${this.classMap(labelClasses)}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t${this.label}\n\t\t\t\t\t\t</label>\n\t\t\t\t\t`,\n\t\t\t\t)}\n\n\t\t\t\t<input\n\t\t\t\t\t${ref(this.inputRef)}\n\t\t\t\t\tid=${this.id}\n\t\t\t\t\tname=${this.name}\n\t\t\t\t\tclass=${this.classMap(inputClasses)}\n\t\t\t\t\tstyle=${this.styleMap(styles)}\n\t\t\t\t\t.value=${this.value}\n\t\t\t\t\t.type=${this.type}\n\t\t\t\t\t.autocomplete=${this.autocomplete}\n\t\t\t\t\t.spellcheck=${this.spellcheck}\n\t\t\t\t\tplaceholder=${this.placeholder}\n\t\t\t\t\tinputmode=${ifDefined(this.inputmode)}\n\t\t\t\t\tpattern=${ifDefined(this.pattern)}\n\t\t\t\t\tstep=${ifDefined(this.step)}\n\t\t\t\t\tminlength=${ifDefined(this.minlength)}\n\t\t\t\t\tmaxlength=${ifDefined(this.maxlength)}\n\t\t\t\t\tmin=${ifDefined(this.min)}\n\t\t\t\t\tmax=${ifDefined(this.max)}\n\t\t\t\t\tlist=${ifDefined(this.list)}\n\t\t\t\t\t?required=${this.required}\n\t\t\t\t\t?disabled=${this.disabled}\n\t\t\t\t\t?readonly=${this.readonly}\n\t\t\t\t\taria-invalid=${this.error ? 'true' : 'false'}\n\t\t\t\t\taria-required=${this.required ? 'true' : 'false'}\n\t\t\t\t\taria-labelledby=${this.label ? `label-${this.id}` : nothing}\n\t\t\t\t\taria-describedby=${this.hint || this.validationMessage ? `hint-${this.id}` : nothing}\n\t\t\t\t\taria-label=${ifDefined(!this.label ? this.placeholder || 'Input' : undefined)}\n\t\t\t\t/>\n\n\t\t\t\t${when(\n\t\t\t\t\tthis.hint || (this.error && this.validationMessage),\n\t\t\t\t\t() => html`\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tid=\"hint-${this.id}\"\n\t\t\t\t\t\t\tclass=\"mt-1 text-sm ${this.error ? 'text-error-default' : 'text-surface-onVariant'}\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t${this.error && this.validationMessage ? this.validationMessage : this.hint}\n\t\t\t\t\t\t</div>\n\t\t\t\t\t`,\n\t\t\t\t)}\n\t\t\t</div>\n\t\t`\n\t}\n}\n\n/**\n * Register the component with the legacy tag name for backward compatibility\n * @prop {string} label - Label text for the form field (inherited from FormFieldMixin)\n * @prop {boolean} required - Whether the field is required (inherited from FormFieldMixin)\n * @prop {boolean} disabled - Whether the field is disabled (inherited from FormFieldMixin)\n * @prop {boolean} readonly - Whether the field is read-only (inherited from FormFieldMixin)\n * @prop {boolean} error - Whether the field is in an error state (inherited from FormFieldMixin)\n * @prop {string} validationMessage - The validation message to display (inherited from FormFieldMixin)\n * @prop {string} hint - Optional hint text to display below the field (inherited from FormFieldMixin)\n */\n@customElement('sch-input')\nexport class SchmancyInputCompat extends SchmancyInput {}\n"],"names":["SchmancyInput","SchmancyFormField","constructor","super","arguments","this","value","type","placeholder","clickable","spellcheck","align","autofocus","autocomplete","tabIndex","size","validateOn","inputRef","createRef","isAutofilled","touched","dirty","submitted","defaultValue","changedProps","id","_idCounter","willUpdate","updated","has","validateInput","hasUpdated","connectedCallback","setupFormIntegration","setupExternalLabelAssociation","form","formResetObserver","MutationObserver","mutations","mutation","attributeName","resetToDefault","observe","attributes","childList","subtree","fromEvent","pipe","takeUntil","disconnecting","subscribe","setupLabelClickListener","document","querySelectorAll","forEach","label","focus","readyState","disconnectedCallback","disconnect","error","validationMessage","dispatchEvent","CustomEvent","bubbles","forceValidation","disabled","shouldValidate","shouldShowValidation","validity","inputElement","customError","valid","hasError","checkValidity","inputValid","parentValid","reportValidity","message","setCustomValidity","firstUpdated","setTimeout","setupInputEvents","setupFocusBlurEvents","setupAutofillDetection","setupEnterKeyEvents","map","ev","inputEvent","target","inputType","data","isComposing","originalEvent","eventData","customEvent","detail","composed","Object","defineProperties","distinctUntilChanged","emitChange","focusEvent","cancelable","relatedTarget","blurEvent","filter","animationName","key","blur","enterEvent","code","keyCode","which","select","getValidity","start","end","direction","setSelectionRange","selectionStart","selectionEnd","selectionDirection","replacement","selectMode","setRangeText","options","Event","click","render","height","padding","fontSize","getHeightAndPadding","isDateType","includes","inputClasses","readonly","autofilled","labelClasses","styles","lineHeight","html","when","classMap","ref","name","styleMap","ifDefined","inputmode","pattern","step","minlength","maxlength","min","max","list","required","nothing","hint","shadowRootOptions","LitElement","delegatesFocus","__decorateClass","property","String","reflect","prototype","Boolean","Number","query","state","customElement","SchmancyInputCompat"],"mappings":"ykBA2DqBA,QAAAA,cAArB,cAA2CC,gmGAA3C,aAAAC,CAAAC,MAAAA,GAAAC,WAUCC,KAAgBC,MAAQ,GAOxBD,KAAOE,KAAiC,OAIxCF,KAAOG,YAAc,GASuBH,KAAOI,UAAAA,GAInDJ,KAAOK,WAAAA,GAOPL,KAAOM,MAAqC,OAuB5CN,KAAOO,UAAAA,GAIPP,KAAOQ,aAAyB,KAMhCR,KAAgBS,SAAW,EAU3BT,KAAOU,KAAkB,KAUzBV,KAAOW,WAA2D,UAalEX,KAAQY,SAAWC,cAUnBb,KAAQc,aAAAA,GAMRd,KAAQe,QAAAA,GAGRf,KAAQgB,SAGRhB,KAAQiB,UAAAA,GAMRjB,KAAQkB,aAAe,EAAA,CAgBJ,WAAWC,EAAAA,CACxBnB,KAAKoB,KACTpB,KAAKoB,GAAK,aAAazB,QAAAA,cAAc0B,cAEtCvB,MAAMwB,WAAWH,CAAAA,CAClB,CAGmB,QAAQA,GAC1BrB,MAAMyB,QAAQJ,CAAAA,EAGVA,EAAaK,IAAI,OAAA,IAEhBxB,KAAKC,QAAUD,KAAKkB,eACvBlB,KAAKgB,MAAAA,IAINhB,KAAKyB,cAAAA,GAAAA,CAIDzB,KAAK0B,YAAcP,EAAaK,IAAI,OAAA,IACxCxB,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AAA,EAGAJ,EAAA,CADPQ,EAAAA,MAAAA,CAAAA,EAhImB3K,sBAiIZuK,UAAA,YAAA,CAAA,EAMAJ,EAAA,CADPQ,EAAAA,MAAAA,CAAAA,EAtImB3K,sBAuIZuK,UAAA,eAAA,GAvIYvK,QAAAA,cAArBmK,EAAA,CADCS,EAAAA,cAAc,gBAAA,CAAA,EACM5K,uBA21BR6K,QAAAA,oBAAN,cAAkC7K,QAAAA,aAAAA,CAAAA,EAA5B6K,QAAAA,oBAANV,EAAA,CADNS,EAAAA,cAAc,cACFC"}
package/dist/input.cjs CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./input-DB269a2X.cjs");Object.defineProperty(exports,"SchmancyInput",{enumerable:!0,get:()=>e.SchmancyInput}),Object.defineProperty(exports,"SchmancyInputCompat",{enumerable:!0,get:()=>e.SchmancyInputCompat});
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./input-wZ6ORWru.cjs");Object.defineProperty(exports,"SchmancyInput",{enumerable:!0,get:()=>e.SchmancyInput}),Object.defineProperty(exports,"SchmancyInputCompat",{enumerable:!0,get:()=>e.SchmancyInputCompat});
2
2
  //# sourceMappingURL=input.cjs.map
package/dist/input.js CHANGED
@@ -1,4 +1,4 @@
1
- import { S as m, a as n } from "./input-CYGSlByl.js";
1
+ import { S as m, a as n } from "./input-DLnKAj3B.js";
2
2
  export {
3
3
  m as SchmancyInput,
4
4
  n as SchmancyInputCompat
package/dist/layout.cjs CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./flex-DakK9gco.cjs");Object.defineProperty(exports,"SchmancyFlex",{enumerable:!0,get:()=>e.SchmancyFlex}),Object.defineProperty(exports,"SchmancyFlexV2",{enumerable:!0,get:()=>e.SchmancyFlexV2}),Object.defineProperty(exports,"SchmancyGrid",{enumerable:!0,get:()=>e.SchmancyGrid}),Object.defineProperty(exports,"SchmancyScroll",{enumerable:!0,get:()=>e.SchmancyScroll});
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./flex-BEB1yuMF.cjs");Object.defineProperty(exports,"SchmancyFlex",{enumerable:!0,get:()=>e.SchmancyFlex}),Object.defineProperty(exports,"SchmancyFlexV2",{enumerable:!0,get:()=>e.SchmancyFlexV2}),Object.defineProperty(exports,"SchmancyGrid",{enumerable:!0,get:()=>e.SchmancyGrid}),Object.defineProperty(exports,"SchmancyScroll",{enumerable:!0,get:()=>e.SchmancyScroll});
2
2
  //# sourceMappingURL=layout.cjs.map
package/dist/layout.js CHANGED
@@ -1,4 +1,4 @@
1
- import { S, c as m, a as h, b as l } from "./flex-DUgMxT_9.js";
1
+ import { S, c as m, a as h, b as l } from "./flex-BgcbHlPo.js";
2
2
  export {
3
3
  S as SchmancyFlex,
4
4
  m as SchmancyFlexV2,
@@ -4,7 +4,7 @@ import "rxjs/operators";
4
4
  import "lit/directives/class-map.js";
5
5
  import "lit/directives/style-map.js";
6
6
  import { property as p, queryAssignedElements as m, customElement as h } from "lit/decorators.js";
7
- import { T as y } from "./tailwind.mixin-xIIxrXd8.js";
7
+ import { T as y } from "./tailwind.mixin-DIW0B_of.js";
8
8
  import { n as f, e as v } from "./provide-tcktw8xB.js";
9
9
  import { html as u, css as b } from "lit";
10
10
  import { when as x } from "lit/directives/when.js";
@@ -66,4 +66,4 @@ export {
66
66
  $ as S,
67
67
  r as a
68
68
  };
69
- //# sourceMappingURL=list-BbzeVuby.js.map
69
+ //# sourceMappingURL=list-BegNkhOn.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"list-BbzeVuby.js","sources":["../src/list/context.ts","../src/surface/context.ts","../src/list/list-item.ts","../src/list/list.ts"],"sourcesContent":["import { createContext } from '@lit/context'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nexport const SchmancyListTypeContext = createContext<TSurfaceColor>(undefined)\n","import { createContext } from '@lit/context'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nexport const SchmancySurfaceTypeContext = createContext<TSurfaceColor>('surface')\n","import { consume } from '@lit/context'\nimport { TailwindElement } from '@mixins/index'\nimport { SchmancySurfaceTypeContext } from '@schmancy/surface/context'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nimport { html } from 'lit'\nimport { customElement, property, queryAssignedElements } from 'lit/decorators.js'\nimport { when } from 'lit/directives/when.js'\n\n/**\n * @element schmancy-list-item\n * @slot leading - leading content\n * @slot trailing - trailing content\n * @slot - default content\n */\n@customElement('schmancy-list-item')\nexport class SchmancyListItem extends TailwindElement() {\n\t@consume({ context: SchmancySurfaceTypeContext, subscribe: true })\n\t@property()\n\tvariant: TSurfaceColor\n\n\t@property({ type: Boolean })\n\trounded: boolean\n\n\t@property({ type: Boolean }) readonly: boolean\n\n\t@property({ type: Boolean }) selected: boolean = false\n\n\t@queryAssignedElements({\n\t\tslot: 'leading',\n\t\tflatten: true,\n\t})\n\tprivate leading!: HTMLElement[]\n\n\t@queryAssignedElements({\n\t\tslot: 'trailing',\n\t\tflatten: true,\n\t})\n\tprivate trailing!: HTMLElement[]\n\n\tprotected get imgClasses(): string[] {\n\t\treturn ['h-5', 'w-5', 'sm:h-6', 'sm:w-6', 'object-contain']\n\t}\n\n\tfirstUpdated() {\n\t\tthis.leading?.forEach(img => {\n\t\t\timg.classList.add(...this.imgClasses)\n\t\t})\n\t\tthis.trailing?.forEach(img => {\n\t\t\timg.classList.add(...this.imgClasses)\n\t\t})\n\t}\n\n\trender() {\n\t\tconst classes = {\n\t\t\t'rounded-none': this.rounded === false,\n\t\t\t'rounded-full': this.rounded,\n\t\t\t'relative inset-0 w-full flex items-center min-h-[44px] sm:min-h-[48px] md:min-h-[56px] py-1 px-2 sm:py-2 sm:px-3 md:py-2 md:px-4 text-sm sm:text-base duration-500 transition-colors focus-visible:outline-solid focus-visible:outline-2 focus-visible:outline-offset-0 focus-visible:z-1 outline-secondary-default outline-hidden':\n\t\t\t\ttrue,\n\t\t\t'bg-secondary-container text-secondery-onContainer': this.selected,\n\t\t}\n\n\t\tconst stateLayerClasses = {\n\t\t\t'z-0 duration-500 transition-opacity': true,\n\t\t\t'rounded-none': this.rounded === false,\n\t\t\t'rounded-full': this.rounded,\n\t\t\t'hover:bg-surface-on opacity-[0.08] cursor-pointer absolute inset-0 ': !this.readonly,\n\t\t}\n\t\treturn html` <li .tabIndex=${this.readonly ? -1 : 0} class=${this.classMap(classes)}>\n\t\t\t${when(!this.readonly, () => html` <div class=\"${this.classMap(stateLayerClasses)}\"></div>`)}\n\t\t\t<slot></slot>\n\t\t</li>`\n\t}\n}\n\ndeclare global {\n\tinterface HTMLElementTagNameMap {\n\t\t'schmancy-list-item': SchmancyListItem\n\t}\n}\n","import { provide } from '@lit/context'\nimport { TailwindElement } from '@mixins/index'\nimport { SchmancySurfaceFill } from '@schmancy/surface'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nimport { css, html } from 'lit'\nimport { customElement, property } from 'lit/decorators.js'\nimport { SchmancyListTypeContext } from './context'\n\n/**\n * `<schmancy-list>` component.\n *\n * A list component that wraps its content within a customizable surface.\n * It allows you to set the surface type and fill style, and can optionally\n * enable scrolling behavior by delegating the scroller attribute to the surface.\n *\n * @element schmancy-list\n * @slot - The default slot for list items.\n *\n * @example\n * <schmancy-list surface=\"container\" scroller>\n * <schmancy-list-item>List Item 1</schmancy-list-item>\n * </schmancy-list>\n */\n@customElement('schmancy-list')\nexport class List extends TailwindElement(css`\n\t:host {\n\t\tdisplay: block;\n\t\tpadding-top: 8px;\n\t\tpadding-bottom: 8px;\n\t}\n`) {\n\t/**\n\t * Defines the type or color of the surface used by the component.\n\t * This value is provided to descendant components via context.\n\t *\n\t * @attr surface\n\t * @type {TSurfaceColor}\n\t * @default 'surface'\n\t */\n\t@provide({ context: SchmancyListTypeContext })\n\t@property()\n\tsurface: TSurfaceColor\n\n\t/**\n\t * Determines the fill style of the underlying surface.\n\t *\n\t * @attr fill\n\t * @type {SchmancySurfaceFill}\n\t * @default 'auto'\n\t */\n\t@property({ type: String, reflect: true })\n\tfill: SchmancySurfaceFill = 'auto'\n\n\t/**\n\t * Defines the elevation level of the surface.\n\t *\n\t * @attr elevation\n\t * @type {number}\n\t * @default 0\n\t */\n\t@property({ type: Number })\n\televation: 0 | 1 | 2 | 3 | 4 | 5 = 0\n\n\t/**\n\t * Renders the component's template.\n\t * The list content is wrapped inside a `<schmancy-surface>` element.\n\t * The scroller property is delegated to the surface so that it controls\n\t * the scrollable behavior.\n\t *\n\t * @returns The HTML template for the component.\n\t */\n\trender() {\n\t\treturn html`\n\t\t\t<schmancy-surface .elevation=${this.elevation} .fill=${this.fill} type=${this.surface}>\n\t\t\t\t<ul>\n\t\t\t\t\t<slot></slot>\n\t\t\t\t</ul>\n\t\t\t</schmancy-surface>\n\t\t`\n\t}\n}\n\ndeclare global {\n\tinterface HTMLElementTagNameMap {\n\t\t'schmancy-list': List\n\t}\n}\n"],"names":["SchmancyListTypeContext","createContext","SchmancySurfaceTypeContext","SchmancyListItem","TailwindElement","constructor","super","arguments","this","selected","imgClasses","firstUpdated","leading","forEach","img","classList","add","trailing","render","classes","rounded","stateLayerClasses","readonly","html","classMap","when","__decorateClass","consume","context","subscribe","property","prototype","type","Boolean","queryAssignedElements","slot","flatten","customElement","List","css","fill","elevation","surface","provide","String","reflect","Number"],"mappings":";;;;;;;;;;AAEO,MAAMA,IAA0BC,EAAAA,MAA6B,GCAvDC,IAA6BD,EAA6B;;;;;ACahE,IAAME,IAAN,cAA+BC,EAAAA,EAAAA;AAAAA,EAA/B,cAAAC;AAAAC,UAAAA,GAAAC,SAAAA,GAUuBC,KAAAC;EAAoB;AAAA,EAcjD,IAAA,aAAcC;AACb,WAAO,CAAC,OAAO,OAAO,UAAU,UAAU,gBAAA;AAAA,EAC3C;AAAA,EAEA,eAAAC;AACCH,SAAKI,SAASC,QAAQC,CAAAA,MAAAA;AACrBA,MAAAA,EAAIC,UAAUC,IAAAA,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ApBEjC,EAsBJ4B,WAAA,YAAA,CAAA,GAtBI5B,IAANuB,EAAA,CADNW,EAAc,oBAAA,CAAA,GACFlC,CAAAA;;;;;ACSN,IAAMmC,IAAN,cAAmBlC,EAAgBmC;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA,CAAnC,EAAA;AAAA,EAAA,cAAAlC;AAAAC,UAAAA,GAAAC,SAAAA,GA2BNC,KAAAgC,OAA4B,QAU5BhC,KAAAiC,YAAmC;AAAA,EAAA;AAAA,EAUnC,SAAAvB;AACC,WAAOK;AAAAA,kCACyBf,KAAKiC,SAAAA,UAAmBjC,KAAKgC,IAAAA,SAAahC,KAAKkC,OAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA,EAMhF;AAAA;AAtCAhB,EAAA,CAFCiB,EAAQ,EAAEf,SAAS5B,EAAAA,CAAAA,GACnB8B,MAhBWQ,EAiBZP,WAAA,WAAA,CAAA,GAUAL,EAAA,CADCI,EAAS,EAAEE,MAAMY,QAAQC,YAAS,CAAA,CAAA,GA1BvBP,EA2BZP,WAAA,QAAA,IAUAL,EAAA,CADCI,EAAS,EAAEE,MAAMc,YApCNR,EAqCZP,WAAA,aAAA,CAAA,GArCYO,IAANZ,EAAA,CADNW,EAAc,eAAA,CAAA,GACFC,CAAAA;"}
1
+ {"version":3,"file":"list-BegNkhOn.js","sources":["../src/list/context.ts","../src/surface/context.ts","../src/list/list-item.ts","../src/list/list.ts"],"sourcesContent":["import { createContext } from '@lit/context'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nexport const SchmancyListTypeContext = createContext<TSurfaceColor>(undefined)\n","import { createContext } from '@lit/context'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nexport const SchmancySurfaceTypeContext = createContext<TSurfaceColor>('surface')\n","import { consume } from '@lit/context'\nimport { TailwindElement } from '@mixins/index'\nimport { SchmancySurfaceTypeContext } from '@schmancy/surface/context'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nimport { html } from 'lit'\nimport { customElement, property, queryAssignedElements } from 'lit/decorators.js'\nimport { when } from 'lit/directives/when.js'\n\n/**\n * @element schmancy-list-item\n * @slot leading - leading content\n * @slot trailing - trailing content\n * @slot - default content\n */\n@customElement('schmancy-list-item')\nexport class SchmancyListItem extends TailwindElement() {\n\t@consume({ context: SchmancySurfaceTypeContext, subscribe: true })\n\t@property()\n\tvariant: TSurfaceColor\n\n\t@property({ type: Boolean })\n\trounded: boolean\n\n\t@property({ type: Boolean }) readonly: boolean\n\n\t@property({ type: Boolean }) selected: boolean = false\n\n\t@queryAssignedElements({\n\t\tslot: 'leading',\n\t\tflatten: true,\n\t})\n\tprivate leading!: HTMLElement[]\n\n\t@queryAssignedElements({\n\t\tslot: 'trailing',\n\t\tflatten: true,\n\t})\n\tprivate trailing!: HTMLElement[]\n\n\tprotected get imgClasses(): string[] {\n\t\treturn ['h-5', 'w-5', 'sm:h-6', 'sm:w-6', 'object-contain']\n\t}\n\n\tfirstUpdated() {\n\t\tthis.leading?.forEach(img => {\n\t\t\timg.classList.add(...this.imgClasses)\n\t\t})\n\t\tthis.trailing?.forEach(img => {\n\t\t\timg.classList.add(...this.imgClasses)\n\t\t})\n\t}\n\n\trender() {\n\t\tconst classes = {\n\t\t\t'rounded-none': this.rounded === false,\n\t\t\t'rounded-full': this.rounded,\n\t\t\t'relative inset-0 w-full flex items-center min-h-[44px] sm:min-h-[48px] md:min-h-[56px] py-1 px-2 sm:py-2 sm:px-3 md:py-2 md:px-4 text-sm sm:text-base duration-500 transition-colors focus-visible:outline-solid focus-visible:outline-2 focus-visible:outline-offset-0 focus-visible:z-1 outline-secondary-default outline-hidden':\n\t\t\t\ttrue,\n\t\t\t'bg-secondary-container text-secondery-onContainer': this.selected,\n\t\t}\n\n\t\tconst stateLayerClasses = {\n\t\t\t'z-0 duration-500 transition-opacity': true,\n\t\t\t'rounded-none': this.rounded === false,\n\t\t\t'rounded-full': this.rounded,\n\t\t\t'hover:bg-surface-on opacity-[0.08] cursor-pointer absolute inset-0 ': !this.readonly,\n\t\t}\n\t\treturn html` <li .tabIndex=${this.readonly ? -1 : 0} class=${this.classMap(classes)}>\n\t\t\t${when(!this.readonly, () => html` <div class=\"${this.classMap(stateLayerClasses)}\"></div>`)}\n\t\t\t<slot></slot>\n\t\t</li>`\n\t}\n}\n\ndeclare global {\n\tinterface HTMLElementTagNameMap {\n\t\t'schmancy-list-item': SchmancyListItem\n\t}\n}\n","import { provide } from '@lit/context'\nimport { TailwindElement } from '@mixins/index'\nimport { SchmancySurfaceFill } from '@schmancy/surface'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nimport { css, html } from 'lit'\nimport { customElement, property } from 'lit/decorators.js'\nimport { SchmancyListTypeContext } from './context'\n\n/**\n * `<schmancy-list>` component.\n *\n * A list component that wraps its content within a customizable surface.\n * It allows you to set the surface type and fill style, and can optionally\n * enable scrolling behavior by delegating the scroller attribute to the surface.\n *\n * @element schmancy-list\n * @slot - The default slot for list items.\n *\n * @example\n * <schmancy-list surface=\"container\" scroller>\n * <schmancy-list-item>List Item 1</schmancy-list-item>\n * </schmancy-list>\n */\n@customElement('schmancy-list')\nexport class List extends TailwindElement(css`\n\t:host {\n\t\tdisplay: block;\n\t\tpadding-top: 8px;\n\t\tpadding-bottom: 8px;\n\t}\n`) {\n\t/**\n\t * Defines the type or color of the surface used by the component.\n\t * This value is provided to descendant components via context.\n\t *\n\t * @attr surface\n\t * @type {TSurfaceColor}\n\t * @default 'surface'\n\t */\n\t@provide({ context: SchmancyListTypeContext })\n\t@property()\n\tsurface: TSurfaceColor\n\n\t/**\n\t * Determines the fill style of the underlying surface.\n\t *\n\t * @attr fill\n\t * @type {SchmancySurfaceFill}\n\t * @default 'auto'\n\t */\n\t@property({ type: String, reflect: true })\n\tfill: SchmancySurfaceFill = 'auto'\n\n\t/**\n\t * Defines the elevation level of the surface.\n\t *\n\t * @attr elevation\n\t * @type {number}\n\t * @default 0\n\t */\n\t@property({ type: Number })\n\televation: 0 | 1 | 2 | 3 | 4 | 5 = 0\n\n\t/**\n\t * Renders the component's template.\n\t * The list content is wrapped inside a `<schmancy-surface>` element.\n\t * The scroller property is delegated to the surface so that it controls\n\t * the scrollable behavior.\n\t *\n\t * @returns The HTML template for the component.\n\t */\n\trender() {\n\t\treturn html`\n\t\t\t<schmancy-surface .elevation=${this.elevation} .fill=${this.fill} type=${this.surface}>\n\t\t\t\t<ul>\n\t\t\t\t\t<slot></slot>\n\t\t\t\t</ul>\n\t\t\t</schmancy-surface>\n\t\t`\n\t}\n}\n\ndeclare global {\n\tinterface HTMLElementTagNameMap {\n\t\t'schmancy-list': List\n\t}\n}\n"],"names":["SchmancyListTypeContext","createContext","SchmancySurfaceTypeContext","SchmancyListItem","TailwindElement","constructor","super","arguments","this","selected","imgClasses","firstUpdated","leading","forEach","img","classList","add","trailing","render","classes","rounded","stateLayerClasses","readonly","html","classMap","when","__decorateClass","consume","context","subscribe","property","prototype","type","Boolean","queryAssignedElements","slot","flatten","customElement","List","css","fill","elevation","surface","provide","String","reflect","Number"],"mappings":";;;;;;;;;;AAEO,MAAMA,IAA0BC,EAAAA,MAA6B,GCAvDC,IAA6BD,EAA6B;;;;;ACahE,IAAME,IAAN,cAA+BC,EAAAA,EAAAA;AAAAA,EAA/B,cAAAC;AAAAC,UAAAA,GAAAC,SAAAA,GAUuBC,KAAAC;EAAoB;AAAA,EAcjD,IAAA,aAAcC;AACb,WAAO,CAAC,OAAO,OAAO,UAAU,UAAU,gBAAA;AAAA,EAC3C;AAAA,EAEA,eAAAC;AACCH,SAAKI,SAASC,QAAQC,CAAAA,MAAAA;AACrBA,MAAAA,EAAIC,UAAUC,IAAAA,GAAOR,KAAKE,UAAAA;AAAAA,IAAAA,CAAAA,GAE3BF,KAAKS,UAAUJ,QAAQC,CAAAA,MAAAA;AACtBA,MAAAA,EAAIC,UAAUC,IAAAA,GAAOR,KAAKE,UAAAA;AAAAA,IAAAA,CAAAA;AAAAA,EAE5B;AAAA,EAEA,SAAAQ;AACC,UA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,cAAAlC;AAAAC,UAAAA,GAAAC,SAAAA,GA2BNC,KAAAgC,OAA4B,QAU5BhC,KAAAiC,YAAmC;AAAA,EAAA;AAAA,EAUnC,SAAAvB;AACC,WAAOK;AAAAA,kCACyBf,KAAKiC,SAAAA,UAAmBjC,KAAKgC,IAAAA,SAAahC,KAAKkC,OAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA,EAMhF;AAAA;AAtCAhB,EAAA,CAFCiB,EAAQ,EAAEf,SAAS5B,EAAAA,CAAAA,GACnB8B,MAhBWQ,EAiBZP,WAAA,WAAA,CAAA,GAUAL,EAAA,CADCI,EAAS,EAAEE,MAAMY,QAAQC,YAAS,CAAA,CAAA,GA1BvBP,EA2BZP,WAAA,QAAA,IAUAL,EAAA,CADCI,EAAS,EAAEE,MAAMc,YApCNR,EAqCZP,WAAA,aAAA,CAAA,GArCYO,IAANZ,EAAA,CADNW,EAAc,eAAA,CAAA,GACFC,CAAAA;"}
@@ -1,4 +1,4 @@
1
- "use strict";const y=require("./consume-edta5ng5.cjs");require("rxjs"),require("rxjs/operators"),require("lit/directives/class-map.js"),require("lit/directives/style-map.js");const r=require("lit/decorators.js"),m=require("./tailwind.mixin-scDxsqaX.cjs"),d=require("./provide-BxZ2kn_p.cjs"),p=require("lit"),h=require("lit/directives/when.js"),u=d.n(void 0),f=d.n("surface");var g=Object.defineProperty,v=Object.getOwnPropertyDescriptor,a=(t,s,n,i)=>{for(var o,e=i>1?void 0:i?v(s,n):s,l=t.length-1;l>=0;l--)(o=t[l])&&(e=(i?o(s,n,e):o(e))||e);return i&&e&&g(s,n,e),e};exports.SchmancyListItem=class extends m.TailwindElement(){constructor(){super(...arguments),this.selected=!1}get imgClasses(){return["h-5","w-5","sm:h-6","sm:w-6","object-contain"]}firstUpdated(){this.leading?.forEach(t=>{t.classList.add(...this.imgClasses)}),this.trailing?.forEach(t=>{t.classList.add(...this.imgClasses)})}render(){const t={"rounded-none":this.rounded===!1,"rounded-full":this.rounded,"relative inset-0 w-full flex items-center min-h-[44px] sm:min-h-[48px] md:min-h-[56px] py-1 px-2 sm:py-2 sm:px-3 md:py-2 md:px-4 text-sm sm:text-base duration-500 transition-colors focus-visible:outline-solid focus-visible:outline-2 focus-visible:outline-offset-0 focus-visible:z-1 outline-secondary-default outline-hidden":!0,"bg-secondary-container text-secondery-onContainer":this.selected},s={"z-0 duration-500 transition-opacity":!0,"rounded-none":this.rounded===!1,"rounded-full":this.rounded,"hover:bg-surface-on opacity-[0.08] cursor-pointer absolute inset-0 ":!this.readonly};return p.html` <li .tabIndex=${this.readonly?-1:0} class=${this.classMap(t)}>
1
+ "use strict";const y=require("./consume-edta5ng5.cjs");require("rxjs"),require("rxjs/operators"),require("lit/directives/class-map.js"),require("lit/directives/style-map.js");const r=require("lit/decorators.js"),m=require("./tailwind.mixin-3TPVvhYf.cjs"),d=require("./provide-BxZ2kn_p.cjs"),p=require("lit"),h=require("lit/directives/when.js"),u=d.n(void 0),f=d.n("surface");var g=Object.defineProperty,v=Object.getOwnPropertyDescriptor,a=(t,s,n,i)=>{for(var o,e=i>1?void 0:i?v(s,n):s,l=t.length-1;l>=0;l--)(o=t[l])&&(e=(i?o(s,n,e):o(e))||e);return i&&e&&g(s,n,e),e};exports.SchmancyListItem=class extends m.TailwindElement(){constructor(){super(...arguments),this.selected=!1}get imgClasses(){return["h-5","w-5","sm:h-6","sm:w-6","object-contain"]}firstUpdated(){this.leading?.forEach(t=>{t.classList.add(...this.imgClasses)}),this.trailing?.forEach(t=>{t.classList.add(...this.imgClasses)})}render(){const t={"rounded-none":this.rounded===!1,"rounded-full":this.rounded,"relative inset-0 w-full flex items-center min-h-[44px] sm:min-h-[48px] md:min-h-[56px] py-1 px-2 sm:py-2 sm:px-3 md:py-2 md:px-4 text-sm sm:text-base duration-500 transition-colors focus-visible:outline-solid focus-visible:outline-2 focus-visible:outline-offset-0 focus-visible:z-1 outline-secondary-default outline-hidden":!0,"bg-secondary-container text-secondery-onContainer":this.selected},s={"z-0 duration-500 transition-opacity":!0,"rounded-none":this.rounded===!1,"rounded-full":this.rounded,"hover:bg-surface-on opacity-[0.08] cursor-pointer absolute inset-0 ":!this.readonly};return p.html` <li .tabIndex=${this.readonly?-1:0} class=${this.classMap(t)}>
2
2
  ${h.when(!this.readonly,()=>p.html` <div class="${this.classMap(s)}"></div>`)}
3
3
  <slot></slot>
4
4
  </li>`}},a([y.c({context:f,subscribe:!0}),r.property()],exports.SchmancyListItem.prototype,"variant",2),a([r.property({type:Boolean})],exports.SchmancyListItem.prototype,"rounded",2),a([r.property({type:Boolean})],exports.SchmancyListItem.prototype,"readonly",2),a([r.property({type:Boolean})],exports.SchmancyListItem.prototype,"selected",2),a([r.queryAssignedElements({slot:"leading",flatten:!0})],exports.SchmancyListItem.prototype,"leading",2),a([r.queryAssignedElements({slot:"trailing",flatten:!0})],exports.SchmancyListItem.prototype,"trailing",2),exports.SchmancyListItem=a([r.customElement("schmancy-list-item")],exports.SchmancyListItem);var b=Object.defineProperty,x=Object.getOwnPropertyDescriptor,c=(t,s,n,i)=>{for(var o,e=i>1?void 0:i?x(s,n):s,l=t.length-1;l>=0;l--)(o=t[l])&&(e=(i?o(s,n,e):o(e))||e);return i&&e&&b(s,n,e),e};exports.List=class extends m.TailwindElement(p.css`
@@ -14,4 +14,4 @@
14
14
  </ul>
15
15
  </schmancy-surface>
16
16
  `}},c([d.e({context:u}),r.property()],exports.List.prototype,"surface",2),c([r.property({type:String,reflect:!0})],exports.List.prototype,"fill",2),c([r.property({type:Number})],exports.List.prototype,"elevation",2),exports.List=c([r.customElement("schmancy-list")],exports.List),exports.SchmancyListTypeContext=u;
17
- //# sourceMappingURL=list-BQVTFNkq.cjs.map
17
+ //# sourceMappingURL=list-CLKiZ6lk.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"list-BQVTFNkq.cjs","sources":["../src/list/context.ts","../src/surface/context.ts","../src/list/list-item.ts","../src/list/list.ts"],"sourcesContent":["import { createContext } from '@lit/context'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nexport const SchmancyListTypeContext = createContext<TSurfaceColor>(undefined)\n","import { createContext } from '@lit/context'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nexport const SchmancySurfaceTypeContext = createContext<TSurfaceColor>('surface')\n","import { consume } from '@lit/context'\nimport { TailwindElement } from '@mixins/index'\nimport { SchmancySurfaceTypeContext } from '@schmancy/surface/context'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nimport { html } from 'lit'\nimport { customElement, property, queryAssignedElements } from 'lit/decorators.js'\nimport { when } from 'lit/directives/when.js'\n\n/**\n * @element schmancy-list-item\n * @slot leading - leading content\n * @slot trailing - trailing content\n * @slot - default content\n */\n@customElement('schmancy-list-item')\nexport class SchmancyListItem extends TailwindElement() {\n\t@consume({ context: SchmancySurfaceTypeContext, subscribe: true })\n\t@property()\n\tvariant: TSurfaceColor\n\n\t@property({ type: Boolean })\n\trounded: boolean\n\n\t@property({ type: Boolean }) readonly: boolean\n\n\t@property({ type: Boolean }) selected: boolean = false\n\n\t@queryAssignedElements({\n\t\tslot: 'leading',\n\t\tflatten: true,\n\t})\n\tprivate leading!: HTMLElement[]\n\n\t@queryAssignedElements({\n\t\tslot: 'trailing',\n\t\tflatten: true,\n\t})\n\tprivate trailing!: HTMLElement[]\n\n\tprotected get imgClasses(): string[] {\n\t\treturn ['h-5', 'w-5', 'sm:h-6', 'sm:w-6', 'object-contain']\n\t}\n\n\tfirstUpdated() {\n\t\tthis.leading?.forEach(img => {\n\t\t\timg.classList.add(...this.imgClasses)\n\t\t})\n\t\tthis.trailing?.forEach(img => {\n\t\t\timg.classList.add(...this.imgClasses)\n\t\t})\n\t}\n\n\trender() {\n\t\tconst classes = {\n\t\t\t'rounded-none': this.rounded === false,\n\t\t\t'rounded-full': this.rounded,\n\t\t\t'relative inset-0 w-full flex items-center min-h-[44px] sm:min-h-[48px] md:min-h-[56px] py-1 px-2 sm:py-2 sm:px-3 md:py-2 md:px-4 text-sm sm:text-base duration-500 transition-colors focus-visible:outline-solid focus-visible:outline-2 focus-visible:outline-offset-0 focus-visible:z-1 outline-secondary-default outline-hidden':\n\t\t\t\ttrue,\n\t\t\t'bg-secondary-container text-secondery-onContainer': this.selected,\n\t\t}\n\n\t\tconst stateLayerClasses = {\n\t\t\t'z-0 duration-500 transition-opacity': true,\n\t\t\t'rounded-none': this.rounded === false,\n\t\t\t'rounded-full': this.rounded,\n\t\t\t'hover:bg-surface-on opacity-[0.08] cursor-pointer absolute inset-0 ': !this.readonly,\n\t\t}\n\t\treturn html` <li .tabIndex=${this.readonly ? -1 : 0} class=${this.classMap(classes)}>\n\t\t\t${when(!this.readonly, () => html` <div class=\"${this.classMap(stateLayerClasses)}\"></div>`)}\n\t\t\t<slot></slot>\n\t\t</li>`\n\t}\n}\n\ndeclare global {\n\tinterface HTMLElementTagNameMap {\n\t\t'schmancy-list-item': SchmancyListItem\n\t}\n}\n","import { provide } from '@lit/context'\nimport { TailwindElement } from '@mixins/index'\nimport { SchmancySurfaceFill } from '@schmancy/surface'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nimport { css, html } from 'lit'\nimport { customElement, property } from 'lit/decorators.js'\nimport { SchmancyListTypeContext } from './context'\n\n/**\n * `<schmancy-list>` component.\n *\n * A list component that wraps its content within a customizable surface.\n * It allows you to set the surface type and fill style, and can optionally\n * enable scrolling behavior by delegating the scroller attribute to the surface.\n *\n * @element schmancy-list\n * @slot - The default slot for list items.\n *\n * @example\n * <schmancy-list surface=\"container\" scroller>\n * <schmancy-list-item>List Item 1</schmancy-list-item>\n * </schmancy-list>\n */\n@customElement('schmancy-list')\nexport class List extends TailwindElement(css`\n\t:host {\n\t\tdisplay: block;\n\t\tpadding-top: 8px;\n\t\tpadding-bottom: 8px;\n\t}\n`) {\n\t/**\n\t * Defines the type or color of the surface used by the component.\n\t * This value is provided to descendant components via context.\n\t *\n\t * @attr surface\n\t * @type {TSurfaceColor}\n\t * @default 'surface'\n\t */\n\t@provide({ context: SchmancyListTypeContext })\n\t@property()\n\tsurface: TSurfaceColor\n\n\t/**\n\t * Determines the fill style of the underlying surface.\n\t *\n\t * @attr fill\n\t * @type {SchmancySurfaceFill}\n\t * @default 'auto'\n\t */\n\t@property({ type: String, reflect: true })\n\tfill: SchmancySurfaceFill = 'auto'\n\n\t/**\n\t * Defines the elevation level of the surface.\n\t *\n\t * @attr elevation\n\t * @type {number}\n\t * @default 0\n\t */\n\t@property({ type: Number })\n\televation: 0 | 1 | 2 | 3 | 4 | 5 = 0\n\n\t/**\n\t * Renders the component's template.\n\t * The list content is wrapped inside a `<schmancy-surface>` element.\n\t * The scroller property is delegated to the surface so that it controls\n\t * the scrollable behavior.\n\t *\n\t * @returns The HTML template for the component.\n\t */\n\trender() {\n\t\treturn html`\n\t\t\t<schmancy-surface .elevation=${this.elevation} .fill=${this.fill} type=${this.surface}>\n\t\t\t\t<ul>\n\t\t\t\t\t<slot></slot>\n\t\t\t\t</ul>\n\t\t\t</schmancy-surface>\n\t\t`\n\t}\n}\n\ndeclare global {\n\tinterface HTMLElementTagNameMap {\n\t\t'schmancy-list': List\n\t}\n}\n"],"names":["SchmancyListTypeContext","createContext","SchmancySurfaceTypeContext","SchmancyListItem","TailwindElement","super","arguments","this","selected","firstUpdated","leading","forEach","img","classList","add","imgClasses","trailing","render","classes","rounded","stateLayerClasses","readonly","html","classMap","when","__decorateClass","consume","context","subscribe","property","prototype","type","Boolean","queryAssignedElements","slot","flatten","customElement","List","css","constructor","fill","elevation","surface","provide","String","reflect","Number"],"mappings":"wVAEaA,EAA0BC,EAAAA,EAAAA,MAA6B,ECAvDC,EAA6BD,EAAAA,EAA6B,SAAA,kMCa1DE,QAAAA,iBAAN,cAA+BC,EAAAA,gBAAAA,CAAAA,CAA/B,cAAAC,MAAAA,GAAAC,SAAAA,EAUuBC,KAAAC,SAAAA,EAAoB,CAcjD,IAAA,aACC,MAAO,CAAC,MAAO,MAAO,SAAU,SAAU,gBAAA,CAC3C,CAEA,cAAAC,CACCF,KAA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A,CADNW,EAAAA,cAAc,oBAAA,CAAA,EACFjC,0NCSAkC,QAAAA,KAAN,cAAmBjC,EAAAA,gBAAgBkC,EAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA,CAAnC,CAAA,CAAA,aAAAC,CAAAlC,MAAAA,GAAAC,SAAAA,EA2BNC,KAAAiC,KAA4B,OAU5BjC,KAAAkC,UAAmC,CAAA,CAUnC,QAAAxB,CACC,OAAOK,EAAAA;AAAAA,kCACyBf,KAAKkC,SAAAA,UAAmBlC,KAAKiC,IAAAA,SAAajC,KAAKmC,OAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA,GAMhF,CAAA,EAtCAjB,EAAA,CAFCkB,IAAQ,CAAEhB,QAAS3B,CAAAA,CAAAA,EACnB6B,EAAAA,SAAAA,CAAAA,EAhBWQ,aAiBZP,UAAA,UAAA,CAAA,EAUAL,EAAA,CADCI,EAAAA,SAAS,CAAEE,KAAMa,OAAQC,QAAAA,EAAS,CAAA,CAAA,EA1BvBR,aA2BZP,UAAA,OAAA,CAAA,EAUAL,EAAA,CADCI,WAAS,CAAEE,KAAMe,MAAAA,CAAAA,CAAAA,EApCNT,aAqCZP,UAAA,YAAA,CAAA,EArCYO,QAAAA,KAANZ,EAAA,CADNW,EAAAA,cAAc,eAAA,CAAA,EACFC"}
1
+ {"version":3,"file":"list-CLKiZ6lk.cjs","sources":["../src/list/context.ts","../src/surface/context.ts","../src/list/list-item.ts","../src/list/list.ts"],"sourcesContent":["import { createContext } from '@lit/context'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nexport const SchmancyListTypeContext = createContext<TSurfaceColor>(undefined)\n","import { createContext } from '@lit/context'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nexport const SchmancySurfaceTypeContext = createContext<TSurfaceColor>('surface')\n","import { consume } from '@lit/context'\nimport { TailwindElement } from '@mixins/index'\nimport { SchmancySurfaceTypeContext } from '@schmancy/surface/context'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nimport { html } from 'lit'\nimport { customElement, property, queryAssignedElements } from 'lit/decorators.js'\nimport { when } from 'lit/directives/when.js'\n\n/**\n * @element schmancy-list-item\n * @slot leading - leading content\n * @slot trailing - trailing content\n * @slot - default content\n */\n@customElement('schmancy-list-item')\nexport class SchmancyListItem extends TailwindElement() {\n\t@consume({ context: SchmancySurfaceTypeContext, subscribe: true })\n\t@property()\n\tvariant: TSurfaceColor\n\n\t@property({ type: Boolean })\n\trounded: boolean\n\n\t@property({ type: Boolean }) readonly: boolean\n\n\t@property({ type: Boolean }) selected: boolean = false\n\n\t@queryAssignedElements({\n\t\tslot: 'leading',\n\t\tflatten: true,\n\t})\n\tprivate leading!: HTMLElement[]\n\n\t@queryAssignedElements({\n\t\tslot: 'trailing',\n\t\tflatten: true,\n\t})\n\tprivate trailing!: HTMLElement[]\n\n\tprotected get imgClasses(): string[] {\n\t\treturn ['h-5', 'w-5', 'sm:h-6', 'sm:w-6', 'object-contain']\n\t}\n\n\tfirstUpdated() {\n\t\tthis.leading?.forEach(img => {\n\t\t\timg.classList.add(...this.imgClasses)\n\t\t})\n\t\tthis.trailing?.forEach(img => {\n\t\t\timg.classList.add(...this.imgClasses)\n\t\t})\n\t}\n\n\trender() {\n\t\tconst classes = {\n\t\t\t'rounded-none': this.rounded === false,\n\t\t\t'rounded-full': this.rounded,\n\t\t\t'relative inset-0 w-full flex items-center min-h-[44px] sm:min-h-[48px] md:min-h-[56px] py-1 px-2 sm:py-2 sm:px-3 md:py-2 md:px-4 text-sm sm:text-base duration-500 transition-colors focus-visible:outline-solid focus-visible:outline-2 focus-visible:outline-offset-0 focus-visible:z-1 outline-secondary-default outline-hidden':\n\t\t\t\ttrue,\n\t\t\t'bg-secondary-container text-secondery-onContainer': this.selected,\n\t\t}\n\n\t\tconst stateLayerClasses = {\n\t\t\t'z-0 duration-500 transition-opacity': true,\n\t\t\t'rounded-none': this.rounded === false,\n\t\t\t'rounded-full': this.rounded,\n\t\t\t'hover:bg-surface-on opacity-[0.08] cursor-pointer absolute inset-0 ': !this.readonly,\n\t\t}\n\t\treturn html` <li .tabIndex=${this.readonly ? -1 : 0} class=${this.classMap(classes)}>\n\t\t\t${when(!this.readonly, () => html` <div class=\"${this.classMap(stateLayerClasses)}\"></div>`)}\n\t\t\t<slot></slot>\n\t\t</li>`\n\t}\n}\n\ndeclare global {\n\tinterface HTMLElementTagNameMap {\n\t\t'schmancy-list-item': SchmancyListItem\n\t}\n}\n","import { provide } from '@lit/context'\nimport { TailwindElement } from '@mixins/index'\nimport { SchmancySurfaceFill } from '@schmancy/surface'\nimport { TSurfaceColor } from '@schmancy/types/surface'\nimport { css, html } from 'lit'\nimport { customElement, property } from 'lit/decorators.js'\nimport { SchmancyListTypeContext } from './context'\n\n/**\n * `<schmancy-list>` component.\n *\n * A list component that wraps its content within a customizable surface.\n * It allows you to set the surface type and fill style, and can optionally\n * enable scrolling behavior by delegating the scroller attribute to the surface.\n *\n * @element schmancy-list\n * @slot - The default slot for list items.\n *\n * @example\n * <schmancy-list surface=\"container\" scroller>\n * <schmancy-list-item>List Item 1</schmancy-list-item>\n * </schmancy-list>\n */\n@customElement('schmancy-list')\nexport class List extends TailwindElement(css`\n\t:host {\n\t\tdisplay: block;\n\t\tpadding-top: 8px;\n\t\tpadding-bottom: 8px;\n\t}\n`) {\n\t/**\n\t * Defines the type or color of the surface used by the component.\n\t * This value is provided to descendant components via context.\n\t *\n\t * @attr surface\n\t * @type {TSurfaceColor}\n\t * @default 'surface'\n\t */\n\t@provide({ context: SchmancyListTypeContext })\n\t@property()\n\tsurface: TSurfaceColor\n\n\t/**\n\t * Determines the fill style of the underlying surface.\n\t *\n\t * @attr fill\n\t * @type {SchmancySurfaceFill}\n\t * @default 'auto'\n\t */\n\t@property({ type: String, reflect: true })\n\tfill: SchmancySurfaceFill = 'auto'\n\n\t/**\n\t * Defines the elevation level of the surface.\n\t *\n\t * @attr elevation\n\t * @type {number}\n\t * @default 0\n\t */\n\t@property({ type: Number })\n\televation: 0 | 1 | 2 | 3 | 4 | 5 = 0\n\n\t/**\n\t * Renders the component's template.\n\t * The list content is wrapped inside a `<schmancy-surface>` element.\n\t * The scroller property is delegated to the surface so that it controls\n\t * the scrollable behavior.\n\t *\n\t * @returns The HTML template for the component.\n\t */\n\trender() {\n\t\treturn html`\n\t\t\t<schmancy-surface .elevation=${this.elevation} .fill=${this.fill} type=${this.surface}>\n\t\t\t\t<ul>\n\t\t\t\t\t<slot></slot>\n\t\t\t\t</ul>\n\t\t\t</schmancy-surface>\n\t\t`\n\t}\n}\n\ndeclare global {\n\tinterface HTMLElementTagNameMap {\n\t\t'schmancy-list': List\n\t}\n}\n"],"names":["SchmancyListTypeContext","createContext","SchmancySurfaceTypeContext","SchmancyListItem","TailwindElement","super","arguments","this","selected","firstUpdated","leading","forEach","img","classList","add","imgClasses","trailing","render","classes","rounded","stateLayerClasses","readonly","html","classMap","when","__decorateClass","consume","context","subscribe","property","prototype","type","Boolean","queryAssignedElements","slot","flatten","customElement","List","css","constructor","fill","elevation","surface","provide","String","reflect","Number"],"mappings":"wVAEaA,EAA0BC,EAAAA,EAAAA,MAA6B,ECAvDC,EAA6BD,EAAAA,EAA6B,SAAA,kMCa1DE,QAAAA,iBAAN,cAA+BC,EAAAA,gBAAAA,CAAAA,CAA/B,cAAAC,MAAAA,GAAAC,SAAAA,EAUuBC,KAAAC,SAAAA,EAAoB,CAcjD,IAAA,aACC,MAAO,CAAC,MAAO,MAAO,SAAU,SAAU,gBAAA,CAC3C,CAEA,cAAAC,CACCF,KAAKG,SAASC,QAAQC,IACrBA,EAAIC,UAAUC,IAAAA,GAAOP,KAAKQ,cAE3BR,KAAKS,UAAUL,QAAQC,GAAAA,CACtBA,EAAIC,UAAUC,IAAAA,GAAOP,KAAKQ,UAAAA,CAAAA,CAAAA,CAE5B,CAEA,QAAAE,CACC,MAAMC,EAAU,CACf,eAAgBX,KAAKY,UAArB,GACA,eAAgBZ,KAAKY,QACrB,qUAAA,GAEA,oDAAqDZ,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,EAAAA;AAAAA,kCACyBf,KAAKkC,SAAAA,UAAmBlC,KAAKiC,IAAAA,SAAajC,KAAKmC,OAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA,GAMhF,CAAA,EAtCAjB,EAAA,CAFCkB,IAAQ,CAAEhB,QAAS3B,CAAAA,CAAAA,EACnB6B,EAAAA,SAAAA,CAAAA,EAhBWQ,aAiBZP,UAAA,UAAA,CAAA,EAUAL,EAAA,CADCI,EAAAA,SAAS,CAAEE,KAAMa,OAAQC,QAAAA,EAAS,CAAA,CAAA,EA1BvBR,aA2BZP,UAAA,OAAA,CAAA,EAUAL,EAAA,CADCI,WAAS,CAAEE,KAAMe,MAAAA,CAAAA,CAAAA,EApCNT,aAqCZP,UAAA,YAAA,CAAA,EArCYO,QAAAA,KAANZ,EAAA,CADNW,EAAAA,cAAc,eAAA,CAAA,EACFC"}
package/dist/list.cjs CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./list-BQVTFNkq.cjs");Object.defineProperty(exports,"List",{enumerable:!0,get:()=>e.List}),Object.defineProperty(exports,"SchmancyListItem",{enumerable:!0,get:()=>e.SchmancyListItem}),exports.SchmancyListTypeContext=e.SchmancyListTypeContext;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./list-CLKiZ6lk.cjs");Object.defineProperty(exports,"List",{enumerable:!0,get:()=>e.List}),Object.defineProperty(exports,"SchmancyListItem",{enumerable:!0,get:()=>e.SchmancyListItem}),exports.SchmancyListTypeContext=e.SchmancyListTypeContext;
2
2
  //# sourceMappingURL=list.cjs.map
package/dist/list.js CHANGED
@@ -1,4 +1,4 @@
1
- import { L as s, a as c, S as e } from "./list-BbzeVuby.js";
1
+ import { L as s, a as c, S as e } from "./list-BegNkhOn.js";
2
2
  export {
3
3
  s as List,
4
4
  c as SchmancyListItem,
@@ -1,2 +1,2 @@
1
- "use strict";const e=require("./tailwind.mixin-scDxsqaX.cjs");exports.$LitElement=t=>{class s extends e.BaseElement(e.TailwindElement(t)){constructor(){super(...arguments),this.disconnectedCallback=()=>{super.disconnectedCallback()}}}return s};
2
- //# sourceMappingURL=litElement.mixin-DzCpXwcY.cjs.map
1
+ "use strict";const e=require("./tailwind.mixin-3TPVvhYf.cjs");exports.$LitElement=t=>{class s extends e.BaseElement(e.TailwindElement(t)){constructor(){super(...arguments),this.disconnectedCallback=()=>{super.disconnectedCallback()}}}return s};
2
+ //# sourceMappingURL=litElement.mixin-CPQYJnK_.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"litElement.mixin-DzCpXwcY.cjs","sources":["../mixins/litElement.mixin.ts"],"sourcesContent":["import { CSSResult, LitElement } from 'lit'\nimport { TailwindElement } from './tailwind.mixin'\nimport { BaseElement, IBaseMixin } from './baseElement'\nimport { Constructor } from './constructor'\n\nexport const $LitElement = <T extends CSSResult>(componentStyle?: T) => {\n\tclass TailwindMixinClass extends BaseElement(TailwindElement(componentStyle)) {\n\t\tdisconnectedCallback = () => {\n\t\t\tsuper.disconnectedCallback()\n\t\t}\n\t}\n\treturn TailwindMixinClass as CustomElementConstructor &\n\t\tConstructor<LitElement> &\n\t\tConstructor<IBaseMixin> /* see \"typing the subclass\" below */\n}\n"],"names":["componentStyle","TailwindMixinClass","BaseElement","TailwindElement","constructor","super","arguments","this","disconnectedCallback"],"mappings":"kFAKiDA,GAAAA,CAChD,MAAMC,UAA2BC,EAAAA,YAAYC,kBAAgBH,CAAAA,CAAAA,CAAAA,CAA7D,aAAAI,CAAAC,MAAAA,GAAAC,SAAAA,EACCC,KAAAC,qBAAuB,IAAA,CACtBH,MAAMG,qBAAAA,CAAAA,CACP,CAAA,CAED,OAAOP,CAAAA"}
1
+ {"version":3,"file":"litElement.mixin-CPQYJnK_.cjs","sources":["../mixins/litElement.mixin.ts"],"sourcesContent":["import { CSSResult, LitElement } from 'lit'\nimport { TailwindElement } from './tailwind.mixin'\nimport { BaseElement, IBaseMixin } from './baseElement'\nimport { Constructor } from './constructor'\n\nexport const $LitElement = <T extends CSSResult>(componentStyle?: T) => {\n\tclass TailwindMixinClass extends BaseElement(TailwindElement(componentStyle)) {\n\t\tdisconnectedCallback = () => {\n\t\t\tsuper.disconnectedCallback()\n\t\t}\n\t}\n\treturn TailwindMixinClass as CustomElementConstructor &\n\t\tConstructor<LitElement> &\n\t\tConstructor<IBaseMixin> /* see \"typing the subclass\" below */\n}\n"],"names":["componentStyle","TailwindMixinClass","BaseElement","TailwindElement","constructor","super","arguments","this","disconnectedCallback"],"mappings":"kFAKiDA,GAAAA,CAChD,MAAMC,UAA2BC,EAAAA,YAAYC,kBAAgBH,CAAAA,CAAAA,CAAAA,CAA7D,aAAAI,CAAAC,MAAAA,GAAAC,SAAAA,EACCC,KAAAC,qBAAuB,IAAA,CACtBH,MAAMG,qBAAAA,CAAAA,CACP,CAAA,CAED,OAAOP,CAAAA"}
@@ -1,4 +1,4 @@
1
- import { B as t, T as r } from "./tailwind.mixin-xIIxrXd8.js";
1
+ import { B as t, T as r } from "./tailwind.mixin-DIW0B_of.js";
2
2
  const n = (s) => {
3
3
  class e extends t(r(s)) {
4
4
  constructor() {
@@ -12,4 +12,4 @@ const n = (s) => {
12
12
  export {
13
13
  n as $
14
14
  };
15
- //# sourceMappingURL=litElement.mixin-BzbZQbxa.js.map
15
+ //# sourceMappingURL=litElement.mixin-DWDPaNoc.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"litElement.mixin-BzbZQbxa.js","sources":["../mixins/litElement.mixin.ts"],"sourcesContent":["import { CSSResult, LitElement } from 'lit'\nimport { TailwindElement } from './tailwind.mixin'\nimport { BaseElement, IBaseMixin } from './baseElement'\nimport { Constructor } from './constructor'\n\nexport const $LitElement = <T extends CSSResult>(componentStyle?: T) => {\n\tclass TailwindMixinClass extends BaseElement(TailwindElement(componentStyle)) {\n\t\tdisconnectedCallback = () => {\n\t\t\tsuper.disconnectedCallback()\n\t\t}\n\t}\n\treturn TailwindMixinClass as CustomElementConstructor &\n\t\tConstructor<LitElement> &\n\t\tConstructor<IBaseMixin> /* see \"typing the subclass\" below */\n}\n"],"names":["$LitElement","componentStyle","TailwindMixinClass","BaseElement","TailwindElement","constructor","super","arguments","this","disconnectedCallback"],"mappings":";AAKO,MAAMA,IAAoCC,CAAAA;EAChD,MAAMC,UAA2BC,EAAYC,EAAgBH,CAAAA,CAAAA,EAAAA;AAAAA,IAA7D,cAAAI;AAAAC,YAAAA,GAAAC,YACCC,KAAAC,uBAAuB;AACtBH,cAAMG,qBAAAA;AAAAA,MAAAA;AAAAA,IACP;AAAA,EAAA;AAED,SAAOP;AAAAA;"}
1
+ {"version":3,"file":"litElement.mixin-DWDPaNoc.js","sources":["../mixins/litElement.mixin.ts"],"sourcesContent":["import { CSSResult, LitElement } from 'lit'\nimport { TailwindElement } from './tailwind.mixin'\nimport { BaseElement, IBaseMixin } from './baseElement'\nimport { Constructor } from './constructor'\n\nexport const $LitElement = <T extends CSSResult>(componentStyle?: T) => {\n\tclass TailwindMixinClass extends BaseElement(TailwindElement(componentStyle)) {\n\t\tdisconnectedCallback = () => {\n\t\t\tsuper.disconnectedCallback()\n\t\t}\n\t}\n\treturn TailwindMixinClass as CustomElementConstructor &\n\t\tConstructor<LitElement> &\n\t\tConstructor<IBaseMixin> /* see \"typing the subclass\" below */\n}\n"],"names":["$LitElement","componentStyle","TailwindMixinClass","BaseElement","TailwindElement","constructor","super","arguments","this","disconnectedCallback"],"mappings":";AAKO,MAAMA,IAAoCC,CAAAA;EAChD,MAAMC,UAA2BC,EAAYC,EAAgBH,CAAAA,CAAAA,EAAAA;AAAAA,IAA7D,cAAAI;AAAAC,YAAAA,GAAAC,YACCC,KAAAC,uBAAuB;AACtBH,cAAMG,qBAAAA;AAAAA,MAAAA;AAAAA,IACP;AAAA,EAAA;AAED,SAAOP;AAAAA;"}
package/dist/mailbox.cjs CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./email-recipients-Bxvu6zi9.cjs");Object.defineProperty(exports,"SchmancyEmailEditor",{enumerable:!0,get:()=>e.SchmancyEmailEditor}),Object.defineProperty(exports,"SchmancyEmailLayoutSelector",{enumerable:!0,get:()=>e.SchmancyEmailLayoutSelector}),Object.defineProperty(exports,"SchmancyEmailRecipients",{enumerable:!0,get:()=>e.SchmancyEmailRecipients}),Object.defineProperty(exports,"SchmancyEmailViewer",{enumerable:!0,get:()=>e.SchmancyEmailViewer}),Object.defineProperty(exports,"SchmancyMailbox",{enumerable:!0,get:()=>e.SchmancyMailbox});
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./email-recipients-Cioc3U0Z.cjs");Object.defineProperty(exports,"SchmancyEmailEditor",{enumerable:!0,get:()=>e.SchmancyEmailEditor}),Object.defineProperty(exports,"SchmancyEmailLayoutSelector",{enumerable:!0,get:()=>e.SchmancyEmailLayoutSelector}),Object.defineProperty(exports,"SchmancyEmailRecipients",{enumerable:!0,get:()=>e.SchmancyEmailRecipients}),Object.defineProperty(exports,"SchmancyEmailViewer",{enumerable:!0,get:()=>e.SchmancyEmailViewer}),Object.defineProperty(exports,"SchmancyMailbox",{enumerable:!0,get:()=>e.SchmancyMailbox});
2
2
  //# sourceMappingURL=mailbox.cjs.map
package/dist/mailbox.js CHANGED
@@ -1,4 +1,4 @@
1
- import { a as m, d as i, c as e, b as S, S as l } from "./email-recipients-DZGMhyg4.js";
1
+ import { a as m, d as i, c as e, b as S, S as l } from "./email-recipients-CmAEJDMC.js";
2
2
  export {
3
3
  m as SchmancyEmailEditor,
4
4
  i as SchmancyEmailLayoutSelector,
@@ -3,7 +3,7 @@ import { tap as c, switchMap as g, catchError as f, finalize as w, takeUntil as
3
3
  import "lit/directives/class-map.js";
4
4
  import "lit/directives/style-map.js";
5
5
  import { property as a, state as m, customElement as M } from "lit/decorators.js";
6
- import { T as x } from "./tailwind.mixin-xIIxrXd8.js";
6
+ import { T as x } from "./tailwind.mixin-DIW0B_of.js";
7
7
  import { css as T, html as d } from "lit";
8
8
  import { createRef as C, ref as I } from "lit/directives/ref.js";
9
9
  import { when as y } from "lit/directives/when.js";
@@ -172,4 +172,4 @@ o([a({ type: String })], t.prototype, "address", 2), o([a({ type: Number })], t.
172
172
  export {
173
173
  t as S
174
174
  };
175
- //# sourceMappingURL=map-CgwU5Px4.js.map
175
+ //# sourceMappingURL=map-CUKZ6LrR.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"map-CgwU5Px4.js","sources":["../src/map/map.ts"],"sourcesContent":["import { TailwindElement } from '@mixins/index'\nimport { css, html } from 'lit'\nimport { customElement, property, state } from 'lit/decorators.js'\nimport { ref, createRef } from 'lit/directives/ref.js'\nimport { when } from 'lit/directives/when.js'\nimport { of, EMPTY, Observable } from 'rxjs'\nimport { switchMap, tap, catchError, takeUntil, finalize, shareReplay } from 'rxjs/operators'\n\ninterface GoogleMapsAPI {\n maps: {\n Map: new (element: HTMLElement, options: any) => any\n Marker: new (options: any) => any\n Geocoder: new () => any\n LatLng: new (lat: number, lng: number) => any\n MapTypeId: {\n ROADMAP: string\n SATELLITE: string\n HYBRID: string\n TERRAIN: string\n }\n }\n}\n\ndeclare global {\n interface Window {\n google?: GoogleMapsAPI\n initGoogleMaps?: () => void\n __schmancyGoogleMapsLoading?: Observable<boolean>\n }\n}\n\n// Singleton for managing Google Maps script loading\nclass GoogleMapsLoader {\n private static loading$?: Observable<boolean>\n\n static load(apiKey: string): Observable<boolean> {\n // If already loaded, return success\n if (window.google?.maps) {\n return of(true)\n }\n\n // If already loading, return the existing observable\n if (this.loading$) {\n return this.loading$\n }\n\n // Create a new loading observable\n this.loading$ = new Observable<boolean>(observer => {\n // Check again if loaded while waiting\n if (window.google?.maps) {\n observer.next(true)\n observer.complete()\n return\n }\n\n const script = document.createElement('script')\n // Using places library instead of geometry for geocoding\n script.src = `https://maps.googleapis.com/maps/api/js?key=${apiKey}&libraries=places&callback=initGoogleMaps&v=weekly`\n script.async = true\n script.defer = true\n\n window.initGoogleMaps = () => {\n observer.next(true)\n observer.complete()\n }\n\n script.onerror = (error) => {\n console.error('Google Maps script loading error:', error)\n observer.error(new Error('Failed to load Google Maps. Please check API key configuration and ensure the domain is authorized.'))\n }\n\n document.head.appendChild(script)\n }).pipe(\n shareReplay(1) // Share the result among all subscribers\n )\n\n return this.loading$\n }\n}\n\n/**\n * `<schmancy-map>` component\n *\n * A Google Maps component with an intuitive API for displaying interactive or static maps.\n * Supports both address strings (with automatic geocoding) and precise coordinates.\n *\n * @element schmancy-map\n *\n * @example\n * <!-- Simple address -->\n * <schmancy-map address=\"Times Square, New York\"></schmancy-map>\n *\n * @example\n * <!-- With coordinates -->\n * <schmancy-map latitude=\"40.758\" longitude=\"-73.985\" zoom=\"17\"></schmancy-map>\n *\n * @example\n * <!-- Satellite view -->\n * <schmancy-map address=\"Grand Canyon\" type=\"satellite\" height=\"500px\"></schmancy-map>\n *\n * @example\n * <!-- Static map -->\n * <schmancy-map address=\"Eiffel Tower, Paris\" interactive=\"false\" controls=\"false\"></schmancy-map>\n */\n@customElement('schmancy-map')\nexport default class SchmancyMap extends TailwindElement(css`\n :host {\n display: block;\n position: relative;\n border-radius: 8px;\n overflow: hidden;\n background-color: var(--schmancy-sys-color-surface-container);\n color: var(--schmancy-sys-color-surface-on);\n }\n \n :host([height]) {\n height: var(--map-height);\n }\n \n .map-container {\n width: 100%;\n height: 100%;\n min-height: 400px;\n }\n \n .loading-container {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 100%;\n height: 100%;\n min-height: 400px;\n background-color: var(--schmancy-sys-color-surface-containerLow);\n }\n \n .error-container {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n width: 100%;\n height: 100%;\n min-height: 400px;\n padding: 24px;\n text-align: center;\n background-color: var(--schmancy-sys-color-surface-containerLow);\n }\n \n .error-icon {\n width: 48px;\n height: 48px;\n margin-bottom: 16px;\n color: var(--schmancy-sys-color-error-default);\n }\n \n .error-title {\n font-size: 18px;\n font-weight: 600;\n margin-bottom: 8px;\n color: var(--schmancy-sys-color-surface-on);\n }\n \n .error-message {\n font-size: 14px;\n color: var(--schmancy-sys-color-surface-onVariant);\n line-height: 1.5;\n }\n`) {\n /**\n * Simple address string that automatically geocodes to display the location.\n * Takes precedence over latitude/longitude if both are provided.\n */\n @property({ type: String })\n address: string = ''\n\n /**\n * Latitude coordinate for precise location.\n * Used when address is not provided.\n */\n @property({ type: Number })\n latitude?: number\n\n /**\n * Longitude coordinate for precise location.\n * Used when address is not provided.\n */\n @property({ type: Number })\n longitude?: number\n\n /**\n * Map zoom level. Higher numbers show more detail.\n * @default 15\n */\n @property({ type: Number })\n zoom: number = 15\n\n /**\n * Height of the map with CSS unit (e.g., \"400px\", \"50vh\").\n * @default \"400px\"\n */\n @property({ type: String, reflect: true })\n height: string = '400px'\n\n /**\n * Whether to show a marker at the location.\n * @default true\n */\n @property({ type: Boolean })\n marker: boolean = true\n\n /**\n * Tooltip text for the location marker.\n */\n @property({ type: String })\n markerTitle: string = ''\n\n /**\n * Map display type.\n * Options: \"roadmap\", \"satellite\", \"hybrid\", \"terrain\"\n * @default \"roadmap\"\n */\n @property({ type: String })\n type: 'roadmap' | 'satellite' | 'hybrid' | 'terrain' = 'roadmap'\n\n /**\n * Whether users can interact with the map (pan, zoom, click).\n * @default true\n */\n @property({ type: Boolean })\n interactive: boolean = true\n\n /**\n * Whether to show map controls (zoom buttons, fullscreen, etc.).\n * @default true\n */\n @property({ type: Boolean })\n controls: boolean = true\n\n /**\n * Google Maps API key. Required for the map to load.\n */\n @property({ type: String })\n apiKey: string = ''\n\n @state() private loading: boolean = false\n @state() private error: string = ''\n\n private mapRef = createRef<HTMLDivElement>()\n private map?: any\n private mapMarker?: any\n private geocoder?: any\n private intersectionObserver?: IntersectionObserver\n private hasLoadedMap = false\n\n connectedCallback() {\n super.connectedCallback()\n \n // Set CSS custom property for height\n this.style.setProperty('--map-height', this.height)\n \n // Only load map when component becomes visible\n this.setupIntersectionObserver()\n }\n\n disconnectedCallback() {\n super.disconnectedCallback()\n if (this.intersectionObserver) {\n this.intersectionObserver.disconnect()\n }\n }\n\n private setupIntersectionObserver() {\n // Load map only when it's visible in the viewport\n this.intersectionObserver = new IntersectionObserver(\n (entries) => {\n entries.forEach(entry => {\n if (entry.isIntersecting && !this.hasLoadedMap) {\n this.hasLoadedMap = true\n this.loadMap()\n // Stop observing after loading\n this.intersectionObserver?.disconnect()\n }\n })\n },\n {\n root: null,\n rootMargin: '50px',\n threshold: 0.01\n }\n )\n \n this.intersectionObserver.observe(this)\n }\n\n private loadMap() {\n of(null).pipe(\n tap(() => {\n this.loading = true\n this.error = ''\n }),\n switchMap(() => {\n if (!this.apiKey) {\n throw new Error('Google Maps API key is required. Please provide it via the apiKey property.')\n }\n return GoogleMapsLoader.load(this.apiKey)\n }),\n switchMap(() => this.getCoordinates()),\n tap((coordinates) => {\n // Store coordinates for later use\n this.pendingCoordinates = coordinates\n }),\n catchError((error) => {\n console.error('Map loading error:', error)\n this.error = error.message || 'Failed to load map'\n return EMPTY\n }),\n finalize(() => {\n this.loading = false\n }),\n takeUntil(this.disconnecting)\n ).subscribe()\n }\n\n private pendingCoordinates?: { lat: number; lng: number }\n\n private getCoordinates() {\n if (this.address) {\n return this.geocodeAddress(this.address)\n }\n\n if (this.latitude !== undefined && this.longitude !== undefined) {\n return of({ lat: this.latitude, lng: this.longitude })\n }\n\n throw new Error('Either address or latitude/longitude coordinates are required')\n }\n\n private geocodeAddress(address: string) {\n if (!this.geocoder) {\n this.geocoder = new window.google!.maps.Geocoder()\n }\n\n return new Promise<{ lat: number; lng: number }>((resolve, reject) => {\n this.geocoder.geocode({ address }, (results: any[], status: string) => {\n if (status === 'OK' && results[0]) {\n const location = results[0].geometry.location\n resolve({\n lat: location.lat(),\n lng: location.lng()\n })\n } else {\n reject(new Error(`Geocoding failed: ${status}`))\n }\n })\n })\n }\n\n private initializeMap(coordinates: { lat: number; lng: number }) {\n if (!this.mapRef.value || !window.google?.maps) {\n return\n }\n\n const mapOptions = {\n center: coordinates,\n zoom: this.zoom,\n mapTypeId: this.getMapTypeId(),\n disableDefaultUI: !this.controls,\n gestureHandling: this.interactive ? 'cooperative' : 'none',\n zoomControl: this.controls,\n mapTypeControl: this.controls,\n scaleControl: this.controls,\n streetViewControl: this.controls,\n rotateControl: this.controls,\n fullscreenControl: this.controls,\n styles: this.interactive ? undefined : [\n {\n featureType: 'poi',\n stylers: [{ visibility: 'off' }]\n }\n ]\n }\n\n this.map = new window.google.maps.Map(this.mapRef.value, mapOptions)\n\n if (this.marker) {\n this.addMarker(coordinates)\n }\n }\n\n private getMapTypeId(): string {\n const typeMap = {\n roadmap: window.google!.maps.MapTypeId.ROADMAP,\n satellite: window.google!.maps.MapTypeId.SATELLITE,\n hybrid: window.google!.maps.MapTypeId.HYBRID,\n terrain: window.google!.maps.MapTypeId.TERRAIN\n }\n return typeMap[this.type] || typeMap.roadmap\n }\n\n private addMarker(coordinates: { lat: number; lng: number }) {\n if (!window.google?.maps || !this.map) {\n return\n }\n\n this.mapMarker = new window.google.maps.Marker({\n position: coordinates,\n map: this.map,\n title: this.markerTitle || this.address || 'Location'\n })\n }\n\n protected updated(changedProperties: Map<string, any>) {\n super.updated(changedProperties)\n\n if (changedProperties.has('height')) {\n this.style.setProperty('--map-height', this.height)\n }\n\n // Initialize map when loading completes and container is ready\n if (changedProperties.has('loading') && !this.loading && this.pendingCoordinates && !this.map) {\n // Wait for next frame to ensure map container is rendered\n requestAnimationFrame(() => {\n if (this.mapRef.value && this.pendingCoordinates) {\n this.initializeMap(this.pendingCoordinates)\n this.pendingCoordinates = undefined\n }\n })\n }\n\n // Reload map if critical properties change (only if map was already loaded)\n if (\n changedProperties.has('address') ||\n changedProperties.has('latitude') ||\n changedProperties.has('longitude') ||\n changedProperties.has('type') ||\n changedProperties.has('zoom')\n ) {\n if (this.map && this.hasLoadedMap) {\n this.loadMap()\n }\n }\n\n // Update marker title if it changes\n if (changedProperties.has('markerTitle') && this.mapMarker) {\n this.mapMarker.setTitle(this.markerTitle || this.address || 'Location')\n }\n }\n\n protected render() {\n return html`\n ${when(\n this.loading,\n () => html`\n <div class=\"loading-container\">\n <schmancy-spinner size=\"32px\"></schmancy-spinner>\n </div>\n `,\n () => when(\n this.error,\n () => html`\n <div class=\"error-container\">\n <svg class=\"error-icon\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" \n d=\"M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-2.5L13.732 4c-.77-.833-1.964-.833-2.732 0L4.082 16.5c-.77.833.192 2.5 1.732 2.5z\" />\n </svg>\n <div class=\"error-title\">Map could not be loaded</div>\n <div class=\"error-message\">${this.error}</div>\n </div>\n `,\n () => html`\n <div class=\"map-container\" ${ref(this.mapRef)}></div>\n `\n )\n )}\n `\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'schmancy-map': SchmancyMap\n }\n}"],"names":["GoogleMapsLoader","apiKey","window","google","maps","of","this","loading$","Observable","observer","next","complete","script","document","createElement","src","async","defer","initGoogleMaps","onerror","error","Error","head","appendChild","pipe","shareReplay","SchmancyMap","TailwindElement","css","constructor","super","arguments","address","zoom","height","marker","markerTitle","type","interactive","controls","loading","mapRef","createRef","hasLoadedMap","connectedCallback","style","setProperty","setupIntersectionObserver","disconnectedCallback","intersectionObserver","disconnect","IntersectionObserver","entries","forEach","entry","isIntersecting","loadMap","root","rootMargin","threshold","observe","tap","switchMap","load","getCoordinates","coordinates","pendingCoordinates","catchError","message","EMPTY","finalize","takeUntil","disconnecting","subscribe","geocodeAddress","latitude","longitude","lat","lng","geocoder","Geocoder","Promise","resolve","reject","geocode","results","status","location","geometry","value","mapOptions","center","mapTypeId","getMapTypeId","disableDefaultUI","gestureHandling","zoomControl","mapTypeControl","scaleControl","streetViewControl","rotateControl","fullscreenControl","styles","featureType","stylers","visibility","map","Map","addMarker","typeMap","roadmap","MapTypeId","ROADMAP","satellite","SATELLITE","hybrid","HYBRID","terrain","TERRAIN","mapMarker","Marker","position","title","changedProperties","updated","has","requestAnimationFrame","initializeMap","setTitle","render","html","when","ref","__decorateClass","property","String","prototype","Number","reflect","Boolean","state","customElement"],"mappings":";;;;;;;;;;;;;AAgCA,MAAMA,EAAAA;AAAAA,EAGJ,OAAA,KAAYC,GAAAA;AAEV,WAAIC,OAAOC,QAAQC,OACVC,EAAAA,EAAG,KAIRC,KAAKC,aAKTD,KAAKC,WAAW,IAAIC,EAAoBC,CAAAA,MAAAA;AAEtC,UAAIP,OAAOC,QAAQC,KAGjB,QAFAK,EAASC,KAAAA,EAAK,GAAA,KACdD,EAASE,SAAAA;AAIX,YAAMC,IAASC,SAASC,cAAc,QAAA;AAEtCF,MAAAA,EAAOG,MAAM,+CAA+Cd,CAAAA,sDAC5DW,EAAOI,QAAAA,IACPJ,EAAOK,QAAAA,IAEPf,OAAOgB,iBAAiB,MAAA;AACtBT,QAAAA,EAASC,OAAK,GACdD,EAASE,SAAAA;AAAAA,MAAAA,GAGXC,EAAOO,UAAWC,CAAAA,MAAAA;AAEhBX,QAAAA,EAASW,MAAM,IAAIC,MAAM,qGAAA,CAAA;AAAA,MAAA,GAG3BR,SAASS,KAAKC,YAAYX;OACzBY,KACDC,EAAY,CAAA,CAAA,IA9BLnB,KAAKC;AAAAA,EAkChB;AAAA;AA4BF,IAAqBmB,IAArB,cAAyCC,EAAgBC;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AAAAA;AA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import { TailwindElement } from '@mixins/index'\nimport { css, html } from 'lit'\nimport { customElement, property, state } from 'lit/decorators.js'\nimport { ref, createRef } from 'lit/directives/ref.js'\nimport { when } from 'lit/directives/when.js'\nimport { of, EMPTY, Observable } from 'rxjs'\nimport { switchMap, tap, catchError, takeUntil, finalize, shareReplay } from 'rxjs/operators'\n\ninterface GoogleMapsAPI {\n maps: {\n Map: new (element: HTMLElement, options: any) => any\n Marker: new (options: any) => any\n Geocoder: new () => any\n LatLng: new (lat: number, lng: number) => any\n MapTypeId: {\n ROADMAP: string\n SATELLITE: string\n HYBRID: string\n TERRAIN: string\n }\n }\n}\n\ndeclare global {\n interface Window {\n google?: GoogleMapsAPI\n initGoogleMaps?: () => void\n __schmancyGoogleMapsLoading?: Observable<boolean>\n }\n}\n\n// Singleton for managing Google Maps script loading\nclass GoogleMapsLoader {\n private static loading$?: Observable<boolean>\n\n static load(apiKey: string): Observable<boolean> {\n // If already loaded, return success\n if (window.google?.maps) {\n return of(true)\n }\n\n // If already loading, return the existing observable\n if (this.loading$) {\n return this.loading$\n }\n\n // Create a new loading observable\n this.loading$ = new Observable<boolean>(observer => {\n // Check again if loaded while waiting\n if (window.google?.maps) {\n observer.next(true)\n observer.complete()\n return\n }\n\n const script = document.createElement('script')\n // Using places library instead of geometry for geocoding\n script.src = `https://maps.googleapis.com/maps/api/js?key=${apiKey}&libraries=places&callback=initGoogleMaps&v=weekly`\n script.async = true\n script.defer = true\n\n window.initGoogleMaps = () => {\n observer.next(true)\n observer.complete()\n }\n\n script.onerror = (error) => {\n console.error('Google Maps script loading error:', error)\n observer.error(new Error('Failed to load Google Maps. Please check API key configuration and ensure the domain is authorized.'))\n }\n\n document.head.appendChild(script)\n }).pipe(\n shareReplay(1) // Share the result among all subscribers\n )\n\n return this.loading$\n }\n}\n\n/**\n * `<schmancy-map>` component\n *\n * A Google Maps component with an intuitive API for displaying interactive or static maps.\n * Supports both address strings (with automatic geocoding) and precise coordinates.\n *\n * @element schmancy-map\n *\n * @example\n * <!-- Simple address -->\n * <schmancy-map address=\"Times Square, New York\"></schmancy-map>\n *\n * @example\n * <!-- With coordinates -->\n * <schmancy-map latitude=\"40.758\" longitude=\"-73.985\" zoom=\"17\"></schmancy-map>\n *\n * @example\n * <!-- Satellite view -->\n * <schmancy-map address=\"Grand Canyon\" type=\"satellite\" height=\"500px\"></schmancy-map>\n *\n * @example\n * <!-- Static map -->\n * <schmancy-map address=\"Eiffel Tower, Paris\" interactive=\"false\" controls=\"false\"></schmancy-map>\n */\n@customElement('schmancy-map')\nexport default class SchmancyMap extends TailwindElement(css`\n :host {\n display: block;\n position: relative;\n border-radius: 8px;\n overflow: hidden;\n background-color: var(--schmancy-sys-color-surface-container);\n color: var(--schmancy-sys-color-surface-on);\n }\n \n :host([height]) {\n height: var(--map-height);\n }\n \n .map-container {\n width: 100%;\n height: 100%;\n min-height: 400px;\n }\n \n .loading-container {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 100%;\n height: 100%;\n min-height: 400px;\n background-color: var(--schmancy-sys-color-surface-containerLow);\n }\n \n .error-container {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n width: 100%;\n height: 100%;\n min-height: 400px;\n padding: 24px;\n text-align: center;\n background-color: var(--schmancy-sys-color-surface-containerLow);\n }\n \n .error-icon {\n width: 48px;\n height: 48px;\n margin-bottom: 16px;\n color: var(--schmancy-sys-color-error-default);\n }\n \n .error-title {\n font-size: 18px;\n font-weight: 600;\n margin-bottom: 8px;\n color: var(--schmancy-sys-color-surface-on);\n }\n \n .error-message {\n font-size: 14px;\n color: var(--schmancy-sys-color-surface-onVariant);\n line-height: 1.5;\n }\n`) {\n /**\n * Simple address string that automatically geocodes to display the location.\n * Takes precedence over latitude/longitude if both are provided.\n */\n @property({ type: String })\n address: string = ''\n\n /**\n * Latitude coordinate for precise location.\n * Used when address is not provided.\n */\n @property({ type: Number })\n latitude?: number\n\n /**\n * Longitude coordinate for precise location.\n * Used when address is not provided.\n */\n @property({ type: Number })\n longitude?: number\n\n /**\n * Map zoom level. Higher numbers show more detail.\n * @default 15\n */\n @property({ type: Number })\n zoom: number = 15\n\n /**\n * Height of the map with CSS unit (e.g., \"400px\", \"50vh\").\n * @default \"400px\"\n */\n @property({ type: String, reflect: true })\n height: string = '400px'\n\n /**\n * Whether to show a marker at the location.\n * @default true\n */\n @property({ type: Boolean })\n marker: boolean = true\n\n /**\n * Tooltip text for the location marker.\n */\n @property({ type: String })\n markerTitle: string = ''\n\n /**\n * Map display type.\n * Options: \"roadmap\", \"satellite\", \"hybrid\", \"terrain\"\n * @default \"roadmap\"\n */\n @property({ type: String })\n type: 'roadmap' | 'satellite' | 'hybrid' | 'terrain' = 'roadmap'\n\n /**\n * Whether users can interact with the map (pan, zoom, click).\n * @default true\n */\n @property({ type: Boolean })\n interactive: boolean = true\n\n /**\n * Whether to show map controls (zoom buttons, fullscreen, etc.).\n * @default true\n */\n @property({ type: Boolean })\n controls: boolean = true\n\n /**\n * Google Maps API key. Required for the map to load.\n */\n @property({ type: String })\n apiKey: string = ''\n\n @state() private loading: boolean = false\n @state() private error: string = ''\n\n private mapRef = createRef<HTMLDivElement>()\n private map?: any\n private mapMarker?: any\n private geocoder?: any\n private intersectionObserver?: IntersectionObserver\n private hasLoadedMap = false\n\n connectedCallback() {\n super.connectedCallback()\n \n // Set CSS custom property for height\n this.style.setProperty('--map-height', this.height)\n \n // Only load map when component becomes visible\n this.setupIntersectionObserver()\n }\n\n disconnectedCallback() {\n super.disconnectedCallback()\n if (this.intersectionObserver) {\n this.intersectionObserver.disconnect()\n }\n }\n\n private setupIntersectionObserver() {\n // Load map only when it's visible in the viewport\n this.intersectionObserver = new IntersectionObserver(\n (entries) => {\n entries.forEach(entry => {\n if (entry.isIntersecting && !this.hasLoadedMap) {\n this.hasLoadedMap = true\n this.loadMap()\n // Stop observing after loading\n this.intersectionObserver?.disconnect()\n }\n })\n },\n {\n root: null,\n rootMargin: '50px',\n threshold: 0.01\n }\n )\n \n this.intersectionObserver.observe(this)\n }\n\n private loadMap() {\n of(null).pipe(\n tap(() => {\n this.loading = true\n this.error = ''\n }),\n switchMap(() => {\n if (!this.apiKey) {\n throw new Error('Google Maps API key is required. Please provide it via the apiKey property.')\n }\n return GoogleMapsLoader.load(this.apiKey)\n }),\n switchMap(() => this.getCoordinates()),\n tap((coordinates) => {\n // Store coordinates for later use\n this.pendingCoordinates = coordinates\n }),\n catchError((error) => {\n console.error('Map loading error:', error)\n this.error = error.message || 'Failed to load map'\n return EMPTY\n }),\n finalize(() => {\n this.loading = false\n }),\n takeUntil(this.disconnecting)\n ).subscribe()\n }\n\n private pendingCoordinates?: { lat: number; lng: number }\n\n private getCoordinates() {\n if (this.address) {\n return this.geocodeAddress(this.address)\n }\n\n if (this.latitude !== undefined && this.longitude !== undefined) {\n return of({ lat: this.latitude, lng: this.longitude })\n }\n\n throw new Error('Either address or latitude/longitude coordinates are required')\n }\n\n private geocodeAddress(address: string) {\n if (!this.geocoder) {\n this.geocoder = new window.google!.maps.Geocoder()\n }\n\n return new Promise<{ lat: number; lng: number }>((resolve, reject) => {\n this.geocoder.geocode({ address }, (results: any[], status: string) => {\n if (status === 'OK' && results[0]) {\n const location = results[0].geometry.location\n resolve({\n lat: location.lat(),\n lng: location.lng()\n })\n } else {\n reject(new Error(`Geocoding failed: ${status}`))\n }\n })\n })\n }\n\n private initializeMap(coordinates: { lat: number; lng: number }) {\n if (!this.mapRef.value || !window.google?.maps) {\n return\n }\n\n const mapOptions = {\n center: coordinates,\n zoom: this.zoom,\n mapTypeId: this.getMapTypeId(),\n disableDefaultUI: !this.controls,\n gestureHandling: this.interactive ? 'cooperative' : 'none',\n zoomControl: this.controls,\n mapTypeControl: this.controls,\n scaleControl: this.controls,\n streetViewControl: this.controls,\n rotateControl: this.controls,\n fullscreenControl: this.controls,\n styles: this.interactive ? undefined : [\n {\n featureType: 'poi',\n stylers: [{ visibility: 'off' }]\n }\n ]\n }\n\n this.map = new window.google.maps.Map(this.mapRef.value, mapOptions)\n\n if (this.marker) {\n this.addMarker(coordinates)\n }\n }\n\n private getMapTypeId(): string {\n const typeMap = {\n roadmap: window.google!.maps.MapTypeId.ROADMAP,\n satellite: window.google!.maps.MapTypeId.SATELLITE,\n hybrid: window.google!.maps.MapTypeId.HYBRID,\n terrain: window.google!.maps.MapTypeId.TERRAIN\n }\n return typeMap[this.type] || typeMap.roadmap\n }\n\n private addMarker(coordinates: { lat: number; lng: number }) {\n if (!window.google?.maps || !this.map) {\n return\n }\n\n this.mapMarker = new window.google.maps.Marker({\n position: coordinates,\n map: this.map,\n title: this.markerTitle || this.address || 'Location'\n })\n }\n\n protected updated(changedProperties: Map<string, any>) {\n super.updated(changedProperties)\n\n if (changedProperties.has('height')) {\n this.style.setProperty('--map-height', this.height)\n }\n\n // Initialize map when loading completes and container is ready\n if (changedProperties.has('loading') && !this.loading && this.pendingCoordinates && !this.map) {\n // Wait for next frame to ensure map container is rendered\n requestAnimationFrame(() => {\n if (this.mapRef.value && this.pendingCoordinates) {\n this.initializeMap(this.pendingCoordinates)\n this.pendingCoordinates = undefined\n }\n })\n }\n\n // Reload map if critical properties change (only if map was already loaded)\n if (\n changedProperties.has('address') ||\n changedProperties.has('latitude') ||\n changedProperties.has('longitude') ||\n changedProperties.has('type') ||\n changedProperties.has('zoom')\n ) {\n if (this.map && this.hasLoadedMap) {\n this.loadMap()\n }\n }\n\n // Update marker title if it changes\n if (changedProperties.has('markerTitle') && this.mapMarker) {\n this.mapMarker.setTitle(this.markerTitle || this.address || 'Location')\n }\n }\n\n protected render() {\n return html`\n ${when(\n this.loading,\n () => html`\n <div class=\"loading-container\">\n <schmancy-spinner size=\"32px\"></schmancy-spinner>\n </div>\n `,\n () => when(\n this.error,\n () => html`\n <div class=\"error-container\">\n <svg class=\"error-icon\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" \n d=\"M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-2.5L13.732 4c-.77-.833-1.964-.833-2.732 0L4.082 16.5c-.77.833.192 2.5 1.732 2.5z\" />\n </svg>\n <div class=\"error-title\">Map could not be loaded</div>\n <div class=\"error-message\">${this.error}</div>\n </div>\n `,\n () => html`\n <div class=\"map-container\" ${ref(this.mapRef)}></div>\n `\n )\n )}\n `\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'schmancy-map': SchmancyMap\n }\n}"],"names":["GoogleMapsLoader","apiKey","window","google","maps","of","this","loading$","Observable","observer","next","complete","script","document","createElement","src","async","defer","initGoogleMaps","onerror","error","Error","head","appendChild","pipe","shareReplay","SchmancyMap","TailwindElement","css","constructor","super","arguments","address","zoom","height","marker","markerTitle","type","interactive","controls","loading","mapRef","createRef","hasLoadedMap","connectedCallback","style","setProperty","setupIntersectionObserver","disconnectedCallback","intersectionObserver","disconnect","IntersectionObserver","entries","forEach","entry","isIntersecting","loadMap","root","rootMargin","threshold","observe","tap","switchMap","load","getCoordinates","coordinates","pendingCoordinates","catchError","message","EMPTY","finalize","takeUntil","disconnecting","subscribe","geocodeAddress","latitude","longitude","lat","lng","geocoder","Geocoder","Promise","resolve","reject","geocode","results","status","location","geometry","value","mapOptions","center","mapTypeId","getMapTypeId","disableDefaultUI","gestureHandling","zoomControl","mapTypeControl","scaleControl","streetViewControl","rotateControl","fullscreenControl","styles","featureType","stylers","visibility","map","Map","addMarker","typeMap","roadmap","MapTypeId","ROADMAP","satellite","SATELLITE","hybrid","HYBRID","terrain","TERRAIN","mapMarker","Marker","position","title","changedProperties","updated","has","requestAnimationFrame","initializeMap","setTitle","render","html","when","ref","__decorateClass","property","String","prototype","Number","reflect","Boolean","state","customElement"],"mappings":";;;;;;;;;;;;;AAgCA,MAAMA,EAAAA;AAAAA,EAGJ,OAAA,KAAYC,GAAAA;AAEV,WAAIC,OAAOC,QAAQC,OACVC,EAAAA,EAAG,KAIRC,KAAKC,aAKTD,KAAKC,WAAW,IAAI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