scb-wc 0.1.2 → 0.1.4

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 (339) hide show
  1. package/README.md +194 -164
  2. package/all.js +91 -5
  3. package/blazor/CustomEvents.cs +83 -0
  4. package/blazor/ScbBlazorInteropBase.cs +4460 -1663
  5. package/blazor/scb-blazor-bridge.js +6827 -2517
  6. package/blazor/wrappers/ScbAccordion.razor +50 -0
  7. package/blazor/wrappers/ScbAppBar.razor +95 -0
  8. package/blazor/wrappers/ScbBreadcrumb.razor +59 -0
  9. package/blazor/wrappers/ScbCalendar.razor +100 -0
  10. package/blazor/wrappers/ScbCalendarCard.razor +189 -0
  11. package/blazor/wrappers/ScbCheckbox.razor +92 -0
  12. package/blazor/wrappers/ScbCollapse.razor +76 -0
  13. package/blazor/wrappers/ScbCookiesConsent.razor +106 -0
  14. package/blazor/wrappers/ScbDatepicker.razor +77 -0
  15. package/blazor/wrappers/ScbDialog.razor +72 -0
  16. package/blazor/wrappers/ScbDrawer.razor +64 -0
  17. package/blazor/wrappers/ScbDropZone.razor +168 -0
  18. package/blazor/wrappers/ScbDropdown.razor +76 -0
  19. package/blazor/wrappers/ScbHorizontalScroller.razor +137 -0
  20. package/blazor/wrappers/ScbList.razor +77 -0
  21. package/blazor/wrappers/ScbMenu.razor +71 -0
  22. package/blazor/wrappers/ScbNav.razor +92 -0
  23. package/blazor/wrappers/ScbNotificationCard.razor +122 -0
  24. package/blazor/wrappers/ScbOptionsMenu.razor +88 -0
  25. package/blazor/wrappers/ScbPagination.razor +80 -0
  26. package/blazor/wrappers/ScbRadioGroup.razor +94 -0
  27. package/blazor/wrappers/ScbSearch.razor +83 -0
  28. package/blazor/wrappers/ScbSegmentedButton.razor +85 -0
  29. package/blazor/wrappers/ScbSelect.razor +79 -0
  30. package/blazor/wrappers/ScbSlider.razor +96 -0
  31. package/blazor/wrappers/ScbSnackbar.razor +93 -0
  32. package/blazor/wrappers/ScbSwitch.razor +92 -0
  33. package/blazor/wrappers/ScbTable.razor +67 -0
  34. package/blazor/wrappers/ScbTableAdvanced.razor +78 -0
  35. package/blazor/wrappers/ScbTabs.razor +55 -0
  36. package/blazor/wrappers/ScbTextfield.razor +104 -0
  37. package/blazor/wrappers/ScbTooltip.razor +88 -0
  38. package/blazor/wrappers/ScbViz.razor +142 -0
  39. package/demo-data-preview.svg +12 -0
  40. package/dummy.png +0 -0
  41. package/fonts/inter/files/inter-latin-wght-italic.woff2 +0 -0
  42. package/fonts/inter/files/inter-latin-wght-normal.woff2 +0 -0
  43. package/fonts/material-symbols-outlined/files/material-symbols-outlined-latin-wght-normal.woff2 +0 -0
  44. package/index.js +91 -1
  45. package/mvc/components/all.js +90 -1
  46. package/mvc/components/scb-accordion/scb-accordion-item.js +211 -0
  47. package/mvc/components/scb-accordion/scb-accordion.js +44 -0
  48. package/mvc/components/scb-app-bar/scb-app-bar.js +166 -0
  49. package/mvc/components/scb-avatar/scb-avatar.js +111 -0
  50. package/mvc/components/scb-badge/scb-badge.js +80 -0
  51. package/mvc/components/scb-breadcrumb/scb-breadcrumb-item.js +14 -0
  52. package/mvc/components/scb-breadcrumb/scb-breadcrumb.js +96 -0
  53. package/mvc/components/scb-button/scb-button.js +268 -0
  54. package/mvc/components/scb-calendar/scb-calendar-event.js +6 -0
  55. package/mvc/components/scb-calendar/scb-calendar.js +168 -0
  56. package/mvc/components/scb-calendar-card/scb-calendar-card.js +346 -0
  57. package/mvc/components/scb-card/scb-card.js +761 -0
  58. package/mvc/components/scb-checkbox/scb-checkbox-group.js +33 -0
  59. package/mvc/components/scb-checkbox/scb-checkbox.js +140 -0
  60. package/mvc/components/scb-chevron/scb-chevron.js +121 -0
  61. package/mvc/components/scb-chip/scb-chip.js +66 -0
  62. package/mvc/components/scb-collapse/scb-collapse.js +89 -0
  63. package/mvc/components/scb-cookies-consent/scb-cookies-consent.js +78 -0
  64. package/mvc/components/scb-datepicker/scb-datepicker.js +296 -0
  65. package/mvc/components/scb-dialog/scb-dialog.js +265 -0
  66. package/mvc/components/scb-divider/scb-divider.js +69 -0
  67. package/mvc/components/scb-drawer/scb-drawer.js +128 -0
  68. package/mvc/components/scb-drop-zone/scb-drop-zone.js +555 -0
  69. package/mvc/components/scb-dropdown/scb-dropdown.js +306 -0
  70. package/mvc/components/scb-fab/scb-fab.js +108 -0
  71. package/mvc/components/scb-fact-card/scb-fact-card-content.js +46 -0
  72. package/mvc/components/scb-fact-card/scb-fact-card.js +226 -0
  73. package/mvc/components/scb-footer/scb-footer-section.js +3 -0
  74. package/mvc/components/scb-footer/scb-footer.js +210 -0
  75. package/mvc/components/scb-gallery-grid/scb-gallery-grid.js +131 -0
  76. package/mvc/components/scb-grid/scb-grid-item.js +11 -0
  77. package/mvc/components/scb-grid/scb-grid.js +98 -0
  78. package/mvc/components/scb-grid/scb-stack.js +33 -0
  79. package/mvc/components/scb-header/scb-header-menu-group.js +1 -0
  80. package/mvc/components/scb-header/scb-header-menu-item.js +5 -0
  81. package/mvc/components/scb-header/scb-header-tab.js +5 -0
  82. package/mvc/components/scb-header/scb-header-utility.js +1 -0
  83. package/mvc/components/scb-header/scb-header.js +681 -0
  84. package/mvc/components/scb-horizontal-scroller/scb-horizontal-scroller.js +196 -0
  85. package/mvc/components/scb-icon-button/scb-icon-button.js +171 -0
  86. package/mvc/components/scb-keyfigure-card/scb-keyfigure-card.js +212 -0
  87. package/mvc/components/scb-link/scb-link.js +61 -0
  88. package/mvc/components/scb-list/scb-list-item.js +153 -0
  89. package/mvc/components/scb-list/scb-list.js +26 -0
  90. package/mvc/components/scb-menu/scb-menu-item.js +205 -0
  91. package/mvc/components/scb-menu/scb-menu-section.js +42 -0
  92. package/mvc/components/scb-menu/scb-menu.js +81 -0
  93. package/mvc/components/scb-menu/scb-sub-menu.js +10 -0
  94. package/mvc/components/scb-nav/scb-nav-item.js +28 -0
  95. package/mvc/components/scb-nav/scb-nav.js +104 -0
  96. package/mvc/components/scb-notification-card/scb-notification-card.js +358 -0
  97. package/mvc/components/scb-options-menu/scb-options-menu-item.js +66 -0
  98. package/mvc/components/scb-options-menu/scb-options-menu.js +88 -0
  99. package/mvc/components/scb-options-menu/scb-options-sub-menu.js +34 -0
  100. package/mvc/components/scb-overlay/scb-overlay.js +49 -0
  101. package/mvc/components/scb-pagination/scb-pagination.js +312 -0
  102. package/mvc/components/scb-progress-indicator/scb-progress-indicator.js +87 -0
  103. package/mvc/components/scb-progress-stepper/scb-progress-step.js +147 -0
  104. package/mvc/components/scb-progress-stepper/scb-progress-stepper.js +62 -0
  105. package/mvc/components/scb-radio-button/scb-radio-button.js +132 -0
  106. package/mvc/components/scb-radio-button/scb-radio-group.js +43 -0
  107. package/mvc/components/scb-scrollspy/scb-scrollspy.js +79 -0
  108. package/mvc/components/scb-search/scb-search.js +292 -0
  109. package/mvc/components/scb-segmented-button/scb-segmented-button.js +32 -0
  110. package/mvc/components/scb-segmented-button/scb-segmented-item.js +74 -0
  111. package/mvc/components/scb-select/scb-select-option.js +61 -0
  112. package/mvc/components/scb-select/scb-select.js +284 -0
  113. package/mvc/components/scb-skeleton/scb-skeleton.js +38 -0
  114. package/mvc/components/scb-slider/scb-slider.js +27 -0
  115. package/mvc/components/scb-snackbar/scb-snackbar.js +128 -0
  116. package/mvc/components/scb-status-pill/scb-status-pill.js +45 -0
  117. package/mvc/components/scb-stepper/scb-step.js +239 -0
  118. package/mvc/components/scb-stepper/scb-stepper.js +139 -0
  119. package/mvc/components/scb-switch/scb-switch.js +59 -0
  120. package/mvc/components/scb-table/scb-table.js +51 -0
  121. package/mvc/components/scb-table-advanced/scb-table-advanced.js +76 -0
  122. package/mvc/components/scb-tabs/scb-primary-tab.js +6 -0
  123. package/mvc/components/scb-tabs/scb-secondary-tab.js +6 -0
  124. package/mvc/components/scb-tabs/scb-tabs.js +28 -0
  125. package/mvc/components/scb-textfield/scb-textfield.js +595 -0
  126. package/mvc/components/scb-toc/scb-toc-item.js +303 -0
  127. package/mvc/components/scb-toc/scb-toc.js +19 -0
  128. package/mvc/components/scb-tooltip/scb-tooltip.js +196 -0
  129. package/mvc/components/scb-vignette/scb-vignette.js +37 -0
  130. package/mvc/components/scb-viz/scb-viz-actions-runtime.js +2 -0
  131. package/mvc/components/scb-viz/scb-viz-print-runtime.js +98 -0
  132. package/mvc/components/scb-viz/scb-viz-series-differentiation-registry.js +1 -0
  133. package/mvc/components/scb-viz/scb-viz-series-differentiation-runtime.js +1 -0
  134. package/mvc/components/scb-viz/scb-viz-table-runtime.js +1 -0
  135. package/mvc/components/scb-viz/scb-viz.js +1140 -0
  136. package/mvc/fonts/inter/files/inter-latin-wght-italic.woff2 +0 -0
  137. package/mvc/fonts/inter/files/inter-latin-wght-normal.woff2 +0 -0
  138. package/mvc/fonts/material-symbols-outlined/files/material-symbols-outlined-latin-wght-normal.woff2 +0 -0
  139. package/mvc/scb-blazor-bridge.js +6827 -2517
  140. package/mvc/scb-logo.svg +20 -20
  141. package/mvc/scb-typography.css +1 -1
  142. package/mvc/scb-wc.css +3 -2
  143. package/mvc/scb.svg +13 -13
  144. package/mvc/vendor/assertClassBrand.js +1 -0
  145. package/mvc/vendor/classPrivateFieldGet2.js +1 -0
  146. package/mvc/vendor/decorate.js +1 -0
  147. package/mvc/vendor/preload-helper.js +1 -0
  148. package/mvc/vendor/vendor-lit.js +1 -0
  149. package/mvc/vendor/vendor-material.js +364 -0
  150. package/mvc/vendor/vendor.js +4 -0
  151. package/package.json +420 -77
  152. package/scb-accordion/scb-accordion-item.js +340 -0
  153. package/scb-accordion/scb-accordion.js +151 -0
  154. package/scb-app-bar/scb-app-bar.js +317 -0
  155. package/scb-avatar/scb-avatar.js +197 -0
  156. package/scb-badge/scb-badge.js +165 -0
  157. package/scb-breadcrumb/scb-breadcrumb-item.js +62 -0
  158. package/scb-breadcrumb/scb-breadcrumb.js +255 -0
  159. package/scb-button/scb-button.js +398 -0
  160. package/scb-calendar/scb-calendar-event.js +48 -0
  161. package/scb-calendar/scb-calendar.js +700 -0
  162. package/scb-calendar-card/scb-calendar-card.js +505 -0
  163. package/scb-card/scb-card.js +1231 -0
  164. package/scb-checkbox/scb-checkbox-group.js +104 -0
  165. package/scb-checkbox/scb-checkbox.js +316 -0
  166. package/scb-chevron/scb-chevron.js +144 -0
  167. package/scb-chip/scb-chip.js +234 -0
  168. package/scb-collapse/scb-collapse.js +231 -0
  169. package/scb-cookies-consent/scb-cookies-consent.js +164 -0
  170. package/scb-datepicker/scb-datepicker.js +470 -0
  171. package/scb-dialog/scb-dialog.js +574 -0
  172. package/scb-divider/scb-divider.js +119 -0
  173. package/scb-drawer/scb-drawer.js +297 -0
  174. package/scb-drop-zone/scb-drop-zone.js +965 -0
  175. package/scb-dropdown/scb-dropdown.js +598 -0
  176. package/scb-fab/scb-fab.js +190 -0
  177. package/scb-fact-card/scb-fact-card-content.js +82 -0
  178. package/scb-fact-card/scb-fact-card.js +376 -0
  179. package/scb-footer/scb-footer-section.js +23 -0
  180. package/scb-footer/scb-footer.js +343 -0
  181. package/scb-gallery-grid/scb-gallery-grid.js +242 -0
  182. package/scb-grid/scb-grid-item.js +81 -0
  183. package/scb-grid/scb-grid.js +200 -0
  184. package/scb-grid/scb-stack.js +120 -0
  185. package/scb-header/scb-header-menu-group.js +21 -0
  186. package/scb-header/scb-header-menu-item.js +22 -0
  187. package/scb-header/scb-header-tab.js +25 -0
  188. package/scb-header/scb-header-utility.js +27 -0
  189. package/scb-header/scb-header.js +1358 -0
  190. package/scb-horizontal-scroller/scb-horizontal-scroller.js +353 -0
  191. package/scb-icon-button/scb-icon-button.js +335 -0
  192. package/scb-keyfigure-card/scb-keyfigure-card.js +340 -0
  193. package/scb-link/scb-link.js +136 -0
  194. package/scb-list/scb-list-item.js +297 -0
  195. package/scb-list/scb-list.js +119 -0
  196. package/scb-menu/scb-menu-item.js +330 -0
  197. package/scb-menu/scb-menu-section.js +60 -0
  198. package/scb-menu/scb-menu.js +154 -0
  199. package/scb-menu/scb-sub-menu.js +36 -0
  200. package/scb-nav/scb-nav-item.js +96 -0
  201. package/scb-nav/scb-nav.js +263 -0
  202. package/scb-notification-card/scb-notification-card.js +479 -0
  203. package/scb-options-menu/scb-options-menu-item.js +218 -0
  204. package/scb-options-menu/scb-options-menu.js +237 -0
  205. package/scb-options-menu/scb-options-sub-menu.js +69 -0
  206. package/scb-overlay/scb-overlay.js +144 -0
  207. package/scb-pagination/scb-pagination.js +438 -0
  208. package/scb-progress-indicator/scb-progress-indicator.js +199 -0
  209. package/scb-progress-stepper/scb-progress-step.js +213 -0
  210. package/scb-progress-stepper/scb-progress-stepper.js +132 -0
  211. package/scb-radio-button/scb-radio-button.js +249 -0
  212. package/scb-radio-button/scb-radio-group.js +216 -0
  213. package/scb-scrollspy/scb-scrollspy.js +670 -0
  214. package/scb-search/scb-search.js +643 -0
  215. package/scb-segmented-button/scb-segmented-button.js +215 -0
  216. package/scb-segmented-button/scb-segmented-item.js +133 -0
  217. package/scb-select/scb-select-option.js +88 -0
  218. package/scb-select/scb-select.js +517 -0
  219. package/scb-skeleton/scb-skeleton.js +92 -0
  220. package/scb-slider/scb-slider.js +98 -0
  221. package/scb-snackbar/scb-snackbar.js +223 -0
  222. package/scb-status-pill/scb-status-pill.js +100 -0
  223. package/scb-stepper/scb-step.js +311 -0
  224. package/scb-stepper/scb-stepper.js +325 -0
  225. package/scb-switch/scb-switch.js +182 -0
  226. package/scb-table/scb-table.js +202 -0
  227. package/scb-table-advanced/scb-table-advanced.js +327 -0
  228. package/scb-tabs/scb-primary-tab.js +68 -0
  229. package/scb-tabs/scb-secondary-tab.js +68 -0
  230. package/scb-tabs/scb-tabs.js +100 -0
  231. package/scb-test-components/index.d.ts +90 -0
  232. package/scb-test-components/scb-accordion/scb-accordion-item.d.ts +39 -0
  233. package/scb-test-components/scb-accordion/scb-accordion.d.ts +27 -0
  234. package/scb-test-components/scb-app-bar/scb-app-bar.d.ts +25 -0
  235. package/scb-test-components/scb-avatar/scb-avatar.d.ts +37 -0
  236. package/scb-test-components/scb-badge/scb-badge.d.ts +28 -0
  237. package/scb-test-components/scb-breadcrumb/scb-breadcrumb-item.d.ts +15 -0
  238. package/scb-test-components/scb-breadcrumb/scb-breadcrumb.d.ts +27 -0
  239. package/scb-test-components/scb-button/scb-button.d.ts +40 -0
  240. package/scb-test-components/scb-calendar/scb-calendar-event.d.ts +15 -0
  241. package/scb-test-components/scb-calendar/scb-calendar.d.ts +77 -0
  242. package/scb-test-components/scb-calendar-card/scb-calendar-card.d.ts +45 -0
  243. package/scb-test-components/scb-card/scb-card.d.ts +101 -0
  244. package/scb-test-components/scb-checkbox/scb-checkbox-group.d.ts +23 -0
  245. package/scb-test-components/scb-checkbox/scb-checkbox.d.ts +52 -0
  246. package/scb-test-components/scb-chevron/scb-chevron.d.ts +13 -0
  247. package/scb-test-components/scb-chip/scb-chip.d.ts +61 -0
  248. package/scb-test-components/scb-collapse/scb-collapse.d.ts +29 -0
  249. package/scb-test-components/scb-cookies-consent/scb-cookies-consent.d.ts +23 -0
  250. package/scb-test-components/scb-datepicker/scb-datepicker.d.ts +39 -0
  251. package/scb-test-components/scb-dialog/scb-dialog.d.ts +72 -0
  252. package/scb-test-components/scb-divider/scb-divider.d.ts +34 -0
  253. package/scb-test-components/scb-drawer/scb-drawer.d.ts +72 -0
  254. package/scb-test-components/scb-drop-zone/scb-drop-zone.d.ts +143 -0
  255. package/scb-test-components/scb-dropdown/scb-dropdown.d.ts +70 -0
  256. package/scb-test-components/scb-fab/scb-fab.d.ts +42 -0
  257. package/scb-test-components/scb-fact-card/scb-fact-card-content.d.ts +15 -0
  258. package/scb-test-components/scb-fact-card/scb-fact-card.d.ts +49 -0
  259. package/scb-test-components/scb-footer/scb-footer-section.d.ts +20 -0
  260. package/scb-test-components/scb-footer/scb-footer.d.ts +31 -0
  261. package/scb-test-components/scb-gallery-grid/scb-gallery-grid.d.ts +20 -0
  262. package/scb-test-components/scb-grid/scb-grid-item.d.ts +32 -0
  263. package/scb-test-components/scb-grid/scb-grid.d.ts +36 -0
  264. package/scb-test-components/scb-grid/scb-stack.d.ts +32 -0
  265. package/scb-test-components/scb-header/scb-header-menu-group.d.ts +12 -0
  266. package/scb-test-components/scb-header/scb-header-menu-item.d.ts +13 -0
  267. package/scb-test-components/scb-header/scb-header-tab.d.ts +13 -0
  268. package/scb-test-components/scb-header/scb-header-utility.d.ts +14 -0
  269. package/scb-test-components/scb-header/scb-header.d.ts +132 -0
  270. package/scb-test-components/scb-horizontal-scroller/scb-horizontal-scroller.d.ts +47 -0
  271. package/scb-test-components/scb-icon-button/scb-icon-button.d.ts +76 -0
  272. package/scb-test-components/scb-keyfigure-card/scb-keyfigure-card.d.ts +46 -0
  273. package/scb-test-components/scb-link/scb-link.d.ts +25 -0
  274. package/scb-test-components/scb-list/scb-list-item.d.ts +38 -0
  275. package/scb-test-components/scb-list/scb-list.d.ts +26 -0
  276. package/scb-test-components/scb-menu/scb-menu-item.d.ts +52 -0
  277. package/scb-test-components/scb-menu/scb-menu-section.d.ts +11 -0
  278. package/scb-test-components/scb-menu/scb-menu.d.ts +25 -0
  279. package/scb-test-components/scb-menu/scb-sub-menu.d.ts +14 -0
  280. package/scb-test-components/scb-nav/scb-nav-item.d.ts +20 -0
  281. package/scb-test-components/scb-nav/scb-nav.d.ts +50 -0
  282. package/scb-test-components/scb-notification-card/scb-notification-card.d.ts +46 -0
  283. package/scb-test-components/scb-options-menu/scb-options-menu-item.d.ts +29 -0
  284. package/scb-test-components/scb-options-menu/scb-options-menu.d.ts +35 -0
  285. package/scb-test-components/scb-options-menu/scb-options-sub-menu.d.ts +11 -0
  286. package/scb-test-components/scb-overlay/scb-overlay.d.ts +24 -0
  287. package/scb-test-components/scb-pagination/scb-pagination.d.ts +36 -0
  288. package/scb-test-components/scb-progress-indicator/scb-progress-indicator.d.ts +28 -0
  289. package/scb-test-components/scb-progress-stepper/scb-progress-step.d.ts +21 -0
  290. package/scb-test-components/scb-progress-stepper/scb-progress-stepper.d.ts +22 -0
  291. package/scb-test-components/scb-radio-button/scb-radio-button.d.ts +26 -0
  292. package/scb-test-components/scb-radio-button/scb-radio-group.d.ts +49 -0
  293. package/scb-test-components/scb-scrollspy/scb-scrollspy.d.ts +217 -0
  294. package/scb-test-components/scb-search/scb-search.d.ts +96 -0
  295. package/scb-test-components/scb-segmented-button/scb-segmented-button.d.ts +80 -0
  296. package/scb-test-components/scb-segmented-button/scb-segmented-item.d.ts +21 -0
  297. package/scb-test-components/scb-select/scb-select-option.d.ts +16 -0
  298. package/scb-test-components/scb-select/scb-select.d.ts +62 -0
  299. package/scb-test-components/scb-skeleton/scb-skeleton.d.ts +25 -0
  300. package/scb-test-components/scb-slider/scb-slider.d.ts +28 -0
  301. package/scb-test-components/scb-snackbar/scb-snackbar.d.ts +24 -0
  302. package/scb-test-components/scb-status-pill/scb-status-pill.d.ts +22 -0
  303. package/scb-test-components/scb-stepper/scb-step.d.ts +22 -0
  304. package/scb-test-components/scb-stepper/scb-stepper.d.ts +47 -0
  305. package/scb-test-components/scb-switch/scb-switch.d.ts +52 -0
  306. package/scb-test-components/scb-table/scb-table.d.ts +24 -0
  307. package/scb-test-components/scb-table-advanced/scb-table-advanced.d.ts +39 -0
  308. package/scb-test-components/scb-tabs/scb-primary-tab.d.ts +15 -0
  309. package/scb-test-components/scb-tabs/scb-secondary-tab.d.ts +15 -0
  310. package/scb-test-components/scb-tabs/scb-tabs.d.ts +21 -0
  311. package/scb-test-components/scb-textfield/scb-textfield.d.ts +75 -0
  312. package/scb-test-components/scb-toc/scb-toc-item.d.ts +38 -0
  313. package/scb-test-components/scb-toc/scb-toc.d.ts +27 -0
  314. package/scb-test-components/scb-tooltip/scb-tooltip.d.ts +51 -0
  315. package/scb-test-components/scb-vignette/scb-vignette.d.ts +20 -0
  316. package/scb-test-components/scb-viz/scb-viz-actions-runtime.d.ts +26 -0
  317. package/scb-test-components/scb-viz/scb-viz-print-runtime.d.ts +27 -0
  318. package/scb-test-components/scb-viz/scb-viz-series-differentiation-registry.d.ts +21 -0
  319. package/scb-test-components/scb-viz/scb-viz-series-differentiation-runtime.d.ts +42 -0
  320. package/scb-test-components/scb-viz/scb-viz-table-runtime.d.ts +28 -0
  321. package/scb-test-components/scb-viz/scb-viz.d.ts +207 -0
  322. package/scb-textfield/scb-textfield.js +827 -0
  323. package/scb-toc/scb-toc-item.js +477 -0
  324. package/scb-toc/scb-toc.js +101 -0
  325. package/scb-tooltip/scb-tooltip.js +402 -0
  326. package/scb-typography.css +1 -1
  327. package/scb-vignette/scb-vignette.js +88 -0
  328. package/scb-viz/scb-viz-actions-runtime.js +143 -0
  329. package/scb-viz/scb-viz-print-runtime.js +121 -0
  330. package/scb-viz/scb-viz-series-differentiation-registry.js +117 -0
  331. package/scb-viz/scb-viz-series-differentiation-runtime.js +126 -0
  332. package/scb-viz/scb-viz-table-runtime.js +86 -0
  333. package/scb-viz/scb-viz.js +2195 -0
  334. package/scb-wc-selfhost.css +29 -0
  335. package/scb-wc.bundle.js +12893 -1099
  336. package/scb-wc.css +3 -2
  337. package/scb-wc.d.ts +180 -0
  338. package/index.d.ts +0 -0
  339. package/mvc/components/index.js +0 -1
