@sondor-technology/sondor-components 1.0.9 → 1.0.10

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 (431) hide show
  1. package/dist/components/accordion/accordion.constants.d.ts +5 -0
  2. package/dist/components/accordion/accordion.constants.d.ts.map +1 -0
  3. package/dist/components/accordion/accordion.constants.js +3 -0
  4. package/dist/components/accordion/accordion.constants.js.map +1 -0
  5. package/dist/components/accordion/accordion.d.ts +29 -0
  6. package/dist/components/accordion/accordion.d.ts.map +1 -0
  7. package/dist/components/accordion/accordion.js +226 -0
  8. package/dist/components/accordion/accordion.js.map +1 -0
  9. package/dist/components/alert/alert.constants.d.ts +2 -0
  10. package/dist/components/alert/alert.constants.d.ts.map +1 -1
  11. package/dist/components/alert/alert.d.ts +50 -2
  12. package/dist/components/alert/alert.d.ts.map +1 -1
  13. package/dist/components/alert/alert.js +285 -16
  14. package/dist/components/alert/alert.js.map +1 -1
  15. package/dist/components/avatar/avatar.d.ts +20 -0
  16. package/dist/components/avatar/avatar.d.ts.map +1 -0
  17. package/dist/components/avatar/avatar.js +100 -0
  18. package/dist/components/avatar/avatar.js.map +1 -0
  19. package/dist/components/back-to-top/back-to-top.d.ts +29 -0
  20. package/dist/components/back-to-top/back-to-top.d.ts.map +1 -0
  21. package/dist/components/back-to-top/back-to-top.js +149 -0
  22. package/dist/components/back-to-top/back-to-top.js.map +1 -0
  23. package/dist/components/bar-chart/bar-chart.d.ts +42 -0
  24. package/dist/components/bar-chart/bar-chart.d.ts.map +1 -0
  25. package/dist/components/bar-chart/bar-chart.js +298 -0
  26. package/dist/components/bar-chart/bar-chart.js.map +1 -0
  27. package/dist/components/breadcrumb/breadcrumb.js +2 -2
  28. package/dist/components/button/button.d.ts +1 -0
  29. package/dist/components/button/button.d.ts.map +1 -1
  30. package/dist/components/button/button.js +8 -8
  31. package/dist/components/button/button.js.map +1 -1
  32. package/dist/components/button-group/button-group.js +4 -4
  33. package/dist/components/calendar/calendar.d.ts.map +1 -1
  34. package/dist/components/calendar/calendar.js +11 -9
  35. package/dist/components/calendar/calendar.js.map +1 -1
  36. package/dist/components/chart/chart-base.d.ts +59 -0
  37. package/dist/components/chart/chart-base.d.ts.map +1 -0
  38. package/dist/components/chart/chart-base.js +261 -0
  39. package/dist/components/chart/chart-base.js.map +1 -0
  40. package/dist/components/chart/chart.utils.d.ts +27 -0
  41. package/dist/components/chart/chart.utils.d.ts.map +1 -0
  42. package/dist/components/chart/chart.utils.js +117 -0
  43. package/dist/components/chart/chart.utils.js.map +1 -0
  44. package/dist/components/code-block/code-block.d.ts +5 -0
  45. package/dist/components/code-block/code-block.d.ts.map +1 -1
  46. package/dist/components/code-block/code-block.js +34 -24
  47. package/dist/components/code-block/code-block.js.map +1 -1
  48. package/dist/components/consent/consent.d.ts +63 -0
  49. package/dist/components/consent/consent.d.ts.map +1 -0
  50. package/dist/components/consent/consent.js +327 -0
  51. package/dist/components/consent/consent.js.map +1 -0
  52. package/dist/components/consent/consent.utils.d.ts +36 -0
  53. package/dist/components/consent/consent.utils.d.ts.map +1 -0
  54. package/dist/components/consent/consent.utils.js +82 -0
  55. package/dist/components/consent/consent.utils.js.map +1 -0
  56. package/dist/components/contact/contact.d.ts +22 -0
  57. package/dist/components/contact/contact.d.ts.map +1 -0
  58. package/dist/components/contact/contact.js +83 -0
  59. package/dist/components/contact/contact.js.map +1 -0
  60. package/dist/components/container/container.d.ts +20 -0
  61. package/dist/components/container/container.d.ts.map +1 -0
  62. package/dist/components/container/container.js +68 -0
  63. package/dist/components/container/container.js.map +1 -0
  64. package/dist/components/content-card/content-card.js +4 -4
  65. package/dist/components/context-menu/context-menu.d.ts +89 -0
  66. package/dist/components/context-menu/context-menu.d.ts.map +1 -0
  67. package/dist/components/context-menu/context-menu.js +414 -0
  68. package/dist/components/context-menu/context-menu.js.map +1 -0
  69. package/dist/components/cron-builder/cron-builder.d.ts.map +1 -1
  70. package/dist/components/cron-builder/cron-builder.js +13 -11
  71. package/dist/components/cron-builder/cron-builder.js.map +1 -1
  72. package/dist/components/cta/cta.d.ts +20 -0
  73. package/dist/components/cta/cta.d.ts.map +1 -0
  74. package/dist/components/cta/cta.js +64 -0
  75. package/dist/components/cta/cta.js.map +1 -0
  76. package/dist/components/drawer/drawer.js +6 -6
  77. package/dist/components/faq/faq-item.d.ts +22 -0
  78. package/dist/components/faq/faq-item.d.ts.map +1 -0
  79. package/dist/components/faq/faq-item.js +117 -0
  80. package/dist/components/faq/faq-item.js.map +1 -0
  81. package/dist/components/faq/faq.d.ts +18 -0
  82. package/dist/components/faq/faq.d.ts.map +1 -0
  83. package/dist/components/faq/faq.js +38 -0
  84. package/dist/components/faq/faq.js.map +1 -0
  85. package/dist/components/feature-grid/feature-grid.d.ts +22 -0
  86. package/dist/components/feature-grid/feature-grid.d.ts.map +1 -0
  87. package/dist/components/feature-grid/feature-grid.js +55 -0
  88. package/dist/components/feature-grid/feature-grid.js.map +1 -0
  89. package/dist/components/feature-grid/feature.d.ts +18 -0
  90. package/dist/components/feature-grid/feature.d.ts.map +1 -0
  91. package/dist/components/feature-grid/feature.js +91 -0
  92. package/dist/components/feature-grid/feature.js.map +1 -0
  93. package/dist/components/field/field.js +2 -2
  94. package/dist/components/footer/footer.js +4 -4
  95. package/dist/components/form/form-reset.d.ts +7 -0
  96. package/dist/components/form/form-reset.d.ts.map +1 -0
  97. package/dist/components/form/form-reset.js +47 -0
  98. package/dist/components/form/form-reset.js.map +1 -0
  99. package/dist/components/form/form.d.ts +5 -0
  100. package/dist/components/form/form.d.ts.map +1 -1
  101. package/dist/components/form/form.js +17 -3
  102. package/dist/components/form/form.js.map +1 -1
  103. package/dist/components/grid/grid.d.ts +5 -0
  104. package/dist/components/grid/grid.d.ts.map +1 -1
  105. package/dist/components/grid/grid.js +86 -4
  106. package/dist/components/grid/grid.js.map +1 -1
  107. package/dist/components/heat-map/heat-map.d.ts +39 -0
  108. package/dist/components/heat-map/heat-map.d.ts.map +1 -0
  109. package/dist/components/heat-map/heat-map.js +306 -0
  110. package/dist/components/heat-map/heat-map.js.map +1 -0
  111. package/dist/components/hero/hero.d.ts +26 -0
  112. package/dist/components/hero/hero.d.ts.map +1 -0
  113. package/dist/components/hero/hero.js +132 -0
  114. package/dist/components/hero/hero.js.map +1 -0
  115. package/dist/components/icon/icon-paths.d.ts +84 -0
  116. package/dist/components/icon/icon-paths.d.ts.map +1 -1
  117. package/dist/components/icon/icon-paths.js +89 -0
  118. package/dist/components/icon/icon-paths.js.map +1 -1
  119. package/dist/components/icon/icon.d.ts +2 -0
  120. package/dist/components/icon/icon.d.ts.map +1 -1
  121. package/dist/components/icon/icon.js +10 -1
  122. package/dist/components/icon/icon.js.map +1 -1
  123. package/dist/components/image/image.d.ts +31 -0
  124. package/dist/components/image/image.d.ts.map +1 -0
  125. package/dist/components/image/image.js +179 -0
  126. package/dist/components/image/image.js.map +1 -0
  127. package/dist/components/input/input.js +4 -4
  128. package/dist/components/lazy/lazy.d.ts +34 -0
  129. package/dist/components/lazy/lazy.d.ts.map +1 -0
  130. package/dist/components/lazy/lazy.js +104 -0
  131. package/dist/components/lazy/lazy.js.map +1 -0
  132. package/dist/components/line-chart/line-chart.d.ts +37 -0
  133. package/dist/components/line-chart/line-chart.d.ts.map +1 -0
  134. package/dist/components/line-chart/line-chart.js +271 -0
  135. package/dist/components/line-chart/line-chart.js.map +1 -0
  136. package/dist/components/list/list-item.d.ts +45 -0
  137. package/dist/components/list/list-item.d.ts.map +1 -0
  138. package/dist/components/list/list-item.js +263 -0
  139. package/dist/components/list/list-item.js.map +1 -0
  140. package/dist/components/list/list.d.ts +50 -0
  141. package/dist/components/list/list.d.ts.map +1 -0
  142. package/dist/components/list/list.js +161 -0
  143. package/dist/components/list/list.js.map +1 -0
  144. package/dist/components/logo-cloud/logo-cloud.d.ts +19 -0
  145. package/dist/components/logo-cloud/logo-cloud.d.ts.map +1 -0
  146. package/dist/components/logo-cloud/logo-cloud.js +66 -0
  147. package/dist/components/logo-cloud/logo-cloud.js.map +1 -0
  148. package/dist/components/modal/modal.d.ts +12 -0
  149. package/dist/components/modal/modal.d.ts.map +1 -1
  150. package/dist/components/modal/modal.js +40 -11
  151. package/dist/components/modal/modal.js.map +1 -1
  152. package/dist/components/page-layout/page-layout.js +8 -8
  153. package/dist/components/pagination/pagination.d.ts +15 -0
  154. package/dist/components/pagination/pagination.d.ts.map +1 -0
  155. package/dist/components/pagination/pagination.js +126 -0
  156. package/dist/components/pagination/pagination.js.map +1 -0
  157. package/dist/components/pagination/pagination.utils.d.ts +3 -0
  158. package/dist/components/pagination/pagination.utils.d.ts.map +1 -0
  159. package/dist/components/pagination/pagination.utils.js +19 -0
  160. package/dist/components/pagination/pagination.utils.js.map +1 -0
  161. package/dist/components/pie-chart/pie-chart.d.ts +33 -0
  162. package/dist/components/pie-chart/pie-chart.d.ts.map +1 -0
  163. package/dist/components/pie-chart/pie-chart.js +233 -0
  164. package/dist/components/pie-chart/pie-chart.js.map +1 -0
  165. package/dist/components/pin-input/pin-input.js +4 -4
  166. package/dist/components/popover/popover.d.ts.map +1 -1
  167. package/dist/components/popover/popover.js +1 -3
  168. package/dist/components/popover/popover.js.map +1 -1
  169. package/dist/components/post-list/post-card.d.ts +16 -0
  170. package/dist/components/post-list/post-card.d.ts.map +1 -0
  171. package/dist/components/post-list/post-card.js +22 -0
  172. package/dist/components/post-list/post-card.js.map +1 -0
  173. package/dist/components/post-list/post-list.d.ts +17 -0
  174. package/dist/components/post-list/post-list.d.ts.map +1 -0
  175. package/dist/components/post-list/post-list.js +23 -0
  176. package/dist/components/post-list/post-list.js.map +1 -0
  177. package/dist/components/pricing/pricing-tier.d.ts +23 -0
  178. package/dist/components/pricing/pricing-tier.d.ts.map +1 -0
  179. package/dist/components/pricing/pricing-tier.js +144 -0
  180. package/dist/components/pricing/pricing-tier.js.map +1 -0
  181. package/dist/components/pricing/pricing.d.ts +18 -0
  182. package/dist/components/pricing/pricing.d.ts.map +1 -0
  183. package/dist/components/pricing/pricing.js +38 -0
  184. package/dist/components/pricing/pricing.js.map +1 -0
  185. package/dist/components/progress/progress.d.ts +17 -0
  186. package/dist/components/progress/progress.d.ts.map +1 -0
  187. package/dist/components/progress/progress.js +109 -0
  188. package/dist/components/progress/progress.js.map +1 -0
  189. package/dist/components/project-grid/project-card.d.ts +17 -0
  190. package/dist/components/project-grid/project-card.d.ts.map +1 -0
  191. package/dist/components/project-grid/project-card.js +23 -0
  192. package/dist/components/project-grid/project-card.js.map +1 -0
  193. package/dist/components/project-grid/project-grid.d.ts +17 -0
  194. package/dist/components/project-grid/project-grid.d.ts.map +1 -0
  195. package/dist/components/project-grid/project-grid.js +23 -0
  196. package/dist/components/project-grid/project-grid.js.map +1 -0
  197. package/dist/components/radio/radio.js +1 -1
  198. package/dist/components/reveal/reveal.constants.d.ts +10 -0
  199. package/dist/components/reveal/reveal.constants.d.ts.map +1 -0
  200. package/dist/components/reveal/reveal.constants.js +11 -0
  201. package/dist/components/reveal/reveal.constants.js.map +1 -0
  202. package/dist/components/reveal/reveal.d.ts +64 -0
  203. package/dist/components/reveal/reveal.d.ts.map +1 -0
  204. package/dist/components/reveal/reveal.js +352 -0
  205. package/dist/components/reveal/reveal.js.map +1 -0
  206. package/dist/components/scroll-progress/scroll-progress.d.ts +32 -0
  207. package/dist/components/scroll-progress/scroll-progress.d.ts.map +1 -0
  208. package/dist/components/scroll-progress/scroll-progress.js +120 -0
  209. package/dist/components/scroll-progress/scroll-progress.js.map +1 -0
  210. package/dist/components/section/card-row.d.ts +30 -0
  211. package/dist/components/section/card-row.d.ts.map +1 -0
  212. package/dist/components/section/card-row.js +174 -0
  213. package/dist/components/section/card-row.js.map +1 -0
  214. package/dist/components/section/card.d.ts +27 -0
  215. package/dist/components/section/card.d.ts.map +1 -0
  216. package/dist/components/section/card.js +205 -0
  217. package/dist/components/section/card.js.map +1 -0
  218. package/dist/components/section/row-item.d.ts +22 -0
  219. package/dist/components/section/row-item.d.ts.map +1 -0
  220. package/dist/components/section/row-item.js +53 -0
  221. package/dist/components/section/row-item.js.map +1 -0
  222. package/dist/components/section/section.d.ts +70 -0
  223. package/dist/components/section/section.d.ts.map +1 -0
  224. package/dist/components/section/section.js +240 -0
  225. package/dist/components/section/section.js.map +1 -0
  226. package/dist/components/select/select.js +3 -3
  227. package/dist/components/series-nav/series-nav.d.ts +29 -0
  228. package/dist/components/series-nav/series-nav.d.ts.map +1 -0
  229. package/dist/components/series-nav/series-nav.js +178 -0
  230. package/dist/components/series-nav/series-nav.js.map +1 -0
  231. package/dist/components/site-header/site-header.d.ts +51 -0
  232. package/dist/components/site-header/site-header.d.ts.map +1 -0
  233. package/dist/components/site-header/site-header.js +296 -0
  234. package/dist/components/site-header/site-header.js.map +1 -0
  235. package/dist/components/skeleton/skeleton.js +7 -7
  236. package/dist/components/sparkline/sparkline.d.ts +19 -0
  237. package/dist/components/sparkline/sparkline.d.ts.map +1 -0
  238. package/dist/components/sparkline/sparkline.js +99 -0
  239. package/dist/components/sparkline/sparkline.js.map +1 -0
  240. package/dist/components/spinner/spinner.d.ts +13 -0
  241. package/dist/components/spinner/spinner.d.ts.map +1 -0
  242. package/dist/components/spinner/spinner.js +65 -0
  243. package/dist/components/spinner/spinner.js.map +1 -0
  244. package/dist/components/split/split.d.ts +23 -0
  245. package/dist/components/split/split.d.ts.map +1 -0
  246. package/dist/components/split/split.js +104 -0
  247. package/dist/components/split/split.js.map +1 -0
  248. package/dist/components/stack/stack.d.ts +21 -0
  249. package/dist/components/stack/stack.d.ts.map +1 -0
  250. package/dist/components/stack/stack.js +102 -0
  251. package/dist/components/stack/stack.js.map +1 -0
  252. package/dist/components/stat-card/stat-card.d.ts +35 -0
  253. package/dist/components/stat-card/stat-card.d.ts.map +1 -0
  254. package/dist/components/stat-card/stat-card.js +199 -0
  255. package/dist/components/stat-card/stat-card.js.map +1 -0
  256. package/dist/components/stats/stat.d.ts +16 -0
  257. package/dist/components/stats/stat.d.ts.map +1 -0
  258. package/dist/components/stats/stat.js +51 -0
  259. package/dist/components/stats/stat.js.map +1 -0
  260. package/dist/components/stats/stats.d.ts +19 -0
  261. package/dist/components/stats/stats.d.ts.map +1 -0
  262. package/dist/components/stats/stats.js +45 -0
  263. package/dist/components/stats/stats.js.map +1 -0
  264. package/dist/components/switch/switch.js +2 -2
  265. package/dist/components/table/data-table.d.ts +115 -27
  266. package/dist/components/table/data-table.d.ts.map +1 -1
  267. package/dist/components/table/data-table.js +1012 -411
  268. package/dist/components/table/data-table.js.map +1 -1
  269. package/dist/components/table/data-table.utils.d.ts +81 -0
  270. package/dist/components/table/data-table.utils.d.ts.map +1 -0
  271. package/dist/components/table/data-table.utils.js +208 -0
  272. package/dist/components/table/data-table.utils.js.map +1 -0
  273. package/dist/components/table/table.d.ts +28 -0
  274. package/dist/components/table/table.d.ts.map +1 -1
  275. package/dist/components/table/table.js +161 -33
  276. package/dist/components/table/table.js.map +1 -1
  277. package/dist/components/team/person.d.ts +19 -0
  278. package/dist/components/team/person.d.ts.map +1 -0
  279. package/dist/components/team/person.js +123 -0
  280. package/dist/components/team/person.js.map +1 -0
  281. package/dist/components/team/team.d.ts +18 -0
  282. package/dist/components/team/team.d.ts.map +1 -0
  283. package/dist/components/team/team.js +36 -0
  284. package/dist/components/team/team.js.map +1 -0
  285. package/dist/components/testimonials/testimonial.d.ts +18 -0
  286. package/dist/components/testimonials/testimonial.d.ts.map +1 -0
  287. package/dist/components/testimonials/testimonial.js +115 -0
  288. package/dist/components/testimonials/testimonial.js.map +1 -0
  289. package/dist/components/testimonials/testimonials.d.ts +18 -0
  290. package/dist/components/testimonials/testimonials.d.ts.map +1 -0
  291. package/dist/components/testimonials/testimonials.js +36 -0
  292. package/dist/components/testimonials/testimonials.js.map +1 -0
  293. package/dist/components/textarea/textarea.js +3 -3
  294. package/dist/components/theme-toggle/theme-toggle.js +1 -1
  295. package/dist/components/time-picker/time-picker.js +3 -3
  296. package/dist/components/timeline/timeline-item.d.ts +18 -0
  297. package/dist/components/timeline/timeline-item.d.ts.map +1 -0
  298. package/dist/components/timeline/timeline-item.js +102 -0
  299. package/dist/components/timeline/timeline-item.js.map +1 -0
  300. package/dist/components/timeline/timeline.d.ts +18 -0
  301. package/dist/components/timeline/timeline.d.ts.map +1 -0
  302. package/dist/components/timeline/timeline.js +30 -0
  303. package/dist/components/timeline/timeline.js.map +1 -0
  304. package/dist/components/toast/toast.d.ts +33 -0
  305. package/dist/components/toast/toast.d.ts.map +1 -0
  306. package/dist/components/toast/toast.js +147 -0
  307. package/dist/components/toast/toast.js.map +1 -0
  308. package/dist/components/toggle-group/toggle-button.d.ts +2 -0
  309. package/dist/components/toggle-group/toggle-button.d.ts.map +1 -1
  310. package/dist/components/toggle-group/toggle-button.js +12 -4
  311. package/dist/components/toggle-group/toggle-button.js.map +1 -1
  312. package/dist/components/toggle-group/toggle-group.js +4 -4
  313. package/dist/components/tooltip/tooltip.js +21 -21
  314. package/dist/components/vertical-nav/vertical-nav-group.js +3 -3
  315. package/dist/components/vertical-nav/vertical-nav-item.js +4 -4
  316. package/dist/components/video-embed/video-embed.d.ts +37 -0
  317. package/dist/components/video-embed/video-embed.d.ts.map +1 -0
  318. package/dist/components/video-embed/video-embed.js +183 -0
  319. package/dist/components/video-embed/video-embed.js.map +1 -0
  320. package/dist/index.d.ts +107 -0
  321. package/dist/index.d.ts.map +1 -0
  322. package/dist/index.js +104 -0
  323. package/dist/index.js.map +1 -0
  324. package/dist/styles/index.css +205 -2
  325. package/dist/styles/reset.d.ts.map +1 -1
  326. package/dist/styles/reset.js +5 -0
  327. package/dist/styles/reset.js.map +1 -1
  328. package/package.json +210 -7
  329. package/src/components/accordion/accordion.constants.ts +5 -0
  330. package/src/components/accordion/accordion.ts +209 -0
  331. package/src/components/alert/alert.constants.ts +3 -0
  332. package/src/components/alert/alert.ts +284 -17
  333. package/src/components/avatar/avatar.ts +84 -0
  334. package/src/components/back-to-top/back-to-top.ts +140 -0
  335. package/src/components/bar-chart/bar-chart.ts +295 -0
  336. package/src/components/breadcrumb/breadcrumb.ts +2 -2
  337. package/src/components/button/button.ts +9 -8
  338. package/src/components/button-group/button-group.ts +4 -4
  339. package/src/components/calendar/calendar.ts +12 -9
  340. package/src/components/chart/chart-base.ts +275 -0
  341. package/src/components/chart/chart.utils.ts +140 -0
  342. package/src/components/code-block/code-block.ts +35 -24
  343. package/src/components/consent/consent.ts +312 -0
  344. package/src/components/consent/consent.utils.ts +110 -0
  345. package/src/components/contact/contact.ts +83 -0
  346. package/src/components/container/container.ts +60 -0
  347. package/src/components/content-card/content-card.ts +4 -4
  348. package/src/components/context-menu/context-menu.ts +426 -0
  349. package/src/components/cron-builder/cron-builder.ts +21 -18
  350. package/src/components/cta/cta.ts +64 -0
  351. package/src/components/drawer/drawer.ts +6 -6
  352. package/src/components/faq/faq-item.ts +110 -0
  353. package/src/components/faq/faq.ts +40 -0
  354. package/src/components/feature-grid/feature-grid.ts +52 -0
  355. package/src/components/feature-grid/feature.ts +84 -0
  356. package/src/components/field/field.ts +2 -2
  357. package/src/components/footer/footer.ts +4 -4
  358. package/src/components/form/form-reset.ts +45 -0
  359. package/src/components/form/form.ts +17 -3
  360. package/src/components/grid/grid.ts +73 -4
  361. package/src/components/heat-map/heat-map.ts +292 -0
  362. package/src/components/hero/hero.ts +132 -0
  363. package/src/components/icon/icon-paths.ts +92 -1
  364. package/src/components/icon/icon.ts +8 -1
  365. package/src/components/image/image.ts +165 -0
  366. package/src/components/input/input.ts +4 -4
  367. package/src/components/lazy/lazy.ts +94 -0
  368. package/src/components/line-chart/line-chart.ts +271 -0
  369. package/src/components/list/list-item.ts +225 -0
  370. package/src/components/list/list.ts +157 -0
  371. package/src/components/logo-cloud/logo-cloud.ts +65 -0
  372. package/src/components/modal/modal.ts +37 -11
  373. package/src/components/page-layout/page-layout.ts +8 -8
  374. package/src/components/pagination/pagination.ts +120 -0
  375. package/src/components/pagination/pagination.utils.ts +14 -0
  376. package/src/components/pie-chart/pie-chart.ts +230 -0
  377. package/src/components/pin-input/pin-input.ts +4 -4
  378. package/src/components/popover/popover.ts +1 -3
  379. package/src/components/post-list/post-card.ts +18 -0
  380. package/src/components/post-list/post-list.ts +19 -0
  381. package/src/components/pricing/pricing-tier.ts +132 -0
  382. package/src/components/pricing/pricing.ts +39 -0
  383. package/src/components/progress/progress.ts +95 -0
  384. package/src/components/project-grid/project-card.ts +19 -0
  385. package/src/components/project-grid/project-grid.ts +19 -0
  386. package/src/components/radio/radio.ts +1 -1
  387. package/src/components/reveal/reveal.constants.ts +20 -0
  388. package/src/components/reveal/reveal.ts +344 -0
  389. package/src/components/scroll-progress/scroll-progress.ts +119 -0
  390. package/src/components/section/card-row.ts +152 -0
  391. package/src/components/section/card.ts +197 -0
  392. package/src/components/section/row-item.ts +38 -0
  393. package/src/components/section/section.ts +232 -0
  394. package/src/components/select/select.ts +3 -3
  395. package/src/components/series-nav/series-nav.ts +164 -0
  396. package/src/components/site-header/site-header.ts +276 -0
  397. package/src/components/skeleton/skeleton.ts +7 -7
  398. package/src/components/sparkline/sparkline.ts +83 -0
  399. package/src/components/spinner/spinner.ts +55 -0
  400. package/src/components/split/split.ts +106 -0
  401. package/src/components/stack/stack.ts +88 -0
  402. package/src/components/stat-card/stat-card.ts +179 -0
  403. package/src/components/stats/stat.ts +49 -0
  404. package/src/components/stats/stats.ts +47 -0
  405. package/src/components/switch/switch.ts +2 -2
  406. package/src/components/table/data-table.ts +1015 -425
  407. package/src/components/table/data-table.utils.ts +276 -0
  408. package/src/components/table/table.ts +168 -38
  409. package/src/components/team/person.ts +113 -0
  410. package/src/components/team/team.ts +37 -0
  411. package/src/components/testimonials/testimonial.ts +108 -0
  412. package/src/components/testimonials/testimonials.ts +37 -0
  413. package/src/components/textarea/textarea.ts +3 -3
  414. package/src/components/theme-toggle/theme-toggle.ts +1 -1
  415. package/src/components/time-picker/time-picker.ts +3 -3
  416. package/src/components/timeline/timeline-item.ts +100 -0
  417. package/src/components/timeline/timeline.ts +31 -0
  418. package/src/components/toast/toast.ts +153 -0
  419. package/src/components/toggle-group/toggle-button.ts +9 -4
  420. package/src/components/toggle-group/toggle-group.ts +4 -4
  421. package/src/components/tooltip/tooltip.ts +21 -21
  422. package/src/components/vertical-nav/vertical-nav-group.ts +3 -3
  423. package/src/components/vertical-nav/vertical-nav-item.ts +4 -4
  424. package/src/components/video-embed/video-embed.ts +162 -0
  425. package/src/index.ts +108 -0
  426. package/src/styles/globals.css +63 -0
  427. package/src/styles/index.css +3 -1
  428. package/src/styles/prose.css +154 -0
  429. package/src/styles/reset.ts +5 -0
  430. package/src/styles/theme.css +53 -1
  431. package/src/styles/typography.css +1 -0
