@mhmo91/schmancy 0.10.42 → 0.10.44

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 (759) hide show
  1. package/custom-elements.json +264 -79
  2. package/dist/SchmancyElement-CeKrBW2j.cjs +2 -0
  3. package/dist/SchmancyElement-CeKrBW2j.cjs.map +1 -0
  4. package/dist/SchmancyElement-Ob9yGkiG.js +286 -0
  5. package/dist/SchmancyElement-Ob9yGkiG.js.map +1 -0
  6. package/dist/agent/schmancy.agent.js +4032 -3886
  7. package/dist/agent/schmancy.agent.js.map +1 -1
  8. package/dist/agent/schmancy.manifest.json +215 -58
  9. package/dist/animation-CCOIW4wJ.cjs.map +1 -1
  10. package/dist/animation-DCznELuT.js.map +1 -1
  11. package/dist/area-CbajcnmJ.cjs +21 -0
  12. package/dist/area-CbajcnmJ.cjs.map +1 -0
  13. package/dist/{area-DtCNCb8w.js → area-MxLAyWgV.js} +22 -22
  14. package/dist/area-MxLAyWgV.js.map +1 -0
  15. package/dist/area.cjs +1 -1
  16. package/dist/area.js +1 -1
  17. package/dist/{audio-DdN76ikW.js → audio-B_0PGwYC.js} +1 -1
  18. package/dist/audio-B_0PGwYC.js.map +1 -0
  19. package/dist/{audio-B924fI5N.cjs → audio-CpwrIaw-.cjs} +1 -1
  20. package/dist/audio-CpwrIaw-.cjs.map +1 -0
  21. package/dist/audio.cjs +1 -1
  22. package/dist/audio.js +2 -2
  23. package/dist/autocomplete-CILzaDB7.cjs +115 -0
  24. package/dist/autocomplete-CILzaDB7.cjs.map +1 -0
  25. package/dist/{autocomplete-UNOknYUz.js → autocomplete-DV9RxCun.js} +113 -113
  26. package/dist/autocomplete-DV9RxCun.js.map +1 -0
  27. package/dist/autocomplete.cjs +1 -1
  28. package/dist/autocomplete.js +1 -1
  29. package/dist/avatar.cjs +1 -1
  30. package/dist/avatar.cjs.map +1 -1
  31. package/dist/avatar.js +4 -4
  32. package/dist/avatar.js.map +1 -1
  33. package/dist/badge.cjs +1 -1
  34. package/dist/badge.js +1 -1
  35. package/dist/{boat-BZah1Sf9.js → boat-DoZGgQ0P.js} +5 -5
  36. package/dist/{boat-BZah1Sf9.js.map → boat-DoZGgQ0P.js.map} +1 -1
  37. package/dist/{boat-D3bEjxf8.cjs → boat-sg0cWO8a.cjs} +2 -2
  38. package/dist/{boat-D3bEjxf8.cjs.map → boat-sg0cWO8a.cjs.map} +1 -1
  39. package/dist/boat.cjs +1 -1
  40. package/dist/boat.js +1 -1
  41. package/dist/breadcrumb.cjs +32 -31
  42. package/dist/breadcrumb.cjs.map +1 -1
  43. package/dist/breadcrumb.js +33 -32
  44. package/dist/breadcrumb.js.map +1 -1
  45. package/dist/busy-Brs-TDh9.cjs +133 -0
  46. package/dist/busy-Brs-TDh9.cjs.map +1 -0
  47. package/dist/busy-g4LoQmhB.js +172 -0
  48. package/dist/busy-g4LoQmhB.js.map +1 -0
  49. package/dist/busy.cjs +1 -1
  50. package/dist/busy.js +1 -1
  51. package/dist/{button-CTvS5YX4.cjs → button-Cml67Y_d.cjs} +41 -32
  52. package/dist/button-Cml67Y_d.cjs.map +1 -0
  53. package/dist/{button-DgoDfcJx.js → button-DWANpZfD.js} +43 -34
  54. package/dist/button-DWANpZfD.js.map +1 -0
  55. package/dist/button.cjs +40 -33
  56. package/dist/button.cjs.map +1 -1
  57. package/dist/button.js +42 -35
  58. package/dist/button.js.map +1 -1
  59. package/dist/calendar-2dJrw9pR.cjs +58 -0
  60. package/dist/calendar-2dJrw9pR.cjs.map +1 -0
  61. package/dist/calendar-kCe5LaBa.js +434 -0
  62. package/dist/calendar-kCe5LaBa.js.map +1 -0
  63. package/dist/calendar.cjs +1 -0
  64. package/dist/calendar.js +2 -0
  65. package/dist/{card-C6ijJZpF.js → card-CS_hYJbz.js} +136 -136
  66. package/dist/card-CS_hYJbz.js.map +1 -0
  67. package/dist/card-d0KhTnx5.cjs +177 -0
  68. package/dist/card-d0KhTnx5.cjs.map +1 -0
  69. package/dist/card.cjs +1 -1
  70. package/dist/card.js +1 -1
  71. package/dist/{checkbox-7vEPZuGC.js → checkbox-Bjp7kWuE.js} +2 -2
  72. package/dist/{checkbox-7vEPZuGC.js.map → checkbox-Bjp7kWuE.js.map} +1 -1
  73. package/dist/{checkbox-DXKdxkXE.cjs → checkbox-DZ2Wrz7Y.cjs} +1 -1
  74. package/dist/{checkbox-DXKdxkXE.cjs.map → checkbox-DZ2Wrz7Y.cjs.map} +1 -1
  75. package/dist/checkbox.cjs +1 -1
  76. package/dist/checkbox.js +1 -1
  77. package/dist/{chips-9eG-96_D.cjs → chips-BHBVkxsa.cjs} +142 -153
  78. package/dist/chips-BHBVkxsa.cjs.map +1 -0
  79. package/dist/{chips-DF7akwz7.js → chips-DACeW7YL.js} +127 -138
  80. package/dist/chips-DACeW7YL.js.map +1 -0
  81. package/dist/chips.cjs +1 -1
  82. package/dist/chips.js +2 -2
  83. package/dist/connectivity.cjs +53 -35
  84. package/dist/connectivity.cjs.map +1 -1
  85. package/dist/connectivity.js +55 -37
  86. package/dist/connectivity.js.map +1 -1
  87. package/dist/content-drawer.cjs +1 -1
  88. package/dist/content-drawer.js +1 -1
  89. package/dist/cursor-glow-Ah7VXSj7.js.map +1 -1
  90. package/dist/cursor-glow-Bulq-38P.cjs.map +1 -1
  91. package/dist/date-range-B2VN7cl_.cjs +138 -0
  92. package/dist/date-range-B2VN7cl_.cjs.map +1 -0
  93. package/dist/date-range-CDF_5ju_.js +439 -0
  94. package/dist/date-range-CDF_5ju_.js.map +1 -0
  95. package/dist/{date-range-inline-DV2c_gWM.cjs → date-range-inline-CGM0SPK9.cjs} +2 -4
  96. package/dist/date-range-inline-CGM0SPK9.cjs.map +1 -0
  97. package/dist/{date-range-inline-BnOD-ddB.js → date-range-inline-D6Ozerzw.js} +3 -5
  98. package/dist/date-range-inline-D6Ozerzw.js.map +1 -0
  99. package/dist/date-range-inline.cjs +1 -1
  100. package/dist/date-range-inline.js +1 -1
  101. package/dist/date-range.cjs +1 -1
  102. package/dist/date-range.js +2 -2
  103. package/dist/dayjs.min-CvRZTfam.cjs +1 -0
  104. package/dist/dayjs.min-CvRZTfam.cjs.map +1 -0
  105. package/dist/dayjs.min-DnELezPs.js +296 -0
  106. package/dist/dayjs.min-DnELezPs.js.map +1 -0
  107. package/dist/delay.cjs +1 -1
  108. package/dist/delay.js +3 -3
  109. package/dist/{details-ByF66CyY.js → details-Ct1_GwKr.js} +104 -93
  110. package/dist/details-Ct1_GwKr.js.map +1 -0
  111. package/dist/{details-B2-jECBh.cjs → details-D4fVOaj4.cjs} +109 -98
  112. package/dist/details-D4fVOaj4.cjs.map +1 -0
  113. package/dist/details.cjs +1 -1
  114. package/dist/details.js +1 -1
  115. package/dist/{directives-DCb_LA9R.cjs → directives-B2VxfwRL.cjs} +1 -1
  116. package/dist/directives-B2VxfwRL.cjs.map +1 -0
  117. package/dist/{directives-BL7mzVsA.js → directives-Dj8jlv-Q.js} +3 -3
  118. package/dist/directives-Dj8jlv-Q.js.map +1 -0
  119. package/dist/directives.cjs +1 -1
  120. package/dist/directives.js +2 -2
  121. package/dist/discovery.service-CIa3Eeuk.cjs.map +1 -1
  122. package/dist/discovery.service-DZFxtRwW.js.map +1 -1
  123. package/dist/divider-B3v33OnX.cjs +57 -0
  124. package/dist/divider-B3v33OnX.cjs.map +1 -0
  125. package/dist/divider-BJHW3q11.js +89 -0
  126. package/dist/divider-BJHW3q11.js.map +1 -0
  127. package/dist/divider.cjs +1 -1
  128. package/dist/divider.js +1 -1
  129. package/dist/dropdown.cjs +40 -40
  130. package/dist/dropdown.cjs.map +1 -1
  131. package/dist/dropdown.js +41 -41
  132. package/dist/dropdown.js.map +1 -1
  133. package/dist/{expand-cZ8rfCWP.js → expand-BT8mOu8Q.js} +103 -97
  134. package/dist/expand-BT8mOu8Q.js.map +1 -0
  135. package/dist/expand-D0YdR9nR.cjs +147 -0
  136. package/dist/expand-D0YdR9nR.cjs.map +1 -0
  137. package/dist/expand.cjs +1 -1
  138. package/dist/expand.js +1 -1
  139. package/dist/fab.cjs +1 -1
  140. package/dist/fab.cjs.map +1 -1
  141. package/dist/fab.js +2 -2
  142. package/dist/fab.js.map +1 -1
  143. package/dist/{float-DkGyWSWy.cjs → float-BPQlDyai.cjs} +1 -1
  144. package/dist/{float-DkGyWSWy.cjs.map → float-BPQlDyai.cjs.map} +1 -1
  145. package/dist/{float-zn3DgXBT.js → float-BQcxj3i_.js} +2 -2
  146. package/dist/{float-zn3DgXBT.js.map → float-BQcxj3i_.js.map} +1 -1
  147. package/dist/float.cjs +1 -1
  148. package/dist/float.js +1 -1
  149. package/dist/{form-DowzVsgI.cjs → form-CoWFnClb.cjs} +8 -13
  150. package/dist/form-CoWFnClb.cjs.map +1 -0
  151. package/dist/{form-tG7LwDm4.js → form-hC2LvCHX.js} +10 -15
  152. package/dist/form-hC2LvCHX.js.map +1 -0
  153. package/dist/form.cjs +12 -13
  154. package/dist/form.cjs.map +1 -1
  155. package/dist/form.js +23 -24
  156. package/dist/form.js.map +1 -1
  157. package/dist/gravity-6pL6CfIr.cjs.map +1 -1
  158. package/dist/gravity-sVK3zGBF.js.map +1 -1
  159. package/dist/handover/agent-runtime-followups.md +1 -1
  160. package/dist/handover/agent-runtime-v1.md +3 -3
  161. package/dist/{hashContent-iRZJJWtE.cjs.map → hashContent--s09Ed_g.cjs.map} +1 -1
  162. package/dist/{hashContent-BqU6v1Xr.js.map → hashContent-CAvrQ56N.js.map} +1 -1
  163. package/dist/icons-BeGKDZ-k.cjs +22 -0
  164. package/dist/icons-BeGKDZ-k.cjs.map +1 -0
  165. package/dist/{icons-Dup5skuk.js → icons-DEJnIxml.js} +20 -22
  166. package/dist/icons-DEJnIxml.js.map +1 -0
  167. package/dist/icons.cjs +1 -1
  168. package/dist/icons.js +1 -1
  169. package/dist/{iframe-CDJjnNmo.cjs → iframe-BkSukM9C.cjs} +9 -9
  170. package/dist/iframe-BkSukM9C.cjs.map +1 -0
  171. package/dist/{iframe-Xc3EPMZT.js → iframe-V3S-bwEY.js} +10 -10
  172. package/dist/iframe-V3S-bwEY.js.map +1 -0
  173. package/dist/iframe.cjs +1 -1
  174. package/dist/iframe.js +1 -1
  175. package/dist/index.cjs +1 -1
  176. package/dist/index.js +61 -60
  177. package/dist/{input-cTyDxW9L.js → input-CPFCSQld.js} +3 -10
  178. package/dist/input-CPFCSQld.js.map +1 -0
  179. package/dist/{input-DnmC6J1T.cjs → input-DSfwfhhj.cjs} +2 -9
  180. package/dist/input-DSfwfhhj.cjs.map +1 -0
  181. package/dist/input-chip-BUuFJUky.cjs +129 -0
  182. package/dist/input-chip-BUuFJUky.cjs.map +1 -0
  183. package/dist/{input-chip-CYI17YOq.js → input-chip-C3a1fwKB.js} +87 -104
  184. package/dist/input-chip-C3a1fwKB.js.map +1 -0
  185. package/dist/input.cjs +1 -1
  186. package/dist/input.js +1 -1
  187. package/dist/json.cjs +5 -1
  188. package/dist/json.cjs.map +1 -1
  189. package/dist/json.js +8 -4
  190. package/dist/json.js.map +1 -1
  191. package/dist/kbd.cjs +28 -28
  192. package/dist/kbd.cjs.map +1 -1
  193. package/dist/kbd.js +29 -29
  194. package/dist/kbd.js.map +1 -1
  195. package/dist/{layout-CNlZSJFU.cjs → layout-CdyHy_oX.cjs} +1 -1
  196. package/dist/layout-CdyHy_oX.cjs.map +1 -0
  197. package/dist/{layout-DDxw0EwL.js → layout-k6fOkpif.js} +1 -1
  198. package/dist/layout-k6fOkpif.js.map +1 -0
  199. package/dist/layout.cjs +26 -26
  200. package/dist/layout.cjs.map +1 -1
  201. package/dist/layout.js +27 -27
  202. package/dist/layout.js.map +1 -1
  203. package/dist/lazy-BaAiIUru.js.map +1 -1
  204. package/dist/lazy-C-7a4FAe.cjs.map +1 -1
  205. package/dist/{lightbox-CH-y3rYB.js → lightbox-DIG0VLOK.js} +8 -14
  206. package/dist/lightbox-DIG0VLOK.js.map +1 -0
  207. package/dist/{lightbox-CvtqoInF.cjs → lightbox-E5rgd-hu.cjs} +7 -13
  208. package/dist/lightbox-E5rgd-hu.cjs.map +1 -0
  209. package/dist/lightbox.cjs +1 -1
  210. package/dist/lightbox.js +1 -1
  211. package/dist/list-BRz0rDSH.cjs +47 -0
  212. package/dist/list-BRz0rDSH.cjs.map +1 -0
  213. package/dist/{list-DrsawQ5R.js → list-NrOYDPBo.js} +42 -35
  214. package/dist/list-NrOYDPBo.js.map +1 -0
  215. package/dist/list.cjs +1 -1
  216. package/dist/list.js +1 -1
  217. package/dist/magnetic-DKtc4umC.cjs.map +1 -1
  218. package/dist/magnetic-DaOOv5Dz.js.map +1 -1
  219. package/dist/{menu-CsY5lMqY.js → menu-B1Ei9SVj.js} +12 -12
  220. package/dist/menu-B1Ei9SVj.js.map +1 -0
  221. package/dist/{menu-BFRcTe3o.cjs → menu-Duvl66Nl.cjs} +10 -10
  222. package/dist/menu-Duvl66Nl.cjs.map +1 -0
  223. package/dist/menu.cjs +1 -1
  224. package/dist/menu.js +1 -1
  225. package/dist/{mixins-BoMURWag.cjs → mixins-Cjn20BQH.cjs} +42 -100
  226. package/dist/mixins-Cjn20BQH.cjs.map +1 -0
  227. package/dist/{mixins-bCEXbwJV.js → mixins-q4KAL8Xr.js} +42 -100
  228. package/dist/mixins-q4KAL8Xr.js.map +1 -0
  229. package/dist/mixins.cjs +1 -1
  230. package/dist/mixins.js +2 -2
  231. package/dist/nav-drawer.cjs +1 -1
  232. package/dist/nav-drawer.js +1 -1
  233. package/dist/navigation-bar.cjs +1 -1
  234. package/dist/navigation-bar.js +1 -1
  235. package/dist/navigation-rail.cjs +2 -4
  236. package/dist/navigation-rail.cjs.map +1 -1
  237. package/dist/navigation-rail.js +3 -5
  238. package/dist/navigation-rail.js.map +1 -1
  239. package/dist/{notification-DFKRMmSq.js → notification-COhUhUCr.js} +5 -7
  240. package/dist/notification-COhUhUCr.js.map +1 -0
  241. package/dist/{notification-FBf3Mb2e.cjs → notification-DsdA_MJe.cjs} +2 -4
  242. package/dist/notification-DsdA_MJe.cjs.map +1 -0
  243. package/dist/notification.cjs +1 -1
  244. package/dist/notification.js +1 -1
  245. package/dist/{option-Ct0lGdH3.js → option-BIzgTbXz.js} +20 -20
  246. package/dist/option-BIzgTbXz.js.map +1 -0
  247. package/dist/option-C5hhqR2z.cjs +43 -0
  248. package/dist/option-C5hhqR2z.cjs.map +1 -0
  249. package/dist/option.cjs +1 -1
  250. package/dist/option.js +1 -1
  251. package/dist/{overlay-sRXiMkjn.cjs → overlay-BzgF8P7i.cjs} +48 -41
  252. package/dist/overlay-BzgF8P7i.cjs.map +1 -0
  253. package/dist/{overlay-Bh8Q_R01.js → overlay-LoRRemny.js} +52 -45
  254. package/dist/overlay-LoRRemny.js.map +1 -0
  255. package/dist/overlay-stack-Bdr9lOqi.cjs.map +1 -1
  256. package/dist/overlay-stack-D2rgxQLh.js.map +1 -1
  257. package/dist/overlay.cjs +1 -1
  258. package/dist/{overlay.confirm-body-CQihsR20.js → overlay.confirm-body-D0b1MoCw.js} +30 -45
  259. package/dist/overlay.confirm-body-D0b1MoCw.js.map +1 -0
  260. package/dist/{overlay.confirm-body-Jc1EuMGs.cjs → overlay.confirm-body-DCneq73Z.cjs} +22 -37
  261. package/dist/overlay.confirm-body-DCneq73Z.cjs.map +1 -0
  262. package/dist/overlay.js +3 -3
  263. package/dist/{overlay.service-BXPgS7ay.js → overlay.service-BuUeti6X.js} +2 -2
  264. package/dist/overlay.service-BuUeti6X.js.map +1 -0
  265. package/dist/{overlay.service-9Dp3g7ot.cjs → overlay.service-MMTiW2T3.cjs} +1 -1
  266. package/dist/overlay.service-MMTiW2T3.cjs.map +1 -0
  267. package/dist/{progress-CYLshdo2.js → progress-D7n3SKAO.js} +50 -50
  268. package/dist/progress-D7n3SKAO.js.map +1 -0
  269. package/dist/progress-DsCnFsH5.cjs +51 -0
  270. package/dist/progress-DsCnFsH5.cjs.map +1 -0
  271. package/dist/progress.cjs +1 -1
  272. package/dist/progress.js +1 -1
  273. package/dist/{radio-group-6kCgOgBL.cjs → radio-group-CaAjg9UV.cjs} +1 -1
  274. package/dist/radio-group-CaAjg9UV.cjs.map +1 -0
  275. package/dist/{radio-group-bZtZHOj_.js → radio-group-Drpl6Pl8.js} +2 -2
  276. package/dist/radio-group-Drpl6Pl8.js.map +1 -0
  277. package/dist/radio-group.cjs +1 -1
  278. package/dist/radio-group.js +1 -1
  279. package/dist/range.cjs +4 -2
  280. package/dist/range.cjs.map +1 -1
  281. package/dist/range.js +5 -3
  282. package/dist/range.js.map +1 -1
  283. package/dist/reduced-motion-D-L12p7G.js.map +1 -1
  284. package/dist/reduced-motion-Ds-HjMzn.cjs.map +1 -1
  285. package/dist/{rxjs-utils-Csnks202.cjs.map → rxjs-utils-4P2v57ke.cjs.map} +1 -1
  286. package/dist/{rxjs-utils-d-ivVN84.js.map → rxjs-utils-JMFdgQSl.js.map} +1 -1
  287. package/dist/rxjs-utils.cjs +1 -1
  288. package/dist/rxjs-utils.js +1 -1
  289. package/dist/search-DPKoC-dT.cjs.map +1 -1
  290. package/dist/search-MvIBA93K.js.map +1 -1
  291. package/dist/{select-CU3X-PIa.js → select-CTXkrrVZ.js} +13 -13
  292. package/dist/select-CTXkrrVZ.js.map +1 -0
  293. package/dist/select-DcLcpPCh.cjs +56 -0
  294. package/dist/select-DcLcpPCh.cjs.map +1 -0
  295. package/dist/select.cjs +1 -1
  296. package/dist/select.js +1 -1
  297. package/dist/skeleton.cjs +37 -33
  298. package/dist/skeleton.cjs.map +1 -1
  299. package/dist/skeleton.js +38 -34
  300. package/dist/skeleton.js.map +1 -1
  301. package/dist/skills/schmancy/surface.md +38 -22
  302. package/dist/skills/surface.md +38 -22
  303. package/dist/slider.cjs +31 -31
  304. package/dist/slider.cjs.map +1 -1
  305. package/dist/slider.js +32 -32
  306. package/dist/slider.js.map +1 -1
  307. package/dist/{sound.service-B4ZmXpH9.js → sound.service-AJwuk3yr.js} +1 -1
  308. package/dist/sound.service-AJwuk3yr.js.map +1 -0
  309. package/dist/{sound.service-DjlMvicQ.cjs → sound.service-CVsxhQkX.cjs} +1 -1
  310. package/dist/sound.service-CVsxhQkX.cjs.map +1 -0
  311. package/dist/{splash-screen-emCLYoVl.js → splash-screen-DANfqvlo.js} +23 -26
  312. package/dist/splash-screen-DANfqvlo.js.map +1 -0
  313. package/dist/splash-screen-K74cgU6S.cjs +38 -0
  314. package/dist/splash-screen-K74cgU6S.cjs.map +1 -0
  315. package/dist/splash-screen.cjs +1 -1
  316. package/dist/splash-screen.js +1 -1
  317. package/dist/{src-DGDTkOvC.js → src-Bo-vvN6m.js} +173 -175
  318. package/dist/src-Bo-vvN6m.js.map +1 -0
  319. package/dist/src-MdpH1zth.cjs +237 -0
  320. package/dist/src-MdpH1zth.cjs.map +1 -0
  321. package/dist/{state-CumAEPQH.cjs → state-BWQiqN6I.cjs} +1 -1
  322. package/dist/state-BWQiqN6I.cjs.map +1 -0
  323. package/dist/{state-DMd_FUeA.js → state-DBA_gzJO.js} +1 -1
  324. package/dist/state-DBA_gzJO.js.map +1 -0
  325. package/dist/state.cjs +1 -1
  326. package/dist/state.js +2 -2
  327. package/dist/steps.cjs +20 -12
  328. package/dist/steps.cjs.map +1 -1
  329. package/dist/steps.js +21 -13
  330. package/dist/steps.js.map +1 -1
  331. package/dist/surface-COBvWWFb.cjs +7 -0
  332. package/dist/surface-COBvWWFb.cjs.map +1 -0
  333. package/dist/{surface-DNiYigsX.js → surface-DXk1X1tL.js} +9 -9
  334. package/dist/{surface-DNiYigsX.js.map → surface-DXk1X1tL.js.map} +1 -1
  335. package/dist/surface.cjs +1 -1
  336. package/dist/surface.js +1 -1
  337. package/dist/switch.cjs +13 -4
  338. package/dist/switch.cjs.map +1 -1
  339. package/dist/switch.js +14 -5
  340. package/dist/switch.js.map +1 -1
  341. package/dist/table.cjs +4 -10
  342. package/dist/table.cjs.map +1 -1
  343. package/dist/table.js +5 -11
  344. package/dist/table.js.map +1 -1
  345. package/dist/{tabs-4T_4kCf-.js → tabs-BYhFWnsx.js} +7 -7
  346. package/dist/tabs-BYhFWnsx.js.map +1 -0
  347. package/dist/{tabs-Byxxt-AH.cjs → tabs-CJwB0fr0.cjs} +6 -6
  348. package/dist/tabs-CJwB0fr0.cjs.map +1 -0
  349. package/dist/tabs.cjs +1 -1
  350. package/dist/tabs.js +1 -1
  351. package/dist/teleport.cjs +1 -1
  352. package/dist/teleport.js +1 -1
  353. package/dist/{textarea-kkYNk1ET.js → textarea-BjDx1w2g.js} +37 -41
  354. package/dist/textarea-BjDx1w2g.js.map +1 -0
  355. package/dist/{textarea-BwYwH9fu.cjs → textarea-CGgznhd6.cjs} +36 -40
  356. package/dist/textarea-CGgznhd6.cjs.map +1 -0
  357. package/dist/textarea.cjs +1 -1
  358. package/dist/textarea.js +1 -1
  359. package/dist/{theme-BG0EnzYP.cjs → theme-BVul7lHS.cjs} +6 -6
  360. package/dist/{theme-BG0EnzYP.cjs.map → theme-BVul7lHS.cjs.map} +1 -1
  361. package/dist/{theme-DwQBl6sr.js → theme-Dvm5J8nh.js} +11 -11
  362. package/dist/{theme-DwQBl6sr.js.map → theme-Dvm5J8nh.js.map} +1 -1
  363. package/dist/{theme-button-BD8anzsZ.js → theme-button-Bko5ohFP.js} +2 -2
  364. package/dist/{theme-button-BD8anzsZ.js.map → theme-button-Bko5ohFP.js.map} +1 -1
  365. package/dist/{theme-button-DlrNoCMA.cjs → theme-button-YLY7zR1c.cjs} +1 -1
  366. package/dist/{theme-button-DlrNoCMA.cjs.map → theme-button-YLY7zR1c.cjs.map} +1 -1
  367. package/dist/theme-button.cjs +1 -1
  368. package/dist/theme-button.js +1 -1
  369. package/dist/theme.cjs +1 -1
  370. package/dist/{theme.interface-CSt7JUBD.cjs.map → theme.interface-B-qxDsZQ.cjs.map} +1 -1
  371. package/dist/{theme.interface-odQEpZZH.js.map → theme.interface-B7caS5cg.js.map} +1 -1
  372. package/dist/theme.js +4 -4
  373. package/dist/{theme.service-Dv_55nfE.js → theme.service-D94nm7Bf.js} +1 -1
  374. package/dist/theme.service-D94nm7Bf.js.map +1 -0
  375. package/dist/{theme.service-pjkTM209.cjs → theme.service-h2fXQq7x.cjs} +1 -1
  376. package/dist/theme.service-h2fXQq7x.cjs.map +1 -0
  377. package/dist/tooltip.cjs.map +1 -1
  378. package/dist/tooltip.js.map +1 -1
  379. package/dist/tree.cjs +14 -14
  380. package/dist/tree.cjs.map +1 -1
  381. package/dist/tree.js +15 -15
  382. package/dist/tree.js.map +1 -1
  383. package/dist/types.cjs +1 -1
  384. package/dist/types.cjs.map +1 -1
  385. package/dist/types.js +19 -2
  386. package/dist/types.js.map +1 -1
  387. package/dist/typewriter.cjs.map +1 -1
  388. package/dist/typewriter.js.map +1 -1
  389. package/dist/typography-ByF2k5yW.js +358 -0
  390. package/dist/typography-ByF2k5yW.js.map +1 -0
  391. package/dist/typography-Cfav17it.cjs +282 -0
  392. package/dist/typography-Cfav17it.cjs.map +1 -0
  393. package/dist/typography.cjs +1 -1
  394. package/dist/typography.js +1 -1
  395. package/dist/utils-DIXndz6Q.cjs.map +1 -0
  396. package/dist/utils-dSPH7Oh9.js.map +1 -0
  397. package/dist/utils.cjs +1 -1
  398. package/dist/utils.js +1 -1
  399. package/dist/visually-hidden.cjs +13 -13
  400. package/dist/visually-hidden.cjs.map +1 -1
  401. package/dist/visually-hidden.js +14 -14
  402. package/dist/visually-hidden.js.map +1 -1
  403. package/dist/window-Br1OmpL-.cjs +67 -0
  404. package/dist/window-Br1OmpL-.cjs.map +1 -0
  405. package/dist/{window-C76zstbV.js → window-CCmN4but.js} +24 -15
  406. package/dist/window-CCmN4but.js.map +1 -0
  407. package/dist/window.cjs +1 -1
  408. package/dist/window.js +1 -1
  409. package/package.json +1 -1
  410. package/skills/schmancy/surface.md +38 -22
  411. package/src/area/area.component.ts +249 -163
  412. package/src/area/area.service.test.ts +994 -1006
  413. package/src/area/area.service.ts +76 -72
  414. package/src/area/index.ts +7 -7
  415. package/src/area/lazy.ts +39 -42
  416. package/src/area/route.component.ts +54 -52
  417. package/src/area/router.types.ts +7 -7
  418. package/src/audio/emotional-sounds.ts +880 -801
  419. package/src/audio/sound.service.ts +26 -5
  420. package/src/avatar/avatar.ts +4 -4
  421. package/src/badge/badge.ts +15 -12
  422. package/src/badge/index.ts +1 -1
  423. package/src/boat/boat.ts +1 -1
  424. package/src/breadcrumb/breadcrumb.ts +37 -32
  425. package/src/busy/busy.ts +15 -12
  426. package/src/busy/index.ts +2 -2
  427. package/src/busy/spinner.ts +132 -119
  428. package/src/button/button.test.ts +5 -1
  429. package/src/button/button.ts +113 -72
  430. package/src/button/icon-button.ts +64 -46
  431. package/src/button/index.ts +2 -2
  432. package/src/calendar/calendar.test.ts +504 -0
  433. package/src/calendar/calendar.ts +587 -0
  434. package/src/calendar/index.ts +2 -0
  435. package/src/card/actions.ts +11 -9
  436. package/src/card/card.ts +79 -77
  437. package/src/card/content.ts +8 -6
  438. package/src/card/index.ts +4 -4
  439. package/src/card/media.ts +50 -50
  440. package/src/chips/assist-chip.ts +1 -1
  441. package/src/chips/chips.ts +1 -1
  442. package/src/chips/filter-chip.ts +1 -1
  443. package/src/chips/index.ts +1 -1
  444. package/src/chips/input-chip.ts +1 -1
  445. package/src/chips/suggestion-chip.ts +1 -1
  446. package/src/connectivity/connectivity-status.ts +90 -62
  447. package/src/content-drawer/drawer.service.ts +47 -36
  448. package/src/content-drawer/drawer.ts +31 -18
  449. package/src/content-drawer/index.ts +5 -5
  450. package/src/content-drawer/main.ts +9 -7
  451. package/src/content-drawer/sheet.ts +8 -6
  452. package/src/date-range-inline/date-range-inline.ts +523 -522
  453. package/src/date-range-inline/index.ts +2 -2
  454. package/src/delay/index.ts +1 -1
  455. package/src/details/details.ts +119 -105
  456. package/src/details/index.ts +1 -1
  457. package/src/directives/ai-badge.ts +1 -5
  458. package/src/directives/animate-text.ts +43 -31
  459. package/src/directives/art/effects/howl.ts +1 -4
  460. package/src/directives/art/effects/samwa.ts +11 -5
  461. package/src/directives/art/effects/snow.ts +1 -2
  462. package/src/directives/battery.ts +21 -12
  463. package/src/directives/confirm-click.ts +9 -17
  464. package/src/directives/cursor-glow.ts +1 -1
  465. package/src/directives/cycle-text.ts +7 -21
  466. package/src/directives/drag.ts +50 -45
  467. package/src/directives/fyi.ts +1 -6
  468. package/src/directives/gravity.ts +10 -8
  469. package/src/directives/hummingbird.ts +256 -107
  470. package/src/directives/index.ts +29 -29
  471. package/src/directives/intersect.ts +11 -11
  472. package/src/directives/layout.ts +25 -36
  473. package/src/directives/liquid.ts +4 -10
  474. package/src/directives/living-border.ts +7 -5
  475. package/src/directives/long-press.ts +2 -1
  476. package/src/directives/magnetic.ts +7 -6
  477. package/src/directives/nebula.ts +34 -28
  478. package/src/directives/overflow-within.ts +18 -20
  479. package/src/directives/reduced-motion.ts +9 -9
  480. package/src/directives/reveal.ts +193 -195
  481. package/src/directives/ripple.ts +9 -7
  482. package/src/directives/urgent.ts +3 -1
  483. package/src/directives/working-snake.ts +1 -1
  484. package/src/discovery/discovery.service.ts +198 -210
  485. package/src/discovery/index.ts +1 -1
  486. package/src/divider/divider.ts +49 -47
  487. package/src/divider/index.ts +1 -1
  488. package/src/dropdown/dropdown-content.ts +42 -40
  489. package/src/dropdown/index.ts +2 -2
  490. package/src/expand/expand-root.component.ts +70 -61
  491. package/src/expand/expand.component.ts +48 -43
  492. package/src/fab/fab.test.ts +1 -2
  493. package/src/fab/fab.ts +2 -4
  494. package/src/form/fields/autocomplete/autocomplete.scss +6 -2
  495. package/src/form/fields/autocomplete/autocomplete.ts +712 -724
  496. package/src/form/fields/autocomplete/index.ts +1 -1
  497. package/src/form/fields/checkbox/checkbox.ts +1 -4
  498. package/src/form/fields/chips/assist-chip.ts +69 -72
  499. package/src/form/fields/chips/chips.ts +14 -15
  500. package/src/form/fields/chips/filter-chip.ts +36 -32
  501. package/src/form/fields/chips/index.ts +5 -5
  502. package/src/form/fields/chips/input-chip.ts +130 -142
  503. package/src/form/fields/chips/suggestion-chip.ts +69 -72
  504. package/src/form/fields/date-range/date-range-dialog.ts +154 -194
  505. package/src/form/fields/date-range/date-range-helpers.ts +63 -64
  506. package/src/form/fields/date-range/date-range.test.ts +575 -121
  507. package/src/form/fields/date-range/date-range.ts +343 -395
  508. package/src/form/fields/date-range/index.ts +2 -2
  509. package/src/form/fields/input/index.ts +8 -8
  510. package/src/form/fields/input/input.scss +30 -26
  511. package/src/form/fields/input/input.test.ts +4 -1
  512. package/src/form/fields/input/input.ts +4 -20
  513. package/src/form/fields/radio-group/index.ts +2 -2
  514. package/src/form/fields/radio-group/radio-button.ts +8 -8
  515. package/src/form/fields/radio-group/radio-group.ts +4 -1
  516. package/src/form/fields/range/range.ts +3 -1
  517. package/src/form/fields/select/index.ts +2 -2
  518. package/src/form/fields/select/select.ts +51 -45
  519. package/src/form/fields/switch/switch.ts +13 -7
  520. package/src/form/fields/textarea/index.ts +1 -1
  521. package/src/form/fields/textarea/textarea.ts +44 -49
  522. package/src/form/form-summary.ts +15 -14
  523. package/src/form/form.test.ts +0 -1
  524. package/src/form/form.ts +11 -23
  525. package/src/icons/icon.ts +25 -25
  526. package/src/icons/index.ts +1 -1
  527. package/src/iframe/iframe.ts +11 -9
  528. package/src/index.ts +1 -0
  529. package/src/json/json.ts +9 -2
  530. package/src/kbd/kbd.ts +30 -28
  531. package/src/layout/scroll/index.ts +1 -1
  532. package/src/layout/scroll/scroll.ts +54 -54
  533. package/src/lightbox/lightbox-service.ts +27 -18
  534. package/src/lightbox/lightbox.directive.ts +2 -1
  535. package/src/lightbox/lightbox.ts +21 -38
  536. package/src/list/index.ts +3 -3
  537. package/src/list/list-item.ts +32 -26
  538. package/src/list/list.ts +13 -8
  539. package/src/menu/index.ts +2 -2
  540. package/src/menu/menu-item.ts +7 -5
  541. package/src/menu/menu.ts +8 -6
  542. package/src/nav-drawer/appbar.ts +9 -7
  543. package/src/nav-drawer/content.ts +10 -8
  544. package/src/nav-drawer/drawer.ts +29 -25
  545. package/src/nav-drawer/index.ts +6 -6
  546. package/src/navigation-bar/index.ts +2 -2
  547. package/src/navigation-bar/navigation-bar-item.ts +127 -118
  548. package/src/navigation-bar/navigation-bar.ts +103 -91
  549. package/src/navigation-rail/index.ts +2 -2
  550. package/src/navigation-rail/navigation-rail.ts +21 -22
  551. package/src/notification/index.ts +6 -6
  552. package/src/notification/notification-service.ts +1 -2
  553. package/src/notification/notification.scss +5 -1
  554. package/src/notification/notification.ts +1 -3
  555. package/src/notification/notify.ts +204 -207
  556. package/src/option/index.ts +1 -1
  557. package/src/option/option.ts +26 -25
  558. package/src/overlay/overlay.animations.ts +4 -14
  559. package/src/overlay/overlay.component.ts +110 -131
  560. package/src/overlay/overlay.confirm-body.ts +26 -48
  561. package/src/overlay/overlay.gestures.ts +8 -10
  562. package/src/overlay/overlay.layout.ts +1 -4
  563. package/src/overlay/overlay.positioning.ts +4 -15
  564. package/src/overlay/overlay.service.ts +9 -24
  565. package/src/overlay/overlay.stack.test.ts +4 -1
  566. package/src/overlay/overlay.stack.ts +4 -4
  567. package/src/overlay/overlay.types.ts +11 -20
  568. package/src/progress/index.ts +1 -1
  569. package/src/progress/progress.ts +135 -133
  570. package/src/rxjs-utils/index.ts +6 -6
  571. package/src/rxjs-utils/waitForElement.ts +20 -20
  572. package/src/rxjs-utils/waitForElementAll.ts +21 -21
  573. package/src/rxjs-utils/waitForElements.ts +27 -27
  574. package/src/rxjs-utils/waitForElementsAll.ts +27 -29
  575. package/src/rxjs-utils/waitUntil.ts +7 -12
  576. package/src/skeleton/skeleton.ts +39 -33
  577. package/src/slider/index.ts +2 -2
  578. package/src/slider/slide.ts +14 -12
  579. package/src/slider/slider.ts +24 -22
  580. package/src/splash-screen/index.ts +1 -1
  581. package/src/splash-screen/splash-screen.ts +26 -27
  582. package/src/state/active-host.ts +4 -5
  583. package/src/state/index.ts +34 -53
  584. package/src/state/persist.ts +14 -11
  585. package/src/state/schmancy-context.ts +88 -88
  586. package/src/state/state.test-d.ts +3 -13
  587. package/src/state/state.test.ts +1 -4
  588. package/src/steps/index.ts +3 -3
  589. package/src/steps/schmancy-step.ts +41 -31
  590. package/src/steps/schmancy-steps.ts +7 -5
  591. package/src/surface/index.ts +1 -1
  592. package/src/surface/surface.styles.ts +53 -104
  593. package/src/surface/surface.ts +10 -8
  594. package/src/table/index.ts +2 -2
  595. package/src/table/row.ts +1 -4
  596. package/src/table/table.ts +2 -5
  597. package/src/tabs/index.ts +2 -2
  598. package/src/tabs/tabs-group.ts +8 -6
  599. package/src/teleport/index.ts +2 -2
  600. package/src/test-utils/a11y.ts +1 -3
  601. package/src/theme/index.ts +17 -17
  602. package/src/theme/theme-audio-player.ts +18 -16
  603. package/src/theme/theme-controller-boat.ts +1 -1
  604. package/src/theme/theme-controller.ts +36 -32
  605. package/src/theme/theme.component.ts +5 -9
  606. package/src/theme/theme.events.ts +1 -1
  607. package/src/theme/theme.format.ts +7 -7
  608. package/src/theme/theme.service.ts +453 -468
  609. package/src/theme/theme.style.css +78 -23
  610. package/src/theme-button/index.ts +1 -1
  611. package/src/tooltip/tooltip.directive.ts +1 -1
  612. package/src/tree/index.ts +1 -1
  613. package/src/tree/tree.ts +24 -16
  614. package/src/types/surface.ts +38 -44
  615. package/src/typewriter/typewriter.directive.ts +30 -39
  616. package/src/typography/typography.ts +289 -269
  617. package/src/utils/animation.ts +2 -8
  618. package/src/utils/index.ts +6 -6
  619. package/src/utils/number.ts +480 -517
  620. package/src/utils/overlay-stack.ts +1 -3
  621. package/src/utils/search.ts +5 -9
  622. package/src/visually-hidden/visually-hidden.ts +15 -13
  623. package/src/window/window-manager.ts +6 -1
  624. package/src/window/window-position.ts +7 -5
  625. package/src/window/window.ts +143 -108
  626. package/types/src/calendar/calendar.d.ts +108 -0
  627. package/types/src/calendar/calendar.test.d.ts +1 -0
  628. package/types/src/calendar/index.d.ts +2 -0
  629. package/types/src/directives/cursor-glow.d.ts +1 -1
  630. package/types/src/directives/hummingbird.d.ts +3 -3
  631. package/types/src/form/fields/date-range/date-range-dialog.d.ts +24 -28
  632. package/types/src/form/fields/date-range/date-range.d.ts +39 -66
  633. package/types/src/form/fields/date-range/date-range.test.d.ts +1 -0
  634. package/types/src/form/fields/date-range/index.d.ts +1 -1
  635. package/types/src/index.d.ts +1 -0
  636. package/types/src/surface/surface.styles.d.ts +13 -6
  637. package/types/src/types/surface.d.ts +17 -22
  638. package/types/src/utils/number.d.ts +1 -1
  639. package/dist/SchmancyElement-OG71FtNv.js +0 -286
  640. package/dist/SchmancyElement-OG71FtNv.js.map +0 -1
  641. package/dist/SchmancyElement-PS1u0j1B.cjs +0 -2
  642. package/dist/SchmancyElement-PS1u0j1B.cjs.map +0 -1
  643. package/dist/area-CaEI33G0.cjs +0 -21
  644. package/dist/area-CaEI33G0.cjs.map +0 -1
  645. package/dist/area-DtCNCb8w.js.map +0 -1
  646. package/dist/audio-B924fI5N.cjs.map +0 -1
  647. package/dist/audio-DdN76ikW.js.map +0 -1
  648. package/dist/autocomplete-Dq3BkitV.cjs +0 -115
  649. package/dist/autocomplete-Dq3BkitV.cjs.map +0 -1
  650. package/dist/autocomplete-UNOknYUz.js.map +0 -1
  651. package/dist/busy--WqiXKnl.cjs +0 -134
  652. package/dist/busy--WqiXKnl.cjs.map +0 -1
  653. package/dist/busy-DzXyO0z6.js +0 -173
  654. package/dist/busy-DzXyO0z6.js.map +0 -1
  655. package/dist/button-CTvS5YX4.cjs.map +0 -1
  656. package/dist/button-DgoDfcJx.js.map +0 -1
  657. package/dist/card-C6ijJZpF.js.map +0 -1
  658. package/dist/card-Ci3_9Dd4.cjs +0 -177
  659. package/dist/card-Ci3_9Dd4.cjs.map +0 -1
  660. package/dist/chips-9eG-96_D.cjs.map +0 -1
  661. package/dist/chips-DF7akwz7.js.map +0 -1
  662. package/dist/date-range-C13_R3OA.js +0 -966
  663. package/dist/date-range-C13_R3OA.js.map +0 -1
  664. package/dist/date-range-Q2xj5Syc.cjs +0 -142
  665. package/dist/date-range-Q2xj5Syc.cjs.map +0 -1
  666. package/dist/date-range-inline-BnOD-ddB.js.map +0 -1
  667. package/dist/date-range-inline-DV2c_gWM.cjs.map +0 -1
  668. package/dist/details-B2-jECBh.cjs.map +0 -1
  669. package/dist/details-ByF66CyY.js.map +0 -1
  670. package/dist/directives-BL7mzVsA.js.map +0 -1
  671. package/dist/directives-DCb_LA9R.cjs.map +0 -1
  672. package/dist/divider-Bv2QiOZL.cjs +0 -57
  673. package/dist/divider-Bv2QiOZL.cjs.map +0 -1
  674. package/dist/divider-gYuz0zDU.js +0 -89
  675. package/dist/divider-gYuz0zDU.js.map +0 -1
  676. package/dist/expand-B9IUGVtc.cjs +0 -141
  677. package/dist/expand-B9IUGVtc.cjs.map +0 -1
  678. package/dist/expand-cZ8rfCWP.js.map +0 -1
  679. package/dist/form-DowzVsgI.cjs.map +0 -1
  680. package/dist/form-tG7LwDm4.js.map +0 -1
  681. package/dist/icons-BZeCloP9.cjs +0 -24
  682. package/dist/icons-BZeCloP9.cjs.map +0 -1
  683. package/dist/icons-Dup5skuk.js.map +0 -1
  684. package/dist/iframe-CDJjnNmo.cjs.map +0 -1
  685. package/dist/iframe-Xc3EPMZT.js.map +0 -1
  686. package/dist/input-DnmC6J1T.cjs.map +0 -1
  687. package/dist/input-cTyDxW9L.js.map +0 -1
  688. package/dist/input-chip-CV91URyU.cjs +0 -146
  689. package/dist/input-chip-CV91URyU.cjs.map +0 -1
  690. package/dist/input-chip-CYI17YOq.js.map +0 -1
  691. package/dist/layout-CNlZSJFU.cjs.map +0 -1
  692. package/dist/layout-DDxw0EwL.js.map +0 -1
  693. package/dist/lightbox-CH-y3rYB.js.map +0 -1
  694. package/dist/lightbox-CvtqoInF.cjs.map +0 -1
  695. package/dist/list-Dl8KfxrF.cjs +0 -40
  696. package/dist/list-Dl8KfxrF.cjs.map +0 -1
  697. package/dist/list-DrsawQ5R.js.map +0 -1
  698. package/dist/menu-BFRcTe3o.cjs.map +0 -1
  699. package/dist/menu-CsY5lMqY.js.map +0 -1
  700. package/dist/mixins-BoMURWag.cjs.map +0 -1
  701. package/dist/mixins-bCEXbwJV.js.map +0 -1
  702. package/dist/notification-DFKRMmSq.js.map +0 -1
  703. package/dist/notification-FBf3Mb2e.cjs.map +0 -1
  704. package/dist/option-Ct0lGdH3.js.map +0 -1
  705. package/dist/option-Il1KpU8M.cjs +0 -43
  706. package/dist/option-Il1KpU8M.cjs.map +0 -1
  707. package/dist/overlay-Bh8Q_R01.js.map +0 -1
  708. package/dist/overlay-sRXiMkjn.cjs.map +0 -1
  709. package/dist/overlay.confirm-body-CQihsR20.js.map +0 -1
  710. package/dist/overlay.confirm-body-Jc1EuMGs.cjs.map +0 -1
  711. package/dist/overlay.service-9Dp3g7ot.cjs.map +0 -1
  712. package/dist/overlay.service-BXPgS7ay.js.map +0 -1
  713. package/dist/progress-CWC5XYZ_.cjs +0 -51
  714. package/dist/progress-CWC5XYZ_.cjs.map +0 -1
  715. package/dist/progress-CYLshdo2.js.map +0 -1
  716. package/dist/radio-group-6kCgOgBL.cjs.map +0 -1
  717. package/dist/radio-group-bZtZHOj_.js.map +0 -1
  718. package/dist/select-CU3X-PIa.js.map +0 -1
  719. package/dist/select-MXsF8KsU.cjs +0 -56
  720. package/dist/select-MXsF8KsU.cjs.map +0 -1
  721. package/dist/sound.service-B4ZmXpH9.js.map +0 -1
  722. package/dist/sound.service-DjlMvicQ.cjs.map +0 -1
  723. package/dist/splash-screen-CN9dZcqC.cjs +0 -41
  724. package/dist/splash-screen-CN9dZcqC.cjs.map +0 -1
  725. package/dist/splash-screen-emCLYoVl.js.map +0 -1
  726. package/dist/src-DGDTkOvC.js.map +0 -1
  727. package/dist/src-DK3111z_.cjs +0 -240
  728. package/dist/src-DK3111z_.cjs.map +0 -1
  729. package/dist/state-CumAEPQH.cjs.map +0 -1
  730. package/dist/state-DMd_FUeA.js.map +0 -1
  731. package/dist/surface-DGI-FBoi.cjs +0 -7
  732. package/dist/surface-DGI-FBoi.cjs.map +0 -1
  733. package/dist/tabs-4T_4kCf-.js.map +0 -1
  734. package/dist/tabs-Byxxt-AH.cjs.map +0 -1
  735. package/dist/textarea-BwYwH9fu.cjs.map +0 -1
  736. package/dist/textarea-kkYNk1ET.js.map +0 -1
  737. package/dist/theme.service-Dv_55nfE.js.map +0 -1
  738. package/dist/theme.service-pjkTM209.cjs.map +0 -1
  739. package/dist/typography-BVkU11_q.js +0 -358
  740. package/dist/typography-BVkU11_q.js.map +0 -1
  741. package/dist/typography-aaQaIcNc.cjs +0 -282
  742. package/dist/typography-aaQaIcNc.cjs.map +0 -1
  743. package/dist/utils-DTa3QHxk.cjs.map +0 -1
  744. package/dist/utils-H8wNknWC.js.map +0 -1
  745. package/dist/window-C76zstbV.js.map +0 -1
  746. package/dist/window-CmB9XZzT.cjs +0 -58
  747. package/dist/window-CmB9XZzT.cjs.map +0 -1
  748. package/src/form/fields/date-range/date-range-presets.ts +0 -220
  749. package/src/form/fields/date-range/date-utils.ts +0 -58
  750. package/types/src/form/fields/date-range/date-range-presets.d.ts +0 -18
  751. package/types/src/form/fields/date-range/date-utils.d.ts +0 -15
  752. /package/dist/{hashContent-iRZJJWtE.cjs → hashContent--s09Ed_g.cjs} +0 -0
  753. /package/dist/{hashContent-BqU6v1Xr.js → hashContent-CAvrQ56N.js} +0 -0
  754. /package/dist/{rxjs-utils-Csnks202.cjs → rxjs-utils-4P2v57ke.cjs} +0 -0
  755. /package/dist/{rxjs-utils-d-ivVN84.js → rxjs-utils-JMFdgQSl.js} +0 -0
  756. /package/dist/{theme.interface-CSt7JUBD.cjs → theme.interface-B-qxDsZQ.cjs} +0 -0
  757. /package/dist/{theme.interface-odQEpZZH.js → theme.interface-B7caS5cg.js} +0 -0
  758. /package/dist/{utils-DTa3QHxk.cjs → utils-DIXndz6Q.cjs} +0 -0
  759. /package/dist/{utils-H8wNknWC.js → utils-dSPH7Oh9.js} +0 -0
