@mhmo91/schmancy 0.10.5 → 0.10.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (383) hide show
  1. package/custom-elements.json +4 -707
  2. package/dist/agent/{flow-CaPi2G8y.js.map → flow-3RrZM-e7.js.map} +1 -1
  3. package/dist/agent/schmancy.agent.js +2807 -4687
  4. package/dist/agent/schmancy.agent.js.map +1 -1
  5. package/dist/agent/schmancy.manifest.json +6 -471
  6. package/dist/agent/{vendor-jsqr-r7GNh4P3.js.map → vendor-jsqr-BUVwyoGC.js.map} +1 -1
  7. package/dist/agent/{vendor-material-color-Be96dpGE.js.map → vendor-material-color-33Mj762T.js.map} +1 -1
  8. package/dist/{area-D5haQE-J.js → area-CIZZ5tbB.js} +1 -1
  9. package/dist/{area-D5haQE-J.js.map → area-CIZZ5tbB.js.map} +1 -1
  10. package/dist/{area-CSQdhCBF.cjs → area-oZjYJlUy.cjs} +1 -1
  11. package/dist/{area-CSQdhCBF.cjs.map → area-oZjYJlUy.cjs.map} +1 -1
  12. package/dist/area.cjs +1 -1
  13. package/dist/area.js +1 -1
  14. package/dist/{autocomplete-DtyjZJ1E.js → autocomplete-C1oDLuol.js} +2 -2
  15. package/dist/{autocomplete-DtyjZJ1E.js.map → autocomplete-C1oDLuol.js.map} +1 -1
  16. package/dist/{autocomplete-B_bJXUjm.cjs → autocomplete-X20i6D62.cjs} +1 -1
  17. package/dist/{autocomplete-B_bJXUjm.cjs.map → autocomplete-X20i6D62.cjs.map} +1 -1
  18. package/dist/autocomplete.cjs +1 -1
  19. package/dist/autocomplete.js +1 -1
  20. package/dist/avatar.cjs +1 -1
  21. package/dist/avatar.js +2 -2
  22. package/dist/badge.cjs +1 -1
  23. package/dist/badge.js +1 -1
  24. package/dist/{boat-BJLCp-Hv.cjs → boat-CUx58Gwe.cjs} +1 -1
  25. package/dist/{boat-BJLCp-Hv.cjs.map → boat-CUx58Gwe.cjs.map} +1 -1
  26. package/dist/{boat-MT8bRT8u.js → boat-CpE0yAlK.js} +1 -1
  27. package/dist/{boat-MT8bRT8u.js.map → boat-CpE0yAlK.js.map} +1 -1
  28. package/dist/boat.cjs +1 -1
  29. package/dist/boat.js +1 -1
  30. package/dist/breadcrumb.cjs +1 -1
  31. package/dist/breadcrumb.js +1 -1
  32. package/dist/{busy-6BqWGryX.js → busy-C9n-DUY4.js} +1 -1
  33. package/dist/{busy-6BqWGryX.js.map → busy-C9n-DUY4.js.map} +1 -1
  34. package/dist/{busy-DSF2E-zy.cjs → busy-D1DKZhgV.cjs} +1 -1
  35. package/dist/{busy-DSF2E-zy.cjs.map → busy-D1DKZhgV.cjs.map} +1 -1
  36. package/dist/busy.cjs +1 -1
  37. package/dist/busy.js +1 -1
  38. package/dist/button.cjs +1 -1
  39. package/dist/button.js +1 -1
  40. package/dist/{card-CvuVha-W.js → card-B3hN-qzk.js} +1 -1
  41. package/dist/{card-CvuVha-W.js.map → card-B3hN-qzk.js.map} +1 -1
  42. package/dist/{card-DnKnaHzf.cjs → card-DZJ7qjf2.cjs} +1 -1
  43. package/dist/{card-DnKnaHzf.cjs.map → card-DZJ7qjf2.cjs.map} +1 -1
  44. package/dist/card.cjs +1 -1
  45. package/dist/card.js +1 -1
  46. package/dist/charts.cjs +1 -1
  47. package/dist/charts.js +1 -1
  48. package/dist/{checkbox-QDRsE8cp.js → checkbox-CvmB1ev9.js} +1 -1
  49. package/dist/{checkbox-QDRsE8cp.js.map → checkbox-CvmB1ev9.js.map} +1 -1
  50. package/dist/{checkbox-D3u8Wm9r.cjs → checkbox-DapdzDow.cjs} +1 -1
  51. package/dist/{checkbox-D3u8Wm9r.cjs.map → checkbox-DapdzDow.cjs.map} +1 -1
  52. package/dist/checkbox.cjs +1 -1
  53. package/dist/checkbox.js +1 -1
  54. package/dist/{chips-CMoQzop1.cjs → chips-7g6mWRuh.cjs} +1 -1
  55. package/dist/{chips-CMoQzop1.cjs.map → chips-7g6mWRuh.cjs.map} +1 -1
  56. package/dist/{chips-Dy9vx8JS.js → chips-C8Y3_3ke.js} +2 -2
  57. package/dist/{chips-Dy9vx8JS.js.map → chips-C8Y3_3ke.js.map} +1 -1
  58. package/dist/chips.cjs +1 -1
  59. package/dist/chips.js +2 -2
  60. package/dist/connectivity.cjs +1 -1
  61. package/dist/connectivity.js +1 -1
  62. package/dist/content-drawer.cjs +1 -1
  63. package/dist/content-drawer.js +1 -1
  64. package/dist/{date-range-Boesjlic.js → date-range-DdcaPX7C.js} +2 -2
  65. package/dist/{date-range-Boesjlic.js.map → date-range-DdcaPX7C.js.map} +1 -1
  66. package/dist/{date-range-B2NuihKA.cjs → date-range-ZfUl4duV.cjs} +1 -1
  67. package/dist/{date-range-B2NuihKA.cjs.map → date-range-ZfUl4duV.cjs.map} +1 -1
  68. package/dist/{date-range-inline-BI6_4Ahl.cjs → date-range-inline-D-d7N6bh.cjs} +1 -1
  69. package/dist/{date-range-inline-BI6_4Ahl.cjs.map → date-range-inline-D-d7N6bh.cjs.map} +1 -1
  70. package/dist/{date-range-inline-DBuND2pc.js → date-range-inline-QQmIWhZ4.js} +1 -1
  71. package/dist/{date-range-inline-DBuND2pc.js.map → date-range-inline-QQmIWhZ4.js.map} +1 -1
  72. package/dist/date-range-inline.cjs +1 -1
  73. package/dist/date-range-inline.js +1 -1
  74. package/dist/date-range.cjs +1 -1
  75. package/dist/date-range.js +1 -1
  76. package/dist/delay.cjs +1 -1
  77. package/dist/delay.js +2 -2
  78. package/dist/{details-BRs_z5-k.cjs → details-3rL6UQU8.cjs} +1 -1
  79. package/dist/{details-BRs_z5-k.cjs.map → details-3rL6UQU8.cjs.map} +1 -1
  80. package/dist/{details-BrGrUTGC.js → details-Dpjh-XnJ.js} +1 -1
  81. package/dist/{details-BrGrUTGC.js.map → details-Dpjh-XnJ.js.map} +1 -1
  82. package/dist/details.cjs +1 -1
  83. package/dist/details.js +1 -1
  84. package/dist/{divider-W3TiDasp.js → divider-BdfEKQsH.js} +1 -1
  85. package/dist/{divider-W3TiDasp.js.map → divider-BdfEKQsH.js.map} +1 -1
  86. package/dist/{divider-BOxQ2T9h.cjs → divider-CutXDz3F.cjs} +1 -1
  87. package/dist/{divider-BOxQ2T9h.cjs.map → divider-CutXDz3F.cjs.map} +1 -1
  88. package/dist/divider.cjs +1 -1
  89. package/dist/divider.js +1 -1
  90. package/dist/dropdown.cjs +1 -1
  91. package/dist/dropdown.js +1 -1
  92. package/dist/{expand-CnccBF91.cjs → expand-DM6zfZf7.cjs} +1 -1
  93. package/dist/{expand-CnccBF91.cjs.map → expand-DM6zfZf7.cjs.map} +1 -1
  94. package/dist/{expand-Pu8fZ0jZ.js → expand-DrgMPJbu.js} +2 -2
  95. package/dist/{expand-Pu8fZ0jZ.js.map → expand-DrgMPJbu.js.map} +1 -1
  96. package/dist/expand.cjs +1 -1
  97. package/dist/expand.js +1 -1
  98. package/dist/{extra-DxEWs41z.js → extra-B6gFu4_1.js} +1 -1
  99. package/dist/{extra-DxEWs41z.js.map → extra-B6gFu4_1.js.map} +1 -1
  100. package/dist/{extra-B8IPs6gG.cjs → extra-DJRYaOXe.cjs} +1 -1
  101. package/dist/{extra-B8IPs6gG.cjs.map → extra-DJRYaOXe.cjs.map} +1 -1
  102. package/dist/extra.cjs +1 -1
  103. package/dist/extra.js +1 -1
  104. package/dist/{float-WCVdp3um.js → float-1iihPek5.js} +1 -1
  105. package/dist/{float-WCVdp3um.js.map → float-1iihPek5.js.map} +1 -1
  106. package/dist/{float-BRKa-P6Z.cjs → float-Ckyk85XG.cjs} +1 -1
  107. package/dist/{float-BRKa-P6Z.cjs.map → float-Ckyk85XG.cjs.map} +1 -1
  108. package/dist/float.cjs +1 -1
  109. package/dist/float.js +1 -1
  110. package/dist/{form-CI59gad4.js.map → form-BF1c3Dk1.js.map} +1 -1
  111. package/dist/{form-B2qudx_q.cjs.map → form-DeO5XX3b.cjs.map} +1 -1
  112. package/dist/form.cjs +1 -1
  113. package/dist/form.js +1 -1
  114. package/dist/handover/agent-runtime-followups.md +1 -1
  115. package/dist/handover/agent-runtime-v1.md +3 -3
  116. package/dist/{hashContent-a8uVr3xs.js.map → hashContent-BU6jl5ih.js.map} +1 -1
  117. package/dist/{hashContent-ejkBgDnN.cjs.map → hashContent-Bobsobip.cjs.map} +1 -1
  118. package/dist/{icons-DXEbmg-O.cjs → icons-CV-fiGcW.cjs} +1 -1
  119. package/dist/{icons-DXEbmg-O.cjs.map → icons-CV-fiGcW.cjs.map} +1 -1
  120. package/dist/{icons-C0ufCcdp.js → icons-DUkcTZAY.js} +1 -1
  121. package/dist/{icons-C0ufCcdp.js.map → icons-DUkcTZAY.js.map} +1 -1
  122. package/dist/icons.cjs +1 -1
  123. package/dist/icons.js +1 -1
  124. package/dist/{iframe-c9lGxw7x.js → iframe-C9tj7F6Y.js} +1 -1
  125. package/dist/{iframe-c9lGxw7x.js.map → iframe-C9tj7F6Y.js.map} +1 -1
  126. package/dist/{iframe-C6RVODkW.cjs → iframe-DF97oGtZ.cjs} +1 -1
  127. package/dist/{iframe-C6RVODkW.cjs.map → iframe-DF97oGtZ.cjs.map} +1 -1
  128. package/dist/iframe.cjs +1 -1
  129. package/dist/iframe.js +1 -1
  130. package/dist/index.cjs +1 -1
  131. package/dist/index.js +70 -72
  132. package/dist/{input-Pmj_bH37.js → input-DE7x223Y.js} +1 -1
  133. package/dist/{input-Pmj_bH37.js.map → input-DE7x223Y.js.map} +1 -1
  134. package/dist/{input-B4HM-9-H.cjs → input-TW9G3n7X.cjs} +1 -1
  135. package/dist/{input-B4HM-9-H.cjs.map → input-TW9G3n7X.cjs.map} +1 -1
  136. package/dist/{input-chip-BIGgd_7w.js → input-chip-BdoaVw_D.js} +1 -1
  137. package/dist/{input-chip-BIGgd_7w.js.map → input-chip-BdoaVw_D.js.map} +1 -1
  138. package/dist/{input-chip-BoDisY6c.cjs → input-chip-Do48eI5r.cjs} +1 -1
  139. package/dist/{input-chip-BoDisY6c.cjs.map → input-chip-Do48eI5r.cjs.map} +1 -1
  140. package/dist/input.cjs +1 -1
  141. package/dist/input.js +1 -1
  142. package/dist/json.cjs +1 -1
  143. package/dist/json.js +2 -2
  144. package/dist/kbd.cjs +1 -1
  145. package/dist/kbd.js +1 -1
  146. package/dist/layout.cjs +1 -1
  147. package/dist/layout.js +1 -1
  148. package/dist/{lightbox-K1eJTYXP.js → lightbox-DcutIyjx.js} +2 -2
  149. package/dist/{lightbox-K1eJTYXP.js.map → lightbox-DcutIyjx.js.map} +1 -1
  150. package/dist/{lightbox-DK1vDKm3.cjs → lightbox-sPfnYzjJ.cjs} +1 -1
  151. package/dist/{lightbox-DK1vDKm3.cjs.map → lightbox-sPfnYzjJ.cjs.map} +1 -1
  152. package/dist/lightbox.cjs +1 -1
  153. package/dist/lightbox.js +1 -1
  154. package/dist/{list-Ds0Nv1y5.js → list-BWrtrdgs.js} +1 -1
  155. package/dist/{list-Ds0Nv1y5.js.map → list-BWrtrdgs.js.map} +1 -1
  156. package/dist/{list-CEuVqAxN.cjs → list-C4vasUly.cjs} +1 -1
  157. package/dist/{list-CEuVqAxN.cjs.map → list-C4vasUly.cjs.map} +1 -1
  158. package/dist/list.cjs +1 -1
  159. package/dist/list.js +1 -1
  160. package/dist/{map-BrBSrIqg.cjs → map-BAQ9FEB6.cjs} +1 -1
  161. package/dist/{map-BrBSrIqg.cjs.map → map-BAQ9FEB6.cjs.map} +1 -1
  162. package/dist/{map-1uwxxvBa.js → map-CEreveeI.js} +1 -1
  163. package/dist/{map-1uwxxvBa.js.map → map-CEreveeI.js.map} +1 -1
  164. package/dist/map.cjs +1 -1
  165. package/dist/map.js +1 -1
  166. package/dist/{menu-Bly30Nje.cjs → menu-3yXDZusj.cjs} +1 -1
  167. package/dist/{menu-Bly30Nje.cjs.map → menu-3yXDZusj.cjs.map} +1 -1
  168. package/dist/{menu-L8MK1ma5.js → menu-CxChOxWT.js} +2 -2
  169. package/dist/{menu-L8MK1ma5.js.map → menu-CxChOxWT.js.map} +1 -1
  170. package/dist/menu.cjs +1 -1
  171. package/dist/menu.js +1 -1
  172. package/dist/mixins-Db7gjDah.cjs +298 -0
  173. package/dist/{mixins-CAb0b03r.cjs.map → mixins-Db7gjDah.cjs.map} +1 -1
  174. package/dist/mixins-Dw6hVfy-.js +627 -0
  175. package/dist/{mixins-B34UxxCe.js.map → mixins-Dw6hVfy-.js.map} +1 -1
  176. package/dist/mixins.cjs +1 -1
  177. package/dist/mixins.js +1 -1
  178. package/dist/nav-drawer.cjs +1 -1
  179. package/dist/nav-drawer.js +1 -1
  180. package/dist/navigation-bar.cjs +1 -1
  181. package/dist/navigation-bar.js +1 -1
  182. package/dist/navigation-rail.cjs +1 -1
  183. package/dist/navigation-rail.js +1 -1
  184. package/dist/{notification-7fSbk8hm.cjs → notification-DKYy9qVe.cjs} +1 -1
  185. package/dist/{notification-7fSbk8hm.cjs.map → notification-DKYy9qVe.cjs.map} +1 -1
  186. package/dist/{notification-DB25M-qo.js → notification-ycbUBbOu.js} +2 -2
  187. package/dist/{notification-DB25M-qo.js.map → notification-ycbUBbOu.js.map} +1 -1
  188. package/dist/notification.cjs +1 -1
  189. package/dist/notification.js +1 -1
  190. package/dist/{option-DDHa25k5.js → option-DtOhMd3k.js} +1 -1
  191. package/dist/{option-DDHa25k5.js.map → option-DtOhMd3k.js.map} +1 -1
  192. package/dist/{option-HF9Xqbuq.cjs → option-zgVge3BH.cjs} +1 -1
  193. package/dist/{option-HF9Xqbuq.cjs.map → option-zgVge3BH.cjs.map} +1 -1
  194. package/dist/option.cjs +1 -1
  195. package/dist/option.js +1 -1
  196. package/dist/{overlay-stack-CCiTaf_C.js.map → overlay-stack-DCDS17uj.js.map} +1 -1
  197. package/dist/{overlay-stack-CFGiYf34.cjs.map → overlay-stack-DPIe_aYv.cjs.map} +1 -1
  198. package/dist/overlay.cjs +1 -1
  199. package/dist/{overlay.confirm-body-BDG94R0x.js → overlay.confirm-body-AFqYBqrI.js} +1 -1
  200. package/dist/{overlay.confirm-body-BDG94R0x.js.map → overlay.confirm-body-AFqYBqrI.js.map} +1 -1
  201. package/dist/{overlay.confirm-body-b4Nx_OVf.cjs → overlay.confirm-body-DctQLDao.cjs} +1 -1
  202. package/dist/{overlay.confirm-body-b4Nx_OVf.cjs.map → overlay.confirm-body-DctQLDao.cjs.map} +1 -1
  203. package/dist/overlay.js +3 -3
  204. package/dist/{overlay.service-BUCuZa6V.js → overlay.service-B9On2-Aa.js} +2 -2
  205. package/dist/{overlay.service-BUCuZa6V.js.map → overlay.service-B9On2-Aa.js.map} +1 -1
  206. package/dist/{overlay.service-CRHZZY9F.cjs → overlay.service-k2nCE4pi.cjs} +1 -1
  207. package/dist/{overlay.service-CRHZZY9F.cjs.map → overlay.service-k2nCE4pi.cjs.map} +1 -1
  208. package/dist/page.cjs +1 -1
  209. package/dist/page.js +2 -2
  210. package/dist/{payment-card-form-C4jb-OdM.js → payment-card-form-Be1-OVlL.js} +1 -1
  211. package/dist/{payment-card-form-C4jb-OdM.js.map → payment-card-form-Be1-OVlL.js.map} +1 -1
  212. package/dist/{payment-card-form-WEx4CscR.cjs → payment-card-form-CNnGePG4.cjs} +1 -1
  213. package/dist/{payment-card-form-WEx4CscR.cjs.map → payment-card-form-CNnGePG4.cjs.map} +1 -1
  214. package/dist/payment-card-form.cjs +1 -1
  215. package/dist/payment-card-form.js +1 -1
  216. package/dist/{progress-CqOyMM4i.js → progress-BFWzmTlz.js} +1 -1
  217. package/dist/{progress-CqOyMM4i.js.map → progress-BFWzmTlz.js.map} +1 -1
  218. package/dist/{progress-54R4QRgW.cjs → progress-C4TGG2eN.cjs} +1 -1
  219. package/dist/{progress-54R4QRgW.cjs.map → progress-C4TGG2eN.cjs.map} +1 -1
  220. package/dist/progress.cjs +1 -1
  221. package/dist/progress.js +1 -1
  222. package/dist/qr-scanner.cjs +1 -1
  223. package/dist/qr-scanner.js +1 -1
  224. package/dist/{radio-group-B4zbBIZF.js → radio-group-DTNAW5dd.js} +1 -1
  225. package/dist/{radio-group-B4zbBIZF.js.map → radio-group-DTNAW5dd.js.map} +1 -1
  226. package/dist/{radio-group-BJqZpYVy.cjs → radio-group-xLRp1g57.cjs} +1 -1
  227. package/dist/{radio-group-BJqZpYVy.cjs.map → radio-group-xLRp1g57.cjs.map} +1 -1
  228. package/dist/radio-group.cjs +1 -1
  229. package/dist/radio-group.js +1 -1
  230. package/dist/range.cjs +1 -1
  231. package/dist/range.js +1 -1
  232. package/dist/{rxjs-utils-BXpvHN4-.js.map → rxjs-utils-BK8VMe3K.js.map} +1 -1
  233. package/dist/{rxjs-utils-CaC-tdot.cjs.map → rxjs-utils-DhOKenkS.cjs.map} +1 -1
  234. package/dist/rxjs-utils.cjs +1 -1
  235. package/dist/rxjs-utils.js +1 -1
  236. package/dist/{scroll-CYm6Krus.js → scroll-BCmdqSQU.js} +1 -1
  237. package/dist/{scroll-CYm6Krus.js.map → scroll-BCmdqSQU.js.map} +1 -1
  238. package/dist/{scroll-iSRovYYt.cjs → scroll-Bdgb-vRy.cjs} +1 -1
  239. package/dist/{scroll-iSRovYYt.cjs.map → scroll-Bdgb-vRy.cjs.map} +1 -1
  240. package/dist/{select-1WHseXP6.js → select-COGARE0b.js} +2 -2
  241. package/dist/{select-1WHseXP6.js.map → select-COGARE0b.js.map} +1 -1
  242. package/dist/{select-DiQHtQJN.cjs → select-Cv5t_PT3.cjs} +1 -1
  243. package/dist/{select-DiQHtQJN.cjs.map → select-Cv5t_PT3.cjs.map} +1 -1
  244. package/dist/select.cjs +1 -1
  245. package/dist/select.js +1 -1
  246. package/dist/skeleton.cjs +1 -1
  247. package/dist/skeleton.js +1 -1
  248. package/dist/skills/INDEX.md +1 -4
  249. package/dist/skills/schmancy/INDEX.md +1 -4
  250. package/dist/slider.cjs +1 -1
  251. package/dist/slider.js +1 -1
  252. package/dist/{splash-screen-CJL8DGDe.cjs → splash-screen-B8rFbjqT.cjs} +1 -1
  253. package/dist/{splash-screen-CJL8DGDe.cjs.map → splash-screen-B8rFbjqT.cjs.map} +1 -1
  254. package/dist/{splash-screen-BwvtKMdN.js → splash-screen-DbGbGttg.js} +1 -1
  255. package/dist/{splash-screen-BwvtKMdN.js.map → splash-screen-DbGbGttg.js.map} +1 -1
  256. package/dist/splash-screen.cjs +1 -1
  257. package/dist/splash-screen.js +1 -1
  258. package/dist/{src-UaZeROcW.js → src-YRir9pOP.js} +37 -39
  259. package/dist/{src-UaZeROcW.js.map → src-YRir9pOP.js.map} +1 -1
  260. package/dist/{src-Bwr2NR0A.cjs → src-b8D-Ec-Q.cjs} +1 -1
  261. package/dist/{src-Bwr2NR0A.cjs.map → src-b8D-Ec-Q.cjs.map} +1 -1
  262. package/dist/steps.cjs +1 -1
  263. package/dist/steps.js +1 -1
  264. package/dist/{surface-DPUkQ3OL.js → surface-BE7sGTBt.js} +1 -1
  265. package/dist/{surface-DPUkQ3OL.js.map → surface-BE7sGTBt.js.map} +1 -1
  266. package/dist/{surface-DE5iuI8e.cjs → surface-BvudRtf5.cjs} +1 -1
  267. package/dist/{surface-DE5iuI8e.cjs.map → surface-BvudRtf5.cjs.map} +1 -1
  268. package/dist/surface.cjs +1 -1
  269. package/dist/surface.js +1 -1
  270. package/dist/switch.cjs +1 -1
  271. package/dist/switch.js +1 -1
  272. package/dist/table.cjs +1 -1
  273. package/dist/table.js +1 -1
  274. package/dist/{tabs-CsDQ72Qk.cjs → tabs-C0XKld1Z.cjs} +1 -1
  275. package/dist/{tabs-CsDQ72Qk.cjs.map → tabs-C0XKld1Z.cjs.map} +1 -1
  276. package/dist/{tabs-B2XEQPQl.js → tabs-DIzCRsA3.js} +1 -1
  277. package/dist/{tabs-B2XEQPQl.js.map → tabs-DIzCRsA3.js.map} +1 -1
  278. package/dist/tabs.cjs +1 -1
  279. package/dist/tabs.js +1 -1
  280. package/dist/teleport.cjs +1 -1
  281. package/dist/teleport.js +1 -1
  282. package/dist/{textarea-aeAP9cDG.cjs → textarea-BCDCGCJd.cjs} +1 -1
  283. package/dist/{textarea-aeAP9cDG.cjs.map → textarea-BCDCGCJd.cjs.map} +1 -1
  284. package/dist/{textarea-C_ps0lL-.js → textarea-UbZzBwqm.js} +1 -1
  285. package/dist/{textarea-C_ps0lL-.js.map → textarea-UbZzBwqm.js.map} +1 -1
  286. package/dist/textarea.cjs +1 -1
  287. package/dist/textarea.js +1 -1
  288. package/dist/{theme-DAYTVw13.cjs → theme-CIsI-sFj.cjs} +1 -1
  289. package/dist/{theme-DAYTVw13.cjs.map → theme-CIsI-sFj.cjs.map} +1 -1
  290. package/dist/{theme-DAx1iRNr.js → theme-Qh-yPEPL.js} +2 -2
  291. package/dist/{theme-DAx1iRNr.js.map → theme-Qh-yPEPL.js.map} +1 -1
  292. package/dist/{theme-button-BrHkzCtj.js → theme-button-CjTnfs9x.js} +1 -1
  293. package/dist/{theme-button-BrHkzCtj.js.map → theme-button-CjTnfs9x.js.map} +1 -1
  294. package/dist/{theme-button-LsMKY_N_.cjs → theme-button-Dv1D_Vil.cjs} +1 -1
  295. package/dist/{theme-button-LsMKY_N_.cjs.map → theme-button-Dv1D_Vil.cjs.map} +1 -1
  296. package/dist/theme-button.cjs +1 -1
  297. package/dist/theme-button.js +1 -1
  298. package/dist/theme.cjs +1 -1
  299. package/dist/{theme.interface-DESopuZS.cjs.map → theme.interface-BeW-sz_g.cjs.map} +1 -1
  300. package/dist/{theme.interface-C_034TxG.js.map → theme.interface-v7SkAnDH.js.map} +1 -1
  301. package/dist/theme.js +3 -3
  302. package/dist/timeline.cjs +1 -1
  303. package/dist/timeline.js +1 -1
  304. package/dist/tree.cjs +1 -1
  305. package/dist/tree.js +1 -1
  306. package/dist/typography.cjs +1 -1
  307. package/dist/typography.js +1 -1
  308. package/dist/{utils-BzFQfaIr.js → utils-BfOze6Tk.js} +1 -1
  309. package/dist/{utils-BzFQfaIr.js.map → utils-BfOze6Tk.js.map} +1 -1
  310. package/dist/{utils-oLBkMvor.cjs → utils-CJ9y2Jz9.cjs} +1 -1
  311. package/dist/{utils-oLBkMvor.cjs.map → utils-CJ9y2Jz9.cjs.map} +1 -1
  312. package/dist/utils.cjs +1 -1
  313. package/dist/utils.js +2 -2
  314. package/dist/visually-hidden.cjs +1 -1
  315. package/dist/visually-hidden.js +1 -1
  316. package/dist/{window-BJrKS6Zr.cjs → window-9HOUXrTU.cjs} +1 -1
  317. package/dist/{window-BJrKS6Zr.cjs.map → window-9HOUXrTU.cjs.map} +1 -1
  318. package/dist/{window-CyDuTN80.js → window-B_55dzk0.js} +2 -2
  319. package/dist/{window-CyDuTN80.js.map → window-B_55dzk0.js.map} +1 -1
  320. package/dist/window.cjs +1 -1
  321. package/dist/window.js +1 -1
  322. package/package.json +1 -2
  323. package/skills/schmancy/INDEX.md +1 -4
  324. package/src/index.ts +0 -2
  325. package/types/src/index.d.ts +0 -2
  326. package/dist/agent/vendor-highlight-CHJZQQB7.js +0 -2178
  327. package/dist/agent/vendor-highlight-CHJZQQB7.js.map +0 -1
  328. package/dist/code-highlight-Ddp0oZnm.cjs +0 -190
  329. package/dist/code-highlight-Ddp0oZnm.cjs.map +0 -1
  330. package/dist/code-highlight-DtE2-ObF.js +0 -296
  331. package/dist/code-highlight-DtE2-ObF.js.map +0 -1
  332. package/dist/code-highlight.cjs +0 -1
  333. package/dist/code-highlight.js +0 -2
  334. package/dist/mailbox-CDWqbVvZ.cjs +0 -1140
  335. package/dist/mailbox-CDWqbVvZ.cjs.map +0 -1
  336. package/dist/mailbox-DD2How0H.js +0 -1607
  337. package/dist/mailbox-DD2How0H.js.map +0 -1
  338. package/dist/mailbox.cjs +0 -1
  339. package/dist/mailbox.js +0 -2
  340. package/dist/mixins-B34UxxCe.js +0 -627
  341. package/dist/mixins-CAb0b03r.cjs +0 -298
  342. package/dist/skills/code-highlight.md +0 -47
  343. package/dist/skills/mailbox.md +0 -102
  344. package/dist/skills/schmancy/code-highlight.md +0 -47
  345. package/dist/skills/schmancy/mailbox.md +0 -102
  346. package/skills/schmancy/code-highlight.md +0 -47
  347. package/skills/schmancy/mailbox.md +0 -102
  348. package/src/code-highlight/code-highlight.ts +0 -345
  349. package/src/code-highlight/code-preview.ts +0 -125
  350. package/src/code-highlight/index.ts +0 -3
  351. package/src/mailbox/README.md +0 -128
  352. package/src/mailbox/email-editor.ts +0 -1076
  353. package/src/mailbox/email-layout-selector.ts +0 -58
  354. package/src/mailbox/email-recipients.ts +0 -599
  355. package/src/mailbox/email-template-picker.ts +0 -303
  356. package/src/mailbox/email-viewer.ts +0 -717
  357. package/src/mailbox/index.ts +0 -31
  358. package/src/mailbox/mailbox.ts +0 -364
  359. package/src/mailbox/types.ts +0 -180
  360. package/types/src/code-highlight/code-highlight.d.ts +0 -49
  361. package/types/src/code-highlight/code-preview.d.ts +0 -30
  362. package/types/src/code-highlight/index.d.ts +0 -3
  363. package/types/src/mailbox/email-editor.d.ts +0 -101
  364. package/types/src/mailbox/email-layout-selector.d.ts +0 -18
  365. package/types/src/mailbox/email-recipients.d.ts +0 -122
  366. package/types/src/mailbox/email-template-picker.d.ts +0 -54
  367. package/types/src/mailbox/email-viewer.d.ts +0 -86
  368. package/types/src/mailbox/index.d.ts +0 -12
  369. package/types/src/mailbox/mailbox.d.ts +0 -82
  370. package/types/src/mailbox/types.d.ts +0 -176
  371. /package/dist/agent/{flow-CaPi2G8y.js → flow-3RrZM-e7.js} +0 -0
  372. /package/dist/agent/{vendor-jsqr-r7GNh4P3.js → vendor-jsqr-BUVwyoGC.js} +0 -0
  373. /package/dist/agent/{vendor-material-color-Be96dpGE.js → vendor-material-color-33Mj762T.js} +0 -0
  374. /package/dist/{form-CI59gad4.js → form-BF1c3Dk1.js} +0 -0
  375. /package/dist/{form-B2qudx_q.cjs → form-DeO5XX3b.cjs} +0 -0
  376. /package/dist/{hashContent-a8uVr3xs.js → hashContent-BU6jl5ih.js} +0 -0
  377. /package/dist/{hashContent-ejkBgDnN.cjs → hashContent-Bobsobip.cjs} +0 -0
  378. /package/dist/{overlay-stack-CCiTaf_C.js → overlay-stack-DCDS17uj.js} +0 -0
  379. /package/dist/{overlay-stack-CFGiYf34.cjs → overlay-stack-DPIe_aYv.cjs} +0 -0
  380. /package/dist/{rxjs-utils-BXpvHN4-.js → rxjs-utils-BK8VMe3K.js} +0 -0
  381. /package/dist/{rxjs-utils-CaC-tdot.cjs → rxjs-utils-DhOKenkS.cjs} +0 -0
  382. /package/dist/{theme.interface-DESopuZS.cjs → theme.interface-BeW-sz_g.cjs} +0 -0
  383. /package/dist/{theme.interface-C_034TxG.js → theme.interface-v7SkAnDH.js} +0 -0