@@ -0,0 +1,426 @@
1
+ import {LitElement, html, css, nothing} from "lit";
2
+ import {customElement, property, query, state} from "lit/decorators.js";
3
+ import {resetStyles} from "../../styles/reset.js";
4
+ import "../icon/icon.js";
5
+
6
+ export interface MenuItem {
7
+ /** Text shown for the item. Omit for a separator. */
8
+ label?: string;
9
+ /** Identifier returned in `st-menu-select`. Defaults to the label. */
10
+ value?: string;
11
+ icon?: string;
12
+ /** Right-aligned hint such as "Ctrl+C" (display only). */
13
+ shortcut?: string;
14
+ disabled?: boolean;
15
+ /** Styles the item as destructive, e.g. Delete. */
16
+ danger?: boolean;
17
+ /** Turns the item into a checkbox item. Update `items` in response to `st-menu-select`. */
18
+ checked?: boolean;
19
+ /** Keeps the menu open after selecting, e.g. for toggles. */
20
+ keepOpen?: boolean;
21
+ /** Renders a divider line instead of an item. */
22
+ separator?: boolean;
23
+ }
24
+
25
+ export type MenuTrigger = "contextmenu" | "click" | "manual";
26
+
27
+ const VIEWPORT_MARGIN = 8;
28
+
29
+ /**
30
+ * A reusable menu styled like a native right-click menu. It renders in the top layer, so it is
31
+ * never clipped by scrolling containers, flips to stay on screen, and is fully keyboard
32
+ * operable (arrows, Home/End, type-ahead, Enter/Space, Escape).
33
+ *
34
+ * Opening: wrap an element in it (default trigger is right-click, which also covers the
35
+ * keyboard Menu key and Shift+F10), or call `show(x, y, context)` / `showAt(element, context)`
36
+ * with `trigger="manual"`.
37
+ *
38
+ * Events (bubble, composed): `st-menu-open`, `st-menu-close`, and `st-menu-select` with
39
+ * `{ item, value, context }`.
40
+ */
41
+ @customElement("st-context-menu")
42
+ export class StContextMenu extends LitElement {
43
+ @property({type: Array}) items: MenuItem[] = [];
44
+ @property({type: String}) trigger: MenuTrigger = "contextmenu";
45
+ /** Accessible name of the menu. */
46
+ @property({type: String}) label = "Actions";
47
+ @property({type: Boolean, reflect: true}) disabled = false;
48
+
49
+ @state() private _open = false;
50
+ @state() private _active = -1;
51
+
52
+ @query("[popover]") private _menu!: HTMLElement;
53
+
54
+ private _context: unknown;
55
+ private _returnFocus: HTMLElement | null = null;
56
+ private _clicked: HTMLElement | null = null;
57
+ private _typeahead = "";
58
+ private _typeaheadTimer?: number;
59
+
60
+ static styles = [
61
+ resetStyles,
62
+ css`
63
+ :host {
64
+ display: contents;
65
+ }
66
+
67
+ [popover] {
68
+ position: fixed;
69
+ inset: auto;
70
+ margin: 0;
71
+ min-width: 12rem;
72
+ max-width: min(24rem, calc(100vw - 16px));
73
+ max-height: calc(100vh - 16px);
74
+ overflow-y: auto;
75
+ padding: var(--st-spacing-xs);
76
+ border: 1px solid var(--st-color-border);
77
+ border-radius: var(--st-radius-md);
78
+ background: var(--st-color-surface);
79
+ color: var(--st-color-text);
80
+ box-shadow: var(--st-shadow-lg);
81
+ font-size: var(--st-font-size-sm);
82
+ }
83
+
84
+ @media (prefers-reduced-motion: no-preference) {
85
+ [popover]:popover-open {
86
+ animation: st-menu-in 0.1s ease-out;
87
+ }
88
+ @keyframes st-menu-in {
89
+ from {
90
+ opacity: 0;
91
+ transform: scale(0.97);
92
+ }
93
+ }
94
+ }
95
+
96
+ .item {
97
+ display: flex;
98
+ align-items: center;
99
+ gap: var(--st-spacing-sm);
100
+ width: 100%;
101
+ padding: var(--st-spacing-xs) var(--st-spacing-sm);
102
+ border: 0;
103
+ border-radius: var(--st-radius-sm);
104
+ background: none;
105
+ color: inherit;
106
+ font: inherit;
107
+ text-align: left;
108
+ cursor: default;
109
+ }
110
+
111
+ .item:hover:not(:disabled),
112
+ .item:focus-visible {
113
+ outline: none;
114
+ background: var(--st-color-primary-bg);
115
+ color: var(--st-color-primary-text);
116
+ }
117
+
118
+ .item:disabled {
119
+ opacity: 0.5;
120
+ cursor: not-allowed;
121
+ }
122
+
123
+ .item.danger {
124
+ color: var(--st-color-error-text);
125
+ }
126
+
127
+ .item.danger:hover:not(:disabled),
128
+ .item.danger:focus-visible {
129
+ background: var(--st-color-error-bg);
130
+ color: var(--st-color-error-text);
131
+ }
132
+
133
+ .lead {
134
+ display: inline-flex;
135
+ flex-shrink: 0;
136
+ width: 1.25rem;
137
+ justify-content: center;
138
+ }
139
+
140
+ .label {
141
+ flex: 1;
142
+ white-space: nowrap;
143
+ }
144
+
145
+ .shortcut {
146
+ padding-left: var(--st-spacing-lg);
147
+ color: var(--st-color-text-muted);
148
+ font-size: var(--st-font-size-xs);
149
+ }
150
+
151
+ .separator {
152
+ height: 1px;
153
+ margin: var(--st-spacing-xs) calc(var(--st-spacing-xs) * -1);
154
+ background: var(--st-color-border);
155
+ }
156
+ `,
157
+ ];
158
+
159
+ connectedCallback() {
160
+ super.connectedCallback();
161
+ this.addEventListener("contextmenu", this._onContextMenu);
162
+ this.addEventListener("click", this._onTriggerClick);
163
+ }
164
+
165
+ disconnectedCallback() {
166
+ this.removeEventListener("contextmenu", this._onContextMenu);
167
+ this.removeEventListener("click", this._onTriggerClick);
168
+ this._listen(false);
169
+ super.disconnectedCallback();
170
+ }
171
+
172
+ /** True while the menu is showing. */
173
+ get isOpen() {
174
+ return this._open;
175
+ }
176
+
177
+ private _onContextMenu = (e: MouseEvent) => {
178
+ if (this.trigger !== "contextmenu" || this.disabled) return;
179
+ // Let the native menu through on text inputs so users keep copy/paste.
180
+ const target = e.composedPath()[0] as HTMLElement;
181
+ if (target?.closest?.("input, textarea, [contenteditable]")) return;
182
+ e.preventDefault();
183
+ // Some browsers don't focus a button on right-click, so remember what was clicked.
184
+ this._clicked = (target?.closest?.("button, a[href], [tabindex]") as HTMLElement | null) ?? null;
185
+ this.show(e.clientX, e.clientY);
186
+ };
187
+
188
+ private _onTriggerClick = (e: MouseEvent) => {
189
+ if (this.trigger !== "click" || this.disabled || this._menu?.contains(e.target as Node)) return;
190
+ this.showAt(this);
191
+ };
192
+
193
+ /** Opens the menu at viewport coordinates. `context` is echoed back in `st-menu-select`. */
194
+ show(x: number, y: number, context?: unknown) {
195
+ this._show(x, y, context);
196
+ }
197
+
198
+ private _show(x: number, y: number, context?: unknown, flipY?: number) {
199
+ if (!this.items.length || this.disabled) return;
200
+ this._context = context;
201
+ const focused = this._activeElement();
202
+ this._returnFocus = focused && focused !== document.body ? focused : this._clicked;
203
+ this._clicked = null;
204
+ this._open = true;
205
+ this.updateComplete.then(() => {
206
+ const menu = this._menu;
207
+ if (!menu) return;
208
+ if (!menu.matches(":popover-open")) menu.showPopover();
209
+ this._place(x, y, flipY);
210
+ this._listen(true);
211
+ this._focusItem(this._nextEnabled(-1, 1));
212
+ this.dispatchEvent(
213
+ new CustomEvent("st-menu-open", {detail: {context}, bubbles: true, composed: true}),
214
+ );
215
+ });
216
+ }
217
+
218
+ /** Opens the menu below (or above, if there is no room) an element, e.g. a "more" button. */
219
+ showAt(anchor: HTMLElement, context?: unknown) {
220
+ const rect = anchor.getBoundingClientRect();
221
+ // Opens below the anchor, or above it when there is no room.
222
+ this._show(rect.left, rect.bottom + 4, context, rect.top - 4);
223
+ }
224
+
225
+ /** Closes the menu and restores focus to where it was before opening. */
226
+ hide() {
227
+ if (this._menu?.matches(":popover-open")) this._menu.hidePopover();
228
+ else this._afterClose();
229
+ }
230
+
231
+ private _activeElement(): HTMLElement | null {
232
+ let el = document.activeElement as HTMLElement | null;
233
+ while (el?.shadowRoot?.activeElement) el = el.shadowRoot.activeElement as HTMLElement;
234
+ return el;
235
+ }
236
+
237
+ private _place(x: number, y: number, flipY?: number) {
238
+ const menu = this._menu;
239
+ if (!menu) return;
240
+ // Layout size, so the opening scale animation does not skew the measurement.
241
+ const {offsetWidth: width, offsetHeight: height} = menu;
242
+ const maxLeft = window.innerWidth - width - VIEWPORT_MARGIN;
243
+ const maxTop = window.innerHeight - height - VIEWPORT_MARGIN;
244
+ const left = x > maxLeft ? Math.max(VIEWPORT_MARGIN, x - width) : x;
245
+ let top = y;
246
+ if (y > maxTop) top = flipY !== undefined ? flipY - height : y - height;
247
+ top = Math.min(Math.max(VIEWPORT_MARGIN, top), Math.max(VIEWPORT_MARGIN, maxTop));
248
+ menu.style.left = `${Math.max(VIEWPORT_MARGIN, left)}px`;
249
+ menu.style.top = `${top}px`;
250
+ }
251
+
252
+ /**
253
+ * Light dismiss is handled here rather than by popover="auto", because browsers that fire
254
+ * contextmenu on mouse-down (macOS, Linux) would close an auto popover on the mouse-up.
255
+ */
256
+ private _listen(on: boolean) {
257
+ const method = on ? "addEventListener" : "removeEventListener";
258
+ window[method]("resize", this._closeOnLayoutChange);
259
+ window[method]("scroll", this._closeOnLayoutChange, true);
260
+ window[method]("blur", this._dismiss);
261
+ document[method]("pointerdown", this._onOutsidePointer as EventListener, true);
262
+ document[method]("keydown", this._onEscape as EventListener, true);
263
+ }
264
+
265
+ private _dismiss = () => this.hide();
266
+
267
+ private _onOutsidePointer = (e: PointerEvent) => {
268
+ if (!e.composedPath().includes(this._menu)) this.hide();
269
+ };
270
+
271
+ private _onEscape = (e: KeyboardEvent) => {
272
+ if (e.key !== "Escape") return;
273
+ e.stopPropagation();
274
+ this.hide();
275
+ };
276
+
277
+ private _closeOnLayoutChange = (e: Event) => {
278
+ // Scrolling inside the menu itself must not dismiss it.
279
+ if (e.target instanceof Node && this._menu?.contains(e.target)) return;
280
+ this.hide();
281
+ };
282
+
283
+ private _onToggle = (e: Event) => {
284
+ const state = (e as ToggleEvent).newState;
285
+ if (state === "closed") this._afterClose();
286
+ };
287
+
288
+ private _afterClose() {
289
+ if (!this._open) return;
290
+ this._open = false;
291
+ this._active = -1;
292
+ this._listen(false);
293
+ this._returnFocus?.focus?.();
294
+ this._returnFocus = null;
295
+ this.dispatchEvent(
296
+ new CustomEvent("st-menu-close", {detail: {context: this._context}, bubbles: true, composed: true}),
297
+ );
298
+ }
299
+
300
+ private _isFocusable(item: MenuItem) {
301
+ return !item.separator && !item.disabled;
302
+ }
303
+
304
+ private _nextEnabled(from: number, step: 1 | -1): number {
305
+ const n = this.items.length;
306
+ for (let i = 1; i <= n; i++) {
307
+ const index = (((from + step * i) % n) + n) % n;
308
+ if (this._isFocusable(this.items[index])) return index;
309
+ }
310
+ return -1;
311
+ }
312
+
313
+ private _focusItem(index: number) {
314
+ if (index < 0) return;
315
+ this._active = index;
316
+ this.updateComplete.then(() => {
317
+ this.renderRoot.querySelector<HTMLElement>(`[data-index="${index}"]`)?.focus();
318
+ });
319
+ }
320
+
321
+ private _onKeydown(e: KeyboardEvent) {
322
+ const last = this.items.length - 1;
323
+ switch (e.key) {
324
+ case "ArrowDown":
325
+ e.preventDefault();
326
+ this._focusItem(this._nextEnabled(this._active, 1));
327
+ break;
328
+ case "ArrowUp":
329
+ e.preventDefault();
330
+ this._focusItem(this._nextEnabled(this._active < 0 ? 0 : this._active, -1));
331
+ break;
332
+ case "Home":
333
+ e.preventDefault();
334
+ this._focusItem(this._nextEnabled(-1, 1));
335
+ break;
336
+ case "End":
337
+ e.preventDefault();
338
+ this._focusItem(this._nextEnabled(last + 1, -1));
339
+ break;
340
+ case "Tab":
341
+ this.hide();
342
+ break;
343
+ default:
344
+ if (e.key.length === 1 && !e.ctrlKey && !e.metaKey && !e.altKey) this._typeaheadSearch(e.key);
345
+ }
346
+ }
347
+
348
+ private _typeaheadSearch(char: string) {
349
+ window.clearTimeout(this._typeaheadTimer);
350
+ this._typeahead += char.toLowerCase();
351
+ this._typeaheadTimer = window.setTimeout(() => (this._typeahead = ""), 600);
352
+ const start = this._typeahead.length === 1 ? this._active : this._active - 1;
353
+ const n = this.items.length;
354
+ for (let i = 1; i <= n; i++) {
355
+ const index = (((start + i) % n) + n) % n;
356
+ const item = this.items[index];
357
+ if (this._isFocusable(item) && item.label?.toLowerCase().startsWith(this._typeahead)) {
358
+ this._focusItem(index);
359
+ return;
360
+ }
361
+ }
362
+ }
363
+
364
+ private _select(item: MenuItem) {
365
+ if (!this._isFocusable(item)) return;
366
+ this.dispatchEvent(
367
+ new CustomEvent("st-menu-select", {
368
+ detail: {item, value: item.value ?? item.label, context: this._context},
369
+ bubbles: true,
370
+ composed: true,
371
+ }),
372
+ );
373
+ if (!item.keepOpen) this.hide();
374
+ }
375
+
376
+ private _renderItem(item: MenuItem, index: number) {
377
+ if (item.separator) return html`<div class="separator" role="separator"></div>`;
378
+ const checkable = item.checked !== undefined;
379
+ return html`
380
+ <button
381
+ class="item ${item.danger ? "danger" : ""}"
382
+ type="button"
383
+ role=${checkable ? "menuitemcheckbox" : "menuitem"}
384
+ aria-checked=${checkable ? String(item.checked) : nothing}
385
+ ?disabled=${item.disabled}
386
+ tabindex=${index === this._active ? "0" : "-1"}
387
+ data-index=${index}
388
+ @click=${() => this._select(item)}
389
+ @pointerenter=${(e: PointerEvent) => !item.disabled && (e.currentTarget as HTMLElement).focus()}
390
+ >
391
+ <span class="lead" aria-hidden="true">
392
+ ${checkable
393
+ ? item.checked
394
+ ? html`<st-icon name="check" size="sm"></st-icon>`
395
+ : nothing
396
+ : item.icon
397
+ ? html`<st-icon name=${item.icon} size="sm"></st-icon>`
398
+ : nothing}
399
+ </span>
400
+ <span class="label">${item.label}</span>
401
+ ${item.shortcut ? html`<span class="shortcut" aria-hidden="true">${item.shortcut}</span>` : nothing}
402
+ </button>
403
+ `;
404
+ }
405
+
406
+ render() {
407
+ return html`
408
+ <slot></slot>
409
+ <div
410
+ popover="manual"
411
+ role="menu"
412
+ aria-label=${this.label}
413
+ @toggle=${this._onToggle}
414
+ @keydown=${this._onKeydown}
415
+ >
416
+ ${this._open ? this.items.map((item, index) => this._renderItem(item, index)) : nothing}
417
+ </div>
418
+ `;
419
+ }
420
+ }
421
+
422
+ declare global {
423
+ interface HTMLElementTagNameMap {
424
+ "st-context-menu": StContextMenu;
425
+ }
426
+ }
@@ -2,6 +2,9 @@ import {LitElement, html, css, PropertyValues} from "lit";
2
2
  import {customElement, property, state} from "lit/decorators.js";
