@ds-mo/ui 3.0.0 → 3.1.0

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 (456) hide show
  1. package/dist/.build-stamp +1 -1
  2. package/dist/angular/angular-component-lib/utils.d.ts +9 -0
  3. package/dist/angular/angular-component-lib/utils.js +58 -0
  4. package/dist/angular/boolean-value-accessor.d.ts +9 -0
  5. package/dist/angular/boolean-value-accessor.js +37 -0
  6. package/dist/angular/ds-app-shell.d.ts +12 -0
  7. package/dist/angular/ds-app-shell.js +38 -0
  8. package/dist/angular/ds-badge.d.ts +12 -0
  9. package/dist/angular/ds-badge.js +38 -0
  10. package/dist/angular/ds-banner.d.ts +15 -0
  11. package/dist/angular/ds-banner.js +42 -0
  12. package/dist/angular/ds-bar-nav.d.ts +18 -0
  13. package/dist/angular/ds-bar-nav.js +42 -0
  14. package/dist/angular/ds-button-filled.d.ts +15 -0
  15. package/dist/angular/ds-button-filled.js +43 -0
  16. package/dist/angular/ds-button-unfilled.d.ts +17 -0
  17. package/dist/angular/ds-button-unfilled.js +46 -0
  18. package/dist/angular/ds-card-data-viz-donut.d.ts +18 -0
  19. package/dist/angular/ds-card-data-viz-donut.js +42 -0
  20. package/dist/angular/ds-card-setting.d.ts +18 -0
  21. package/dist/angular/ds-card-setting.js +42 -0
  22. package/dist/angular/ds-card.d.ts +12 -0
  23. package/dist/angular/ds-card.js +38 -0
  24. package/dist/angular/ds-chart-bar.d.ts +12 -0
  25. package/dist/angular/ds-chart-bar.js +38 -0
  26. package/dist/angular/ds-chart-donut.d.ts +19 -0
  27. package/dist/angular/ds-chart-donut.js +42 -0
  28. package/dist/angular/ds-chart-legend.d.ts +30 -0
  29. package/dist/angular/ds-chart-legend.js +45 -0
  30. package/dist/angular/ds-chart-line.d.ts +12 -0
  31. package/dist/angular/ds-chart-line.js +38 -0
  32. package/dist/angular/ds-checkbox.d.ts +15 -0
  33. package/dist/angular/ds-checkbox.js +42 -0
  34. package/dist/angular/ds-chip.d.ts +18 -0
  35. package/dist/angular/ds-chip.js +42 -0
  36. package/dist/angular/ds-divider.d.ts +12 -0
  37. package/dist/angular/ds-divider.js +38 -0
  38. package/dist/angular/ds-empty-state.d.ts +12 -0
  39. package/dist/angular/ds-empty-state.js +38 -0
  40. package/dist/angular/ds-field.d.ts +12 -0
  41. package/dist/angular/ds-field.js +38 -0
  42. package/dist/angular/ds-icon.d.ts +12 -0
  43. package/dist/angular/ds-icon.js +38 -0
  44. package/dist/angular/ds-input.d.ts +17 -0
  45. package/dist/angular/ds-input.js +46 -0
  46. package/dist/angular/ds-loader.d.ts +12 -0
  47. package/dist/angular/ds-loader.js +38 -0
  48. package/dist/angular/ds-menu.d.ts +24 -0
  49. package/dist/angular/ds-menu.js +48 -0
  50. package/dist/angular/ds-modal.d.ts +15 -0
  51. package/dist/angular/ds-modal.js +42 -0
  52. package/dist/angular/ds-pagination.d.ts +15 -0
  53. package/dist/angular/ds-pagination.js +42 -0
  54. package/dist/angular/ds-panel-nav.d.ts +42 -0
  55. package/dist/angular/ds-panel-nav.js +58 -0
  56. package/dist/angular/ds-panel-tools.d.ts +33 -0
  57. package/dist/angular/ds-panel-tools.js +49 -0
  58. package/dist/angular/ds-radio-group.d.ts +15 -0
  59. package/dist/angular/ds-radio-group.js +42 -0
  60. package/dist/angular/ds-select.d.ts +18 -0
  61. package/dist/angular/ds-select.js +42 -0
  62. package/dist/angular/ds-shell-gradient-picker.d.ts +16 -0
  63. package/dist/angular/ds-shell-gradient-picker.js +42 -0
  64. package/dist/angular/ds-shell-gradient-swatch.d.ts +16 -0
  65. package/dist/angular/ds-shell-gradient-swatch.js +42 -0
  66. package/dist/angular/ds-skeleton.d.ts +12 -0
  67. package/dist/angular/ds-skeleton.js +38 -0
  68. package/dist/angular/ds-slider.d.ts +15 -0
  69. package/dist/angular/ds-slider.js +42 -0
  70. package/dist/angular/ds-tab-group-nav.d.ts +20 -0
  71. package/dist/angular/ds-tab-group-nav.js +46 -0
  72. package/dist/angular/ds-tab-group.d.ts +15 -0
  73. package/dist/angular/ds-tab-group.js +42 -0
  74. package/dist/angular/ds-table.d.ts +33 -0
  75. package/dist/angular/ds-table.js +48 -0
  76. package/dist/angular/ds-tag.d.ts +12 -0
  77. package/dist/angular/ds-tag.js +38 -0
  78. package/dist/angular/ds-text.d.ts +12 -0
  79. package/dist/angular/ds-text.js +38 -0
  80. package/dist/angular/ds-toggle.d.ts +15 -0
  81. package/dist/angular/ds-toggle.js +42 -0
  82. package/dist/angular/ds-tooltip-data-viz.d.ts +12 -0
  83. package/dist/angular/ds-tooltip-data-viz.js +38 -0
  84. package/dist/angular/ds-tooltip.d.ts +12 -0
  85. package/dist/angular/ds-tooltip.js +38 -0
  86. package/dist/angular/index.d.ts +2 -0
  87. package/dist/angular/index.js +43 -0
  88. package/dist/angular/proxies.d.ts +44 -0
  89. package/dist/angular/proxies.js +45 -0
  90. package/dist/angular/radio-value-accessor.d.ts +8 -0
  91. package/dist/angular/radio-value-accessor.js +34 -0
  92. package/dist/angular/select-value-accessor.d.ts +8 -0
  93. package/dist/angular/select-value-accessor.js +34 -0
  94. package/dist/angular/text-value-accessor.d.ts +8 -0
  95. package/dist/angular/text-value-accessor.js +34 -0
  96. package/dist/angular/value-accessor.d.ts +18 -0
  97. package/dist/angular/value-accessor.js +39 -0
  98. package/dist/components/ds-badge.js +1 -1
  99. package/dist/components/ds-banner.js +1 -1
  100. package/dist/components/ds-bar-nav.js +1 -1
  101. package/dist/components/ds-bar-nav.js.map +1 -1
  102. package/dist/components/ds-button-filled.js +1 -1
  103. package/dist/components/ds-button-unfilled.js +1 -1
  104. package/dist/components/ds-card-data-viz-donut.js +1 -1
  105. package/dist/components/ds-card-data-viz-donut.js.map +1 -1
  106. package/dist/components/ds-card-setting.js +1 -1
  107. package/dist/components/ds-card-setting.js.map +1 -1
  108. package/dist/components/ds-card.js +1 -1
  109. package/dist/components/ds-chart-donut.js +1 -1
  110. package/dist/components/ds-chart-donut.js.map +1 -1
  111. package/dist/components/ds-chart-legend.js +1 -1
  112. package/dist/components/ds-chart-legend.js.map +1 -1
  113. package/dist/components/ds-checkbox.js +1 -1
  114. package/dist/components/ds-checkbox.js.map +1 -1
  115. package/dist/components/ds-chip.js +1 -1
  116. package/dist/components/ds-chip.js.map +1 -1
  117. package/dist/components/ds-empty-state.js +1 -1
  118. package/dist/components/ds-empty-state.js.map +1 -1
  119. package/dist/components/ds-field.js +1 -1
  120. package/dist/components/ds-input.js +1 -1
  121. package/dist/components/ds-input.js.map +1 -1
  122. package/dist/components/ds-menu.js +1 -1
  123. package/dist/components/ds-modal.js +1 -1
  124. package/dist/components/ds-pagination.js +1 -1
  125. package/dist/components/ds-pagination.js.map +1 -1
  126. package/dist/components/ds-panel-nav.js +1 -1
  127. package/dist/components/ds-panel-nav.js.map +1 -1
  128. package/dist/components/ds-panel-tools.js +1 -1
  129. package/dist/components/ds-panel-tools.js.map +1 -1
  130. package/dist/components/ds-radio-group.js +1 -1
  131. package/dist/components/ds-radio-group.js.map +1 -1
  132. package/dist/components/ds-select.js +1 -1
  133. package/dist/components/ds-select.js.map +1 -1
  134. package/dist/components/ds-shell-gradient-picker.js +1 -1
  135. package/dist/components/ds-shell-gradient-swatch.js +1 -1
  136. package/dist/components/ds-slider.js +1 -1
  137. package/dist/components/ds-tab-group-nav.js +1 -1
  138. package/dist/components/ds-tab-group.js +1 -1
  139. package/dist/components/ds-tab-group.js.map +1 -1
  140. package/dist/components/ds-table.js +1 -1
  141. package/dist/components/ds-table.js.map +1 -1
  142. package/dist/components/ds-tag.js +1 -1
  143. package/dist/components/ds-text.js +1 -1
  144. package/dist/components/ds-toggle.js +1 -1
  145. package/dist/components/ds-toggle.js.map +1 -1
  146. package/dist/components/ds-tooltip-data-viz.js +1 -1
  147. package/dist/components/ds-tooltip.js +1 -1
  148. package/dist/components/index.js +1 -1
  149. package/dist/components/index.js.map +1 -1
  150. package/dist/components/p-BBpASejH.js +2 -0
  151. package/dist/components/p-BBpASejH.js.map +1 -0
  152. package/dist/components/{p-V2qW8NL0.js → p-BFiaUYu7.js} +2 -2
  153. package/dist/components/p-BFiaUYu7.js.map +1 -0
  154. package/dist/components/p-BOQRM49Q.js +2 -0
  155. package/dist/components/{p-sBx2MuF2.js.map → p-BOQRM49Q.js.map} +1 -1
  156. package/dist/components/p-CTK82RIw.js +2 -0
  157. package/dist/components/p-CTK82RIw.js.map +1 -0
  158. package/dist/components/{p-BSNlp8Di.js → p-Cp86p-11.js} +2 -2
  159. package/dist/components/{p-BSNlp8Di.js.map → p-Cp86p-11.js.map} +1 -1
  160. package/dist/components/{p-DQ3l2TXw.js → p-DEgY_Lnb.js} +2 -2
  161. package/dist/components/{p-CNgNgezy.js → p-DHjjwgku.js} +2 -2
  162. package/dist/components/{p-CNgNgezy.js.map → p-DHjjwgku.js.map} +1 -1
  163. package/dist/components/p-DI8rHm9u.js +2 -0
  164. package/dist/components/p-DI8rHm9u.js.map +1 -0
  165. package/dist/components/p-DMD-RO1W.js +2 -0
  166. package/dist/components/p-DMD-RO1W.js.map +1 -0
  167. package/dist/components/{p-BVNJnFI9.js → p-DOEMwKBb.js} +2 -2
  168. package/dist/components/{p-BVNJnFI9.js.map → p-DOEMwKBb.js.map} +1 -1
  169. package/dist/components/p-DolYlDbY.js +2 -0
  170. package/dist/components/p-DolYlDbY.js.map +1 -0
  171. package/dist/framework/angular.d.ts +6 -0
  172. package/dist/framework/angular.js +6 -0
  173. package/dist/lib/utils/format-compact-number.d.ts +1 -1
  174. package/dist/lib/utils/index.js +8 -1
  175. package/dist/lib/utils/index.js.map +2 -2
  176. package/dist/react/components.d.ts +44 -0
  177. package/{src/react/components.ts → dist/react/components.js} +0 -1
  178. package/dist/react/ds-app-shell.d.ts +9 -0
  179. package/dist/react/ds-app-shell.js +12 -0
  180. package/dist/react/ds-badge.d.ts +9 -0
  181. package/dist/react/ds-badge.js +12 -0
  182. package/dist/react/ds-banner.d.ts +12 -0
  183. package/dist/react/ds-banner.js +12 -0
  184. package/dist/react/ds-bar-nav.d.ts +12 -0
  185. package/dist/react/ds-bar-nav.js +12 -0
  186. package/dist/react/ds-button-filled.d.ts +12 -0
  187. package/dist/react/ds-button-filled.js +12 -0
  188. package/dist/react/ds-button-unfilled.d.ts +13 -0
  189. package/dist/react/ds-button-unfilled.js +15 -0
  190. package/dist/react/ds-card-data-viz-donut.d.ts +12 -0
  191. package/dist/react/ds-card-data-viz-donut.js +12 -0
  192. package/dist/react/ds-card-setting.d.ts +12 -0
  193. package/dist/react/ds-card-setting.js +12 -0
  194. package/dist/react/ds-card.d.ts +9 -0
  195. package/dist/react/ds-card.js +12 -0
  196. package/dist/react/ds-chart-bar.d.ts +9 -0
  197. package/dist/react/ds-chart-bar.js +12 -0
  198. package/dist/react/ds-chart-donut.d.ts +12 -0
  199. package/dist/react/ds-chart-donut.js +12 -0
  200. package/dist/react/ds-chart-legend.d.ts +16 -0
  201. package/dist/react/ds-chart-legend.js +15 -0
  202. package/dist/react/ds-chart-line.d.ts +9 -0
  203. package/dist/react/ds-chart-line.js +12 -0
  204. package/dist/react/ds-checkbox.d.ts +12 -0
  205. package/dist/react/ds-checkbox.js +12 -0
  206. package/dist/react/ds-chip.d.ts +12 -0
  207. package/dist/react/ds-chip.js +12 -0
  208. package/dist/react/ds-divider.d.ts +9 -0
  209. package/dist/react/ds-divider.js +12 -0
  210. package/dist/react/ds-empty-state.d.ts +9 -0
  211. package/dist/react/ds-empty-state.js +12 -0
  212. package/dist/react/ds-field.d.ts +9 -0
  213. package/dist/react/ds-field.js +12 -0
  214. package/dist/react/ds-icon.d.ts +9 -0
  215. package/dist/react/ds-icon.js +12 -0
  216. package/dist/react/ds-input.d.ts +13 -0
  217. package/dist/react/ds-input.js +15 -0
  218. package/dist/react/ds-loader.d.ts +9 -0
  219. package/dist/react/ds-loader.js +12 -0
  220. package/dist/react/ds-menu.d.ts +14 -0
  221. package/dist/react/ds-menu.js +16 -0
  222. package/dist/react/ds-modal.d.ts +12 -0
  223. package/dist/react/ds-modal.js +12 -0
  224. package/dist/react/ds-pagination.d.ts +12 -0
  225. package/dist/react/ds-pagination.js +12 -0
  226. package/dist/react/ds-panel-nav.d.ts +17 -0
  227. package/dist/react/ds-panel-nav.js +19 -0
  228. package/dist/react/ds-panel-tools.d.ts +17 -0
  229. package/dist/react/ds-panel-tools.js +16 -0
  230. package/dist/react/ds-radio-group.d.ts +12 -0
  231. package/dist/react/ds-radio-group.js +12 -0
  232. package/dist/react/ds-select.d.ts +12 -0
  233. package/dist/react/ds-select.js +12 -0
  234. package/dist/react/ds-shell-gradient-picker.d.ts +12 -0
  235. package/dist/react/ds-shell-gradient-picker.js +12 -0
  236. package/dist/react/ds-shell-gradient-swatch.d.ts +12 -0
  237. package/dist/react/ds-shell-gradient-swatch.js +12 -0
  238. package/dist/react/ds-skeleton.d.ts +9 -0
  239. package/dist/react/ds-skeleton.js +12 -0
  240. package/dist/react/ds-slider.d.ts +12 -0
  241. package/dist/react/ds-slider.js +12 -0
  242. package/dist/react/ds-tab-group-nav.d.ts +13 -0
  243. package/dist/react/ds-tab-group-nav.js +15 -0
  244. package/dist/react/ds-tab-group.d.ts +12 -0
  245. package/dist/react/ds-tab-group.js +12 -0
  246. package/dist/react/ds-table.d.ts +21 -0
  247. package/dist/react/ds-table.js +16 -0
  248. package/dist/react/ds-tag.d.ts +9 -0
  249. package/dist/react/ds-tag.js +12 -0
  250. package/dist/react/ds-text.d.ts +9 -0
  251. package/dist/react/ds-text.js +12 -0
  252. package/dist/react/ds-toggle.d.ts +12 -0
  253. package/dist/react/ds-toggle.js +12 -0
  254. package/dist/react/ds-tooltip-data-viz.d.ts +9 -0
  255. package/dist/react/ds-tooltip-data-viz.js +12 -0
  256. package/dist/react/ds-tooltip.d.ts +9 -0
  257. package/dist/react/ds-tooltip.js +12 -0
  258. package/dist/types/components/BarNav/BarNav.d.ts +1 -0
  259. package/dist/types/components/ButtonFilled/ButtonFilled.d.ts +1 -1
  260. package/dist/types/components/ButtonUnfilled/ButtonUnfilled.d.ts +1 -1
  261. package/dist/types/components/CardDataVizDonut/CardDataVizDonut.d.ts +1 -0
  262. package/dist/types/components/CardSetting/CardSetting.d.ts +3 -0
  263. package/dist/types/components/ChartDonut/ChartDonut.d.ts +2 -0
  264. package/dist/types/components/ChartLegend/ChartLegend.d.ts +1 -0
  265. package/dist/types/components/Checkbox/Checkbox.d.ts +12 -0
  266. package/dist/types/components/Chip/Chip.d.ts +2 -0
  267. package/dist/types/components/EmptyState/EmptyState.d.ts +2 -0
  268. package/dist/types/components/Input/Input.d.ts +14 -1
  269. package/dist/types/components/Menu/Menu.d.ts +2 -0
  270. package/dist/types/components/Pagination/Pagination.d.ts +3 -0
  271. package/dist/types/components/PanelNav/PanelNav.d.ts +7 -0
  272. package/dist/types/components/PanelTools/PanelTools.d.ts +2 -0
  273. package/dist/types/components/RadioGroup/RadioGroup.d.ts +13 -1
  274. package/dist/types/components/Select/Select.d.ts +13 -1
  275. package/dist/types/components/ShellGradientPicker/ShellGradientPicker.d.ts +1 -0
  276. package/dist/types/components/ShellGradientSwatch/ShellGradientSwatch.d.ts +1 -1
  277. package/dist/types/components/TabGroup/TabGroup.d.ts +1 -1
  278. package/dist/types/components/TabGroupNav/TabGroupNav.d.ts +1 -1
  279. package/dist/types/components/Table/Table.d.ts +6 -0
  280. package/dist/types/components/Text/Text.d.ts +2 -1
  281. package/dist/types/components/Toggle/Toggle.d.ts +12 -0
  282. package/dist/types/components/Tooltip/Tooltip.d.ts +6 -0
  283. package/dist/types/components.d.ts +527 -32
  284. package/dist/types/stencil-public-runtime.d.ts +1 -0
  285. package/dist/types/utils/format-compact-number.d.ts +1 -1
  286. package/package.json +58 -41
  287. package/dist/components/p-B_ENgncs.js +0 -2
  288. package/dist/components/p-B_ENgncs.js.map +0 -1
  289. package/dist/components/p-CQmul5NK.js +0 -2
  290. package/dist/components/p-CQmul5NK.js.map +0 -1
  291. package/dist/components/p-CsaW5gDM.js +0 -2
  292. package/dist/components/p-CsaW5gDM.js.map +0 -1
  293. package/dist/components/p-DEpLlQZK.js +0 -2
  294. package/dist/components/p-DEpLlQZK.js.map +0 -1
  295. package/dist/components/p-DRqJ3RUb.js +0 -2
  296. package/dist/components/p-DRqJ3RUb.js.map +0 -1
  297. package/dist/components/p-V2qW8NL0.js.map +0 -1
  298. package/dist/components/p-sBx2MuF2.js +0 -2
  299. package/src/angular/angular-component-lib/utils.ts +0 -65
  300. package/src/angular/index.ts +0 -45
  301. package/src/angular/proxies.ts +0 -1156
  302. package/src/react/ds-app-shell.ts +0 -26
  303. package/src/react/ds-badge.ts +0 -26
  304. package/src/react/ds-banner.ts +0 -27
  305. package/src/react/ds-bar-nav.ts +0 -27
  306. package/src/react/ds-button-filled.ts +0 -27
  307. package/src/react/ds-button-unfilled.ts +0 -33
  308. package/src/react/ds-card-data-viz-donut.ts +0 -27
  309. package/src/react/ds-card-setting.ts +0 -27
  310. package/src/react/ds-card.ts +0 -26
  311. package/src/react/ds-chart-bar.ts +0 -26
  312. package/src/react/ds-chart-donut.ts +0 -27
  313. package/src/react/ds-chart-legend.ts +0 -33
  314. package/src/react/ds-chart-line.ts +0 -26
  315. package/src/react/ds-checkbox.ts +0 -27
  316. package/src/react/ds-chip.ts +0 -27
  317. package/src/react/ds-divider.ts +0 -26
  318. package/src/react/ds-empty-state.ts +0 -26
  319. package/src/react/ds-field.ts +0 -26
  320. package/src/react/ds-icon.ts +0 -26
  321. package/src/react/ds-input.ts +0 -33
  322. package/src/react/ds-loader.ts +0 -26
  323. package/src/react/ds-menu.ts +0 -35
  324. package/src/react/ds-modal.ts +0 -27
  325. package/src/react/ds-pagination.ts +0 -27
  326. package/src/react/ds-panel-nav.ts +0 -41
  327. package/src/react/ds-panel-tools.ts +0 -35
  328. package/src/react/ds-radio-group.ts +0 -27
  329. package/src/react/ds-select.ts +0 -27
  330. package/src/react/ds-shell-gradient-picker.ts +0 -27
  331. package/src/react/ds-shell-gradient-swatch.ts +0 -27
  332. package/src/react/ds-skeleton.ts +0 -26
  333. package/src/react/ds-slider.ts +0 -27
  334. package/src/react/ds-tab-group-nav.ts +0 -33
  335. package/src/react/ds-tab-group.ts +0 -27
  336. package/src/react/ds-table.ts +0 -35
  337. package/src/react/ds-tag.ts +0 -26
  338. package/src/react/ds-text.ts +0 -26
  339. package/src/react/ds-toggle.ts +0 -27
  340. package/src/react/ds-tooltip-data-viz.ts +0 -26
  341. package/src/react/ds-tooltip.ts +0 -26
  342. package/src/wc/components/AppShell/AppShell.tsx +0 -377
  343. package/src/wc/components/Badge/Badge.tsx +0 -179
  344. package/src/wc/components/Badge/index.ts +0 -1
  345. package/src/wc/components/Banner/Banner.tsx +0 -156
  346. package/src/wc/components/BarNav/BarNav.tsx +0 -742
  347. package/src/wc/components/BarNav/bar-nav-dom-utils.ts +0 -23
  348. package/src/wc/components/BarNav/bar-nav-tabs-menu-utils.ts +0 -114
  349. package/src/wc/components/BarNav/bar-nav-types.ts +0 -3
  350. package/src/wc/components/BarNav/bar-nav-utils.ts +0 -67
  351. package/src/wc/components/BarNav/index.ts +0 -2
  352. package/src/wc/components/ButtonFilled/ButtonFilled.tsx +0 -171
  353. package/src/wc/components/ButtonFilled/index.ts +0 -7
  354. package/src/wc/components/ButtonUnfilled/ButtonUnfilled.tsx +0 -229
  355. package/src/wc/components/ButtonUnfilled/index.ts +0 -7
  356. package/src/wc/components/Card/Card.tsx +0 -78
  357. package/src/wc/components/Card/index.ts +0 -1
  358. package/src/wc/components/CardDataVizDonut/CardDataVizDonut.tsx +0 -108
  359. package/src/wc/components/CardDataVizDonut/index.ts +0 -1
  360. package/src/wc/components/CardSetting/CardSetting.tsx +0 -81
  361. package/src/wc/components/CardSetting/index.ts +0 -1
  362. package/src/wc/components/ChartBar/ChartBar.tsx +0 -88
  363. package/src/wc/components/ChartBar/index.ts +0 -1
  364. package/src/wc/components/ChartDonut/ChartDonut.tsx +0 -289
  365. package/src/wc/components/ChartDonut/index.ts +0 -1
  366. package/src/wc/components/ChartLegend/ChartLegend.tsx +0 -125
  367. package/src/wc/components/ChartLegend/index.ts +0 -2
  368. package/src/wc/components/ChartLine/ChartLine.tsx +0 -102
  369. package/src/wc/components/ChartLine/index.ts +0 -1
  370. package/src/wc/components/Checkbox/Checkbox.tsx +0 -60
  371. package/src/wc/components/Checkbox/index.ts +0 -1
  372. package/src/wc/components/Chip/Chip.tsx +0 -104
  373. package/src/wc/components/Chip/index.ts +0 -1
  374. package/src/wc/components/Divider/Divider.tsx +0 -107
  375. package/src/wc/components/Divider/index.ts +0 -2
  376. package/src/wc/components/EmptyState/EmptyState.tsx +0 -30
  377. package/src/wc/components/Field/Field.tsx +0 -30
  378. package/src/wc/components/Icon/Icon.tsx +0 -172
  379. package/src/wc/components/Icon/flag-icon-catalog.ts +0 -36
  380. package/src/wc/components/Icon/icon-cache.ts +0 -47
  381. package/src/wc/components/Icon/icon-svg.ts +0 -73
  382. package/src/wc/components/Icon/index.ts +0 -1
  383. package/src/wc/components/Icon/system-icon-catalog.ts +0 -401
  384. package/src/wc/components/Input/Input.tsx +0 -107
  385. package/src/wc/components/Input/index.ts +0 -1
  386. package/src/wc/components/Loader/Loader.tsx +0 -99
  387. package/src/wc/components/Loader/index.ts +0 -1
  388. package/src/wc/components/Menu/Menu.tsx +0 -437
  389. package/src/wc/components/Menu/menu-placement.ts +0 -26
  390. package/src/wc/components/Menu/menu-position.ts +0 -78
  391. package/src/wc/components/Menu/menu-types.ts +0 -39
  392. package/src/wc/components/Modal/Modal.tsx +0 -213
  393. package/src/wc/components/Pagination/Pagination.tsx +0 -97
  394. package/src/wc/components/PanelNav/PanelNav.tsx +0 -707
  395. package/src/wc/components/PanelNav/index.ts +0 -17
  396. package/src/wc/components/PanelNav/panel-nav-types.ts +0 -36
  397. package/src/wc/components/PanelNav/panel-nav-utils.ts +0 -79
  398. package/src/wc/components/PanelTools/PanelTools.tsx +0 -366
  399. package/src/wc/components/PanelTools/index.ts +0 -7
  400. package/src/wc/components/PanelTools/panel-tools-types.ts +0 -44
  401. package/src/wc/components/PanelTools/panel-tools-utils.ts +0 -50
  402. package/src/wc/components/RadioGroup/RadioGroup.tsx +0 -130
  403. package/src/wc/components/RadioGroup/index.ts +0 -1
  404. package/src/wc/components/Select/Select.tsx +0 -274
  405. package/src/wc/components/Select/index.ts +0 -1
  406. package/src/wc/components/ShellGradientPicker/ShellGradientPicker.tsx +0 -55
  407. package/src/wc/components/ShellGradientSwatch/ShellGradientSwatch.tsx +0 -69
  408. package/src/wc/components/ShellGradientSwatch/shell-gradient-swatch-types.ts +0 -17
  409. package/src/wc/components/Skeleton/Skeleton.tsx +0 -64
  410. package/src/wc/components/Skeleton/index.ts +0 -1
  411. package/src/wc/components/Slider/Slider.tsx +0 -76
  412. package/src/wc/components/Slider/index.ts +0 -1
  413. package/src/wc/components/TabGroup/TabGroup.tsx +0 -204
  414. package/src/wc/components/TabGroup/tab-item-utils.ts +0 -25
  415. package/src/wc/components/TabGroupNav/TabGroupNav.tsx +0 -347
  416. package/src/wc/components/Table/Table.tsx +0 -273
  417. package/src/wc/components/Tag/Tag.tsx +0 -63
  418. package/src/wc/components/Tag/index.ts +0 -1
  419. package/src/wc/components/Text/Text.tsx +0 -98
  420. package/src/wc/components/Text/index.ts +0 -12
  421. package/src/wc/components/Text/text-types.ts +0 -23
  422. package/src/wc/components/Text/text-utils.ts +0 -13
  423. package/src/wc/components/Toggle/Toggle.tsx +0 -43
  424. package/src/wc/components/Toggle/index.ts +0 -1
  425. package/src/wc/components/Tooltip/Tooltip.tsx +0 -372
  426. package/src/wc/components/TooltipDataViz/TooltipDataViz.tsx +0 -145
  427. package/src/wc/components/TooltipDataViz/index.ts +0 -1
  428. package/src/wc/components.d.ts +0 -3569
  429. package/src/wc/nav/badge-gradient-ring.ts +0 -109
  430. package/src/wc/nav/chrome-transition.ts +0 -62
  431. package/src/wc/nav/index.ts +0 -80
  432. package/src/wc/nav/nav-chrome.ts +0 -47
  433. package/src/wc/nav/shell-chrome-metrics.ts +0 -49
  434. package/src/wc/nav/shell-gradient-presets.ts +0 -60
  435. package/src/wc/nav/shell-gradient.ts +0 -94
  436. package/src/wc/nav/shell-shortcuts.ts +0 -63
  437. package/src/wc/nav/shell-view-transition.ts +0 -122
  438. package/src/wc/utils/chart-colors.ts +0 -7
  439. package/src/wc/utils/chart-types.ts +0 -25
  440. package/src/wc/utils/control-density.css +0 -43
  441. package/src/wc/utils/control-inactive.css +0 -20
  442. package/src/wc/utils/control-text.ts +0 -11
  443. package/src/wc/utils/control-width.css +0 -28
  444. package/src/wc/utils/control-width.ts +0 -10
  445. package/src/wc/utils/focus-ring.css +0 -33
  446. package/src/wc/utils/format-compact-number.ts +0 -27
  447. package/src/wc/utils/index.ts +0 -27
  448. package/src/wc/utils/interaction-fill.css +0 -162
  449. package/src/wc/utils/resolve-css-length-px.ts +0 -66
  450. package/src/wc/utils/resolve-css-time-ms.ts +0 -46
  451. package/src/wc/utils/scroll-edge-fade.css +0 -80
  452. package/src/wc/utils/scroll-edge-fade.ts +0 -148
  453. package/src/wc/utils/token-defaults.ts +0 -81
  454. package/src/wc/utils/truncate-svg-text.ts +0 -25
  455. package/src/wc/utils/typography.css +0 -146
  456. /package/dist/components/{p-DQ3l2TXw.js.map → p-DEgY_Lnb.js.map} +0 -0