@@ -1,282 +0,0 @@
1
- require(`./chunk-CncqDLb2.cjs`);const e=require(`./SchmancyElement-PS1u0j1B.cjs`);require(`./mixins-BoMURWag.cjs`);let t=require(`rxjs`),n=require(`rxjs/operators`),r=require(`lit/decorators.js`),i=require(`lit`),a=require(`lit/directives/ref.js`);var o=class extends e.t{constructor(...e){super(...e),this.type=`body`,this.token=`md`,this.editable=!1,this.value=``,this.placeholder=``,this.editRef=(0,a.createRef)()}static{this.styles=[i.css`
2
- :host {
3
- display: block;
4
- font-family: inherit;
5
- hyphens: none;
6
- }
7
-
8
- /* Text alignment */
9
- :host([align='center']) {
10
- text-align: center;
11
- }
12
-
13
- :host([align='left']) {
14
- text-align: start;
15
- }
16
-
17
- :host([align='right']) {
18
- text-align: right;
19
- }
20
-
21
- :host([align='justify']) {
22
- text-align: justify;
23
- }
24
-
25
- /* Font weight */
26
- :host([weight='bold']) {
27
- font-weight: 700;
28
- }
29
-
30
- :host([weight='medium']) {
31
- font-weight: 500;
32
- }
33
-
34
- :host([weight='normal']) {
35
- font-weight: 400;
36
- }
37
-
38
- /* Text transform */
39
- :host([transform='uppercase']) {
40
- text-transform: uppercase;
41
- }
42
-
43
- :host([transform='lowercase']) {
44
- text-transform: lowercase;
45
- }
46
-
47
- :host([transform='capitalize']) {
48
- text-transform: capitalize;
49
- }
50
-
51
- :host([transform='normal']) {
52
- text-transform: none;
53
- }
54
-
55
- /* Type-based weight defaults (when using Tailwind classes without token) */
56
- :host([type='display']),
57
- :host([type='headline']),
58
- :host([type='body']) {
59
- font-weight: 400;
60
- }
61
-
62
- :host([type='label']),
63
- :host([type='subtitle']),
64
- :host([type='title']) {
65
- font-weight: 500;
66
- }
67
-
68
- /* Display typography variants - Material Design 3 + Extended */
69
- :host([type='display'][token='xl']) {
70
- font-size: 72px;
71
- line-height: 80px;
72
- font-weight: 400;
73
- }
74
-
75
- :host([type='display'][token='lg']) {
76
- font-size: 57px;
77
- line-height: 64px;
78
- font-weight: 400;
79
- }
80
-
81
- :host([type='display'][token='md']) {
82
- font-size: 45px;
83
- line-height: 52px;
84
- font-weight: 400;
85
- }
86
-
87
- :host([type='display'][token='sm']) {
88
- font-size: 36px;
89
- line-height: 44px;
90
- font-weight: 400;
91
- }
92
-
93
- :host([type='display'][token='xs']) {
94
- font-size: 28px;
95
- line-height: 36px;
96
- font-weight: 400;
97
- }
98
-
99
- /* Headline typography variants - Material Design 3 + Extended */
100
- :host([type='headline'][token='xl']) {
101
- font-size: 36px;
102
- line-height: 44px;
103
- font-weight: 400;
104
- }
105
-
106
- :host([type='headline'][token='lg']) {
107
- font-size: 32px;
108
- line-height: 40px;
109
- font-weight: 400;
110
- }
111
-
112
- :host([type='headline'][token='md']) {
113
- font-size: 28px;
114
- line-height: 36px;
115
- font-weight: 400;
116
- }
117
-
118
- :host([type='headline'][token='sm']) {
119
- font-size: 24px;
120
- line-height: 32px;
121
- font-weight: 400;
122
- }
123
-
124
- :host([type='headline'][token='xs']) {
125
- font-size: 20px;
126
- line-height: 28px;
127
- font-weight: 400;
128
- }
129
-
130
- /* Title typography variants - Material Design 3 + Extended */
131
- :host([type='title'][token='xl']) {
132
- font-size: 24px;
133
- line-height: 32px;
134
- font-weight: 400;
135
- }
136
-
137
- :host([type='title'][token='lg']) {
138
- font-size: 22px;
139
- line-height: 28px;
140
- font-weight: 400;
141
- }
142
-
143
- :host([type='title'][token='md']) {
144
- font-size: 16px;
145
- line-height: 24px;
146
- font-weight: 500;
147
- }
148
-
149
- :host([type='title'][token='sm']) {
150
- font-size: 14px;
151
- line-height: 20px;
152
- font-weight: 500;
153
- }
154
-
155
- :host([type='title'][token='xs']) {
156
- font-size: 12px;
157
- line-height: 16px;
158
- font-weight: 500;
159
- }
160
-
161
- /* Subtitle typography variants - Extended from Material Design 3 */
162
- :host([type='subtitle'][token='xl']) {
163
- font-size: 20px;
164
- line-height: 28px;
165
- font-weight: 500;
166
- }
167
-
168
- :host([type='subtitle'][token='lg']) {
169
- font-size: 18px;
170
- line-height: 24px;
171
- font-weight: 500;
172
- }
173
-
174
- :host([type='subtitle'][token='md']) {
175
- font-size: 16px;
176
- line-height: 24px;
177
- font-weight: 500;
178
- }
179
-
180
- :host([type='subtitle'][token='sm']) {
181
- font-size: 14px;
182
- line-height: 20px;
183
- font-weight: 500;
184
- }
185
-
186
- :host([type='subtitle'][token='xs']) {
187
- font-size: 12px;
188
- line-height: 16px;
189
- font-weight: 500;
190
- }
191
-
192
- /* Body typography variants - Material Design 3 + Extended */
193
- :host([type='body'][token='xl']) {
194
- font-size: 18px;
195
- line-height: 28px;
196
- font-weight: 400;
197
- }
198
-
199
- :host([type='body'][token='lg']) {
200
- font-size: 16px;
201
- line-height: 24px;
202
- font-weight: 400;
203
- }
204
-
205
- :host([type='body'][token='md']) {
206
- font-size: 14px;
207
- line-height: 20px;
208
- font-weight: 400;
209
- }
210
-
211
- :host([type='body'][token='sm']) {
212
- font-size: 12px;
213
- line-height: 16px;
214
- font-weight: 400;
215
- }
216
-
217
- :host([type='body'][token='xs']) {
218
- font-size: 10px;
219
- line-height: 14px;
220
- font-weight: 400;
221
- }
222
-
223
- /* Label typography variants - Material Design 3 + Extended */
224
- :host([type='label'][token='xl']) {
225
- font-size: 16px;
226
- line-height: 22px;
227
- font-weight: 500;
228
- }
229
-
230
- :host([type='label'][token='lg']) {
231
- font-size: 14px;
232
- line-height: 20px;
233
- font-weight: 500;
234
- }
235
-
236
- :host([type='label'][token='md']) {
237
- font-size: 12px;
238
- line-height: 16px;
239
- font-weight: 500;
240
- }
241
-
242
- :host([type='label'][token='sm']) {
243
- font-size: 11px;
244
- line-height: 16px;
245
- font-weight: 500;
246
- }
247
-
248
- :host([type='label'][token='xs']) {
249
- font-size: 10px;
250
- line-height: 14px;
251
- font-weight: 500;
252
- }
253
-
254
- /* Note: Custom letter-spacing, font-size, and line-height should be applied via inline styles or Tailwind classes */
255
-
256
- :host([editable]) {
257
- cursor: text;
258
- border-radius: 4px;
259
- transition: background 150ms;
260
- min-height: 1em;
261
- }
262
- /* Editable div lives in shadow DOM so light DOM (Lit markers) is untouched */
263
- .edit {
264
- outline: none;
265
- min-height: 1em;
266
- font: inherit;
267
- color: inherit;
268
- letter-spacing: inherit;
269
- line-height: inherit;
270
- }
271
- .edit:empty::before {
272
- content: attr(data-placeholder);
273
- pointer-events: none;
274
- display: block;
275
- opacity: 0.35;
276
- }
277
- `]}static{this.shadowRootOptions={mode:`open`,delegatesFocus:!0}}selectAll(){let e=this.editRef.value;if(!e)return;e.focus();let t=window.getSelection();if(t&&e.textContent){let n=document.createRange();n.selectNodeContents(e),t.removeAllRanges(),t.addRange(n)}}connectedCallback(){super.connectedCallback(),(0,t.fromEvent)(this,`focusout`).pipe((0,n.filter)(()=>this.editable),(0,n.tap)(()=>{let e=this.editRef.value;if(!e)return;let t=e.innerText.trim();t!==this.value&&this.dispatchEvent(new CustomEvent(`change`,{detail:{value:t},bubbles:!0,composed:!0})),t||(e.textContent=``)}),(0,n.takeUntil)(this.disconnecting)).subscribe(),(0,t.fromEvent)(this,`input`).pipe((0,n.filter)(()=>this.editable),(0,n.tap)(()=>{let e=this.editRef.value;e&&!e.innerText.trim()&&(e.textContent=``)}),(0,n.takeUntil)(this.disconnecting)).subscribe(),(0,t.fromEvent)(this,`keydown`).pipe((0,n.filter)(()=>this.editable),(0,n.filter)(e=>e.key===`Enter`),(0,n.tap)(e=>{e.preventDefault(),(this.editRef.value??this).blur()}),(0,n.takeUntil)(this.disconnecting)).subscribe()}updated(e){if(super.updated(e),e.has(`maxLines`)&&(this.classList.remove(`line-clamp-1`,`line-clamp-2`,`line-clamp-3`,`line-clamp-4`,`line-clamp-5`,`line-clamp-6`),this.maxLines&&this.classList.add(`line-clamp-${this.maxLines}`)),(e.has(`value`)||e.has(`editable`))&&this.editable){let e=this.editRef.value;e&&document.activeElement!==e&&(this.value?e.innerText=this.value:e.textContent=``)}}render(){return this.editable?i.html`<div
278
- ${(0,a.ref)(this.editRef)}
279
- class="edit"
280
- contenteditable="true"
281
- data-placeholder=${this.placeholder??``}
282
- ></div>`:i.html`<slot></slot>`}};e.u([(0,r.property)({type:String,reflect:!0})],o.prototype,`type`,void 0),e.u([(0,r.property)({type:String,reflect:!0})],o.prototype,`token`,void 0),e.u([(0,r.property)({type:String,reflect:!0})],o.prototype,`align`,void 0),e.u([(0,r.property)({type:String,reflect:!0})],o.prototype,`weight`,void 0),e.u([(0,r.property)({type:String,reflect:!0})],o.prototype,`transform`,void 0),e.u([(0,r.property)({type:Number})],o.prototype,`maxLines`,void 0),e.u([(0,r.property)({type:Boolean,reflect:!0})],o.prototype,`editable`,void 0),e.u([(0,r.property)({type:String})],o.prototype,`value`,void 0),e.u([(0,r.property)({type:String})],o.prototype,`placeholder`,void 0),o=e.u([(0,r.customElement)(`schmancy-typography`)],o),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return o}});
@@ -1 +0,0 @@
1
- {"version":3,"file":"typography-aaQaIcNc.cjs","names":[],"sources":["../src/typography/typography.ts"],"sourcesContent":["import { SchmancyElement } from '@mixins/index'\nimport { css, html } from 'lit'\nimport { customElement, property } from 'lit/decorators.js'\nimport { createRef, ref } from 'lit/directives/ref.js'\nimport { fromEvent } from 'rxjs'\nimport { filter, tap, takeUntil } from 'rxjs/operators'\n\n// Material Design 3 typography - https://m3.material.io/styles/typography/type-scale-tokens\n\n/**\n * @element schmancy-typography\n * @slot - The text for the typography.\n */\n@customElement('schmancy-typography')\nexport class SchmancyTypography extends SchmancyElement {\n\tstatic styles = [css`\n\t:host {\n\t\tdisplay: block;\n\t\tfont-family: inherit;\n\t\thyphens: none;\n\t}\n\n\t/* Text alignment */\n\t:host([align='center']) {\n\t\ttext-align: center;\n\t}\n\n\t:host([align='left']) {\n\t\ttext-align: start;\n\t}\n\n\t:host([align='right']) {\n\t\ttext-align: right;\n\t}\n\n\t:host([align='justify']) {\n\t\ttext-align: justify;\n\t}\n\n\t/* Font weight */\n\t:host([weight='bold']) {\n\t\tfont-weight: 700;\n\t}\n\n\t:host([weight='medium']) {\n\t\tfont-weight: 500;\n\t}\n\n\t:host([weight='normal']) {\n\t\tfont-weight: 400;\n\t}\n\n\t/* Text transform */\n\t:host([transform='uppercase']) {\n\t\ttext-transform: uppercase;\n\t}\n\n\t:host([transform='lowercase']) {\n\t\ttext-transform: lowercase;\n\t}\n\n\t:host([transform='capitalize']) {\n\t\ttext-transform: capitalize;\n\t}\n\n\t:host([transform='normal']) {\n\t\ttext-transform: none;\n\t}\n\n\t/* Type-based weight defaults (when using Tailwind classes without token) */\n\t:host([type='display']),\n\t:host([type='headline']),\n\t:host([type='body']) {\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='label']),\n\t:host([type='subtitle']),\n\t:host([type='title']) {\n\t\tfont-weight: 500;\n\t}\n\n\t/* Display typography variants - Material Design 3 + Extended */\n\t:host([type='display'][token='xl']) {\n\t\tfont-size: 72px;\n\t\tline-height: 80px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='display'][token='lg']) {\n\t\tfont-size: 57px;\n\t\tline-height: 64px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='display'][token='md']) {\n\t\tfont-size: 45px;\n\t\tline-height: 52px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='display'][token='sm']) {\n\t\tfont-size: 36px;\n\t\tline-height: 44px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='display'][token='xs']) {\n\t\tfont-size: 28px;\n\t\tline-height: 36px;\n\t\tfont-weight: 400;\n\t}\n\n\t/* Headline typography variants - Material Design 3 + Extended */\n\t:host([type='headline'][token='xl']) {\n\t\tfont-size: 36px;\n\t\tline-height: 44px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='headline'][token='lg']) {\n\t\tfont-size: 32px;\n\t\tline-height: 40px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='headline'][token='md']) {\n\t\tfont-size: 28px;\n\t\tline-height: 36px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='headline'][token='sm']) {\n\t\tfont-size: 24px;\n\t\tline-height: 32px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='headline'][token='xs']) {\n\t\tfont-size: 20px;\n\t\tline-height: 28px;\n\t\tfont-weight: 400;\n\t}\n\n\t/* Title typography variants - Material Design 3 + Extended */\n\t:host([type='title'][token='xl']) {\n\t\tfont-size: 24px;\n\t\tline-height: 32px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='title'][token='lg']) {\n\t\tfont-size: 22px;\n\t\tline-height: 28px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='title'][token='md']) {\n\t\tfont-size: 16px;\n\t\tline-height: 24px;\n\t\tfont-weight: 500;\n\t}\n\n\t:host([type='title'][token='sm']) {\n\t\tfont-size: 14px;\n\t\tline-height: 20px;\n\t\tfont-weight: 500;\n\t}\n\n\t:host([type='title'][token='xs']) {\n\t\tfont-size: 12px;\n\t\tline-height: 16px;\n\t\tfont-weight: 500;\n\t}\n\n\t/* Subtitle typography variants - Extended from Material Design 3 */\n\t:host([type='subtitle'][token='xl']) {\n\t\tfont-size: 20px;\n\t\tline-height: 28px;\n\t\tfont-weight: 500;\n\t}\n\n\t:host([type='subtitle'][token='lg']) {\n\t\tfont-size: 18px;\n\t\tline-height: 24px;\n\t\tfont-weight: 500;\n\t}\n\n\t:host([type='subtitle'][token='md']) {\n\t\tfont-size: 16px;\n\t\tline-height: 24px;\n\t\tfont-weight: 500;\n\t}\n\n\t:host([type='subtitle'][token='sm']) {\n\t\tfont-size: 14px;\n\t\tline-height: 20px;\n\t\tfont-weight: 500;\n\t}\n\n\t:host([type='subtitle'][token='xs']) {\n\t\tfont-size: 12px;\n\t\tline-height: 16px;\n\t\tfont-weight: 500;\n\t}\n\n\t/* Body typography variants - Material Design 3 + Extended */\n\t:host([type='body'][token='xl']) {\n\t\tfont-size: 18px;\n\t\tline-height: 28px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='body'][token='lg']) {\n\t\tfont-size: 16px;\n\t\tline-height: 24px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='body'][token='md']) {\n\t\tfont-size: 14px;\n\t\tline-height: 20px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='body'][token='sm']) {\n\t\tfont-size: 12px;\n\t\tline-height: 16px;\n\t\tfont-weight: 400;\n\t}\n\n\t:host([type='body'][token='xs']) {\n\t\tfont-size: 10px;\n\t\tline-height: 14px;\n\t\tfont-weight: 400;\n\t}\n\n\t/* Label typography variants - Material Design 3 + Extended */\n\t:host([type='label'][token='xl']) {\n\t\tfont-size: 16px;\n\t\tline-height: 22px;\n\t\tfont-weight: 500;\n\t}\n\n\t:host([type='label'][token='lg']) {\n\t\tfont-size: 14px;\n\t\tline-height: 20px;\n\t\tfont-weight: 500;\n\t}\n\n\t:host([type='label'][token='md']) {\n\t\tfont-size: 12px;\n\t\tline-height: 16px;\n\t\tfont-weight: 500;\n\t}\n\n\t:host([type='label'][token='sm']) {\n\t\tfont-size: 11px;\n\t\tline-height: 16px;\n\t\tfont-weight: 500;\n\t}\n\n\t:host([type='label'][token='xs']) {\n\t\tfont-size: 10px;\n\t\tline-height: 14px;\n\t\tfont-weight: 500;\n\t}\n\n\t/* Note: Custom letter-spacing, font-size, and line-height should be applied via inline styles or Tailwind classes */\n\n\t:host([editable]) {\n\t\tcursor: text;\n\t\tborder-radius: 4px;\n\t\ttransition: background 150ms;\n\t\tmin-height: 1em;\n\t}\n\t/* Editable div lives in shadow DOM so light DOM (Lit markers) is untouched */\n\t.edit {\n\t\toutline: none;\n\t\tmin-height: 1em;\n\t\tfont: inherit;\n\t\tcolor: inherit;\n\t\tletter-spacing: inherit;\n\t\tline-height: inherit;\n\t}\n\t.edit:empty::before {\n\t\tcontent: attr(data-placeholder);\n\t\tpointer-events: none;\n\t\tdisplay: block;\n\t\topacity: 0.35;\n\t}\n`];\n\tstatic shadowRootOptions: ShadowRootInit = {\n\t\tmode: 'open',\n\t\tdelegatesFocus: true,\n\t}\n\n\t/**\n\t * @attr type - The type of the typography.\n\t * @default 'body'\n\t * @type {'display' | 'headline' | 'title' | 'subtitle' | 'body' | 'label'}\n\t */\n\t@property({ type: String, reflect: true })\n\ttype: 'display' | 'headline' | 'title' | 'subtitle' | 'body' | 'label' = 'body'\n\n\t/**\n\t * @attr token - The size token.\n\t * @deprecated Prefer using Tailwind responsive text classes for better responsive design.\n\t * Set token=\"\" and use class=\"text-sm md:text-base lg:text-lg\" instead.\n\t * Example: <schmancy-typography type=\"display\" token=\"\" class=\"text-2xl sm:text-3xl md:text-4xl\">\n\t * @default 'md'\n\t * @type {'xs' | 'sm' | 'md' | 'lg' | 'xl' | ''}\n\t */\n\t@property({ type: String, reflect: true })\n\ttoken: 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '' = 'md'\n\n\t/**\n\t * @attr\n\t * @default inherit\n\t * @type {'left' |'center' |'right'}\n\t */\n\t@property({ type: String, reflect: true })\n\talign: 'left' | 'center' | 'justify' | 'right' | undefined\n\n\t/**\n\t * @attr\n\t * @default inherit\n\t * @type {'normal' | 'medium' |'bold'}\n\t * @public\n\t */\n\t@property({ type: String, reflect: true })\n\tweight: 'normal' | 'medium' | 'bold' | undefined\n\t\n\t/**\n\t *\n\t * @attr\n\t * @default inherit\n\t * @type {'uppercase' |'lowercase' |'capitalize' |'normal'}\n\t * @public\n\t */\n\t@property({ type: String, reflect: true }) \n\ttransform: 'uppercase' | 'lowercase' | 'capitalize' | 'normal' | undefined\n\n\t@property({ type: Number })\n\tmaxLines: 1 | 2 | 3 | 4 | 5 | 6 | undefined\n\n\t/** When true, the element becomes contenteditable and dispatches 'change' events on blur/Enter */\n\t@property({ type: Boolean, reflect: true }) editable = false\n\t/** The text value when in editable mode. Set via property binding: .value=${...} */\n\t@property({ type: String }) value = ''\n\t/** Placeholder shown when editable and empty */\n\t@property({ type: String }) placeholder = ''\n\n\tprivate editRef = createRef<HTMLDivElement>()\n\n\t/** Focus and select all text in editable mode */\n\tselectAll() {\n\t\tconst el = this.editRef.value\n\t\tif (!el) return\n\t\tel.focus()\n\t\tconst sel = window.getSelection()\n\t\tif (sel && el.textContent) {\n\t\t\tconst range = document.createRange()\n\t\t\trange.selectNodeContents(el)\n\t\t\tsel.removeAllRanges()\n\t\t\tsel.addRange(range)\n\t\t}\n\t}\n\n\tconnectedCallback() {\n\t\tsuper.connectedCallback()\n\n\t\tfromEvent<FocusEvent>(this, 'focusout').pipe(\n\t\t\tfilter(() => this.editable),\n\t\t\ttap(() => {\n\t\t\t\tconst el = this.editRef.value\n\t\t\t\tif (!el) return\n\t\t\t\tconst newValue = el.innerText.trim()\n\t\t\t\tif (newValue !== this.value) {\n\t\t\t\t\tthis.dispatchEvent(new CustomEvent('change', {\n\t\t\t\t\t\tdetail: { value: newValue },\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\t\t\t\t// Ensure truly empty so :empty CSS placeholder works\n\t\t\t\tif (!newValue) el.textContent = ''\n\t\t\t}),\n\t\t\ttakeUntil(this.disconnecting),\n\t\t).subscribe()\n\n\t\t// Clean stray <br> / whitespace nodes so :empty CSS matches\n\t\tfromEvent(this, 'input').pipe(\n\t\t\tfilter(() => this.editable),\n\t\t\ttap(() => {\n\t\t\t\tconst el = this.editRef.value\n\t\t\t\tif (el && !el.innerText.trim()) el.textContent = ''\n\t\t\t}),\n\t\t\ttakeUntil(this.disconnecting),\n\t\t).subscribe()\n\n\t\tfromEvent<KeyboardEvent>(this, 'keydown').pipe(\n\t\t\tfilter(() => this.editable),\n\t\t\tfilter(e => e.key === 'Enter'),\n\t\t\ttap(e => { e.preventDefault(); (this.editRef.value ?? this).blur() }),\n\t\t\ttakeUntil(this.disconnecting),\n\t\t).subscribe()\n\t}\n\n\tprotected updated(changedProperties: Map<string, unknown>): void {\n\t\tsuper.updated(changedProperties)\n\t\tif (changedProperties.has('maxLines')) {\n\t\t\t// Remove all line-clamp classes\n\t\t\tthis.classList.remove('line-clamp-1', 'line-clamp-2', 'line-clamp-3', 'line-clamp-4', 'line-clamp-5', 'line-clamp-6')\n\t\t\t// Add the appropriate one\n\t\t\tif (this.maxLines) {\n\t\t\t\tthis.classList.add(`line-clamp-${this.maxLines}`)\n\t\t\t}\n\t\t}\n\t\tif ((changedProperties.has('value') || changedProperties.has('editable')) && this.editable) {\n\t\t\tconst el = this.editRef.value\n\t\t\tif (el && document.activeElement !== el) {\n\t\t\t\tif (this.value) {\n\t\t\t\t\tel.innerText = this.value\n\t\t\t\t} else {\n\t\t\t\t\tel.textContent = ''\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tprotected render(): unknown {\n\t\tif (this.editable) {\n\t\t\treturn html`<div\n\t\t\t\t${ref(this.editRef)}\n\t\t\t\tclass=\"edit\"\n\t\t\t\tcontenteditable=\"true\"\n\t\t\t\tdata-placeholder=${this.placeholder ?? ''}\n\t\t\t></div>`\n\t\t}\n\t\treturn html`<slot></slot>`\n\t}\n}\n\ndeclare global {\n\tinterface HTMLElementTagNameMap {\n\t\t'schmancy-typography': SchmancyTypography\n\t}\n}"],"mappings":"wPAcO,IAAA,EAAA,cAAiC,EAAA,CAAA,CAAA,YAAA,GAAA,EAAA,CAAA,MAAA,GAAA,CAAA,EAAA,KAAA,KAiSkC,OAAA,KAAA,MAW1B,KAAA,KAAA,SAAA,CAiCQ,EAAA,KAAA,MAEnB,GAAA,KAAA,YAEM,GAAA,KAAA,SAAA,EAAA,EAAA,WAAA,CAAA,CAAA,OAAA,KAAA,OAhV1B,CAAC,EAAA,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iCAqRuB,CAC1C,KAAM,OACN,eAAA,CAAgB,CAAA,CAAA,CA8DjB,WAAA,CACC,IAAM,EAAK,KAAK,QAAQ,MACxB,GAAA,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A,IAAA,EAAA,EAAA,EAAA,EAAA,EAAA,EAAA,EAAA,UAIhB,CAAE,KAAM,QAAS,QAAA,CAAS,CAAA,CAAA,CAAA,EAAM,EAAA,UAAA,WAAA,IAAA,EAAA,EAAA,EAAA,EAAA,EAAA,EAAA,EAAA,UAEhC,CAAE,KAAM,MAAA,CAAA,CAAA,EAAQ,EAAA,UAAA,QAAA,IAAA,EAAA,EAAA,EAAA,EAAA,EAAA,EAAA,EAAA,UAEhB,CAAE,KAAM,MAAA,CAAA,CAAA,EAAQ,EAAA,UAAA,cAAA,IAAA,EAAA,EAAA,EAAA,EAAA,EAAA,EAAA,EAAA,EAAA,eAlVZ,qBAAA,CAAA,EAAqB,CAAA,EAAA,OAAA,eAAA,QAAA,IAAA,CAAA,WAAA,CAAA,EAAA,IAAA,UAAA,CAAA,OAAA,CAAA,CAAA,CAAA"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"utils-DTa3QHxk.cjs","names":[],"sources":["../src/utils/intersection.ts","../src/utils/number.ts"],"sourcesContent":["import { Observable } from 'rxjs'\n\nexport function intersection$(\n\telement: Element | Element[],\n\toptions = {\n\t\tthreshold: 0.5,\n\t},\n) {\n\treturn new Observable(subscriber => {\n\t\tconst observer = new IntersectionObserver(entries => {\n\t\t\tsubscriber.next(entries) // Emit the entries array\n\t\t}, options)\n\n\t\t// Observe each element\n\t\tif (Array.isArray(element)) {\n\t\t\telement.forEach(el => observer.observe(el))\n\t\t} else {\n\t\t\tobserver.observe(element)\n\t\t}\n\n\t\t// Cleanup on unsubscription\n\t\treturn () => {\n\t\t\tobserver.disconnect()\n\t\t}\n\t})\n}\n","/**\n * Gets the user's system locale from browser settings.\n * Falls back to 'de-DE' if not available (e.g., in Node.js environment).\n */\nconst getSystemLocale = (): string => {\n if (typeof navigator !== 'undefined' && navigator.language) {\n return navigator.language\n }\n return 'de-DE'\n}\n\nexport class Numbers {\n /**\n * The system locale detected from user's browser/OS settings.\n * Use this for display formatting. For exports, use explicit locale like 'de-DE'.\n */\n readonly systemLocale = getSystemLocale()\n\n /**\n * Rounds a number to the specified number of decimal places.\n * @param {number} number - The number to round.\n * @param {number} [decimalPlaces=2] - The number of decimal places to round to.\n * @returns {number} - The rounded number.\n */\n roundNumber(number: number, decimalPlaces: number = 2): number {\n const factor = Math.pow(10, decimalPlaces);\n return Math.round(number * factor) / factor;\n }\n\n /**\n * Formats a number according to the specified locale and options.\n * Uses the user's system locale by default for display formatting.\n *\n * @param {number} number - The number to format.\n * @param {string} [locale] - The locale string (e.g., 'de-DE'). Defaults to system locale.\n * @param {Intl.NumberFormatOptions} [options={}] - Additional formatting options.\n * @returns {string} - The formatted number as a string.\n *\n * @example\n * // Uses system locale (e.g., user's browser setting)\n * numbers.formatNumber(1234.56)\n *\n * // Explicit locale for exports (bank systems expect German format)\n * numbers.formatNumber(1234.56, 'de-DE', { useGrouping: false })\n */\n formatNumber(\n number: number,\n locale: string = this.systemLocale,\n options: Intl.NumberFormatOptions = {},\n ): string {\n return new Intl.NumberFormat(locale, options).format(number);\n }\n\n /**\n * Parses a string with a specified decimal separator into a number.\n * @param {string} numberString - The string to parse.\n * @param {string} [decimalSeparator=','] - The decimal separator used in the string.\n * @returns {number} - The parsed number.\n */\n parseToPureNumber(\n numberString: string,\n decimalSeparator: string = \",\",\n ): number {\n const normalizedString = numberString.replace(decimalSeparator, \".\");\n return parseFloat(normalizedString);\n }\n\n /**\n * Rounds a number to the specified decimal places and formats it according to the specified locale and options.\n * Uses the user's system locale by default.\n *\n * @param {number} number - The number to process.\n * @param {number} [decimalPlaces=2] - The number of decimal places to round to.\n * @param {string} [locale] - The locale string. Defaults to system locale.\n * @param {Intl.NumberFormatOptions} [options={}] - Additional formatting options.\n * @returns {string} - The formatted number as a string.\n */\n doIt(\n number: number,\n decimalPlaces: number = 2,\n locale: string = this.systemLocale,\n options: Intl.NumberFormatOptions = {},\n ): string {\n const roundedNumber = this.roundNumber(number, decimalPlaces);\n return this.formatNumber(roundedNumber, locale, options);\n }\n\n /**\n * Format a currency amount consistently across the application\n *\n * @param amount The amount to format\n * @param currency The currency symbol to display (default: '€')\n * @returns Formatted amount with currency symbol\n */\n formatCurrency(amount: number, currency: string = \"€\"): string {\n return `${currency}${this.doIt(amount)}`;\n }\n\n /**\n * Format a delta value with appropriate directional indicator\n *\n * @param delta The delta amount to format\n * @param currency The currency symbol to display (default: '€')\n * @returns Formatted delta with direction indicator and currency symbol\n */\n formatDelta(delta: number, currency: string = \"€\"): string {\n const symbol = delta > 0 ? \"↑\" : delta < 0 ? \"↓\" : \"→\";\n return `${symbol} ${currency}${this.doIt(Math.abs(delta))}`;\n }\n\n /**\n * Get CSS class for delta value\n *\n * @param delta The delta amount\n * @returns CSS class based on delta direction\n */\n getDeltaClass(delta: number): string {\n return delta > 0\n ? \"text-error-default\"\n : delta < 0\n ? \"text-primary-default\"\n : \"text-neutral\";\n }\n\n /**\n * Converts a decimal number to a mixed fraction string\n * For example: 1.5 becomes \"1 1/2\", 2.25 becomes \"2 1/4\"\n *\n * @param number The decimal number to convert\n * @param precision The precision level for fraction approximation (default: 16)\n * @param maxDenominator The maximum allowed denominator (default: 4)\n * @returns A string representing the mixed fraction\n */\n toMixedFraction(\n number: number,\n precision: number = 16,\n maxDenominator: number = 4,\n ): string {\n // Handle negative numbers\n const isNegative = number < 0;\n number = Math.abs(number);\n\n // Extract whole number part\n const wholePart = Math.floor(number);\n\n // Extract decimal part and convert to fraction\n let decimalPart = number - wholePart;\n\n // If the decimal part is very small or zero, just return the whole number\n if (decimalPart < 1 / Math.pow(10, precision)) {\n return isNegative ? `-${wholePart}` : `${wholePart}`;\n }\n\n // Find the best fraction approximation using precision and max denominator\n const { numerator, denominator } = this.decimalToFraction(\n decimalPart,\n precision,\n maxDenominator,\n );\n\n // Format based on whether there's a whole part\n if (wholePart === 0) {\n return isNegative\n ? `-${numerator}/${denominator}`\n : `${numerator}/${denominator}`;\n } else {\n return isNegative\n ? `-${wholePart} ${numerator}/${denominator}`\n : `${wholePart} ${numerator}/${denominator}`;\n }\n }\n\n /**\n * Converts a decimal to a simplified fraction with a maximum denominator\n *\n * @param decimal The decimal part to convert (0 <= decimal < 1)\n * @param precision The precision level for approximation\n * @param maxDenominator The maximum allowed denominator (default: 4)\n * @returns Object containing numerator and denominator\n */\n private decimalToFraction(\n decimal: number,\n precision: number,\n maxDenominator: number = 4,\n ): { numerator: number; denominator: number } {\n if (decimal === 0) {\n return { numerator: 0, denominator: 1 };\n }\n\n // Initialize best approximation\n let bestError = Infinity;\n let bestNumerator = 0;\n let bestDenominator = 1;\n\n // Check common fractions first for better user experience\n // Filter to only include fractions with denominators <= maxDenominator\n const commonFractions = [\n { n: 1, d: 2 }, // 1/2\n { n: 1, d: 3 }, // 1/3\n { n: 2, d: 3 }, // 2/3\n { n: 1, d: 4 }, // 1/4\n { n: 3, d: 4 }, // 3/4\n ];\n\n // Add additional fractions only if maxDenominator allows\n const additionalFractions = [];\n if (maxDenominator >= 5) {\n additionalFractions.push(\n { n: 1, d: 5 }, // 1/5\n { n: 2, d: 5 }, // 2/5\n { n: 3, d: 5 }, // 3/5\n { n: 4, d: 5 }, // 4/5\n );\n }\n if (maxDenominator >= 6) {\n additionalFractions.push(\n { n: 1, d: 6 }, // 1/6\n { n: 5, d: 6 }, // 5/6\n );\n }\n if (maxDenominator >= 8) {\n additionalFractions.push(\n { n: 1, d: 8 }, // 1/8\n { n: 3, d: 8 }, // 3/8\n { n: 5, d: 8 }, // 5/8\n { n: 7, d: 8 }, // 7/8\n );\n }\n if (maxDenominator >= 10) {\n additionalFractions.push(\n { n: 1, d: 10 }, // 1/10\n { n: 3, d: 10 }, // 3/10\n { n: 7, d: 10 }, // 7/10\n { n: 9, d: 10 }, // 9/10\n );\n }\n if (maxDenominator >= 12) {\n additionalFractions.push(\n { n: 1, d: 12 }, // 1/12\n { n: 5, d: 12 }, // 5/12\n { n: 7, d: 12 }, // 7/12\n { n: 11, d: 12 }, // 11/12\n );\n }\n if (maxDenominator >= 16) {\n additionalFractions.push(\n { n: 1, d: 16 }, // 1/16\n { n: 3, d: 16 }, // 3/16\n { n: 5, d: 16 }, // 5/16\n { n: 7, d: 16 }, // 7/16\n { n: 9, d: 16 }, // 9/16\n { n: 11, d: 16 }, // 11/16\n { n: 13, d: 16 }, // 13/16\n { n: 15, d: 16 }, // 15/16\n );\n }\n\n // Combine all applicable fractions\n const allFractions = [...commonFractions, ...additionalFractions];\n\n // Check common fractions first\n for (const frac of allFractions) {\n if (frac.d <= maxDenominator) {\n const error = Math.abs(decimal - frac.n / frac.d);\n if (error < bestError) {\n bestError = error;\n bestNumerator = frac.n;\n bestDenominator = frac.d;\n\n // If we're very close to a common fraction, just use it\n if (error < 1 / Math.pow(10, precision)) {\n return { numerator: frac.n, denominator: frac.d };\n }\n }\n }\n }\n\n // If no suitable common fraction found, use a more sophisticated approach\n // for denominators up to maxDenominator\n\n // Find the best approximation with denominator <= maxDenominator\n for (let d = 1; d <= maxDenominator; d++) {\n // Find best numerator for this denominator\n const n = Math.round(decimal * d);\n const error = Math.abs(decimal - n / d);\n\n if (error < bestError) {\n bestError = error;\n bestNumerator = n;\n bestDenominator = d;\n }\n }\n\n // Only use continued fraction expansion if we're significantly off\n // and maxDenominator allows for larger denominators\n if (bestError > 1 / Math.pow(10, precision / 2) && maxDenominator > 4) {\n // Implementation of continued fraction expansion\n let n1 = 1,\n n2 = 0;\n let d1 = 0,\n d2 = 1;\n let b = decimal;\n\n do {\n let a = Math.floor(b);\n let aux = n1;\n n1 = a * n1 + n2;\n n2 = aux;\n\n aux = d1;\n d1 = a * d1 + d2;\n d2 = aux;\n\n b = 1 / (b - a);\n\n // Calculate the current approximation\n const currentError = Math.abs(decimal - n1 / d1);\n\n // If we hit the precision limit or if the denominator gets too large, use this approximation\n if (currentError < 1 / Math.pow(10, precision) || d1 > maxDenominator) {\n // If d1 exceeds maxDenominator, return the previous best result\n if (d1 > maxDenominator) {\n return { numerator: bestNumerator, denominator: bestDenominator };\n }\n\n // Otherwise return this result\n return { numerator: n1, denominator: d1 };\n }\n } while (b !== Infinity);\n\n bestNumerator = n1;\n bestDenominator = d1;\n }\n\n // Simplify the fraction\n const gcd = this.findGCD(bestNumerator, bestDenominator);\n return {\n numerator: bestNumerator / gcd,\n denominator: bestDenominator / gcd,\n };\n }\n\n /**\n * Calculates the greatest common divisor of two numbers\n */\n private findGCD(a: number, b: number): number {\n return b === 0 ? a : this.findGCD(b, a % b);\n }\n\n /**\n * Alternative method to get a formatted mixed fraction with a specified format\n *\n * @param number The decimal number to convert\n * @param format The format specification ('unicode', 'ascii', 'superscript')\n * @param precision The precision level for fraction approximation\n * @param maxDenominator The maximum allowed denominator (default: 4)\n * @returns A formatted string representing the mixed fraction\n */\n formatMixedFraction(\n number: number,\n format: \"unicode\" | \"ascii\" | \"superscript\" = \"ascii\",\n precision: number = 16,\n maxDenominator: number = 4,\n ): string {\n // Get the basic mixed fraction\n const basicFraction = this.toMixedFraction(\n number,\n precision,\n maxDenominator,\n );\n\n // If the format is ascii, just return the basic fraction\n if (format === \"ascii\") {\n return basicFraction;\n }\n\n // For unicode and superscript formats, we need to parse the basic fraction\n const isNegative = basicFraction.startsWith(\"-\");\n const withoutSign = isNegative ? basicFraction.substring(1) : basicFraction;\n\n // Check if it's a pure fraction or mixed fraction\n const hasMixedPart = withoutSign.includes(\" \");\n\n if (!withoutSign.includes(\"/\")) {\n // If there's no fraction part, just return the number\n return basicFraction;\n }\n\n let wholePart = \"\";\n let fractionPart = withoutSign;\n\n if (hasMixedPart) {\n // Split the whole and fraction parts\n const parts = withoutSign.split(\" \");\n wholePart = parts[0];\n fractionPart = parts[1];\n }\n\n // Split the fraction part into numerator and denominator\n const [numerator, denominator] = fractionPart.split(\"/\");\n\n if (format === \"unicode\") {\n // Try to find a unicode fraction character\n const unicodeFraction = this.getUnicodeFraction(\n parseInt(numerator),\n parseInt(denominator),\n );\n\n if (unicodeFraction) {\n return isNegative\n ? `-${wholePart}${hasMixedPart ? \" \" : \"\"}${unicodeFraction}`\n : `${wholePart}${hasMixedPart ? \" \" : \"\"}${unicodeFraction}`;\n }\n\n // Fallback to basic format if no unicode fraction is available\n return basicFraction;\n }\n\n // Handle superscript format\n if (format === \"superscript\") {\n const superNumerator = this.toSuperscript(numerator);\n const subDenominator = this.toSubscript(denominator);\n\n if (hasMixedPart) {\n return isNegative\n ? `-${wholePart} ${superNumerator}⁄${subDenominator}`\n : `${wholePart} ${superNumerator}⁄${subDenominator}`;\n } else {\n return isNegative\n ? `-${superNumerator}⁄${subDenominator}`\n : `${superNumerator}⁄${subDenominator}`;\n }\n }\n\n // Fallback to basic format\n return basicFraction;\n }\n\n /**\n * Gets the Unicode fraction character if available\n *\n * @param numerator The numerator\n * @param denominator The denominator\n * @returns Unicode fraction character or null if not available\n */\n private getUnicodeFraction(\n numerator: number,\n denominator: number,\n ): string | null {\n // Map common fractions to their Unicode characters\n const fractionMap: Record<string, string> = {\n \"1/4\": \"¼\",\n \"1/2\": \"½\",\n \"3/4\": \"¾\",\n \"1/3\": \"⅓\",\n \"2/3\": \"⅔\",\n \"1/5\": \"⅕\",\n \"2/5\": \"⅖\",\n \"3/5\": \"⅗\",\n \"4/5\": \"⅘\",\n \"1/6\": \"⅙\",\n \"5/6\": \"⅚\",\n \"1/7\": \"⅐\",\n \"1/8\": \"⅛\",\n \"3/8\": \"⅜\",\n \"5/8\": \"⅝\",\n \"7/8\": \"⅞\",\n \"1/9\": \"⅑\",\n \"1/10\": \"⅒\",\n };\n\n const key = `${numerator}/${denominator}`;\n return fractionMap[key] || null;\n }\n\n /**\n * Converts digits to superscript\n */\n private toSuperscript(str: string): string {\n const superscriptMap: Record<string, string> = {\n \"0\": \"⁰\",\n \"1\": \"¹\",\n \"2\": \"²\",\n \"3\": \"³\",\n \"4\": \"⁴\",\n \"5\": \"⁵\",\n \"6\": \"⁶\",\n \"7\": \"⁷\",\n \"8\": \"⁸\",\n \"9\": \"⁹\",\n \"-\": \"⁻\",\n };\n\n return str\n .split(\"\")\n .map((char) => superscriptMap[char] || char)\n .join(\"\");\n }\n\n /**\n * Converts digits to subscript\n */\n private toSubscript(str: string): string {\n const subscriptMap: Record<string, string> = {\n \"0\": \"₀\",\n \"1\": \"₁\",\n \"2\": \"₂\",\n \"3\": \"₃\",\n \"4\": \"₄\",\n \"5\": \"₅\",\n \"6\": \"₆\",\n \"7\": \"₇\",\n \"8\": \"₈\",\n \"9\": \"₉\",\n \"-\": \"₋\",\n };\n\n return str\n .split(\"\")\n .map((char) => subscriptMap[char] || char)\n .join(\"\");\n }\n}\n\n\n\nconst numbers = new Numbers()\n\nexport default numbers"],"mappings":"kIAEA,SAAgB,EACf,EACA,EAAU,CACT,UAAW,EAAA,EAAA,CAGZ,OAAO,IAAI,EAAA,WAAW,GAAA,CACrB,IAAM,EAAW,IAAI,qBAAqB,GAAA,CACzC,EAAW,KAAK,CAAA,CAAA,EACd,CAAA,EAUH,OAPI,MAAM,QAAQ,CAAA,EACjB,EAAQ,QAAQ,GAAM,EAAS,QAAQ,CAAA,CAAA,EAEvC,EAAS,QAAQ,CAAA,MAIlB,CACC,EAAS,WAAA,CAAA,CAAA,CAAA,CAGZ,CCrBA,IAOa,EAAb,KAAA,CAAA,aAAA,CAAA,KAAA,aAN2B,OAAd,UAAc,KAAe,UAAU,SACzC,UAAU,SAEZ,OAAA,CAgBP,YAAY,EAAgB,EAAwB,EAAA,CAClD,IAAM,EAAkB,IAAI,EAC5B,OAAO,KAAK,MAAM,EAAS,CAAA,EAAU,CACvC,CAkBA,aACE,EACA,EAAiB,KAAK,aACtB,EAAoC,CAAC,EAAA,CAErC,OAAO,IAAI,KAAK,aAAa,EAAQ,CAAA,EAAS,OAAO,CAAA,CACvD,CAQA,kBACE,EACA,EAA2B,IAAA,CAE3B,IAAM,EAAmB,EAAa,QAAQ,EAAkB,GAAA,EAChE,OAAO,WAAW,CAAA,CACpB,CAYA,KACE,EACA,EAAwB,EACxB,EAAiB,KAAK,aACtB,EAAoC,CAAC,EAAA,CAErC,IAAM,EAAgB,KAAK,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EAAA,CACV,CAKA,YAAoB,EAAA,CAClB,IAAM,EAAuC,CAC3C,EAAK,IACL,EAAK,IACL,EAAK,IACL,EAAK,IACL,EAAK,IACL,EAAK,IACL,EAAK,IACL,EAAK,IACL,EAAK,IACL,EAAK,IACL,IAAK,GAAA,EAGP,OAAO,EACJ,MAAM,EAAA,EACN,IAAK,GAAS,EAAa,IAAS,CAAA,EACpC,KAAK,EAAA,CACV,CAAA,EAKc,IAAI,EAAA,OAAA,eAAA,QAAA,IAAA,CAAA,WAAA,CAAA,EAAA,IAAA,UAAA,CAAA,OAAA,CAAA,CAAA,CAAA,EAAA,OAAA,eAAA,QAAA,IAAA,CAAA,WAAA,CAAA,EAAA,IAAA,UAAA,CAAA,OAAA,CAAA,CAAA,CAAA"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"utils-H8wNknWC.js","names":[],"sources":["../src/utils/intersection.ts","../src/utils/number.ts"],"sourcesContent":["import { Observable } from 'rxjs'\n\nexport function intersection$(\n\telement: Element | Element[],\n\toptions = {\n\t\tthreshold: 0.5,\n\t},\n) {\n\treturn new Observable(subscriber => {\n\t\tconst observer = new IntersectionObserver(entries => {\n\t\t\tsubscriber.next(entries) // Emit the entries array\n\t\t}, options)\n\n\t\t// Observe each element\n\t\tif (Array.isArray(element)) {\n\t\t\telement.forEach(el => observer.observe(el))\n\t\t} else {\n\t\t\tobserver.observe(element)\n\t\t}\n\n\t\t// Cleanup on unsubscription\n\t\treturn () => {\n\t\t\tobserver.disconnect()\n\t\t}\n\t})\n}\n","/**\n * Gets the user's system locale from browser settings.\n * Falls back to 'de-DE' if not available (e.g., in Node.js environment).\n */\nconst getSystemLocale = (): string => {\n if (typeof navigator !== 'undefined' && navigator.language) {\n return navigator.language\n }\n return 'de-DE'\n}\n\nexport class Numbers {\n /**\n * The system locale detected from user's browser/OS settings.\n * Use this for display formatting. For exports, use explicit locale like 'de-DE'.\n */\n readonly systemLocale = getSystemLocale()\n\n /**\n * Rounds a number to the specified number of decimal places.\n * @param {number} number - The number to round.\n * @param {number} [decimalPlaces=2] - The number of decimal places to round to.\n * @returns {number} - The rounded number.\n */\n roundNumber(number: number, decimalPlaces: number = 2): number {\n const factor = Math.pow(10, decimalPlaces);\n return Math.round(number * factor) / factor;\n }\n\n /**\n * Formats a number according to the specified locale and options.\n * Uses the user's system locale by default for display formatting.\n *\n * @param {number} number - The number to format.\n * @param {string} [locale] - The locale string (e.g., 'de-DE'). Defaults to system locale.\n * @param {Intl.NumberFormatOptions} [options={}] - Additional formatting options.\n * @returns {string} - The formatted number as a string.\n *\n * @example\n * // Uses system locale (e.g., user's browser setting)\n * numbers.formatNumber(1234.56)\n *\n * // Explicit locale for exports (bank systems expect German format)\n * numbers.formatNumber(1234.56, 'de-DE', { useGrouping: false })\n */\n formatNumber(\n number: number,\n locale: string = this.systemLocale,\n options: Intl.NumberFormatOptions = {},\n ): string {\n return new Intl.NumberFormat(locale, options).format(number);\n }\n\n /**\n * Parses a string with a specified decimal separator into a number.\n * @param {string} numberString - The string to parse.\n * @param {string} [decimalSeparator=','] - The decimal separator used in the string.\n * @returns {number} - The parsed number.\n */\n parseToPureNumber(\n numberString: string,\n decimalSeparator: string = \",\",\n ): number {\n const normalizedString = numberString.replace(decimalSeparator, \".\");\n return parseFloat(normalizedString);\n }\n\n /**\n * Rounds a number to the specified decimal places and formats it according to the specified locale and options.\n * Uses the user's system locale by default.\n *\n * @param {number} number - The number to process.\n * @param {number} [decimalPlaces=2] - The number of decimal places to round to.\n * @param {string} [locale] - The locale string. Defaults to system locale.\n * @param {Intl.NumberFormatOptions} [options={}] - Additional formatting options.\n * @returns {string} - The formatted number as a string.\n */\n doIt(\n number: number,\n decimalPlaces: number = 2,\n locale: string = this.systemLocale,\n options: Intl.NumberFormatOptions = {},\n ): string {\n const roundedNumber = this.roundNumber(number, decimalPlaces);\n return this.formatNumber(roundedNumber, locale, options);\n }\n\n /**\n * Format a currency amount consistently across the application\n *\n * @param amount The amount to format\n * @param currency The currency symbol to display (default: '€')\n * @returns Formatted amount with currency symbol\n */\n formatCurrency(amount: number, currency: string = \"€\"): string {\n return `${currency}${this.doIt(amount)}`;\n }\n\n /**\n * Format a delta value with appropriate directional indicator\n *\n * @param delta The delta amount to format\n * @param currency The currency symbol to display (default: '€')\n * @returns Formatted delta with direction indicator and currency symbol\n */\n formatDelta(delta: number, currency: string = \"€\"): string {\n const symbol = delta > 0 ? \"↑\" : delta < 0 ? \"↓\" : \"→\";\n return `${symbol} ${currency}${this.doIt(Math.abs(delta))}`;\n }\n\n /**\n * Get CSS class for delta value\n *\n * @param delta The delta amount\n * @returns CSS class based on delta direction\n */\n getDeltaClass(delta: number): string {\n return delta > 0\n ? \"text-error-default\"\n : delta < 0\n ? \"text-primary-default\"\n : \"text-neutral\";\n }\n\n /**\n * Converts a decimal number to a mixed fraction string\n * For example: 1.5 becomes \"1 1/2\", 2.25 becomes \"2 1/4\"\n *\n * @param number The decimal number to convert\n * @param precision The precision level for fraction approximation (default: 16)\n * @param maxDenominator The maximum allowed denominator (default: 4)\n * @returns A string representing the mixed fraction\n */\n toMixedFraction(\n number: number,\n precision: number = 16,\n maxDenominator: number = 4,\n ): string {\n // Handle negative numbers\n const isNegative = number < 0;\n number = Math.abs(number);\n\n // Extract whole number part\n const wholePart = Math.floor(number);\n\n // Extract decimal part and convert to fraction\n let decimalPart = number - wholePart;\n\n // If the decimal part is very small or zero, just return the whole number\n if (decimalPart < 1 / Math.pow(10, precision)) {\n return isNegative ? `-${wholePart}` : `${wholePart}`;\n }\n\n // Find the best fraction approximation using precision and max denominator\n const { numerator, denominator } = this.decimalToFraction(\n decimalPart,\n precision,\n maxDenominator,\n );\n\n // Format based on whether there's a whole part\n if (wholePart === 0) {\n return isNegative\n ? `-${numerator}/${denominator}`\n : `${numerator}/${denominator}`;\n } else {\n return isNegative\n ? `-${wholePart} ${numerator}/${denominator}`\n : `${wholePart} ${numerator}/${denominator}`;\n }\n }\n\n /**\n * Converts a decimal to a simplified fraction with a maximum denominator\n *\n * @param decimal The decimal part to convert (0 <= decimal < 1)\n * @param precision The precision level for approximation\n * @param maxDenominator The maximum allowed denominator (default: 4)\n * @returns Object containing numerator and denominator\n */\n private decimalToFraction(\n decimal: number,\n precision: number,\n maxDenominator: number = 4,\n ): { numerator: number; denominator: number } {\n if (decimal === 0) {\n return { numerator: 0, denominator: 1 };\n }\n\n // Initialize best approximation\n let bestError = Infinity;\n let bestNumerator = 0;\n let bestDenominator = 1;\n\n // Check common fractions first for better user experience\n // Filter to only include fractions with denominators <= maxDenominator\n const commonFractions = [\n { n: 1, d: 2 }, // 1/2\n { n: 1, d: 3 }, // 1/3\n { n: 2, d: 3 }, // 2/3\n { n: 1, d: 4 }, // 1/4\n { n: 3, d: 4 }, // 3/4\n ];\n\n // Add additional fractions only if maxDenominator allows\n const additionalFractions = [];\n if (maxDenominator >= 5) {\n additionalFractions.push(\n { n: 1, d: 5 }, // 1/5\n { n: 2, d: 5 }, // 2/5\n { n: 3, d: 5 }, // 3/5\n { n: 4, d: 5 }, // 4/5\n );\n }\n if (maxDenominator >= 6) {\n additionalFractions.push(\n { n: 1, d: 6 }, // 1/6\n { n: 5, d: 6 }, // 5/6\n );\n }\n if (maxDenominator >= 8) {\n additionalFractions.push(\n { n: 1, d: 8 }, // 1/8\n { n: 3, d: 8 }, // 3/8\n { n: 5, d: 8 }, // 5/8\n { n: 7, d: 8 }, // 7/8\n );\n }\n if (maxDenominator >= 10) {\n additionalFractions.push(\n { n: 1, d: 10 }, // 1/10\n { n: 3, d: 10 }, // 3/10\n { n: 7, d: 10 }, // 7/10\n { n: 9, d: 10 }, // 9/10\n );\n }\n if (maxDenominator >= 12) {\n additionalFractions.push(\n { n: 1, d: 12 }, // 1/12\n { n: 5, d: 12 }, // 5/12\n { n: 7, d: 12 }, // 7/12\n { n: 11, d: 12 }, // 11/12\n );\n }\n if (maxDenominator >= 16) {\n additionalFractions.push(\n { n: 1, d: 16 }, // 1/16\n { n: 3, d: 16 }, // 3/16\n { n: 5, d: 16 }, // 5/16\n { n: 7, d: 16 }, // 7/16\n { n: 9, d: 16 }, // 9/16\n { n: 11, d: 16 }, // 11/16\n { n: 13, d: 16 }, // 13/16\n { n: 15, d: 16 }, // 15/16\n );\n }\n\n // Combine all applicable fractions\n const allFractions = [...commonFractions, ...additionalFractions];\n\n // Check common fractions first\n for (const frac of allFractions) {\n if (frac.d <= maxDenominator) {\n const error = Math.abs(decimal - frac.n / frac.d);\n if (error < bestError) {\n bestError = error;\n bestNumerator = frac.n;\n bestDenominator = frac.d;\n\n // If we're very close to a common fraction, just use it\n if (error < 1 / Math.pow(10, precision)) {\n return { numerator: frac.n, denominator: frac.d };\n }\n }\n }\n }\n\n // If no suitable common fraction found, use a more sophisticated approach\n // for denominators up to maxDenominator\n\n // Find the best approximation with denominator <= maxDenominator\n for (let d = 1; d <= maxDenominator; d++) {\n // Find best numerator for this denominator\n const n = Math.round(decimal * d);\n const error = Math.abs(decimal - n / d);\n\n if (error < bestError) {\n bestError = error;\n bestNumerator = n;\n bestDenominator = d;\n }\n }\n\n // Only use continued fraction expansion if we're significantly off\n // and maxDenominator allows for larger denominators\n if (bestError > 1 / Math.pow(10, precision / 2) && maxDenominator > 4) {\n // Implementation of continued fraction expansion\n let n1 = 1,\n n2 = 0;\n let d1 = 0,\n d2 = 1;\n let b = decimal;\n\n do {\n let a = Math.floor(b);\n let aux = n1;\n n1 = a * n1 + n2;\n n2 = aux;\n\n aux = d1;\n d1 = a * d1 + d2;\n d2 = aux;\n\n b = 1 / (b - a);\n\n // Calculate the current approximation\n const currentError = Math.abs(decimal - n1 / d1);\n\n // If we hit the precision limit or if the denominator gets too large, use this approximation\n if (currentError < 1 / Math.pow(10, precision) || d1 > maxDenominator) {\n // If d1 exceeds maxDenominator, return the previous best result\n if (d1 > maxDenominator) {\n return { numerator: bestNumerator, denominator: bestDenominator };\n }\n\n // Otherwise return this result\n return { numerator: n1, denominator: d1 };\n }\n } while (b !== Infinity);\n\n bestNumerator = n1;\n bestDenominator = d1;\n }\n\n // Simplify the fraction\n const gcd = this.findGCD(bestNumerator, bestDenominator);\n return {\n numerator: bestNumerator / gcd,\n denominator: bestDenominator / gcd,\n };\n }\n\n /**\n * Calculates the greatest common divisor of two numbers\n */\n private findGCD(a: number, b: number): number {\n return b === 0 ? a : this.findGCD(b, a % b);\n }\n\n /**\n * Alternative method to get a formatted mixed fraction with a specified format\n *\n * @param number The decimal number to convert\n * @param format The format specification ('unicode', 'ascii', 'superscript')\n * @param precision The precision level for fraction approximation\n * @param maxDenominator The maximum allowed denominator (default: 4)\n * @returns A formatted string representing the mixed fraction\n */\n formatMixedFraction(\n number: number,\n format: \"unicode\" | \"ascii\" | \"superscript\" = \"ascii\",\n precision: number = 16,\n maxDenominator: number = 4,\n ): string {\n // Get the basic mixed fraction\n const basicFraction = this.toMixedFraction(\n number,\n precision,\n maxDenominator,\n );\n\n // If the format is ascii, just return the basic fraction\n if (format === \"ascii\") {\n return basicFraction;\n }\n\n // For unicode and superscript formats, we need to parse the basic fraction\n const isNegative = basicFraction.startsWith(\"-\");\n const withoutSign = isNegative ? basicFraction.substring(1) : basicFraction;\n\n // Check if it's a pure fraction or mixed fraction\n const hasMixedPart = withoutSign.includes(\" \");\n\n if (!withoutSign.includes(\"/\")) {\n // If there's no fraction part, just return the number\n return basicFraction;\n }\n\n let wholePart = \"\";\n let fractionPart = withoutSign;\n\n if (hasMixedPart) {\n // Split the whole and fraction parts\n const parts = withoutSign.split(\" \");\n wholePart = parts[0];\n fractionPart = parts[1];\n }\n\n // Split the fraction part into numerator and denominator\n const [numerator, denominator] = fractionPart.split(\"/\");\n\n if (format === \"unicode\") {\n // Try to find a unicode fraction character\n const unicodeFraction = this.getUnicodeFraction(\n parseInt(numerator),\n parseInt(denominator),\n );\n\n if (unicodeFraction) {\n return isNegative\n ? `-${wholePart}${hasMixedPart ? \" \" : \"\"}${unicodeFraction}`\n : `${wholePart}${hasMixedPart ? \" \" : \"\"}${unicodeFraction}`;\n }\n\n // Fallback to basic format if no unicode fraction is available\n return basicFraction;\n }\n\n // Handle superscript format\n if (format === \"superscript\") {\n const superNumerator = this.toSuperscript(numerator);\n const subDenominator = this.toSubscript(denominator);\n\n if (hasMixedPart) {\n return isNegative\n ? `-${wholePart} ${superNumerator}⁄${subDenominator}`\n : `${wholePart} ${superNumerator}⁄${subDenominator}`;\n } else {\n return isNegative\n ? `-${superNumerator}⁄${subDenominator}`\n : `${superNumerator}⁄${subDenominator}`;\n }\n }\n\n // Fallback to basic format\n return basicFraction;\n }\n\n /**\n * Gets the Unicode fraction character if available\n *\n * @param numerator The numerator\n * @param denominator The denominator\n * @returns Unicode fraction character or null if not available\n */\n private getUnicodeFraction(\n numerator: number,\n denominator: number,\n ): string | null {\n // Map common fractions to their Unicode characters\n const fractionMap: Record<string, string> = {\n \"1/4\": \"¼\",\n \"1/2\": \"½\",\n \"3/4\": \"¾\",\n \"1/3\": \"⅓\",\n \"2/3\": \"⅔\",\n \"1/5\": \"⅕\",\n \"2/5\": \"⅖\",\n \"3/5\": \"⅗\",\n \"4/5\": \"⅘\",\n \"1/6\": \"⅙\",\n \"5/6\": \"⅚\",\n \"1/7\": \"⅐\",\n \"1/8\": \"⅛\",\n \"3/8\": \"⅜\",\n \"5/8\": \"⅝\",\n \"7/8\": \"⅞\",\n \"1/9\": \"⅑\",\n \"1/10\": \"⅒\",\n };\n\n const key = `${numerator}/${denominator}`;\n return fractionMap[key] || null;\n }\n\n /**\n * Converts digits to superscript\n */\n private toSuperscript(str: string): string {\n const superscriptMap: Record<string, string> = {\n \"0\": \"⁰\",\n \"1\": \"¹\",\n \"2\": \"²\",\n \"3\": \"³\",\n \"4\": \"⁴\",\n \"5\": \"⁵\",\n \"6\": \"⁶\",\n \"7\": \"⁷\",\n \"8\": \"⁸\",\n \"9\": \"⁹\",\n \"-\": \"⁻\",\n };\n\n return str\n .split(\"\")\n .map((char) => superscriptMap[char] || char)\n .join(\"\");\n }\n\n /**\n * Converts digits to subscript\n */\n private toSubscript(str: string): string {\n const subscriptMap: Record<string, string> = {\n \"0\": \"₀\",\n \"1\": \"₁\",\n \"2\": \"₂\",\n \"3\": \"₃\",\n \"4\": \"₄\",\n \"5\": \"₅\",\n \"6\": \"₆\",\n \"7\": \"₇\",\n \"8\": \"₈\",\n \"9\": \"₉\",\n \"-\": \"₋\",\n };\n\n return str\n .split(\"\")\n .map((char) => subscriptMap[char] || char)\n .join(\"\");\n }\n}\n\n\n\nconst numbers = new Numbers()\n\nexport default numbers"],"mappings":";;;AAEA,SAAgB,EACf,GACA,IAAU,EACT,WAAW,GAAA,GAAA;CAGZ,OAAO,IAAI,GAAW,MAAA;EACrB,IAAM,IAAW,IAAI,sBAAqB,MAAA;GACzC,EAAW,KAAK,CAAA;EAAA,GACd,CAAA;EAUH,OAPI,MAAM,QAAQ,CAAA,IACjB,EAAQ,SAAQ,MAAM,EAAS,QAAQ,CAAA,CAAA,IAEvC,EAAS,QAAQ,CAAA,SAIlB;GACC,EAAS,WAAA;EAAA;CAAA,CAAA;AAGZ;ACrBA,IAOa,IAAb,MAAA;CAAA,cAAA;EAAA,KAAA,eAN2B,OAAd,YAAc,OAAe,UAAU,WACzC,UAAU,WAEZ;CAAA;CAgBP,YAAY,GAAgB,IAAwB,GAAA;EAClD,IAAM,IAAkB,MAAI;EAC5B,OAAO,KAAK,MAAM,IAAS,CAAA,IAAU;CACvC;CAkBA,aACE,GACA,IAAiB,KAAK,cACtB,IAAoC,CAAC,GAAA;EAErC,OAAO,IAAI,KAAK,aAAa,GAAQ,CAAA,EAAS,OAAO,CAAA;CACvD;CAQA,kBACE,GACA,IAA2B,KAAA;EAE3B,IAAM,IAAmB,EAAa,QAAQ,GAAkB,GAAA;EAChE,OAAO,WAAW,CAAA;CACpB;CAYA,KACE,GACA,IAAwB,GACxB,IAAiB,KAAK,cACtB,IAAoC,CAAC,GAAA;EAErC,IAAM,IAAgB,KAAK,YAAY,GAAQ,CAAA;EAC/C,OAAO,KAAK,aAAa,GAAe,GAAQ,CAAA;CAClD;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AK;GACL,GAAK;GACL,GAAK;GACL,GAAK;GACL,GAAK;GACL,GAAK;GACL,GAAK;GACL,GAAK;GACL,GAAK;GACL,KAAK;EAAA;EAGP,OAAO,EACJ,MAAM,EAAA,EACN,KAAK,MAAS,EAAa,MAAS,CAAA,EACpC,KAAK,EAAA;CACV;AAAA;AAKc,IAAI;AAAA,SAAA,QAAA,KAAA"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"window-C76zstbV.js","names":["#state$"],"sources":["../src/window/window-manager.ts","../src/window/window-position.ts","../src/window/window.ts"],"sourcesContent":["/**\n * Window Manager — singleton service for multi-window coordination.\n *\n * Tracks all schmancy-window instances: positions, z-indices, focus, visual states.\n * Components register on connectedCallback, unregister on disconnectedCallback.\n * Focus changes, position updates, and overlap queries all flow through here.\n *\n * Follows the ThemeService singleton pattern (theme/theme.service.ts).\n *\n * Example:\n * windowManager.register('chat-1', bounds, 'bottom-right')\n * windowManager.focus('chat-1') // bumps z-index, updates focusedId\n * const overlaps = windowManager.findOverlaps(projectedBounds, 'chat-1')\n */\n\nimport { BehaviorSubject, Observable, distinctUntilChanged, map } from 'rxjs'\nimport { overlayStack } from '../utils/overlay-stack.js'\nimport type { WindowBounds, WindowRecord, WindowRegistryState, SnapTarget } from './window-registry.js'\n\nconst STORAGE_PREFIX = 'schmancy-window-'\nconst LEGACY_STORAGE_PREFIX = 'schmancy-float-'\n\nclass WindowManagerService {\n\tprivate static instance: WindowManagerService\n\n\treadonly #state$ = new BehaviorSubject<WindowRegistryState>({\n\t\twindows: new Map(),\n\t\tfocusedId: null,\n\t\tstackOrder: [],\n\t})\n\n\treadonly state$ = this.#state$.asObservable()\n\n\tprivate constructor() {}\n\n\tstatic getInstance(): WindowManagerService {\n\t\tif (!WindowManagerService.instance) {\n\t\t\tWindowManagerService.instance = new WindowManagerService()\n\t\t}\n\t\treturn WindowManagerService.instance\n\t}\n\n\t// ── Synchronous accessors ──────────────────────────────────────────\n\n\tget windows(): Map<string, WindowRecord> {\n\t\treturn this.#state$.value.windows\n\t}\n\n\tget focusedId(): string | null {\n\t\treturn this.#state$.value.focusedId\n\t}\n\n\t// ── Registration ───────────────────────────────────────────────────\n\n\tregister(id: string, initialBounds: WindowBounds, snapTarget: SnapTarget): void {\n\t\tconst state = this.#state$.value\n\t\tif (state.windows.has(id)) return\n\n\t\tconst zIndex = overlayStack.assignZIndex(id)\n\t\tconst record: WindowRecord = {\n\t\t\tid,\n\t\t\tbounds: initialBounds,\n\t\t\tvisualState: 'normal',\n\t\t\tzIndex,\n\t\t\topen: false,\n\t\t\tsnapTarget,\n\t\t}\n\n\t\tconst windows = new Map(state.windows)\n\t\twindows.set(id, record)\n\t\tconst stackOrder = overlayStack.getStackOrder()\n\n\t\tthis.#state$.next({ ...state, windows, stackOrder })\n\t}\n\n\tunregister(id: string): void {\n\t\tconst state = this.#state$.value\n\t\tif (!state.windows.has(id)) return\n\n\t\toverlayStack.releaseId(id)\n\t\tconst windows = new Map(state.windows)\n\t\twindows.delete(id)\n\t\tconst stackOrder = overlayStack.getStackOrder()\n\t\tconst focusedId = state.focusedId === id ? null : state.focusedId\n\n\t\tthis.#state$.next({ ...state, windows, stackOrder, focusedId })\n\t}\n\n\t// ── State mutations ────────────────────────────────────────────────\n\n\tupdateBounds(id: string, bounds: WindowBounds): void {\n\t\tthis.updateRecord(id, { bounds })\n\t}\n\n\tupdateVisualState(id: string, visualState: WindowRecord['visualState']): void {\n\t\tthis.updateRecord(id, { visualState })\n\t}\n\n\tupdateOpen(id: string, open: boolean): void {\n\t\tthis.updateRecord(id, { open })\n\t}\n\n\tfocus(id: string): void {\n\t\tconst state = this.#state$.value\n\t\tif (!state.windows.has(id)) return\n\t\tif (state.focusedId === id) return\n\n\t\tconst zIndex = overlayStack.bringToFront(id)\n\t\tconst windows = new Map(state.windows)\n\t\tconst record = windows.get(id)\n\t\tif (record) {\n\t\t\twindows.set(id, { ...record, zIndex })\n\t\t}\n\t\tconst stackOrder = overlayStack.getStackOrder()\n\n\t\tthis.#state$.next({ ...state, windows, stackOrder, focusedId: id })\n\t}\n\n\t// ── Queries ────────────────────────────────────────────────────────\n\n\tfindOverlaps(bounds: WindowBounds, excludeId: string): WindowRecord[] {\n\t\tconst result: WindowRecord[] = []\n\t\tfor (const [id, record] of this.#state$.value.windows) {\n\t\t\tif (id === excludeId) continue\n\t\t\tif (rectsOverlap(bounds, record.bounds)) {\n\t\t\t\tresult.push(record)\n\t\t\t}\n\t\t}\n\t\treturn result\n\t}\n\n\tgetNeighbors(id: string): WindowRecord[] {\n\t\tconst result: WindowRecord[] = []\n\t\tfor (const [otherId, record] of this.#state$.value.windows) {\n\t\t\tif (otherId !== id) result.push(record)\n\t\t}\n\t\treturn result\n\t}\n\n\t// ── Selectors ──────────────────────────────────────────────────────\n\n\tselectWindow(id: string): Observable<WindowRecord | undefined> {\n\t\treturn this.#state$.pipe(\n\t\t\tmap(state => state.windows.get(id)),\n\t\t\tdistinctUntilChanged(),\n\t\t)\n\t}\n\n\tselectFocused(): Observable<string | null> {\n\t\treturn this.#state$.pipe(\n\t\t\tmap(state => state.focusedId),\n\t\t\tdistinctUntilChanged(),\n\t\t)\n\t}\n\n\t// ── Persistence ────────────────────────────────────────────────────\n\n\tloadPosition(id: string): { x: number; y: number; anchor: string } | null {\n\t\ttry {\n\t\t\t// Try new key first, fall back to legacy\n\t\t\tconst raw = localStorage.getItem(STORAGE_PREFIX + id) ?? localStorage.getItem(LEGACY_STORAGE_PREFIX + id)\n\t\t\tif (!raw) return null\n\t\t\treturn JSON.parse(raw) as { x: number; y: number; anchor: string }\n\t\t} catch {\n\t\t\treturn null\n\t\t}\n\t}\n\n\tsavePosition(id: string, data: { x: number; y: number; anchor: string }): void {\n\t\ttry {\n\t\t\tlocalStorage.setItem(STORAGE_PREFIX + id, JSON.stringify(data))\n\t\t} catch {\n\t\t\t// ignore\n\t\t}\n\t}\n\n\tclearPosition(id: string): void {\n\t\ttry {\n\t\t\tlocalStorage.removeItem(STORAGE_PREFIX + id)\n\t\t\tlocalStorage.removeItem(LEGACY_STORAGE_PREFIX + id)\n\t\t} catch {\n\t\t\t// ignore\n\t\t}\n\t}\n\n\t// ── Internal ───────────────────────────────────────────────────────\n\n\tprivate updateRecord(id: string, updates: Partial<WindowRecord>): void {\n\t\tconst state = this.#state$.value\n\t\tconst record = state.windows.get(id)\n\t\tif (!record) return\n\n\t\tconst windows = new Map(state.windows)\n\t\twindows.set(id, { ...record, ...updates })\n\t\tthis.#state$.next({ ...state, windows })\n\t}\n}\n\n/** Simple rect overlap check (inline — no circular import with window-position) */\nfunction rectsOverlap(a: WindowBounds, b: WindowBounds): boolean {\n\treturn !(a.left >= b.left + b.width || a.left + a.width <= b.left || a.top >= b.top + b.height || a.top + a.height <= b.top)\n}\n\nexport const windowManager = WindowManagerService.getInstance()\n","/**\n * Window Position — pure functions for overlap resolution, cascade, and snapping.\n *\n * All functions are stateless: they take window bounds and viewport dimensions,\n * return new bounds. No side effects, no DOM access, no subscriptions.\n *\n * Example:\n * const projected = { left: 100, top: 400, width: 360, height: 500 }\n * const neighbors = windowManager.findOverlaps(projected, 'my-id')\n * const resolved = resolveOverlap(projected, neighbors, { width: 1440, height: 900 })\n * // → { left: 144, top: 444, width: 360, height: 500 } (cascaded away from conflict)\n */\n\nimport type { WindowBounds, WindowRecord } from './window-registry.js'\n\nconst HEAD_HEIGHT = 44\nconst CASCADE_OFFSET = HEAD_HEIGHT\nconst MAX_CASCADE_ATTEMPTS = 10\n\n/** Check if two rectangles overlap (edges touching does NOT count as overlap) */\nexport function rectsOverlap(a: WindowBounds, b: WindowBounds): boolean {\n\treturn !(a.left >= b.left + b.width || a.left + a.width <= b.left || a.top >= b.top + b.height || a.top + a.height <= b.top)\n}\n\n/**\n * Resolve overlap by cascading diagonally until no conflict.\n * Shifts by (HEAD_HEIGHT, HEAD_HEIGHT) per attempt, clamped to viewport.\n */\nexport function resolveOverlap(\n\tcandidate: WindowBounds,\n\texisting: WindowRecord[],\n\tviewport: { width: number; height: number },\n): WindowBounds {\n\tconst bounds = { ...candidate }\n\n\tfor (let attempt = 0; attempt < MAX_CASCADE_ATTEMPTS; attempt++) {\n\t\tconst hasOverlap = existing.some(w => rectsOverlap(bounds, w.bounds))\n\t\tif (!hasOverlap) break\n\n\t\tbounds.left += CASCADE_OFFSET\n\t\tbounds.top += CASCADE_OFFSET\n\t}\n\n\treturn clampToViewport(bounds, viewport)\n}\n\n/**\n * Clamp bounds so the window stays fully within the viewport.\n */\nexport function clampToViewport(\n\tbounds: WindowBounds,\n\tviewport: { width: number; height: number },\n): WindowBounds {\n\treturn {\n\t\twidth: bounds.width,\n\t\theight: bounds.height,\n\t\tleft: Math.max(0, Math.min(bounds.left, viewport.width - bounds.width)),\n\t\ttop: Math.max(0, Math.min(bounds.top, viewport.height - bounds.height)),\n\t}\n}\n","import { SchmancyElement } from '@mixins/index'\nimport { css, html, nothing } from 'lit'\nimport { customElement, property, state } from 'lit/decorators.js'\nimport { classMap } from 'lit/directives/class-map.js'\nimport { createRef, ref } from 'lit/directives/ref.js'\nimport { styleMap } from 'lit/directives/style-map.js'\nimport {\n\tanimationFrameScheduler,\n\tauditTime,\n\tcatchError,\n\tEMPTY,\n\tfilter,\n\tfinalize,\n\tfrom,\n\tfromEvent,\n\tmap,\n\tmerge,\n\tObservable,\n\tswitchMap,\n\ttake,\n\ttakeUntil,\n\ttap,\n} from 'rxjs'\nimport { SPRING_SMOOTH, SPRING_SNAPPY } from '../utils/animation.js'\nimport { cursorGlow } from '../directives/cursor-glow'\nimport { reducedMotion$ } from '../directives/reduced-motion'\nimport { theme } from '../theme/theme.service.js'\nimport type { SnapCorner, WindowBounds, WindowVisualState } from './window-registry.js'\nimport { windowManager } from './window-manager.js'\nimport { resolveOverlap } from './window-position.js'\n\nconst HEAD_HEIGHT = 48\nconst DRAG_THRESHOLD = 5\n\ninterface Position {\n\tx: number\n\ty: number\n}\n\n@customElement('schmancy-window')\nexport default class SchmancyWindow extends SchmancyElement {\n\tstatic styles = [css`\n\t:host {\n\t\tdisplay: contents;\n\t\tposition: relative;\n\t\tz-index: 1000;\n\t}\n\t:host([hidden]) {\n\t\tdisplay: none !important;\n\t}\n`]\n\n\t@property({ type: String }) id: string = 'default'\n\t/** Override the expanded panel width (e.g. '320px', '24rem'). Defaults to responsive sizing. */\n\t@property({ type: String }) expandedWidth?: string\n\t/** Override the expanded panel height (e.g. '400px', '50vh'). */\n\t@property({ type: String }) expandedHeight?: string\n\t/** When true, uses a lower elevation shadow in the collapsed state. */\n\t@property({ type: Boolean, reflect: true }) lowered: boolean = false\n\t/** Corner the window is anchored to. */\n\t@property({ type: String }) corner: SnapCorner = 'bottom-right'\n\t/** When true, window can be resized by the user. */\n\t@property({ type: Boolean }) resizable = false\n\t/** When true, window stays at its dragged position instead of snapping to a corner. */\n\t@property({ type: Boolean }) freePosition = false\n\t/** Visual state of the window (minimized, normal, maximized). */\n\t@property({ type: String, reflect: true }) visualState: WindowVisualState = 'normal'\n\t/** Minimum width in pixels. */\n\t@property({ type: Number }) minWidth = 280\n\t/** Minimum height in pixels. */\n\t@property({ type: Number }) minHeight = 200\n\n\t/** Whether the body is expanded. */\n\t@property({ type: Boolean, reflect: true }) open = false\n\n\tprivate currentAnimation?: Animation\n\n\t/** Lazy rendering: body content not in DOM until first expand. */\n\t@state() private hasOpened = false\n\n\t// Internal position -- plain fields, updated directly during drag\n\tprivate position: Position = { x: 16, y: 16 }\n\t@state() private currentCorner: SnapCorner = 'bottom-right'\n\n\t// Track applied corner to avoid unnecessary style.removeProperty calls during drag\n\tprivate appliedCorner: string = ''\n\n\t// Refs\n\tprivate containerRef = createRef<HTMLElement>()\n\tprivate bodyRef = createRef<HTMLElement>()\n\tprivate headRef = createRef<HTMLElement>()\n\n\t// ============================================\n\t// COMPUTED\n\t// ============================================\n\n\tprivate get panelWidth(): string {\n\t\treturn this.expandedWidth ?? 'min(360px, calc(100vw - 32px))'\n\t}\n\n\tprivate get isBottomCorner(): boolean {\n\t\treturn this.currentCorner.startsWith('bottom')\n\t}\n\n\tprivate get closedClipPath(): string {\n\t\treturn this.isBottomCorner\n\t\t\t? `inset(calc(100% - ${HEAD_HEIGHT}px) 0px 0px 0px round 22px)`\n\t\t\t: `inset(0px 0px calc(100% - ${HEAD_HEIGHT}px) 0px round 22px)`\n\t}\n\n\tprivate get openClipPath(): string {\n\t\treturn 'inset(0px 0px 0px 0px round 12px)'\n\t}\n\n\t// ============================================\n\t// POSITION MANAGEMENT\n\t// ============================================\n\n\tprivate applyContainerPosition() {\n\t\tconst container = this.containerRef.value\n\t\tif (!container) return\n\t\t// Only clear position properties when corner changes (avoids 4 style invalidations per drag frame)\n\t\tif (this.appliedCorner !== this.currentCorner) {\n\t\t\tcontainer.style.removeProperty('left')\n\t\t\tcontainer.style.removeProperty('right')\n\t\t\tcontainer.style.removeProperty('top')\n\t\t\tcontainer.style.removeProperty('bottom')\n\t\t\tthis.appliedCorner = this.currentCorner\n\t\t}\n\t\tconst { x, y } = this.position\n\t\tif (this.currentCorner.includes('right')) {\n\t\t\tcontainer.style.right = `${x}px`\n\t\t} else {\n\t\t\tcontainer.style.left = `${x}px`\n\t\t}\n\t\tif (this.currentCorner.includes('bottom')) {\n\t\t\tcontainer.style.bottom = `${y + theme.bottomOffset}px`\n\t\t} else {\n\t\t\tcontainer.style.top = `${y}px`\n\t\t}\n\t}\n\n\tprivate static readonly VALID_CORNERS = new Set<string>(['top-left', 'top-right', 'bottom-left', 'bottom-right'])\n\n\tprivate loadPosition() {\n\t\tconst saved = windowManager.loadPosition(this.id)\n\t\tif (saved) {\n\t\t\tthis.position = { x: saved.x, y: saved.y }\n\t\t\tif (SchmancyWindow.VALID_CORNERS.has(saved.anchor)) {\n\t\t\t\tthis.currentCorner = saved.anchor as SnapCorner\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate savePosition() {\n\t\twindowManager.savePosition(this.id, { ...this.position, anchor: this.currentCorner })\n\t}\n\n\tprivate validateBounds() {\n\t\tconst container = this.containerRef.value\n\t\tif (!container) return\n\t\tconst rect = container.getBoundingClientRect()\n\t\tif (rect.width === 0) return\n\t\tconst vw = window.innerWidth\n\t\tconst vh = window.innerHeight\n\t\tconst isRight = this.currentCorner.includes('right')\n\t\tconst isBottom = this.currentCorner.includes('bottom')\n\t\tconst actualLeft = isRight ? vw - this.position.x - rect.width : this.position.x\n\t\tconst actualTop = isBottom ? vh - this.position.y - rect.height : this.position.y\n\t\tconst newLeft = Math.max(0, Math.min(actualLeft, vw - rect.width))\n\t\tconst newTop = Math.max(0, Math.min(actualTop, vh - rect.height))\n\t\tthis.position = {\n\t\t\tx: isRight ? vw - newLeft - rect.width : newLeft,\n\t\t\ty: isBottom ? vh - newTop - rect.height : newTop,\n\t\t}\n\t\tthis.applyContainerPosition()\n\t}\n\n\t// ============================================\n\t// CORNER SNAPPING\n\t// ============================================\n\n\tprivate reorientToNearestCorner(skipAnimation = false): void {\n\t\t// Free position mode: skip corner snapping\n\t\tif (this.freePosition) {\n\t\t\tthis.savePosition()\n\t\t\tconst rect = this.containerRef.value?.getBoundingClientRect()\n\t\t\tif (rect) {\n\t\t\t\twindowManager.updateBounds(this.id, { left: rect.left, top: rect.top, width: rect.width, height: rect.height })\n\t\t\t}\n\t\t\treturn\n\t\t}\n\n\t\tconst container = this.containerRef.value\n\t\tif (!container) return\n\n\t\t// F -- record current screen position before DOM mutation\n\t\tconst rect = container.getBoundingClientRect()\n\n\t\t// L -- calculate nearest corner using head visual center\n\t\tconst currentIsBottom = this.currentCorner.includes('bottom')\n\t\tconst headCenterX = rect.left + rect.width / 2\n\t\tconst headCenterY = currentIsBottom\n\t\t\t? rect.bottom - HEAD_HEIGHT / 2\n\t\t\t: rect.top + HEAD_HEIGHT / 2\n\t\tconst side = headCenterX > window.innerWidth / 2 ? 'right' : 'left'\n\t\tconst vert = headCenterY > window.innerHeight / 2 ? 'bottom' : 'top'\n\t\tconst newCorner: SnapCorner = `${vert}-${side}` as SnapCorner\n\n\t\t// Snap corner and reset offset to standard edge gap\n\t\tthis.currentCorner = newCorner\n\t\tthis.position = { x: 16, y: 16 }\n\t\tthis.applyContainerPosition()\n\t\t// Sync clip-path to new corner\n\t\tif (!this.open) {\n\t\t\tcontainer.style.clipPath = this.closedClipPath\n\t\t}\n\n\t\tif (skipAnimation || reducedMotion$.value) {\n\t\t\tthis.savePosition()\n\t\t\tconst snapRect = container.getBoundingClientRect()\n\t\t\twindowManager.updateBounds(this.id, { left: snapRect.left, top: snapRect.top, width: snapRect.width, height: snapRect.height })\n\t\t\treturn\n\t\t}\n\n\t\t// I -- invert: shift element back to its original visual position\n\t\tconst newRect = container.getBoundingClientRect()\n\t\tconst dx = rect.left - newRect.left\n\t\tconst dy = rect.top - newRect.top\n\t\tcontainer.style.translate = `${dx}px ${dy}px`\n\n\t\t// P -- play: animate from the inverse offset to natural resting position\n\t\tconst flipKeyframes: Keyframe[] = [{ translate: `${dx}px ${dy}px` }, { translate: '0px 0px' }]\n\t\tconst anim = container.animate(\n\t\t\tflipKeyframes,\n\t\t\t{\n\t\t\t\tduration: SPRING_SMOOTH.duration,\n\t\t\t\teasing: SPRING_SMOOTH.easingFallback,\n\t\t\t\tfill: 'forwards',\n\t\t\t},\n\t\t)\n\t\tfrom(anim.finished).pipe(\n\t\t\ttake(1),\n\t\t\ttap(() => {\n\t\t\t\tif (container.isConnected) container.style.translate = ''\n\t\t\t\t// Report final resting bounds after animation completes\n\t\t\t\tconst finalRect = container.getBoundingClientRect()\n\t\t\t\twindowManager.updateBounds(this.id, { left: finalRect.left, top: finalRect.top, width: finalRect.width, height: finalRect.height })\n\t\t\t}),\n\t\t\tcatchError(() => EMPTY),\n\t\t\ttakeUntil(this.disconnecting),\n\t\t).subscribe()\n\n\t\tthis.savePosition()\n\t}\n\n\t// ============================================\n\t// DRAG PIPELINE\n\t// ============================================\n\n\tprivate drag$(): Observable<never> {\n\t\treturn new Observable(() => {\n\t\t\tconst head = this.headRef.value\n\t\t\tconst container = this.containerRef.value\n\t\t\tif (!head || !container) return\n\n\t\t\tlet didDrag = false\n\n\t\t\tconst sub = fromEvent<PointerEvent>(head, 'pointerdown').pipe(\n\t\t\t\tfilter(e => e.button === 0),\n\t\t\t\tfilter(e => {\n\t\t\t\t\tconst tag = (e.target as HTMLElement).tagName?.toLowerCase()\n\t\t\t\t\treturn !['input', 'textarea', 'select', 'button'].includes(tag)\n\t\t\t\t\t\t&& !(e.target as HTMLElement).closest('schmancy-input, schmancy-icon-button, button, a')\n\t\t\t\t}),\n\t\t\t\ttap(e => {\n\t\t\t\t\te.preventDefault()\n\t\t\t\t\te.stopPropagation()\n\t\t\t\t}),\n\t\t\t)\n\t\t\t\t.pipe(\n\t\t\t\t\tmap(e => {\n\t\t\t\t\t\tconst rect = container.getBoundingClientRect()\n\t\t\t\t\t\tconst isBottom = this.currentCorner.includes('bottom')\n\t\t\t\t\t\tconst wasOpen = this.open\n\t\t\t\t\t\tdidDrag = false\n\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\tstartX: e.clientX,\n\t\t\t\t\t\t\tstartY: e.clientY,\n\t\t\t\t\t\t\toffsetX: e.clientX - rect.left,\n\t\t\t\t\t\t\toffsetY: e.clientY - rect.top,\n\t\t\t\t\t\t\trect,\n\t\t\t\t\t\t\tvw: window.innerWidth,\n\t\t\t\t\t\t\tvh: window.innerHeight,\n\t\t\t\t\t\t\tisBottom,\n\t\t\t\t\t\t\twasOpen,\n\t\t\t\t\t\t\tpointerId: e.pointerId,\n\t\t\t\t\t\t}\n\t\t\t\t\t}),\n\t\t\t\t\tswitchMap(({ startX, startY, offsetX, offsetY, rect, vw, vh, isBottom, wasOpen, pointerId }) => {\n\t\t\t\t\t\tconst move$ = fromEvent<PointerEvent>(window, 'pointermove').pipe(\n\t\t\t\t\t\t\tfilter(e => e.pointerId === pointerId),\n\t\t\t\t\t\t\tauditTime(0, animationFrameScheduler),\n\t\t\t\t\t\t\tmap(e => ({ clientX: e.clientX, clientY: e.clientY })),\n\t\t\t\t\t\t)\n\t\t\t\t\t\tconst end$ = fromEvent<PointerEvent>(window, 'pointerup').pipe(\n\t\t\t\t\t\t\tfilter(e => e.pointerId === pointerId),\n\t\t\t\t\t\t)\n\n\t\t\t\t\t\treturn move$.pipe(\n\t\t\t\t\t\t\ttap(({ clientX, clientY }) => {\n\t\t\t\t\t\t\t\tconst dx = clientX - startX\n\t\t\t\t\t\t\t\tconst dy = clientY - startY\n\t\t\t\t\t\t\t\tif (Math.sqrt(dx * dx + dy * dy) > DRAG_THRESHOLD && !didDrag) {\n\t\t\t\t\t\t\t\t\tdidDrag = true\n\t\t\t\t\t\t\t\t\tthis.applyDragVisuals(true)\n\t\t\t\t\t\t\t\t\t// Collapse on first confirmed drag move\n\t\t\t\t\t\t\t\t\tif (wasOpen) {\n\t\t\t\t\t\t\t\t\t\tthis.open = false\n\t\t\t\t\t\t\t\t\t\tcontainer.style.clipPath = this.closedClipPath\n\t\t\t\t\t\t\t\t\t\tcontainer.style.overflow = 'hidden'\n\t\t\t\t\t\t\t\t\t\tconst body = this.bodyRef.value\n\t\t\t\t\t\t\t\t\t\tif (body) {\n\t\t\t\t\t\t\t\t\t\t\tbody.inert = true\n\t\t\t\t\t\t\t\t\t\t\tbody.style.visibility = 'hidden'\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif (!didDrag) return\n\n\t\t\t\t\t\t\t\tconst left = Math.max(0, Math.min(clientX - offsetX, vw - rect.width))\n\t\t\t\t\t\t\t\tconst minTop = isBottom ? HEAD_HEIGHT - rect.height : 0\n\t\t\t\t\t\t\t\tconst maxTop = isBottom ? vh - rect.height : vh - HEAD_HEIGHT\n\t\t\t\t\t\t\t\tconst top = Math.max(minTop, Math.min(clientY - offsetY, maxTop))\n\n\t\t\t\t\t\t\t\tthis.position = {\n\t\t\t\t\t\t\t\t\tx: this.currentCorner.includes('right') ? vw - left - rect.width : left,\n\t\t\t\t\t\t\t\t\ty: isBottom ? vh - top - rect.height : top,\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tthis.applyContainerPosition()\n\t\t\t\t\t\t\t}),\n\t\t\t\t\t\t\ttakeUntil(end$),\n\t\t\t\t\t\t\tfinalize(() => {\n\t\t\t\t\t\t\t\tif (didDrag) {\n\t\t\t\t\t\t\t\t\tthis.reorientToNearestCorner()\n\t\t\t\t\t\t\t\t\tthis.applyDragVisuals(false)\n\t\t\t\t\t\t\t\t\tdidDrag = false\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tdidDrag = false\n\t\t\t\t\t\t\t\t\tthis.toggle()\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}),\n\t\t\t\t\t\t)\n\t\t\t\t\t}),\n\t\t\t\t)\n\t\t\t\t.subscribe()\n\n\t\t\treturn () => sub.unsubscribe()\n\t\t})\n\t}\n\n\t// ============================================\n\t// LIFECYCLE\n\t// ============================================\n\n\tconnectedCallback() {\n\t\tsuper.connectedCallback()\n\n\t\t// Pipeline 1: DOM setup + manager registration + drag + z-index sync\n\t\tfrom(this.updateComplete).pipe(\n\t\t\ttake(1),\n\t\t\ttap(() => {\n\t\t\t\tthis.currentCorner = this.corner\n\t\t\t\tthis.loadPosition()\n\t\t\t\tthis.applyContainerPosition()\n\t\t\t\tthis.initDOMState()\n\t\t\t\t// Register with window manager\n\t\t\t\tconst container = this.containerRef.value\n\t\t\t\tif (container) {\n\t\t\t\t\tconst rect = container.getBoundingClientRect()\n\t\t\t\t\tconst bounds: WindowBounds = { left: rect.left, top: rect.top, width: rect.width, height: rect.height }\n\t\t\t\t\twindowManager.register(this.id, bounds, this.freePosition ? 'free' : this.currentCorner)\n\t\t\t\t}\n\t\t\t}),\n\t\t\tswitchMap(() => merge(\n\t\t\t\tthis.drag$(),\n\t\t\t\twindowManager.selectWindow(this.id).pipe(\n\t\t\t\t\ttap(record => {\n\t\t\t\t\t\tif (!record) return\n\t\t\t\t\t\tconst container = this.containerRef.value\n\t\t\t\t\t\tif (container) container.style.zIndex = String(record.zIndex)\n\t\t\t\t\t}),\n\t\t\t\t),\n\t\t\t)),\n\t\t\ttakeUntil(this.disconnecting),\n\t\t).subscribe()\n\n\n\t\t// Pipeline 3: Environment -- one subscription\n\t\tmerge(\n\t\t\tfromEvent(window, 'resize').pipe(\n\t\t\t\tauditTime(0, animationFrameScheduler),\n\t\t\t\ttap(() => this.validateBounds()),\n\t\t\t),\n\t\t\ttheme.bottomOffset$.pipe(\n\t\t\t\ttap(() => this.applyContainerPosition()),\n\t\t\t),\n\t\t).pipe(takeUntil(this.disconnecting)).subscribe()\n\t}\n\n\tdisconnectedCallback() {\n\t\tsuper.disconnectedCallback()\n\t\twindowManager.unregister(this.id)\n\t}\n\n\tprivate initDOMState() {\n\t\tconst container = this.containerRef.value\n\t\tconst body = this.bodyRef.value\n\t\tif (!container) return\n\n\t\tthis.applyContainerPosition()\n\n\t\tif (this.open) {\n\t\t\tthis.hasOpened = true\n\t\t\tcontainer.style.overflow = ''\n\t\t\tif (body) {\n\t\t\t\tbody.inert = false\n\t\t\t\tbody.style.visibility = 'visible'\n\t\t\t}\n\t\t} else {\n\t\t\tcontainer.style.clipPath = this.closedClipPath\n\t\t\tcontainer.style.overflow = 'hidden'\n\t\t\tif (body) {\n\t\t\t\tbody.inert = true\n\t\t\t\tbody.style.visibility = 'hidden'\n\t\t\t}\n\t\t}\n\t}\n\n\t// ============================================\n\t// ANIMATION\n\t// ============================================\n\n\tprivate animateOpen() {\n\t\tconst container = this.containerRef.value\n\t\tconst body = this.bodyRef.value\n\t\tif (!container) return\n\n\t\tthis.hasOpened = true\n\t\tthis.open = true\n\n\t\t// Overlap avoidance\n\t\tconst rect = container.getBoundingClientRect()\n\t\tconst projectedBounds: WindowBounds = {\n\t\t\tleft: rect.left,\n\t\t\ttop: this.isBottomCorner ? rect.top - 400 : rect.top,\n\t\t\twidth: rect.width,\n\t\t\theight: 400 + HEAD_HEIGHT,\n\t\t}\n\t\tconst overlaps = windowManager.findOverlaps(projectedBounds, this.id)\n\t\tif (overlaps.length > 0) {\n\t\t\tconst resolved = resolveOverlap(projectedBounds, overlaps, { width: window.innerWidth, height: window.innerHeight })\n\t\t\tif (Math.abs(resolved.left - projectedBounds.left) > 10 || Math.abs(resolved.top - projectedBounds.top) > 10) {\n\t\t\t\tconst isRight = this.currentCorner.includes('right')\n\t\t\t\tconst isBottom = this.currentCorner.includes('bottom')\n\t\t\t\tthis.position = {\n\t\t\t\t\tx: isRight ? window.innerWidth - resolved.left - resolved.width : resolved.left,\n\t\t\t\t\ty: isBottom ? window.innerHeight - resolved.top - resolved.height : resolved.top,\n\t\t\t\t}\n\t\t\t\tthis.applyContainerPosition()\n\t\t\t}\n\t\t}\n\n\t\tif (body) {\n\t\t\tbody.style.visibility = 'visible'\n\t\t\tbody.inert = false\n\t\t}\n\n\t\tif (reducedMotion$.value) {\n\t\t\tcontainer.style.clipPath = ''\n\t\t\tcontainer.style.overflow = ''\n\t\t\tthis.dispatchScopedEvent('window-toggle', { state: 'expanded' })\n\t\t\treturn\n\t\t}\n\n\t\tthis.currentAnimation?.cancel()\n\t\tcontainer.style.overflow = 'hidden'\n\t\tcontainer.style.willChange = 'opacity'\n\t\tconst openKeyframes: Keyframe[] = [\n\t\t\t{ clipPath: this.closedClipPath, opacity: 0.95 },\n\t\t\t{ clipPath: this.openClipPath, opacity: 1 },\n\t\t]\n\t\tconst anim = container.animate(openKeyframes, {\n\t\t\tduration: SPRING_SNAPPY.duration,\n\t\t\teasing: SPRING_SNAPPY.easingFallback,\n\t\t\tfill: 'forwards',\n\t\t})\n\t\tthis.currentAnimation = anim\n\n\t\tfrom(anim.finished).pipe(\n\t\t\ttake(1),\n\t\t\ttap(() => {\n\t\t\t\tif (container.isConnected) {\n\t\t\t\t\tcontainer.style.clipPath = ''\n\t\t\t\t\tcontainer.style.overflow = ''\n\t\t\t\t\tcontainer.style.willChange = ''\n\t\t\t\t}\n\t\t\t}),\n\t\t\tcatchError(() => EMPTY),\n\t\t\ttakeUntil(this.disconnecting),\n\t\t).subscribe()\n\n\t\tthis.dispatchScopedEvent('window-toggle', { state: 'expanded' })\n\t}\n\n\tprivate animateClose() {\n\t\tconst container = this.containerRef.value\n\t\tif (!container) return\n\n\t\tif (reducedMotion$.value) {\n\t\t\tcontainer.style.clipPath = this.closedClipPath\n\t\t\tcontainer.style.overflow = 'hidden'\n\t\t\tthis.open = false\n\t\t\tconst body = this.bodyRef.value\n\t\t\tif (body) { body.inert = true; body.style.visibility = 'hidden' }\n\t\t\tthis.dispatchScopedEvent('window-toggle', { state: 'collapsed' })\n\t\t\treturn\n\t\t}\n\n\t\tthis.currentAnimation?.cancel()\n\t\tcontainer.style.overflow = 'hidden'\n\t\tcontainer.style.willChange = 'opacity'\n\t\tconst closeKeyframes: Keyframe[] = [\n\t\t\t{ clipPath: this.openClipPath, opacity: 1 },\n\t\t\t{ clipPath: this.closedClipPath, opacity: 0.95 },\n\t\t]\n\t\tconst anim = container.animate(closeKeyframes, {\n\t\t\tduration: Math.round(SPRING_SNAPPY.duration * 0.7),\n\t\t\teasing: 'cubic-bezier(0.4, 0, 0.8, 0.15)',\n\t\t\tfill: 'forwards',\n\t\t})\n\t\tthis.currentAnimation = anim\n\n\t\tfrom(anim.finished).pipe(\n\t\t\ttake(1),\n\t\t\ttap(() => {\n\t\t\t\tthis.open = false\n\t\t\t\tcontainer.style.willChange = ''\n\t\t\t\tconst body = this.bodyRef.value\n\t\t\t\tif (body) { body.inert = true; body.style.visibility = 'hidden' }\n\t\t\t}),\n\t\t\tcatchError(() => EMPTY),\n\t\t\ttakeUntil(this.disconnecting),\n\t\t).subscribe()\n\n\t\tthis.dispatchScopedEvent('window-toggle', { state: 'collapsed' })\n\t}\n\n\t// ============================================\n\t// VISUAL STATE HELPERS\n\t// ============================================\n\n\t/** Apply drag visuals directly on DOM refs — avoids full Lit re-render for cursor + opacity */\n\tprivate applyDragVisuals(dragging: boolean) {\n\t\tconst head = this.headRef.value\n\t\tconst container = this.containerRef.value\n\t\tif (head) {\n\t\t\thead.classList.toggle('cursor-grabbing', dragging)\n\t\t\thead.classList.toggle('cursor-move', !dragging)\n\t\t}\n\t\tif (container) {\n\t\t\tcontainer.style.opacity = dragging ? '0.95' : ''\n\t\t}\n\t}\n\n\tprivate handleFocus = () => windowManager.focus(this.id)\n\n\tprivate handleHeadKeydown = (e: KeyboardEvent) => {\n\t\tif (e.key === 'Enter' || e.key === ' ') {\n\t\t\te.preventDefault()\n\t\t\tthis.toggle()\n\t\t\treturn\n\t\t}\n\t\tif (e.key === 'ArrowUp' || e.key === 'ArrowDown' || e.key === 'ArrowLeft' || e.key === 'ArrowRight') {\n\t\t\te.preventDefault()\n\t\t\tconst step = e.shiftKey ? 20 : 5\n\t\t\tconst dx = e.key === 'ArrowRight' ? step : e.key === 'ArrowLeft' ? -step : 0\n\t\t\tconst dy = e.key === 'ArrowDown' ? step : e.key === 'ArrowUp' ? -step : 0\n\t\t\tthis.position = { x: this.position.x + dx, y: this.position.y + dy }\n\t\t\tthis.applyContainerPosition()\n\t\t\tthis.savePosition()\n\t\t}\n\t}\n\n\t// ============================================\n\t// PUBLIC API\n\t// ============================================\n\n\ttoggle() {\n\t\tif (this.open) this.animateClose()\n\t\telse this.animateOpen()\n\t}\n\n\texpand() {\n\t\tif (this.open) return\n\t\tthis.animateOpen()\n\t}\n\n\tclose() {\n\t\tif (!this.open) return\n\t\tthis.animateClose()\n\t}\n\n\t// ============================================\n\t// RENDER\n\t// ============================================\n\n\tprotected render(): unknown {\n\t\tconst isBottom = this.currentCorner.startsWith('bottom')\n\n\t\tconst containerClasses = classMap({\n\t\t\tfixed: true,\n\t\t\tflex: true,\n\t\t\t'flex-col': isBottom,\n\t\t\t'flex-col-reverse': !isBottom,\n\t\t\t'z-1000': true,\n\t\t\t'rounded-2xl': this.open,\n\t\t\t'rounded-[22px]': !this.open,\n\t\t\t'overflow-hidden': true,\n\t\t\t'shadow-sm': !this.open && this.lowered,\n\t\t\t'shadow-md': !this.open && !this.lowered,\n\t\t\t'shadow-lg': this.open,\n\t\t})\n\n\t\tconst containerStyles = styleMap({\n\t\t\twidth: this.panelWidth,\n\t\t\t'max-height': 'calc(100vh - 32px)',\n\t\t\t'pointer-events': 'none',\n\t\t})\n\n\t\tconst bodyStyles = styleMap({\n\t\t\t'pointer-events': this.open ? 'auto' : 'none',\n\t\t})\n\n\t\tconst headClasses = classMap({\n\t\t\t'h-full': true,\n\t\t\t'px-3': true,\n\t\t\tflex: true,\n\t\t\t'items-center': true,\n\t\t\t'gap-2': true,\n\t\t\t'select-none': true,\n\t\t\t'cursor-move': true,\n\t\t})\n\n\t\treturn html`\n\t\t\t<schmancy-surface\n\t\t\t\t${ref(this.containerRef)}\n\t\t\t\ttype=\"glass\"\n\t\t\t\tclass=${containerClasses}\n\t\t\t\tstyle=${containerStyles}\n\t\t\t\taria-expanded=${this.open}\n\t\t\t\t@pointerdown=${this.handleFocus}\n\t\t\t>\n\t\t\t\t<!-- Details section (visually above summary for bottom corners) -->\n\t\t\t\t<section\n\t\t\t\t\t${ref(this.bodyRef)}\n\t\t\t\t\tclass=\"flex-1 min-h-0 overflow-hidden flex flex-col\"\n\t\t\t\t\tstyle=${bodyStyles}\n\t\t\t\t\trole=\"region\"\n\t\t\t\t\taria-label=\"Expandable content\"\n\t\t\t\t>\n\t\t\t\t\t${this.hasOpened ? html`<slot name=\"details\"></slot>` : nothing}\n\t\t\t\t</section>\n\n\t\t\t\t<!-- Summary section -- always interactive, always visible -->\n\t\t\t\t<section\n\t\t\t\t\tclass=\"shrink-0 bg-surface-lowest\"\n\t\t\t\t\tstyle=${styleMap({ 'pointer-events': 'auto', height: `${HEAD_HEIGHT}px` })}\n\t\t\t\t>\n\t\t\t\t\t<div\n\t\t\t\t\t\t${ref(this.headRef)}\n\t\t\t\t\t\t${cursorGlow({ radius: 200, intensity: 0.10 })}\n\t\t\t\t\t\tclass=${headClasses}\n\t\t\t\t\t\trole=\"button\"\n\t\t\t\t\t\ttabindex=\"0\"\n\t\t\t\t\t\ttitle=\"Drag to move, click to expand\"\n\t\t\t\t\t\taria-label=\"${this.open ? 'Collapse window' : 'Expand window'}\"\n\t\t\t\t\t\t@keydown=${this.handleHeadKeydown}\n\t\t\t\t\t>\n\t\t\t\t\t\t<div class=\"flex-1 min-w-0\">\n\t\t\t\t\t\t\t<slot></slot>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t<svg\n\t\t\t\t\t\t\twidth=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\"\n\t\t\t\t\t\t\tclass=\"shrink-0 text-surface-on/40 transition-transform duration-200 ${this.open ? 'rotate-180' : ''}\"\n\t\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<path d=\"M6 9L12 15L18 9\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" />\n\t\t\t\t\t\t</svg>\n\t\t\t\t\t</div>\n\t\t\t\t</section>\n\t\t\t</schmancy-surface>\n\t\t`\n\t}\n}\n\ndeclare global {\n\tinterface HTMLElementTagNameMap {\n\t\t'schmancy-window': SchmancyWindow\n\t}\n}\n"],"mappings":";;;;;;;;;;;;;AAmBA,IAAM,IAAiB,oBACjB,IAAwB;AAmL9B,SAAS,EAAa,GAAiB,GAAA;CACtC,OAAA,EAAS,EAAE,QAAQ,EAAE,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,UAAU,EAAE;AACzH;AAEA,IAAA,GAAa,IArLb,MAAM,EAAA;CAGL;CAQA,cAAA;EAAA,KAAA,KARmB,IAAI,EAAqC;GAC3D,yBAAS,IAAI,IAAA;GACb,WAAW;GACX,YAAY,CAAA;EAAA,CAAA,GAAA,KAAA,SAGK,KAAA,GAAa,aAAA;CAER;CAEvB,OAAA,cAAO;EAIN,OAHK,AACJ,EAAqB,aAAW,IAAI,KAE9B,EAAqB;C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