3
3
  import {resetStyles} from "../../styles/reset";
4
4
 
5
+ /** Reads `.value` from a custom form element event target. */
6
+ const targetValue = <T = string>(e: Event) => (e.target as unknown as {value: T}).value;
7
+
5
8
  @customElement("st-cron-builder")
6
9
  export class StCronBuilder extends LitElement {
7
10
  static formAssociated = true;
@@ -42,7 +45,7 @@ export class StCronBuilder extends LitElement {
42
45
  border: 1px solid var(--st-color-border);
43
46
  border-radius: var(--st-radius-lg);
44
47
  padding: var(--st-spacing-lg);
45
- box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
48
+ box-shadow: var(--st-shadow-sm);
46
49
  }
47
50
 
48
51
  .builder-grid {
@@ -81,7 +84,7 @@ export class StCronBuilder extends LitElement {
81
84
  text-align: center;
82
85
  font-size: 11px;
83
86
  padding: 4px;
84
- background: var(--st-color-surface-muted, #f1f5f9);
87
+ background: var(--st-color-surface-muted);
85
88
  border-radius: var(--st-radius-sm);
86
89
  color: var(--st-color-text-muted);
87
90
  border: 1px solid var(--st-color-border);
@@ -89,25 +92,25 @@ export class StCronBuilder extends LitElement {
89
92
  }
90
93
 
91
94
  .segment-badge.active {
92
- background: var(--st-color-primary, #eff6ff);
95
+ background: var(--st-color-primary);
93
96
  color: var(--st-color-surface);
94
97
  border-color: var(--st-color-primary);
95
98
  font-weight: 600;
96
99
  }
97
100
 
98
101
  .success-text {
99
- color: var(--st-color-success, #16a34a);
102
+ color: var(--st-color-success);
100
103
  }
101
104
 
102
105
  .error-text {
103
- color: var(--st-color-danger, #dc2626);
106
+ color: var(--st-color-danger);
104
107
  font-weight: 500;
105
108
  }
106
109
 
107
110
  .output-preview {
108
111
  margin-top: var(--st-spacing-md);
109
112
  padding: var(--st-spacing-md);
110
- background: var(--st-color-surface-muted, #f8fafc);
113
+ background: var(--st-color-surface-muted);
111
114
  border-radius: var(--st-radius-md);
112
115
  border: 1px dashed var(--st-color-border);
113
116
  }
@@ -357,8 +360,8 @@ export class StCronBuilder extends LitElement {
357
360
  }
358
361
  }
359
362
 
360
- private _handleCustomCronInput(e: any) {
361
- const inputEl = e.target;
363
+ private _handleCustomCronInput(e: Event) {
364
+ const inputEl = e.target as HTMLInputElement;
362
365
  const sanitized = inputEl.value.replace(/[^0-9A-Za-z\s\*\/\-\,]/g, "");
363
366
 
364
367
  if (inputEl.value !== sanitized) {
@@ -369,8 +372,8 @@ export class StCronBuilder extends LitElement {
369
372
  this._generateOutput();
370
373
  }
371
374
 
372
- private _handleFrequencyChange(e: any) {
373
- this._frequency = e.target.value;
375
+ private _handleFrequencyChange(e: Event) {
376
+ this._frequency = targetValue(e);
374
377
  this._generateOutput();
375
378
  }
376
379
 
@@ -422,8 +425,8 @@ export class StCronBuilder extends LitElement {
422
425
  <st-toggle-group
423
426
  multiple
424
427
  .value=${this._days}
425
- @change=${(e: any) => {
426
- this._days = e.target.value;
428
+ @change=${(e: Event) => {
429
+ this._days = targetValue(e);
427
430
  this._generateOutput();
428
431
  }}
429
432
  >
@@ -445,8 +448,8 @@ export class StCronBuilder extends LitElement {
445
448
  label="Run on day of month"
446
449
  .options=${monthDayOptions}
447
450
  .value=${this._monthDay}
448
- @change=${(e: any) => {
449
- this._monthDay = e.target.value;
451
+ @change=${(e: Event) => {
452
+ this._monthDay = targetValue(e);
450
453
  this._generateOutput();
451
454
  }}
452
455
  ></st-select>
@@ -459,8 +462,8 @@ export class StCronBuilder extends LitElement {
459
462
  <label>Execution Date</label>
460
463
  <st-calendar
461
464
  .value=${this._date}
462
- @change=${(e: any) => {
463
- this._date = e.target.value;
465
+ @change=${(e: Event) => {
466
+ this._date = targetValue(e);
464
467
  this._generateOutput();
465
468
  }}
466
469
  ></st-calendar>
@@ -504,8 +507,8 @@ export class StCronBuilder extends LitElement {
504
507
  <st-time-picker
505
508
  label="Execution Time"
506
509
  .value=${this._time}
507
- @change=${(e: any) => {
508
- this._time = e.target.value;
510
+ @change=${(e: Event) => {
511
+ this._time = targetValue(e);
509
512
  this._generateOutput();
510
513
  }}
511
514
  ></st-time-picker>
@@ -0,0 +1,64 @@
1
+ import {html, css} from "lit";
2
+ import {customElement, state} from "lit/decorators.js";
3
+ import {StSection} from "../section/section.js";
4
+
5
+ /**
6
+ * A closing call to action: one clear message and the buttons that act on it. Highlighted in the
7
+ * accent colour by default; set `tone` to change that.
8
+ *
9
+ * Slots: `eyebrow`, `title`, `lead`, `actions` (buttons) and the default slot for a short note
10
+ * under the buttons.
11
+ */
12
+ @customElement("st-cta")
13
+ export class StCta extends StSection {
14
+ @state() private _hasActions = false;
15
+
16
+ constructor() {
17
+ super();
18
+ this.tone = "accent";
19
+ this.width = "md";
20
+ }
21
+
22
+ static styles = [
23
+ ...StSection.styles,
24
+ css`
25
+ .header {
26
+ margin-bottom: var(--st-spacing-lg);
27
+ }
28
+
29
+ .actions {
30
+ display: flex;
31
+ flex-wrap: wrap;
32
+ gap: var(--st-spacing-md);
33
+ justify-content: center;
34
+ }
35
+
36
+ .note {
37
+ margin-top: var(--st-spacing-md);
38
+ text-align: center;
39
+ font-size: var(--st-font-size-sm);
40
+ }
41
+ `,
42
+ ];
43
+
44
+ render() {
45
+ return this.frame(
46
+ html`
47
+ <div class="actions" ?hidden=${!this._hasActions}>
48
+ <slot
49
+ name="actions"
50
+ @slotchange=${(e: Event) =>
51
+ (this._hasActions = (e.target as HTMLSlotElement).assignedNodes().length > 0)}
52
+ ></slot>
53
+ </div>
54
+ <div class="note"><slot></slot></div>
55
+ `,
56
+ );
57
+ }
58
+ }
59
+
60
+ declare global {
61
+ interface HTMLElementTagNameMap {
62
+ "st-cta": StCta;
63
+ }
64
+ }
@@ -37,7 +37,7 @@ export class StDrawer extends LitElement {
37
37
  left: 0;
38
38
  width: 100vw;
39
39
  height: 100vh;
40
- background-color: rgba(0, 0, 0, 0.5);
40
+ background-color: var(--st-color-overlay);
41
41
  backdrop-filter: blur(2px);
42
42
  z-index: 1000;
43
43
  display: flex;
@@ -62,7 +62,7 @@ export class StDrawer extends LitElement {
62
62
  bottom: 0;
63
63
  width: var(--st-drawer-width, 320px);
64
64
  max-width: 90vw;
65
- background-color: var(--st-color-surface, #ffffff);
65
+ background-color: var(--st-color-surface);
66
66
  display: flex;
67
67
  flex-direction: column;
68
68
  z-index: 1001;
@@ -79,7 +79,7 @@ export class StDrawer extends LitElement {
79
79
 
80
80
  :host([open]) .panel {
81
81
  visibility: visible;
82
- box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
82
+ box-shadow: var(--st-shadow-drawer);
83
83
  }
84
84
 
85
85
  /* Slide from Left */
@@ -105,7 +105,7 @@ export class StDrawer extends LitElement {
105
105
  align-items: center;
106
106
  justify-content: space-between;
107
107
  padding: var(--st-spacing-md) var(--st-spacing-lg);
108
- border-bottom: 1px solid var(--st-color-border, #e2e8f0);
108
+ border-bottom: 1px solid var(--st-color-border);
109
109
  }
110
110
 
111
111
  .title {
@@ -125,12 +125,12 @@ export class StDrawer extends LitElement {
125
125
  display: flex;
126
126
  align-items: center;
127
127
  justify-content: center;
128
- border-radius: var(--st-radius-sm, 0.375rem);
128
+ border-radius: var(--st-radius-sm);
129
129
  }
130
130
 
131
131
  .close-btn:hover {
132
132
  color: var(--st-color-text);
133
- background-color: var(--st-color-surface-muted, #f1f5f9);
133
+ background-color: var(--st-color-surface-muted);
134
134
  }
135
135
 
136
136
  .close-btn svg {