@@ -0,0 +1,479 @@
1
+ import { __decorate as e } from "../_virtual/_@oxc-project_runtime@0.126.0/helpers/decorate.js";
2
+ import "../scb-icon-button/scb-icon-button.js";
3
+ import { LitElement as t, css as n, html as r } from "lit";
4
+ import { customElement as i, property as a } from "lit/decorators.js";
5
+ import "@material/web/focus/md-focus-ring.js";
6
+ import "@material/web/icon/icon.js";
7
+ //#region src/scb-test-components/scb-notification-card/scb-notification-card.ts
8
+ var o = class extends t {
9
+ constructor(...e) {
10
+ super(...e), this.variant = "success", this.direction = "horizontal", this.size = "large", this.title = "", this.notificationCardTitle = "", this.subtitle = "", this.supportingText = "", this.open = !1, this.linkText = "", this.linkHref = "#", this.href = "", this.showIcon = !1, this.showCloseButton = !1, this.sizing = "stretch", this.width = "", this.maxWidth = "", this.height = "", this.maxHeight = "", this.fullHeight = !1, this.fullWidth = !1, this.spacing = void 0, this.spacingTop = void 0, this.spacingBottom = void 0, this.spacingLeft = void 0, this.spacingRight = void 0, this._closeNotification = () => {
11
+ this.open = !1;
12
+ let e = new CustomEvent("close", {
13
+ detail: { open: this.open },
14
+ bubbles: !0,
15
+ composed: !0
16
+ });
17
+ this.dispatchEvent(e);
18
+ let t = new CustomEvent("Close", {
19
+ detail: { open: this.open },
20
+ bubbles: !0,
21
+ composed: !0
22
+ });
23
+ this.dispatchEvent(t);
24
+ };
25
+ }
26
+ get #e() {
27
+ return this.notificationCardTitle || this.title;
28
+ }
29
+ static {
30
+ this.styles = [n`
31
+ :host {
32
+ display: block;
33
+ position: relative;
34
+ box-sizing: border-box;
35
+ inline-size: 100%;
36
+ min-inline-size: 0;
37
+ /* Om det behövs kan maxbredd styras via css-variabel, samma idé som övriga kort */
38
+ max-inline-size: var(--scb-notification-card-max-w, none);
39
+ height: auto;
40
+ padding: var(--scb-notification-card-focus-ring-gap, 4px);
41
+
42
+ --scb-notification-card-padding: var(--spacing-5, 16px);
43
+ --scb-notification-card-column-gap: var(--spacing-4, 12px);
44
+ --scb-notification-card-row-gap: var(--spacing-3, 8px);
45
+
46
+ --scb-notification-main-horizontal-gap: var(--spacing-4, 12px);
47
+ --scb-notification-main-vertical-gap: var(--spacing-4, 12px);
48
+ --scb-notification-text-container-gap: var(--spacing-4, 12px);
49
+
50
+ --scb-notification-icon-size: var(--icon-size-small, 24px);
51
+
52
+ --scb-notification-title-size: var(--md-sys-typescale-headline-small-size, 24px);
53
+ --scb-notification-title-line-height: var(--md-sys-typescale-headline-small-line-height, 30px);
54
+ --scb-notification-title-letter-spacing: var(--md-sys-typescale-headline-small-tracking, -0.6px);
55
+
56
+ --scb-notification-subtitle-size: var(--md-sys-typescale-title-medium-size, 18px);
57
+ --scb-notification-subtitle-line-height: var(--md-sys-typescale-title-medium-line-height, 26px);
58
+ --scb-notification-subtitle-letter-spacing: var(--md-sys-typescale-title-medium-tracking, -0.3px);
59
+
60
+ --scb-notification-text-size: var(--md-sys-typescale-body-medium-size, 16px);
61
+ --scb-notification-text-line-height: var(--md-sys-typescale-body-medium-line-height, 24px);
62
+ --scb-notification-text-letter-spacing: var(--md-sys-typescale-body-medium-tracking, -0.15px);
63
+
64
+ --scb-notification-footer-size: 18px;
65
+ --scb-notification-footer-line-height: 26px;
66
+ }
67
+
68
+ :host([size='medium']) {
69
+ --scb-notification-card-padding: var(--spacing-4, 12px);
70
+ --scb-notification-card-column-gap: var(--spacing-3, 8px);
71
+ --scb-notification-card-row-gap: var(--spacing-2, 4px);
72
+
73
+ --scb-notification-main-horizontal-gap: var(--spacing-3, 8px);
74
+ --scb-notification-main-vertical-gap: var(--spacing-3, 8px);
75
+ --scb-notification-text-container-gap: var(--spacing-3, 8px);
76
+
77
+ --scb-notification-icon-size: var(--icon-size-medium, 20px);
78
+
79
+ --scb-notification-title-size: var(--md-sys-typescale-title-large-size, 20px);
80
+ --scb-notification-title-line-height: var(--md-sys-typescale-title-large-line-height, 28px);
81
+ --scb-notification-title-letter-spacing: var(--md-sys-typescale-title-large-tracking, -0.3px);
82
+
83
+ --scb-notification-subtitle-size: var(--md-sys-typescale-title-small-size, 16px);
84
+ --scb-notification-subtitle-line-height: var(--md-sys-typescale-title-small-line-height, 24px);
85
+ --scb-notification-subtitle-letter-spacing: var(--md-sys-typescale-title-small-tracking, -0.2px);
86
+
87
+ --scb-notification-text-size: var(--md-sys-typescale-body-small-size, 14px);
88
+ --scb-notification-text-line-height: var(--md-sys-typescale-body-small-line-height, 20px);
89
+ --scb-notification-text-letter-spacing: var(--md-sys-typescale-body-small-tracking, -0.1px);
90
+
91
+ --scb-notification-footer-size: 16px;
92
+ --scb-notification-footer-line-height: 24px;
93
+ }
94
+
95
+ :host([size='small']) {
96
+ --scb-notification-card-padding: var(--spacing-3, 8px);
97
+ --scb-notification-card-column-gap: var(--spacing-2, 4px);
98
+ --scb-notification-card-row-gap: var(--spacing-1, 2px);
99
+
100
+ --scb-notification-main-horizontal-gap: var(--spacing-2, 4px);
101
+ --scb-notification-main-vertical-gap: var(--spacing-2, 4px);
102
+ --scb-notification-text-container-gap: var(--spacing-2, 4px);
103
+
104
+ --scb-notification-icon-size: var(--icon-size-medium, 20px);
105
+
106
+ --scb-notification-title-size: var(--md-sys-typescale-title-medium-size, 18px);
107
+ --scb-notification-title-line-height: var(--md-sys-typescale-title-medium-line-height, 26px);
108
+ --scb-notification-title-letter-spacing: var(--md-sys-typescale-title-medium-tracking, -0.3px);
109
+
110
+ --scb-notification-subtitle-size: var(--md-sys-typescale-body-medium-size, 16px);
111
+ --scb-notification-subtitle-line-height: var(--md-sys-typescale-body-medium-line-height, 24px);
112
+ --scb-notification-subtitle-letter-spacing: var(--md-sys-typescale-body-medium-tracking, -0.15px);
113
+
114
+ --scb-notification-text-size: var(--md-sys-typescale-body-small-size, 14px);
115
+ --scb-notification-text-line-height: var(--md-sys-typescale-body-small-line-height, 20px);
116
+ --scb-notification-text-letter-spacing: var(--md-sys-typescale-body-small-tracking, -0.1px);
117
+
118
+ --scb-notification-footer-size: 14px;
119
+ --scb-notification-footer-line-height: 20px;
120
+ }
121
+
122
+ /* Stretch: fyller både bredd och höjd, som standard */
123
+ :host([sizing='stretch']) {
124
+ inline-size: 100%;
125
+ block-size: 100%;
126
+ max-inline-size: none;
127
+ }
128
+
129
+ /* Legacy full-width / full-height */
130
+ :host([full-width]) {
131
+ inline-size: 100%;
132
+ }
133
+
134
+ :host([full-height]) {
135
+ block-size: 100%;
136
+ }
137
+
138
+ /* content-width: samma upplägg som card / fact-card */
139
+ :host([sizing='content-width']) {
140
+ display: inline-block;
141
+ inline-size: auto;
142
+ block-size: auto;
143
+ }
144
+
145
+ :host([sizing='content-width']) .notification {
146
+ inline-size: max-content;
147
+ }
148
+
149
+ /* content-height: bredd fyller, höjd styrs av innehåll */
150
+ :host([sizing='content-height']) {
151
+ inline-size: 100%;
152
+ block-size: auto;
153
+ max-inline-size: none;
154
+ }
155
+
156
+ /* När värd-elementet fyller höjd ska själva kortet också göra det */
157
+ :host([height]) .notification,
158
+ :host([max-height]) .notification,
159
+ :host([sizing='stretch']) .notification,
160
+ :host([full-height]) .notification {
161
+ block-size: 100%;
162
+ }
163
+
164
+ /* Öppen / stängd */
165
+ :host([open]) .notification {
166
+ display: flex;
167
+ }
168
+
169
+ :host(:not([open])) .notification {
170
+ display: none;
171
+ }
172
+
173
+ .notification {
174
+ box-sizing: border-box;
175
+ border-radius: var(--md-sys-shape-corner-large, 16px);
176
+ padding: var(--scb-notification-card-padding);
177
+ display: flex;
178
+ flex-direction: row;
179
+ align-items: flex-start;
180
+ justify-content: space-between;
181
+ column-gap: var(--scb-notification-card-column-gap);
182
+ row-gap: var(--scb-notification-card-row-gap);
183
+ inline-size: 100%;
184
+ max-inline-size: 100%;
185
+ color: inherit;
186
+ }
187
+
188
+ /* Variantfärger */
189
+ :host([variant='success']) .notification {
190
+ background: var(--md-sys-color-success-container, #E7FEE9);
191
+ color: var(--md-sys-color-on-success-container, #007041);
192
+ }
193
+
194
+ :host([variant='error']) .notification {
195
+ background: var(--md-sys-color-error-container, #FFD7C7);
196
+ color: var(--md-sys-color-on-error-container, #942500);
197
+ }
198
+
199
+ :host([variant='warning']) .notification {
200
+ background: var(--md-sys-color-warning-container, #FEEEA0);
201
+ color: var(--md-sys-color-on-warning-container, #6B5600);
202
+ }
203
+
204
+ :host([variant='info']) .notification {
205
+ background: var(--md-sys-color-info-container, #D6F1FF);
206
+ color: var(--md-sys-color-on-info-container, #1E00BE);
207
+ }
208
+
209
+ .notification a {
210
+ text-decoration: underline;
211
+ text-decoration-thickness: 1px;
212
+ text-underline-offset: 0.1578em;
213
+ }
214
+
215
+ .notification a:hover {
216
+ text-decoration-thickness: 2px;
217
+ }
218
+
219
+ .notification-main {
220
+ display: flex;
221
+ flex: 1 1 auto;
222
+ min-width: 0;
223
+ }
224
+
225
+ .notification-main.horizontal {
226
+ flex-direction: row;
227
+ column-gap: var(--scb-notification-main-horizontal-gap);
228
+ row-gap: 0;
229
+ align-items: flex-start;
230
+ }
231
+
232
+ .notification-main.vertical {
233
+ flex-direction: column;
234
+ column-gap: 0;
235
+ row-gap: var(--scb-notification-main-vertical-gap);
236
+ align-items: flex-start;
237
+ }
238
+
239
+ .notification-leading-icon {
240
+ display: flex;
241
+ align-items: flex-start;
242
+ justify-content: center;
243
+ flex: 0 0 auto;
244
+ margin-top: 2px;
245
+ }
246
+
247
+ .notification-leading-icon md-icon {
248
+ font-size: var(--scb-notification-icon-size);
249
+ }
250
+
251
+ .notification-text-container {
252
+ display: flex;
253
+ flex-direction: column;
254
+ gap: var(--scb-notification-text-container-gap);
255
+ font-family: var(--brand-font, "Inter", sans-serif);
256
+ font-style: normal;
257
+ min-width: 0;
258
+ }
259
+
260
+ .notification-text-container.no-gap {
261
+ gap: 0;
262
+ }
263
+
264
+ .notification-title-container{
265
+ display: flex;
266
+ flex-direction: column;
267
+ }
268
+
269
+ .notification-title {
270
+ font-size: var(--scb-notification-title-size);
271
+ font-weight: var(--weight-bold, 700);
272
+ line-height: var(--scb-notification-title-line-height);
273
+ letter-spacing: var(--scb-notification-title-letter-spacing);
274
+ white-space: normal;
275
+ word-break: normal;
276
+ overflow-wrap: normal;
277
+ hyphens: auto;
278
+ overflow: visible;
279
+ text-overflow: clip;
280
+ }
281
+
282
+ .notification-subtitle {
283
+ font-size: var(--scb-notification-subtitle-size);
284
+ font-weight: var(--weight-semibold, 600);
285
+ line-height: var(--scb-notification-subtitle-line-height);
286
+ letter-spacing: var(--scb-notification-subtitle-letter-spacing);
287
+ white-space: normal;
288
+ word-break: normal;
289
+ overflow-wrap: normal;
290
+ hyphens: auto;
291
+ overflow: visible;
292
+ text-overflow: clip;
293
+ }
294
+
295
+ .notification-text {
296
+ font-size: var(--scb-notification-text-size);
297
+ font-weight: var(--weight-regular, 400);
298
+ line-height: var(--scb-notification-text-line-height);
299
+ letter-spacing: var(--scb-notification-text-letter-spacing);
300
+
301
+ white-space: normal;
302
+ word-break: normal;
303
+ overflow-wrap: normal;
304
+ hyphens: auto;
305
+ overflow: visible;
306
+ text-overflow: clip;
307
+ }
308
+
309
+ .notification-footer {
310
+ font-size: var(--scb-notification-footer-size);
311
+ margin-top: 4px;
312
+ line-height: var(--scb-notification-footer-line-height);
313
+ }
314
+
315
+ .footer-link {
316
+ display: inline-block;
317
+ vertical-align: middle;
318
+ transition: box-shadow 0.25s cubic-bezier(0.4, 0, 0.2, 1);
319
+ }
320
+
321
+ .footer-link:focus-visible {
322
+ outline: none;
323
+ border-radius: 4px;
324
+ animation: growShrinkRing 0.25s cubic-bezier(0.4, 0, 0.2, 1);
325
+ box-shadow: 0 0 0 2px var(--md-sys-color-primary, #1976d2);
326
+ }
327
+
328
+ .notification-close-button {
329
+ flex: 0 0 auto;
330
+ display: flex;
331
+ align-items: flex-start;
332
+ justify-content: flex-end;
333
+ }
334
+
335
+ /* Justering så att krysset linjerar bättre med ikon / titel */
336
+ .notification-close-button scb-icon-button {
337
+ margin-top: -5px;
338
+ }
339
+
340
+ @keyframes growShrinkRing {
341
+ 0% {
342
+ box-shadow: 0 0 0 2px var(--md-sys-color-primary, #1976d2);
343
+ }
344
+ 50% {
345
+ box-shadow: 0 0 0 7px var(--md-sys-color-primary, #1976d2);
346
+ }
347
+ 100% {
348
+ box-shadow: 0 0 0 2px var(--md-sys-color-primary, #1976d2);
349
+ }
350
+ }
351
+ `];
352
+ }
353
+ _iconForVariant() {
354
+ switch (this.variant) {
355
+ case "success": return "check_circle";
356
+ case "error": return "error";
357
+ case "warning": return "warning";
358
+ default: return "info";
359
+ }
360
+ }
361
+ __resolveSpacingToken(e) {
362
+ let t = (e ?? "").trim();
363
+ return t ? /^\d+$/.test(t) ? `var(--spacing-${Math.max(0, Math.min(14, parseInt(t, 10)))})` : t : "";
364
+ }
365
+ __applySpacing() {
366
+ let e = this.__resolveSpacingToken(this.spacingTop || this.spacing), t = this.__resolveSpacingToken(this.spacingBottom || this.spacing), n = this.__resolveSpacingToken(this.spacingLeft || this.spacing), r = this.__resolveSpacingToken(this.spacingRight || this.spacing);
367
+ e ? this.style.marginBlockStart = e : this.style.removeProperty("margin-block-start"), t ? this.style.marginBlockEnd = t : this.style.removeProperty("margin-block-end"), n ? this.style.marginInlineStart = n : this.style.removeProperty("margin-inline-start"), r ? this.style.marginInlineEnd = r : this.style.removeProperty("margin-inline-end");
368
+ }
369
+ updated(e) {
370
+ super.updated(e), e.has("width") && (this.width && this.width.trim() !== "" ? this.style.inlineSize = this.width : this.style.removeProperty("inline-size")), e.has("maxWidth") && (this.maxWidth && this.maxWidth.trim() !== "" ? this.style.maxInlineSize = this.maxWidth : this.style.removeProperty("max-inline-size")), e.has("height") && (this.height && this.height.trim() !== "" ? this.style.blockSize = this.height : this.style.removeProperty("block-size")), e.has("maxHeight") && (this.maxHeight && this.maxHeight.trim() !== "" ? this.style.maxBlockSize = this.maxHeight : this.style.removeProperty("max-block-size")), (e.has("spacing") || e.has("spacingTop") || e.has("spacingBottom") || e.has("spacingLeft") || e.has("spacingRight")) && this.__applySpacing();
371
+ }
372
+ render() {
373
+ let e = this.direction === "vertical" ? "vertical" : "horizontal", t = !!(this.#e || this.subtitle), n = !!(this.supportingText && !this.#e && !this.subtitle && !this.linkText), i = this.variant === "success" ? "--_icon-color: var(--md-sys-color-on-success-container, #007041);" : this.variant === "error" ? "--_icon-color: var(--md-sys-color-on-error-container, #942500);" : this.variant === "warning" ? "--_icon-color: var(--md-sys-color-on-warning-container, #6B5600);" : "--_icon-color: var(--md-sys-color-on-info-container, #1E00BE);", a = this.linkHref && this.linkHref !== "#" ? this.linkHref : this.href || this.linkHref;
374
+ return r`
375
+ <div class="notification" type=${this.variant} role="alert" aria-live="assertive" aria-atomic="true">
376
+ <div class="notification-main ${e}">
377
+ ${this.showIcon ? r`
378
+ <div class="notification-leading-icon">
379
+ <md-icon aria-hidden="true">${this._iconForVariant()}</md-icon>
380
+ </div>
381
+ ` : null}
382
+ <div class="notification-text-container ${n ? "no-gap" : ""}">
383
+ ${t ? r`
384
+ <div class="notification-title-container">
385
+ ${this.#e ? r`<div class="notification-title">${this.#e}</div>` : null}
386
+ ${this.subtitle ? r`<div class="notification-subtitle">${this.subtitle}</div>` : null}
387
+ </div>
388
+ ` : null}
389
+ ${this.supportingText ? r`<div class="notification-text">${this.supportingText}</div>` : null}
390
+ ${this.linkText ? r`
391
+ <div class="notification-footer">
392
+ <a class="footer-link" href="${a}">${this.linkText}</a>
393
+ </div>
394
+ ` : null}
395
+ </div>
396
+ </div>
397
+ ${this.showCloseButton ? r`
398
+ <div class="notification-close-button">
399
+ <scb-icon-button
400
+ aria-label="Stäng meddelande"
401
+ icon="close"
402
+ style=${i}
403
+ @click=${this._closeNotification}
404
+ >
405
+ </scb-icon-button>
406
+ </div>
407
+ ` : null}
408
+ </div>
409
+ <md-focus-ring></md-focus-ring>
410
+ `;
411
+ }
412
+ };
413
+ e([a({ type: String })], o.prototype, "variant", void 0), e([a({
414
+ type: String,
415
+ reflect: !0
416
+ })], o.prototype, "direction", void 0), e([a({
417
+ type: String,
418
+ reflect: !0
419
+ })], o.prototype, "size", void 0), e([a({ type: String })], o.prototype, "title", void 0), e([a({
420
+ type: String,
421
+ attribute: "notification-card-title"
422
+ })], o.prototype, "notificationCardTitle", void 0), e([a({ type: String })], o.prototype, "subtitle", void 0), e([a({
423
+ type: String,
424
+ attribute: "supporting-text"
425
+ })], o.prototype, "supportingText", void 0), e([a({
426
+ type: Boolean,
427
+ reflect: !0
428
+ })], o.prototype, "open", void 0), e([a({
429
+ type: String,
430
+ attribute: "link-text"
431
+ })], o.prototype, "linkText", void 0), e([a({
432
+ type: String,
433
+ attribute: "link-href"
434
+ })], o.prototype, "linkHref", void 0), e([a({ type: String })], o.prototype, "href", void 0), e([a({
435
+ type: Boolean,
436
+ attribute: "show-icon"
437
+ })], o.prototype, "showIcon", void 0), e([a({
438
+ type: Boolean,
439
+ attribute: "show-close-button"
440
+ })], o.prototype, "showCloseButton", void 0), e([a({
441
+ type: String,
442
+ reflect: !0
443
+ })], o.prototype, "sizing", void 0), e([a({
444
+ type: String,
445
+ reflect: !0
446
+ })], o.prototype, "width", void 0), e([a({
447
+ type: String,
448
+ reflect: !0,
449
+ attribute: "max-width"
450
+ })], o.prototype, "maxWidth", void 0), e([a({
451
+ type: String,
452
+ reflect: !0
453
+ })], o.prototype, "height", void 0), e([a({
454
+ type: String,
455
+ reflect: !0,
456
+ attribute: "max-height"
457
+ })], o.prototype, "maxHeight", void 0), e([a({
458
+ type: Boolean,
459
+ reflect: !0,
460
+ attribute: "full-height"
461
+ })], o.prototype, "fullHeight", void 0), e([a({
462
+ type: Boolean,
463
+ reflect: !0,
464
+ attribute: "full-width"
465
+ })], o.prototype, "fullWidth", void 0), e([a({ type: String })], o.prototype, "spacing", void 0), e([a({
466
+ type: String,
467
+ attribute: "spacing-top"
468
+ })], o.prototype, "spacingTop", void 0), e([a({
469
+ type: String,
470
+ attribute: "spacing-bottom"
471
+ })], o.prototype, "spacingBottom", void 0), e([a({
472
+ type: String,
473
+ attribute: "spacing-left"
474
+ })], o.prototype, "spacingLeft", void 0), e([a({
475
+ type: String,
476
+ attribute: "spacing-right"
477
+ })], o.prototype, "spacingRight", void 0), o = e([i("scb-notification-card")], o);
478
+ //#endregion
479
+ export { o as ScbNotificationCard };
@@ -0,0 +1,218 @@
1
+ import { __decorate as e } from "../_virtual/_@oxc-project_runtime@0.126.0/helpers/decorate.js";
2
+ import "../scb-divider/scb-divider.js";
3
+ import { LitElement as t, css as n, html as r } from "lit";
4
+ import { customElement as i, property as a } from "lit/decorators.js";
5
+ import "@material/web/focus/md-focus-ring.js";
6
+ import "@material/web/icon/icon.js";
7
+ import "@material/web/ripple/ripple.js";
8
+ //#region src/scb-test-components/scb-options-menu/scb-options-menu-item.ts
9
+ var o = class extends t {
10
+ constructor(...e) {
11
+ super(...e), this.label = "", this.hasSubMenu = !1, this.openLeft = !1, this.divider = !1, this.leadingIcon = "", this.trailingIcon = "", this.itemHref = "", this.href = "", this._observedSubMenu = null, this._syncSubMenuFlags = () => {
12
+ let e = this.nextElementSibling, t = !!(e && e.tagName === "SCB-OPTIONS-SUB-MENU"), n = !!(t && e.hasAttribute("open-left"));
13
+ t !== this.hasSubMenu && (this.hasSubMenu = t), n !== this.openLeft && (this.openLeft = n);
14
+ let r = t ? e : null;
15
+ r !== this._observedSubMenu && (this._subMenuAttrObserver?.disconnect(), this._subMenuAttrObserver = void 0, this._observedSubMenu = r, r && (this._subMenuAttrObserver = new MutationObserver(() => this._syncSubMenuFlags()), this._subMenuAttrObserver.observe(r, {
16
+ attributes: !0,
17
+ attributeFilter: ["open-left"]
18
+ })));
19
+ }, this.handleClick = (e) => {
20
+ this._effectiveHref ? this._navigateToHref(e) : this._toggleSubMenu();
21
+ }, this._onBlur = (e) => {
22
+ let t = this.closest("scb-options-sub-menu");
23
+ if (t && t.open) {
24
+ let n = e.relatedTarget;
25
+ (!n || !t.contains(n)) && (t.dispatchEvent(new CustomEvent("hide-submenu", {
26
+ bubbles: !0,
27
+ composed: !0
28
+ })), t.dispatchEvent(new CustomEvent("hidesubmenu", {
29
+ bubbles: !0,
30
+ composed: !0
31
+ })));
32
+ }
33
+ }, this._onFocus = () => {
34
+ let e = this.nextElementSibling;
35
+ this.classList.contains("open-submenu") && (e && e.tagName === "SCB-OPTIONS-SUB-MENU" && e.hasAttribute("open") || this.classList.remove("open-submenu"));
36
+ }, this._onKeyDown = (e) => {
37
+ if (e.key === "Enter" || e.key === " ") {
38
+ e.preventDefault(), this.handleClick(e);
39
+ return;
40
+ }
41
+ if (e.key === "ArrowDown") {
42
+ e.preventDefault();
43
+ let t = this.nextElementSibling;
44
+ for (; t && t.tagName !== "SCB-OPTIONS-MENU-ITEM";) t = t.nextElementSibling;
45
+ t && (t.shadowRoot?.querySelector("li"))?.focus();
46
+ return;
47
+ }
48
+ if (e.key === "ArrowUp") {
49
+ e.preventDefault();
50
+ let t = this.previousElementSibling;
51
+ for (; t && t.tagName !== "SCB-OPTIONS-MENU-ITEM";) t = t.previousElementSibling;
52
+ t && (t.shadowRoot?.querySelector("li"))?.focus();
53
+ return;
54
+ }
55
+ if (e.key === "ArrowRight") {
56
+ e.preventDefault();
57
+ let t = this.nextElementSibling;
58
+ t && t.tagName === "SCB-OPTIONS-SUB-MENU" && (t.hasAttribute("open") || (this._toggleSubMenu(), t.dispatchEvent(new CustomEvent("show-submenu", {
59
+ bubbles: !0,
60
+ composed: !0
61
+ })), t.dispatchEvent(new CustomEvent("showsubmenu", {
62
+ bubbles: !0,
63
+ composed: !0
64
+ }))), setTimeout(() => {
65
+ let e = t.querySelector("scb-options-menu-item");
66
+ e && (e.shadowRoot?.querySelector("li"))?.focus();
67
+ }, 0));
68
+ return;
69
+ }
70
+ if (e.key === "ArrowLeft") {
71
+ e.preventDefault();
72
+ let t = this.nextElementSibling;
73
+ if (t && t.tagName === "SCB-OPTIONS-SUB-MENU" && t.hasAttribute("open")) {
74
+ this._toggleSubMenu(), t.dispatchEvent(new CustomEvent("hide-submenu", {
75
+ bubbles: !0,
76
+ composed: !0
77
+ })), t.dispatchEvent(new CustomEvent("hidesubmenu", {
78
+ bubbles: !0,
79
+ composed: !0
80
+ }));
81
+ return;
82
+ }
83
+ let n = this.closest("scb-options-sub-menu");
84
+ if (n) {
85
+ let e = n.previousElementSibling;
86
+ e && e.tagName === "SCB-OPTIONS-MENU-ITEM" && (e.shadowRoot?.querySelector("li"))?.focus();
87
+ }
88
+ return;
89
+ }
90
+ };
91
+ }
92
+ static {
93
+ this.styles = n`
94
+ :host {
95
+ display: block;
96
+ }
97
+ :host li{
98
+ position: relative;
99
+ list-style: none;
100
+ padding: var(--scb-options-menu-item-padding-block, var(--spacing-3, 8px)) var(--scb-options-menu-item-padding-inline, var(--spacing-5, 16px));
101
+ cursor: pointer;
102
+ min-height: var(--scb-options-menu-item-min-height, 56px);
103
+ display: flex;
104
+ gap: var(--scb-options-menu-item-gap, var(--spacing-4, 12px));
105
+ align-items: center;
106
+
107
+ }
108
+ :host li .label {
109
+ font-size: var(--scb-options-menu-label-font-size, var(--md-sys-typescale-body-large-size));
110
+ line-height: var(--scb-options-menu-label-line-height, var(--md-sys-typescale-body-large-line-height));
111
+ letter-spacing: var(--scb-options-menu-label-letter-spacing, var(--md-sys-typescale-body-large-tracking));
112
+ }
113
+ :host li md-focus-ring {
114
+ border-radius: var(--md-sys-shape-corner-small);
115
+ position: absolute;
116
+ inset: 0;
117
+ pointer-events: none;
118
+ z-index: 1;
119
+ }
120
+ :host li md-icon {
121
+ --md-icon-size: var(--scb-options-menu-icon-size, 24px);
122
+ }
123
+ :host li md-icon.ti {
124
+ margin-left: auto;
125
+ }
126
+ :host li a {
127
+ display: flex;
128
+ gap: var(--scb-options-menu-item-gap, var(--spacing-4, 12px));
129
+ align-items: center;
130
+ color: var(--md-sys-color-on-surface);
131
+ text-decoration: none;
132
+ width: 100%;
133
+ }
134
+ :host(.open-submenu) li {
135
+ background: var(--md-sys-color-secondary-container);
136
+ }
137
+ :host li:focus {
138
+ outline: none;
139
+ }
140
+ `;
141
+ }
142
+ get _effectiveHref() {
143
+ return this.itemHref || this.href;
144
+ }
145
+ connectedCallback() {
146
+ super.connectedCallback(), this._syncSubMenuFlags(), this._subMenuChildObserver ??= new MutationObserver(() => this._syncSubMenuFlags()), this._subMenuChildObserver.disconnect();
147
+ let e = this.parentElement;
148
+ e && this._subMenuChildObserver.observe(e, { childList: !0 });
149
+ }
150
+ disconnectedCallback() {
151
+ this._subMenuChildObserver?.disconnect(), this._subMenuAttrObserver?.disconnect(), this._subMenuChildObserver = void 0, this._subMenuAttrObserver = void 0, this._observedSubMenu = null, super.disconnectedCallback();
152
+ }
153
+ render() {
154
+ return r`
155
+ ${this.divider ? r`<scb-divider></scb-divider>` : ""}
156
+ <li @click=${this.handleClick} @keydown=${this._onKeyDown} @blur=${this._onBlur} @focus=${this._onFocus} role="menuitem" tabindex="0">
157
+
158
+
159
+ <md-focus-ring inward></md-focus-ring>
160
+ ${this._effectiveHref ? r`<a href="${this._effectiveHref}">
161
+ ${this.leadingIcon ? r`<md-icon>${this.leadingIcon}</md-icon>` : ""}
162
+ <div class="label">${this.label}</div>
163
+ ${this.trailingIcon ? r`<md-icon class="ti">${this.trailingIcon}</md-icon>` : ""}
164
+ <md-ripple></md-ripple>
165
+ </a>` : r`
166
+ ${this.leadingIcon ? r`<md-icon>${this.leadingIcon}</md-icon>` : ""}
167
+ <div class="label">${this.label}</div>
168
+ ${this.trailingIcon ? r`<md-icon class="ti">${this.trailingIcon}</md-icon>` : ""}
169
+ <md-ripple></md-ripple>
170
+ `}
171
+ </li>
172
+ `;
173
+ }
174
+ _navigateToHref(e) {
175
+ let t = this._effectiveHref;
176
+ if (!t) return;
177
+ let n = { href: t }, r = !this.dispatchEvent(new CustomEvent("item-navigate", {
178
+ detail: n,
179
+ bubbles: !0,
180
+ composed: !0,
181
+ cancelable: !0
182
+ })) || !this.dispatchEvent(new CustomEvent("itemnavigate", {
183
+ detail: n,
184
+ bubbles: !0,
185
+ composed: !0,
186
+ cancelable: !0
187
+ }));
188
+ e.preventDefault(), e.stopPropagation(), r || (window.location.href = t);
189
+ }
190
+ _toggleSubMenu() {
191
+ let e = this.nextElementSibling;
192
+ e && e.tagName === "SCB-OPTIONS-SUB-MENU" && (this.classList.toggle("open-submenu"), e.hasAttribute("open") ? (e.dispatchEvent(new CustomEvent("hide-submenu", {
193
+ bubbles: !0,
194
+ composed: !0
195
+ })), e.dispatchEvent(new CustomEvent("hidesubmenu", {
196
+ bubbles: !0,
197
+ composed: !0
198
+ }))) : (e.dispatchEvent(new CustomEvent("show-submenu", {
199
+ bubbles: !0,
200
+ composed: !0
201
+ })), e.dispatchEvent(new CustomEvent("showsubmenu", {
202
+ bubbles: !0,
203
+ composed: !0
204
+ }))));
205
+ }
206
+ };
207
+ e([a({ type: String })], o.prototype, "label", void 0), e([a({ type: Boolean })], o.prototype, "hasSubMenu", void 0), e([a({ type: Boolean })], o.prototype, "openLeft", void 0), e([a({ type: Boolean })], o.prototype, "divider", void 0), e([a({
208
+ type: String,
209
+ attribute: "leading-icon"
210
+ })], o.prototype, "leadingIcon", void 0), e([a({
211
+ type: String,
212
+ attribute: "trailing-icon"
213
+ })], o.prototype, "trailingIcon", void 0), e([a({
214
+ type: String,
215
+ attribute: "item-href"
216
+ })], o.prototype, "itemHref", void 0), e([a({ type: String })], o.prototype, "href", void 0), o = e([i("scb-options-menu-item")], o);
217
+ //#endregion
218
+ export { o as ScbOptionsMenuItem };