@@ -1,47 +0,0 @@
1
- # schmancy-code
2
-
3
- > Syntax-highlighted code block with line numbers, copy button, and collapsible display.
4
-
5
- ## Usage
6
- ```html
7
- <schmancy-code language="typescript" .code=${'const x = 42'}></schmancy-code>
8
- ```
9
-
10
- ## Properties
11
- | Property | Type | Default | Description |
12
- |----------|------|---------|-------------|
13
- | code | string | `''` | Code content to highlight |
14
- | language | string | `'javascript'` | Language for syntax highlighting |
15
- | filename | string | `undefined` | Filename shown in header |
16
- | lineNumbers | boolean | `false` | Show line numbers |
17
- | copyButton | boolean | `true` | Show copy-to-clipboard button |
18
- | highlightLines | string | `undefined` | Lines to highlight (e.g., `'1-3,5,7-9'`) |
19
- | maxHeight | string | `undefined` | Max height before scrolling |
20
-
21
- ## Supported Languages
22
- javascript, typescript, html, xml, markdown, bash
23
-
24
- ## Examples
25
- ```html
26
- <!-- TypeScript with line numbers and highlighted lines -->
27
- <schmancy-code
28
- language="typescript"
29
- lineNumbers
30
- highlightLines="2-3"
31
- .code=${`import { html } from 'lit'
32
- const greeting = 'Hello'
33
- console.log(greeting)`}>
34
- </schmancy-code>
35
-
36
- <!-- Bash with filename -->
37
- <schmancy-code language="bash" filename="install.sh"
38
- .code=${'npm install @mhmo91/schmancy'}>
39
- </schmancy-code>
40
-
41
- <!-- With max height -->
42
- <schmancy-code language="javascript" maxHeight="300px"
43
- .code=${longCodeString}>
44
- </schmancy-code>
45
- ```
46
-
47
- Renders inside a collapsible `schmancy-details` with a macOS-style header (colored dots + language label). Uses highlight.js with schmancy color tokens.
@@ -1,102 +0,0 @@
1
- # Schmancy Mailbox
2
-
3
- > Full email composition + campaign management system. Orchestrates recipients, templates, editor, attachments, and preview.
4
-
5
- ## Components
6
-
7
- | Tag | Purpose |
8
- |-----|---------|
9
- | `schmancy-mailbox` | Top-level orchestrator |
10
- | `schmancy-email-editor` | Subject + body composition |
11
- | `schmancy-email-viewer` | HTML/plaintext preview |
12
- | `schmancy-email-recipients` | Recipient list with import/CSV |
13
- | `schmancy-email-layout-selector` | Layout template picker |
14
- | `schmancy-email-template-picker` | Email template browser |
15
-
16
- ## Usage
17
- ```html
18
- <schmancy-mailbox
19
- .config=${{
20
- sendEndpoint: '/api/emails/send',
21
- uploadEndpoint: '/api/uploads',
22
- authenticateRequest: (req) => ({ ...req, headers: { Authorization: `Bearer ${token}` } })
23
- }}
24
- .templates=${myTemplates}
25
- .importSources=${[
26
- { id: 'ticketholders', label: 'Ticket holders', icon: 'confirmation_number', handler: loadTicketHolders },
27
- { id: 'waitlist', label: 'Waitlist', icon: 'hourglass_empty', handler: loadWaitlist },
28
- ]}
29
- ></schmancy-mailbox>
30
- ```
31
-
32
- ## schmancy-mailbox Properties
33
- | Property | Type | Default | Description |
34
- |----------|------|---------|-------------|
35
- | `config` | `EmailComposeConfig` | `{}` | Endpoints, auth, upload handlers |
36
- | `templates` | `EmailTemplate[]` | `[]` | Available email templates |
37
- | `importSources` | `ImportSource[]` | `[]` | Import buttons shown in recipients panel |
38
- | `disabled` | boolean | `false` | Disable all interactions |
39
- | `recipientsTitle` | string | `'Recipients'` | Recipients panel heading |
40
- | `recipientsEmptyTitle` | string | `'No recipients yet'` | Empty state title |
41
- | `recipientsEmptyMessage` | string | `'Import from sources or upload a CSV'` | Empty state body |
42
- | `enableCsvImport` | boolean | `true` | Allow CSV file import |
43
- | `enableDragDrop` | boolean | `true` | Accept dropped CSV files |
44
-
45
- ## Key Types
46
- ```typescript
47
- interface EmailTemplate { id, name, subject, body, category?, thumbnail? }
48
-
49
- interface EmailComposeConfig {
50
- sendEndpoint?: string
51
- templatesEndpoint?: string
52
- uploadEndpoint?: string
53
- authenticateRequest?: (req: RequestInit) => RequestInit
54
- uploadHandler?: (file: File) => Promise<string>
55
- imageUploadHandler?: (file: File) => Promise<string>
56
- }
57
-
58
- interface SendEmailRequest {
59
- recipients: string[]
60
- subject: string
61
- body: string
62
- attachments: EmailAttachment[]
63
- templateId?: string | null
64
- }
65
-
66
- interface ImportSource {
67
- id: string
68
- label: string
69
- icon: string // Material icon name
70
- handler: () => void // Populates recipients via events
71
- }
72
- ```
73
-
74
- ## Events
75
- | Event | Detail | Where |
76
- |-------|--------|-------|
77
- | `emails-imported` | `{ emails, source }` | Recipients |
78
- | `recipient-removed` | `{ email }` | Recipients |
79
- | `recipients-cleared` | `{}` | Recipients |
80
- | `selection-changed` | `{ selectedEmails }` | Recipients |
81
- | `compose-changed` | `{ subject, body, templateId, attachments }` | Editor |
82
- | `send-email` | `{ request: SendEmailRequest }` | Mailbox — consumer POSTs to backend |
83
- | `send-error` | `{ error }` | Mailbox |
84
-
85
- ## Recipients Flow
86
- 1. User clicks an `ImportSource` button (or drops a CSV).
87
- 2. CSV is parsed → `validEmails`, `invalidEmails`, `duplicates` reported.
88
- 3. `emails-imported` event fires; mailbox merges into selected recipients.
89
- 4. User edits subject/body via email-editor; changes bubble as `compose-changed`.
90
- 5. On send, `send-email` fires with the full `SendEmailRequest` — parent handles network.
91
-
92
- ## Minimal Integration
93
- ```typescript
94
- <schmancy-mailbox
95
- .config=${config}
96
- .templates=${templates}
97
- @send-email=${async (e: CustomEvent<{ request: SendEmailRequest }>) => {
98
- const result = await api.sendCampaign(e.detail.request)
99
- if (!result.success) this.dispatchError(result.message)
100
- }}
101
- ></schmancy-mailbox>
102
- ```
@@ -1,47 +0,0 @@
1
- # schmancy-code
2
-
3
- > Syntax-highlighted code block with line numbers, copy button, and collapsible display.
4
-
5
- ## Usage
6
- ```html
7
- <schmancy-code language="typescript" .code=${'const x = 42'}></schmancy-code>
8
- ```
9
-
10
- ## Properties
11
- | Property | Type | Default | Description |
12
- |----------|------|---------|-------------|
13
- | code | string | `''` | Code content to highlight |
14
- | language | string | `'javascript'` | Language for syntax highlighting |
15
- | filename | string | `undefined` | Filename shown in header |
16
- | lineNumbers | boolean | `false` | Show line numbers |
17
- | copyButton | boolean | `true` | Show copy-to-clipboard button |
18
- | highlightLines | string | `undefined` | Lines to highlight (e.g., `'1-3,5,7-9'`) |
19
- | maxHeight | string | `undefined` | Max height before scrolling |
20
-
21
- ## Supported Languages
22
- javascript, typescript, html, xml, markdown, bash
23
-
24
- ## Examples
25
- ```html
26
- <!-- TypeScript with line numbers and highlighted lines -->
27
- <schmancy-code
28
- language="typescript"
29
- lineNumbers
30
- highlightLines="2-3"
31
- .code=${`import { html } from 'lit'
32
- const greeting = 'Hello'
33
- console.log(greeting)`}>
34
- </schmancy-code>
35
-
36
- <!-- Bash with filename -->
37
- <schmancy-code language="bash" filename="install.sh"
38
- .code=${'npm install @mhmo91/schmancy'}>
39
- </schmancy-code>
40
-
41
- <!-- With max height -->
42
- <schmancy-code language="javascript" maxHeight="300px"
43
- .code=${longCodeString}>
44
- </schmancy-code>
45
- ```
46
-
47
- Renders inside a collapsible `schmancy-details` with a macOS-style header (colored dots + language label). Uses highlight.js with schmancy color tokens.
@@ -1,102 +0,0 @@
1
- # Schmancy Mailbox
2
-
3
- > Full email composition + campaign management system. Orchestrates recipients, templates, editor, attachments, and preview.
4
-
5
- ## Components
6
-
7
- | Tag | Purpose |
8
- |-----|---------|
9
- | `schmancy-mailbox` | Top-level orchestrator |
10
- | `schmancy-email-editor` | Subject + body composition |
11
- | `schmancy-email-viewer` | HTML/plaintext preview |
12
- | `schmancy-email-recipients` | Recipient list with import/CSV |
13
- | `schmancy-email-layout-selector` | Layout template picker |
14
- | `schmancy-email-template-picker` | Email template browser |
15
-
16
- ## Usage
17
- ```html
18
- <schmancy-mailbox
19
- .config=${{
20
- sendEndpoint: '/api/emails/send',
21
- uploadEndpoint: '/api/uploads',
22
- authenticateRequest: (req) => ({ ...req, headers: { Authorization: `Bearer ${token}` } })
23
- }}
24
- .templates=${myTemplates}
25
- .importSources=${[
26
- { id: 'ticketholders', label: 'Ticket holders', icon: 'confirmation_number', handler: loadTicketHolders },
27
- { id: 'waitlist', label: 'Waitlist', icon: 'hourglass_empty', handler: loadWaitlist },
28
- ]}
29
- ></schmancy-mailbox>
30
- ```
31
-
32
- ## schmancy-mailbox Properties
33
- | Property | Type | Default | Description |
34
- |----------|------|---------|-------------|
35
- | `config` | `EmailComposeConfig` | `{}` | Endpoints, auth, upload handlers |
36
- | `templates` | `EmailTemplate[]` | `[]` | Available email templates |
37
- | `importSources` | `ImportSource[]` | `[]` | Import buttons shown in recipients panel |
38
- | `disabled` | boolean | `false` | Disable all interactions |
39
- | `recipientsTitle` | string | `'Recipients'` | Recipients panel heading |
40
- | `recipientsEmptyTitle` | string | `'No recipients yet'` | Empty state title |
41
- | `recipientsEmptyMessage` | string | `'Import from sources or upload a CSV'` | Empty state body |
42
- | `enableCsvImport` | boolean | `true` | Allow CSV file import |
43
- | `enableDragDrop` | boolean | `true` | Accept dropped CSV files |
44
-
45
- ## Key Types
46
- ```typescript
47
- interface EmailTemplate { id, name, subject, body, category?, thumbnail? }
48
-
49
- interface EmailComposeConfig {
50
- sendEndpoint?: string
51
- templatesEndpoint?: string
52
- uploadEndpoint?: string
53
- authenticateRequest?: (req: RequestInit) => RequestInit
54
- uploadHandler?: (file: File) => Promise<string>
55
- imageUploadHandler?: (file: File) => Promise<string>
56
- }
57
-
58
- interface SendEmailRequest {
59
- recipients: string[]
60
- subject: string
61
- body: string
62
- attachments: EmailAttachment[]
63
- templateId?: string | null
64
- }
65
-
66
- interface ImportSource {
67
- id: string
68
- label: string
69
- icon: string // Material icon name
70
- handler: () => void // Populates recipients via events
71
- }
72
- ```
73
-
74
- ## Events
75
- | Event | Detail | Where |
76
- |-------|--------|-------|
77
- | `emails-imported` | `{ emails, source }` | Recipients |
78
- | `recipient-removed` | `{ email }` | Recipients |
79
- | `recipients-cleared` | `{}` | Recipients |
80
- | `selection-changed` | `{ selectedEmails }` | Recipients |
81
- | `compose-changed` | `{ subject, body, templateId, attachments }` | Editor |
82
- | `send-email` | `{ request: SendEmailRequest }` | Mailbox — consumer POSTs to backend |
83
- | `send-error` | `{ error }` | Mailbox |
84
-
85
- ## Recipients Flow
86
- 1. User clicks an `ImportSource` button (or drops a CSV).
87
- 2. CSV is parsed → `validEmails`, `invalidEmails`, `duplicates` reported.
88
- 3. `emails-imported` event fires; mailbox merges into selected recipients.
89
- 4. User edits subject/body via email-editor; changes bubble as `compose-changed`.
90
- 5. On send, `send-email` fires with the full `SendEmailRequest` — parent handles network.
91
-
92
- ## Minimal Integration
93
- ```typescript
94
- <schmancy-mailbox
95
- .config=${config}
96
- .templates=${templates}
97
- @send-email=${async (e: CustomEvent<{ request: SendEmailRequest }>) => {
98
- const result = await api.sendCampaign(e.detail.request)
99
- if (!result.success) this.dispatchError(result.message)
100
- }}
101
- ></schmancy-mailbox>
102
- ```
@@ -1,345 +0,0 @@
1
- import { SchmancyElement } from '@mixins/index'
2
- import hljs from 'highlight.js/lib/core'
3
- import bash from 'highlight.js/lib/languages/bash'
4
- import javascript from 'highlight.js/lib/languages/javascript'
5
- import markdown from 'highlight.js/lib/languages/markdown'
6
- import typescript from 'highlight.js/lib/languages/typescript'
7
- import xml from 'highlight.js/lib/languages/xml'
8
- import { css, html } from 'lit'
9
- import { customElement, property, state } from 'lit/decorators.js'
10
- import { unsafeHTML } from 'lit/directives/unsafe-html.js'
11
-
12
- // Register only the languages we need
13
- hljs.registerLanguage('javascript', javascript)
14
- hljs.registerLanguage('typescript', typescript)
15
- hljs.registerLanguage('html', xml)
16
- hljs.registerLanguage('xml', xml)
17
- hljs.registerLanguage('markdown', markdown)
18
- hljs.registerLanguage('bash', bash)
19
-
20
- /**
21
- * @element schmancy-code
22
- * Code highlighting component using highlight.js with schmancy theming support
23
- */
24
- @customElement('schmancy-code')
25
- export class SchmancyCode extends SchmancyElement {
26
- static styles = [css`
27
- :host {
28
- display: block;
29
- width: 100%;
30
- overflow: hidden;
31
- }
32
-
33
- /* Code block styling using schmancy color system */
34
- .hljs {
35
- display: block;
36
- overflow-x: auto;
37
- padding: 0.5em;
38
- color: var(--md-sys-color-on-surface-variant);
39
- background: var(--md-sys-color-surface-container-lowest);
40
- font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New', monospace;
41
- }
42
-
43
- /* Comments and documentation */
44
- .hljs-comment,
45
- .hljs-quote {
46
- color: var(--md-sys-color-outline);
47
- font-style: italic;
48
- }
49
-
50
- /* Keywords, doctags, formulas */
51
- .hljs-doctag,
52
- .hljs-keyword,
53
- .hljs-formula {
54
- color: var(--md-sys-color-primary);
55
- }
56
-
57
- /* Tags, sections, names, deletions */
58
- .hljs-section,
59
- .hljs-name,
60
- .hljs-selector-tag,
61
- .hljs-deletion,
62
- .hljs-subst {
63
- color: var(--md-sys-color-error);
64
- }
65
-
66
- /* Literals */
67
- .hljs-literal {
68
- color: var(--md-sys-color-tertiary);
69
- }
70
-
71
- /* Strings, regex, additions */
72
- .hljs-string,
73
- .hljs-regexp,
74
- .hljs-addition,
75
- .hljs-attribute,
76
- .hljs-meta-string {
77
- color: var(--md-sys-color-secondary);
78
- }
79
-
80
- /* Built-ins and class titles */
81
- .hljs-built_in,
82
- .hljs-class .hljs-title {
83
- color: var(--md-sys-color-tertiary);
84
- }
85
-
86
- /* Variables, attributes, types */
87
- .hljs-attr,
88
- .hljs-variable,
89
- .hljs-template-variable,
90
- .hljs-type,
91
- .hljs-selector-class,
92
- .hljs-selector-attr,
93
- .hljs-selector-pseudo,
94
- .hljs-number {
95
- color: var(--md-sys-color-on-surface);
96
- }
97
-
98
- /* Symbols, bullets, links, meta */
99
- .hljs-symbol,
100
- .hljs-bullet,
101
- .hljs-link,
102
- .hljs-meta,
103
- .hljs-selector-id,
104
- .hljs-title {
105
- color: var(--md-sys-color-secondary);
106
- }
107
-
108
- .hljs-emphasis {
109
- font-style: italic;
110
- }
111
-
112
- .hljs-strong {
113
- font-weight: bold;
114
- }
115
-
116
- .hljs-link {
117
- text-decoration: underline;
118
- }
119
-
120
- /* Line features styling */
121
- .code-with-lines {
122
- background: transparent;
123
- padding: 0;
124
- }
125
-
126
- .code-line {
127
- display: block;
128
- padding-left: 0;
129
- transition: background-color 0.2s ease;
130
- }
131
-
132
- .code-line.highlighted {
133
- background-color: var(--md-sys-color-primary-container);
134
- opacity: 0.2;
135
- }
136
-
137
- .line-number {
138
- display: inline-block;
139
- width: 3rem;
140
- padding-right: 1rem;
141
- text-align: right;
142
- color: var(--md-sys-color-outline);
143
- user-select: none;
144
- font-size: inherit;
145
- }
146
- `];
147
- /**
148
- * Programming language for syntax highlighting
149
- */
150
- @property({ type: String })
151
- language: string = 'javascript'
152
-
153
- /**
154
- * Code content to highlight
155
- */
156
- @property({ type: String })
157
- code: string = ''
158
-
159
- /**
160
- * Optional filename or title to display in header
161
- */
162
- @property({ type: String })
163
- filename?: string
164
-
165
- /**
166
- * Show line numbers
167
- */
168
- @property({ type: Boolean })
169
- lineNumbers: boolean = false
170
-
171
- /**
172
- * Show copy button
173
- */
174
- @property({ type: Boolean })
175
- copyButton: boolean = true
176
-
177
- /**
178
- * Highlighted line numbers (comma-separated or ranges like "1-3,5,7-9")
179
- */
180
- @property({ type: String })
181
- highlightLines?: string
182
-
183
- /**
184
- * Maximum height before scrolling
185
- */
186
- @property({ type: String })
187
- maxHeight?: string
188
-
189
- @state()
190
- private copied: boolean = false
191
-
192
- private get highlightedCode(): string {
193
- if (!this.code) return ''
194
-
195
- let highlightedHtml = ''
196
-
197
- try {
198
- // Use highlight.js to get highlighted code
199
- const result = hljs.highlight(this.code.trim(), { language: this.language })
200
- highlightedHtml = result.value
201
- } catch {
202
- // Fallback to auto-detection if language is not supported
203
- try {
204
- const result = hljs.highlightAuto(this.code.trim())
205
- highlightedHtml = result.value
206
- } catch {
207
- // Final fallback to escaped plain text
208
- highlightedHtml = this.escapeHtml(this.code.trim())
209
- }
210
- }
211
-
212
- // Process for line numbers and highlighting if needed
213
- if (this.lineNumbers || this.highlightLines) {
214
- return this.addLineFeatures(highlightedHtml)
215
- }
216
-
217
- return highlightedHtml
218
- }
219
-
220
- private escapeHtml(text: string): string {
221
- const div = document.createElement('div')
222
- div.textContent = text
223
- return div.innerHTML
224
- }
225
-
226
- private getHighlightedLines(): Set<number> {
227
- const lines = new Set<number>()
228
- if (!this.highlightLines) return lines
229
-
230
- const parts = this.highlightLines.split(',')
231
- for (const part of parts) {
232
- const trimmed = part.trim()
233
- if (trimmed.includes('-')) {
234
- const [start, end] = trimmed.split('-').map(n => parseInt(n.trim()))
235
- if (!isNaN(start) && !isNaN(end)) {
236
- for (let i = start; i <= end; i++) {
237
- lines.add(i)
238
- }
239
- }
240
- } else {
241
- const lineNum = parseInt(trimmed)
242
- if (!isNaN(lineNum)) {
243
- lines.add(lineNum)
244
- }
245
- }
246
- }
247
- return lines
248
- }
249
-
250
- private addLineFeatures(highlightedHtml: string): string {
251
- const lines = highlightedHtml.split('\n')
252
- const highlightedLines = this.getHighlightedLines()
253
-
254
- return lines
255
- .map((line, index) => {
256
- const lineNumber = index + 1
257
- const isHighlighted = highlightedLines.has(lineNumber)
258
- const lineClass = isHighlighted ? 'code-line highlighted' : 'code-line'
259
-
260
- let content = ''
261
- if (this.lineNumbers) {
262
- content += `<span class="line-number">${lineNumber}</span>`
263
- }
264
- content += line
265
-
266
- return `<div class="${lineClass}">${content}</div>`
267
- })
268
- .join('')
269
- }
270
-
271
- private async copyCode() {
272
- try {
273
- await navigator.clipboard.writeText(this.code)
274
- this.copied = true
275
- setTimeout(() => {
276
- this.copied = false
277
- }, 2000)
278
- } catch (err) {
279
- console.error('Failed to copy code:', err)
280
- }
281
- }
282
-
283
- private getLanguageLabel(): string {
284
- const languageMap: Record<string, string> = {
285
- javascript: 'JavaScript',
286
- typescript: 'TypeScript',
287
- html: 'HTML',
288
- markdown: 'Markdown',
289
- bash: 'Bash',
290
- }
291
-
292
- if (this.filename) {
293
- return this.filename
294
- }
295
-
296
- return languageMap[this.language.toLowerCase()] || this.language.toUpperCase()
297
- }
298
-
299
- render() {
300
- const codeClass = this.lineNumbers || this.highlightLines ? 'code-with-lines' : 'hljs'
301
-
302
- return html`
303
- <schmancy-details class="bg-surface-default">
304
- <section slot="summary">
305
- <!-- Header -->
306
- <div class="flex items-center justify-between"
307
- >
308
- <div class="flex items-center gap-2">
309
- <div class="flex gap-1.5">
310
- <div class="w-3 h-3 rounded-full opacity-60" style="background-color: var(--md-sys-color-error);"></div>
311
- <div class="w-3 h-3 rounded-full opacity-60" style="background-color: var(--md-sys-color-tertiary);"></div>
312
- <div class="w-3 h-3 rounded-full opacity-60" style="background-color: var(--md-sys-color-secondary);"></div>
313
- </div>
314
- <span class="text-xs font-medium opacity-70 ml-2" style="color: var(--md-sys-color-on-surface-variant);">
315
- ${this.getLanguageLabel()}
316
- </span>
317
- </div>
318
- ${this.copyButton
319
- ? html`
320
- <schmancy-button
321
- .variant="${this.copied ? 'filled tonal' : 'text'}"
322
- @click=${this.copyCode}
323
- class="transition-all"
324
- >
325
- <schmancy-icon > ${this.copied ? 'check' : 'content_copy'} </schmancy-icon>
326
- <span class="ml-1">${this.copied ? 'Copied!' : 'Copy'}</span>
327
- </schmancy-button>
328
- `
329
- : ''}
330
- </div>
331
- </section>
332
- <!-- Code -->
333
- <div class="overflow-auto" style="${this.maxHeight ? `max-height: ${this.maxHeight}` : ''}">
334
- <pre class="m-0"><code class="${codeClass}">${unsafeHTML(this.highlightedCode)}</code></pre>
335
- </div>
336
- </schmancy-details>
337
- `
338
- }
339
- }
340
-
341
- declare global {
342
- interface HTMLElementTagNameMap {
343
- 'schmancy-code': SchmancyCode
344
- }
345
- }