@@ -1,125 +0,0 @@
1
- import { Component, Prop, State, Event, EventEmitter, h, Host } from '@stencil/core';
2
- import { categoryColor } from '../../utils/chart-colors';
3
- import { formatCompactNumber } from '../../utils';
4
- import type { ChartLegendItem } from '../../utils/chart-types';
5
-
6
- export type ChartLegendDirection = 'vertical' | 'horizontal';
7
-
8
- const DIMMED_OPACITY = 0.25;
9
-
10
- /**
11
- * Base legend for `ds-chart-*` components. Webapp's Overview widgets each style
12
- * legends differently (list w/ values, compact chips, bare swatches, external
13
- * stat callouts) — this covers the common "swatch + label + optional value" case.
14
- * Consumers who need a different treatment skip this component entirely and
15
- * render their own markup against the same `ChartDatum[]` data.
16
- */
17
- @Component({
18
- tag: 'ds-chart-legend',
19
- styleUrl: 'ChartLegend.css',
20
- scoped: true,
21
- })
22
- export class ChartLegend {
23
- /** Legend entries. Set as a JS property (not an HTML attribute). */
24
- @Prop() items: ChartLegendItem[] = [];
25
- @Prop() direction: ChartLegendDirection = 'vertical';
26
- /** Show each item's share of the total (of items with a `value`) alongside its count. */
27
- @Prop() showPercentage: boolean = true;
28
- /**
29
- * Externally controlled highlight, matched by `label` — e.g. drive this from a sibling
30
- * chart's `dsSliceHover` event to keep chart and legend hover in sync. Only dims the other
31
- * rows' opacity (like a chart dimming its other slices) — it never shows the hover-fill,
32
- * since that's reserved for a real pointer/keyboard interaction on this row.
33
- */
34
- @Prop() activeLabel: string | null = null;
35
-
36
- /** Own pointer/focus hover, kept separate from `activeLabel` so the hover-fill (a "you can
37
- * click here" affordance) never shows just because an external row was synced in. */
38
- @State() private hoveredLabel: string | null = null;
39
-
40
- /** Fires on row hover/focus with the item, or `null` on leave/blur. */
41
- @Event() dsItemHover!: EventEmitter<ChartLegendItem | null>;
42
- /** Fires when a deep-linkable row (`item.href` set) is activated. */
43
- @Event() dsItemClick!: EventEmitter<{ item: ChartLegendItem; originalEvent: MouseEvent }>;
44
-
45
- private handleHover(item: ChartLegendItem | null) {
46
- this.hoveredLabel = item?.label ?? null;
47
- this.dsItemHover.emit(item);
48
- }
49
-
50
- private handleClick = (item: ChartLegendItem, originalEvent: MouseEvent) => {
51
- this.dsItemClick.emit({ item, originalEvent });
52
- };
53
-
54
- render() {
55
- const total = this.items.reduce((sum, item) => sum + (item.value ?? 0), 0);
56
- // Highlight/dim from either this component's own hover or an externally-synced label
57
- // (e.g. a sibling ds-chart-donut slice) — same mechanism ds-chart-donut uses for its slices.
58
- const highlightLabel = this.activeLabel ?? this.hoveredLabel;
59
-
60
- return (
61
- <Host class={{ 'chart-legend': true, [`chart-legend--${this.direction}`]: true }}>
62
- {/* mouseleave lives on the list, not each row — the row-gap between items is still
63
- inside the list's box, so crossing it while moving between rows never fires this.
64
- Only actually leaving the whole list does, and that clears with no delay. */}
65
- <ul class="chart-legend__list" onMouseLeave={() => this.handleHover(null)}>
66
- {this.items.map((item, i) => {
67
- const isDimmed = highlightLabel != null && item.label !== highlightLabel;
68
- const RowTag = item.href ? 'a' : 'div';
69
-
70
- return (
71
- <li class="chart-legend__list-item" key={item.label}>
72
- <RowTag
73
- class={{
74
- 'chart-legend__item': true,
75
- 'chart-legend__item--interactive': !!item.href,
76
- 'ds-control--md': true,
77
- 'ds-interaction-fill': true,
78
- 'ds-focus-ring-inset': !!item.href,
79
- }}
80
- style={{ opacity: isDimmed ? String(DIMMED_OPACITY) : '1' }}
81
- href={item.href}
82
- onClick={item.href ? (e: MouseEvent) => this.handleClick(item, e) : undefined}
83
- onMouseEnter={() => this.handleHover(item)}
84
- onFocus={() => this.handleHover(item)}
85
- onBlur={() => this.handleHover(null)}
86
- >
87
- <span class="chart-legend__swatch-box">
88
- <span class="chart-legend__swatch" style={{ backgroundColor: item.color ?? categoryColor(i) }} />
89
- </span>
90
- <ds-text
91
- class="chart-legend__label"
92
- as="span"
93
- variant="text-body-medium"
94
- color="secondary"
95
- lineTruncation={1}
96
- title={item.label}
97
- >
98
- {item.label}
99
- </ds-text>
100
- {item.value != null && (
101
- <ds-text
102
- class="chart-legend__value"
103
- as="span"
104
- variant="text-body-medium"
105
- color="primary"
106
- lineTruncation={1}
107
- title={String(item.value)}
108
- >
109
- {formatCompactNumber(item.value)}
110
- </ds-text>
111
- )}
112
- {item.value != null && this.showPercentage && (
113
- <ds-text class="chart-legend__percentage" as="span" variant="text-body-medium" color="primary">
114
- {(total ? (item.value / total) * 100 : 0).toFixed(1)}%
115
- </ds-text>
116
- )}
117
- </RowTag>
118
- </li>
119
- );
120
- })}
121
- </ul>
122
- </Host>
123
- );
124
- }
125
- }
@@ -1,2 +0,0 @@
1
- export type { ChartLegendDirection } from './ChartLegend';
2
- export type { ChartLegendItem } from '../../utils/chart-types';
@@ -1,102 +0,0 @@
1
- import { Component, Prop, h, Host } from '@stencil/core';
2
- import { line as lineShape } from 'd3-shape';
3
- import { scaleLinear, scalePoint } from 'd3-scale';
4
- import { max } from 'd3-array';
5
- import { categoryColor } from '../../utils/chart-colors';
6
- import type { ChartSeries } from '../../utils/chart-types';
7
-
8
- const MARGIN = { top: 16, right: 16, bottom: 24, left: 32 };
9
-
10
- @Component({
11
- tag: 'ds-chart-line',
12
- styleUrl: 'ChartLine.css',
13
- scoped: true,
14
- })
15
- export class ChartLine {
16
- /** One or more series to plot. Set as a JS property (not an HTML attribute). */
17
- @Prop() series: ChartSeries[] = [];
18
- /** X-axis labels — must match each series' `data` length. Set as a JS property. */
19
- @Prop() categories: string[] = [];
20
- @Prop() width: number = 480;
21
- @Prop() height: number = 240;
22
- @Prop() showPoints: boolean = true;
23
-
24
- render() {
25
- const innerWidth = this.width - MARGIN.left - MARGIN.right;
26
- const innerHeight = this.height - MARGIN.top - MARGIN.bottom;
27
-
28
- const allValues = this.series.flatMap(s => s.data);
29
- const yMax = max(allValues) ?? 0;
30
-
31
- const xScale = scalePoint<number>()
32
- .domain(this.categories.map((_, i) => i))
33
- .range([0, innerWidth]);
34
-
35
- const yScale = scaleLinear()
36
- .domain([0, yMax || 1])
37
- .range([innerHeight, 0])
38
- .nice();
39
-
40
- const lineGenerator = lineShape<number>()
41
- .x((_, i) => xScale(i) ?? 0)
42
- .y(d => yScale(d));
43
-
44
- const yTicks = yScale.ticks(4);
45
-
46
- return (
47
- <Host class="chart-line">
48
- <svg
49
- class="chart-line__svg"
50
- viewBox={`0 0 ${this.width} ${this.height}`}
51
- width={this.width}
52
- height={this.height}
53
- role="img"
54
- aria-label={this.series.map(s => s.name).join(', ')}
55
- >
56
- <g transform={`translate(${MARGIN.left}, ${MARGIN.top})`}>
57
- {yTicks.map(tick => (
58
- <g key={`grid-${tick}`} transform={`translate(0, ${yScale(tick)})`}>
59
- <line class="chart-line__gridline" x1={0} x2={innerWidth} />
60
- <text class="chart-line__axis-label" x={-8} text-anchor="end" dominant-baseline="middle">
61
- {tick}
62
- </text>
63
- </g>
64
- ))}
65
-
66
- {this.categories.map((label, i) => (
67
- <text
68
- key={`x-${label}`}
69
- class="chart-line__axis-label"
70
- x={xScale(i) ?? 0}
71
- y={innerHeight + 16}
72
- text-anchor="middle"
73
- >
74
- {label}
75
- </text>
76
- ))}
77
-
78
- {this.series.map((s, si) => {
79
- const color = s.color ?? categoryColor(si);
80
- return (
81
- <g key={s.name}>
82
- <path class="chart-line__path" d={lineGenerator(s.data) ?? undefined} stroke={color} />
83
- {this.showPoints &&
84
- s.data.map((d, i) => (
85
- <circle
86
- key={`${s.name}-${i}`}
87
- class="chart-line__point"
88
- cx={xScale(i) ?? 0}
89
- cy={yScale(d)}
90
- r={3}
91
- fill={color}
92
- />
93
- ))}
94
- </g>
95
- );
96
- })}
97
- </g>
98
- </svg>
99
- </Host>
100
- );
101
- }
102
- }
@@ -1 +0,0 @@
1
- export type { ChartSeries } from '../../utils/chart-types';
@@ -1,60 +0,0 @@
1
- import { Component, Prop, Event, EventEmitter, h, Host } from '@stencil/core';
2
-
3
- let idCounter = 0;
4
-
5
- @Component({
6
- tag: 'ds-checkbox',
7
- styleUrl: 'Checkbox.css',
8
- scoped: true,
9
- })
10
- export class Checkbox {
11
- private labelId = `ds-checkbox-label-${++idCounter}`;
12
-
13
- @Prop() label!: string;
14
- @Prop({ mutable: true }) checked: boolean = false;
15
- @Prop() indeterminate: boolean = false;
16
- @Prop() isInactive: boolean = false;
17
-
18
- @Event() dsChange!: EventEmitter<boolean>;
19
-
20
- private handleActivate = () => {
21
- if (this.isInactive) return;
22
- this.checked = !this.checked;
23
- this.dsChange.emit(this.checked);
24
- };
25
-
26
- private handleKeyDown = (e: KeyboardEvent) => {
27
- if (e.key === ' ' || e.key === 'Enter') {
28
- e.preventDefault();
29
- this.handleActivate();
30
- }
31
- };
32
-
33
- render() {
34
- const isMarked = this.checked || this.indeterminate;
35
-
36
- return (
37
- <Host
38
- role="checkbox"
39
- aria-checked={this.indeterminate ? 'mixed' : String(this.checked)}
40
- aria-disabled={this.isInactive || undefined}
41
- aria-labelledby={this.labelId}
42
- tabIndex={this.isInactive ? -1 : 0}
43
- class={{ checkbox: true, 'ds-control-inactive': this.isInactive }}
44
- onClick={this.handleActivate}
45
- onKeyDown={this.handleKeyDown}
46
- >
47
- <span class={{ box: true, 'box--marked': isMarked }}>
48
- {isMarked && (
49
- <span class="checkmark" aria-hidden="true">
50
- {this.indeterminate ? '−' : '✓'}
51
- </span>
52
- )}
53
- </span>
54
- <ds-text class="checkbox__label" as="span" variant="text-body-medium" textId={this.labelId}>
55
- {this.label}
56
- </ds-text>
57
- </Host>
58
- );
59
- }
60
- }
@@ -1 +0,0 @@
1
- export type { } from './Checkbox';
@@ -1,104 +0,0 @@
1
- import { Component, Prop, Event, EventEmitter, h, Host } from '@stencil/core';
2
- import { CONTROL_TEXT_VARIANT } from '../../utils';
3
-
4
- /**
5
- * Semantic chip state — replaces Tag’s intent × contrast matrix.
6
- * - `default` — neutral faint
7
- * - `active` — brand faint
8
- * - `error` — negative faint
9
- * - `caution` — caution faint
10
- */
11
- export type ChipState = 'default' | 'active' | 'error' | 'caution';
12
- export type ChipSize = 'md' | 'sm' | 'xs';
13
- export type ChipBackground = 'faint' | 'medium' | 'bold' | 'strong' | 'always-dark';
14
-
15
- /** Dismiss `ds-icon` size — same iconography metrics as Tag’s leading icon. */
16
- const ICON_SIZE: Record<ChipSize, 'md' | 'sm' | 'xs'> = {
17
- md: 'md',
18
- sm: 'sm',
19
- xs: 'xs',
20
- };
21
-
22
- /**
23
- * Removable chip — same density recipe as Tag, but colored by semantic `state`
24
- * (not intent × contrast). Not a toggle/select control; the only intentional
25
- * action is remove.
26
- */
27
- @Component({
28
- tag: 'ds-chip',
29
- styleUrl: 'Chip.css',
30
- scoped: true,
31
- })
32
- export class Chip {
33
- @Prop() label!: string;
34
- /** Semantic color state. @default 'default' */
35
- @Prop() state: ChipState = 'default';
36
- @Prop() size: ChipSize = 'md';
37
- @Prop() rounded: boolean = false;
38
- /** When true (default), shows the trailing dismiss control. */
39
- @Prop() removable: boolean = true;
40
- @Prop() maxWidth: string | number | undefined;
41
- @Prop() isInactive: boolean = false;
42
- /** Surface context for interaction-fill tokens when the chip sits on a non-default surface. */
43
- @Prop() background: ChipBackground | undefined;
44
-
45
- /** Fired when the remove button is clicked. */
46
- @Event() dsRemove!: EventEmitter<void>;
47
-
48
- private handleRemove = (e: MouseEvent) => {
49
- e.stopPropagation();
50
- if (this.isInactive) return;
51
- this.dsRemove.emit();
52
- };
53
-
54
- render() {
55
- const textVariant = CONTROL_TEXT_VARIANT[this.size];
56
- const iconSize = ICON_SIZE[this.size];
57
-
58
- const maxWidthStyle = this.maxWidth != null
59
- ? { maxWidth: typeof this.maxWidth === 'number' ? `${this.maxWidth}px` : this.maxWidth }
60
- : undefined;
61
-
62
- return (
63
- <Host
64
- class={{
65
- 'tag': true,
66
- 'chip': true,
67
- [`chip--${this.state}`]: true,
68
- [`tag--size-${this.size}`]: true,
69
- 'ds-control--md': this.size === 'md',
70
- 'ds-control--sm': this.size === 'sm',
71
- 'ds-control--xs': this.size === 'xs',
72
- 'tag--rounded': this.rounded,
73
- 'tag--removable': this.removable,
74
- /* Hover overlay on the chip surface — dismiss is the only action. */
75
- 'ds-interaction-fill': !this.isInactive && this.removable,
76
- 'ds-interaction-fill--on-medium': this.background === 'medium',
77
- 'ds-interaction-fill--on-bold': this.background === 'bold',
78
- 'ds-interaction-fill--on-strong': this.background === 'strong',
79
- 'ds-interaction-fill--on-always-dark': this.background === 'always-dark',
80
- 'ds-control-inactive': this.isInactive,
81
- }}
82
- style={maxWidthStyle}
83
- aria-disabled={this.isInactive || undefined}
84
- >
85
- <ds-text class="tag__label" as="span" variant={textVariant} color="inherit">
86
- {this.label}
87
- </ds-text>
88
- {this.removable && (
89
- <button
90
- type="button"
91
- class="tag__remove ds-focus-ring-inset"
92
- onClick={this.handleRemove}
93
- aria-label={`Remove ${this.label}`}
94
- disabled={this.isInactive || undefined}
95
- >
96
- <slot name="remove-icon">
97
- <ds-icon class="tag__remove-x" name="Cross" size={iconSize} color="inherit"></ds-icon>
98
- </slot>
99
- </button>
100
- )}
101
- </Host>
102
- );
103
- }
104
- }
@@ -1 +0,0 @@
1
- export type { ChipState, ChipSize, ChipBackground } from './Chip';
@@ -1,107 +0,0 @@
1
- import { Component, Prop, h, Host } from '@stencil/core';
2
-
3
- export type DividerOrientation = 'horizontal' | 'vertical';
4
- export type DividerSurface =
5
- | 'default'
6
- | 'on-bold-background'
7
- | 'on-strong-background'
8
- | 'on-medium-background'
9
- | 'on-translucent-background'
10
- | 'navigation'
11
- | 'media'
12
- | 'always-dark'
13
- | 'inverted';
14
- export type DividerInsetToken =
15
- | 'space-000'
16
- | 'space-012'
17
- | 'space-025'
18
- | 'space-050'
19
- | 'space-075'
20
- | 'space-100'
21
- | 'space-125'
22
- | 'space-150'
23
- | 'space-175'
24
- | 'space-200'
25
- | 'space-250'
26
- | 'space-300'
27
- | 'space-400'
28
- | 'space-600'
29
- | 'space-800';
30
- export type DividerInset = 'none' | DividerInsetToken | (string & {});
31
- export type DividerLength = 'auto' | 'full' | (string & {});
32
-
33
- const INSET_VALUE: Record<'none' | DividerInsetToken, string> = {
34
- none: '0',
35
- 'space-000': 'var(--dimension-space-000)',
36
- 'space-012': 'var(--dimension-space-012)',
37
- 'space-025': 'var(--dimension-space-025)',
38
- 'space-050': 'var(--dimension-space-050)',
39
- 'space-075': 'var(--dimension-space-075)',
40
- 'space-100': 'var(--dimension-space-100)',
41
- 'space-125': 'var(--dimension-space-125)',
42
- 'space-150': 'var(--dimension-space-150)',
43
- 'space-175': 'var(--dimension-space-175)',
44
- 'space-200': 'var(--dimension-space-200)',
45
- 'space-250': 'var(--dimension-space-250)',
46
- 'space-300': 'var(--dimension-space-300)',
47
- 'space-400': 'var(--dimension-space-400)',
48
- 'space-600': 'var(--dimension-space-600)',
49
- 'space-800': 'var(--dimension-space-800)',
50
- };
51
-
52
- @Component({
53
- tag: 'ds-divider',
54
- styleUrl: 'Divider.css',
55
- scoped: true,
56
- })
57
- export class Divider {
58
- /** Direction of the divider line. Defaults to 'horizontal'. */
59
- @Prop() orientation: DividerOrientation = 'horizontal';
60
-
61
- /** Surface context so the divider uses the right TokoMo divider token. */
62
- @Prop() surface: DividerSurface = 'default';
63
-
64
- /** Insets the divider from its start/end edges. Accepts spacing token names or any CSS length. */
65
- @Prop() inset: DividerInset = 'none';
66
-
67
- /** Visual line length. Defaults to filling the available axis. Accepts any CSS length. */
68
- @Prop() length: DividerLength = 'auto';
69
-
70
- /** Expose the divider as a semantic separator. Visual-only dividers are hidden from assistive tech by default. */
71
- @Prop() semantic: boolean = false;
72
-
73
- private resolveInset(): string {
74
- return Object.prototype.hasOwnProperty.call(INSET_VALUE, this.inset)
75
- ? INSET_VALUE[this.inset as keyof typeof INSET_VALUE]
76
- : this.inset;
77
- }
78
-
79
- private resolveLength(): string {
80
- return this.length === 'auto' || this.length === 'full'
81
- ? '100%'
82
- : this.length;
83
- }
84
-
85
- render() {
86
- const isVertical = this.orientation === 'vertical';
87
- const hasCustomLength = this.length !== 'auto' && this.length !== 'full';
88
-
89
- return (
90
- <Host
91
- role={this.semantic ? 'separator' : undefined}
92
- aria-orientation={this.semantic ? this.orientation : undefined}
93
- aria-hidden={this.semantic ? undefined : 'true'}
94
- class={{
95
- divider: true,
96
- 'divider--vertical': isVertical,
97
- 'divider--custom-length': hasCustomLength,
98
- [`divider--surface-${this.surface}`]: true,
99
- }}
100
- style={{
101
- '--_divider-inset': this.resolveInset(),
102
- '--_divider-length': this.resolveLength(),
103
- }}
104
- />
105
- );
106
- }
107
- }
@@ -1,2 +0,0 @@
1
- export type { DividerOrientation } from './Divider';
2
-
@@ -1,30 +0,0 @@
1
- import { Component, Prop, h, Host } from '@stencil/core';
2
-
3
- export type EmptyStateType = 'no-content' | 'no-results' | 'no-results-filter' | 'no-access';
4
-
5
- const DEFAULT_MESSAGES: Record<EmptyStateType, string> = {
6
- 'no-content': 'No page contents to display.',
7
- 'no-results': 'No results found.',
8
- 'no-results-filter': 'No results found. Please update search criteria.',
9
- 'no-access': "You don't have access to this page.",
10
- };
11
-
12
- @Component({
13
- tag: 'ds-empty-state',
14
- styleUrl: 'EmptyState.css',
15
- scoped: true,
16
- })
17
- export class EmptyState {
18
- @Prop() type: EmptyStateType = 'no-content';
19
- @Prop() message: string | undefined;
20
-
21
- render() {
22
- return (
23
- <Host>
24
- <ds-text class="empty-state" as="p" variant="text-body-medium" color="secondary">
25
- {this.message || DEFAULT_MESSAGES[this.type]}
26
- </ds-text>
27
- </Host>
28
- );
29
- }
30
- }
@@ -1,30 +0,0 @@
1
- import { Component, Prop, h, Host } from '@stencil/core';
2
-
3
- let fieldCounter = 0;
4
-
5
- @Component({
6
- tag: 'ds-field',
7
- styleUrl: 'Field.css',
8
- scoped: true,
9
- })
10
- export class Field {
11
- @Prop() label!: string;
12
- /** ID forwarded to the slotted control via the label's `for` attribute. Auto-generated if omitted. */
13
- @Prop() fieldId: string | undefined;
14
-
15
- private resolvedId = `ds-field-${++fieldCounter}`;
16
-
17
- render() {
18
- const id = this.fieldId || this.resolvedId;
19
- return (
20
- <Host>
21
- <div class="field">
22
- <ds-text as="label" variant="text-body-small" emphasis for={id}>
23
- {this.label}
24
- </ds-text>
25
- <slot />
26
- </div>
27
- </Host>
28
- );
29
- }
30
- }