@ebrains/components 0.2.0-alpha.0 → 0.4.0-alpha.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 (347) hide show
  1. package/dist/cjs/{color-3ffe3072.js → color-88793e49.js} +2 -2
  2. package/dist/cjs/color-primary-palette_6.cjs.entry.js +14 -14
  3. package/dist/cjs/components.cjs.js +1 -1
  4. package/dist/cjs/correct-use-of-colors.cjs.entry.js +1 -1
  5. package/dist/cjs/{eds-alert_28.cjs.entry.js → eds-accordion_33.cjs.entry.js} +773 -162
  6. package/dist/cjs/eds-card-project.cjs.entry.js +1 -1
  7. package/dist/cjs/eds-card-section.cjs.entry.js +18 -7
  8. package/dist/cjs/eds-card-tags.cjs.entry.js +1 -1
  9. package/dist/cjs/eds-card-tool.cjs.entry.js +1 -1
  10. package/dist/cjs/eds-card-wrapper.cjs.entry.js +1 -1
  11. package/dist/cjs/eds-code-block.cjs.entry.js +48 -1
  12. package/dist/cjs/eds-components-section.cjs.entry.js +44 -24
  13. package/dist/cjs/eds-docs-palettes.cjs.entry.js +1 -1
  14. package/dist/cjs/eds-docs-tokens.cjs.entry.js +1 -1
  15. package/dist/cjs/eds-login.cjs.entry.js +1 -1
  16. package/dist/cjs/eds-logo-variations.cjs.entry.js +27 -0
  17. package/dist/cjs/eds-matomo-notice.cjs.entry.js +1 -1
  18. package/dist/cjs/{eds-pagination.cjs.entry.js → eds-pagination_2.cjs.entry.js} +184 -9
  19. package/dist/cjs/eds-progress-bar.cjs.entry.js +29 -0
  20. package/dist/cjs/eds-rating.cjs.entry.js +5 -7
  21. package/dist/cjs/eds-svg-repository.cjs.entry.js +7 -1
  22. package/dist/cjs/eds-tabs-content.cjs.entry.js +3 -3
  23. package/dist/cjs/eds-tabs.cjs.entry.js +27 -6
  24. package/dist/cjs/eds-timeline.cjs.entry.js +77 -0
  25. package/dist/cjs/eds-tooltip.cjs.entry.js +11 -1
  26. package/dist/cjs/eds-trl.cjs.entry.js +51 -0
  27. package/dist/cjs/incorrect-use-of-colors.cjs.entry.js +1 -1
  28. package/dist/cjs/index-f08e4f5c.js +20 -44
  29. package/dist/cjs/loader.cjs.js +1 -1
  30. package/dist/cjs/logo-space.cjs.entry.js +1 -1
  31. package/dist/cjs/logo-variations-horizontal_2.cjs.entry.js +36 -0
  32. package/dist/cjs/logo-wrong-usage.cjs.entry.js +2 -2
  33. package/dist/cjs/token-list_3.cjs.entry.js +3 -3
  34. package/dist/cjs/token-ratios.cjs.entry.js +1 -1
  35. package/dist/cjs/token-spacing.cjs.entry.js +1 -1
  36. package/dist/cjs/token-typography.cjs.entry.js +1 -1
  37. package/dist/collection/collection-manifest.json +2 -1
  38. package/dist/collection/components/eds-accordion/eds-accordion.js +11 -20
  39. package/dist/collection/components/eds-alert/eds-alert.js +5 -7
  40. package/dist/collection/components/eds-alert/eds-alert.stories.js +4 -4
  41. package/dist/collection/components/eds-avatar/eds-avatar.js +1 -1
  42. package/dist/collection/components/eds-avatar/eds-avatar.stories.js +24 -22
  43. package/dist/collection/components/eds-block-break/eds-block-break.js +1 -1
  44. package/dist/collection/components/eds-breadcrump/eds-breadcrump.js +14 -12
  45. package/dist/collection/components/eds-button/eds-button.js +3 -3
  46. package/dist/collection/components/eds-cards/eds-card-composer/eds-card-desc/eds-card-desc.js +9 -1
  47. package/dist/collection/components/eds-cards/eds-card-composer/eds-card-tags/eds-card-tags.js +1 -1
  48. package/dist/collection/components/eds-cards/eds-card-composer/eds-card-title/eds-card-title.js +1 -1
  49. package/dist/collection/components/eds-cards/eds-card-composer/eds-card-wrapper/eds-card-wrapper.js +1 -1
  50. package/dist/collection/components/eds-cards/eds-card-generic/eds-card-generic.js +14 -8
  51. package/dist/collection/components/eds-cards/eds-card-generic/eds-card-generic.stories.js +1 -1
  52. package/dist/collection/components/eds-code-block/eds-code-block.js +57 -2
  53. package/dist/collection/components/eds-code-block/eds-code-block.stories.js +78 -0
  54. package/dist/collection/components/eds-dropdown/eds-dropdown.js +11 -21
  55. package/dist/collection/components/eds-form/eds-form.js +41 -31
  56. package/dist/collection/components/eds-form/eds-form.stories.js +0 -3
  57. package/dist/collection/components/eds-frame/eds-frame.stories.js +19 -18
  58. package/dist/collection/components/eds-input-elements/eds-input-select/eds-input-select.js +142 -14
  59. package/dist/collection/components/eds-link/eds-link.js +3 -4
  60. package/dist/collection/components/eds-modal/eds-modal.css +16 -0
  61. package/dist/collection/components/eds-modal/eds-modal.js +71 -29
  62. package/dist/collection/components/eds-modal/eds-modal.stories.js +34 -18
  63. package/dist/collection/components/eds-pagination/eds-pagination.js +13 -9
  64. package/dist/collection/components/eds-rating/eds-rating.js +8 -10
  65. package/dist/collection/components/eds-section/eds-section-core/eds-section-core.stories.js +12 -11
  66. package/dist/collection/components/eds-table/eds-table.css +4 -0
  67. package/dist/collection/components/eds-table/eds-table.js +83 -12
  68. package/dist/collection/components/eds-table/eds-table.stories.js +14 -93
  69. package/dist/collection/components/eds-timeline/eds-timeline.js +27 -16
  70. package/dist/collection/components/eds-toast/eds-toast.js +21 -0
  71. package/dist/collection/components/eds-tooltip/eds-tooltip.js +10 -1
  72. package/dist/collection/components/eds-trl/eds-trl.js +29 -22
  73. package/dist/collection/eds-docs-ui/colors/color-palette/primary.js +1 -1
  74. package/dist/collection/eds-docs-ui/colors/color-palette/secondary.js +1 -1
  75. package/dist/collection/eds-docs-ui/colors/color-palette/support.js +1 -1
  76. package/dist/collection/eds-docs-ui/colors/gradient-palette/primary.js +1 -1
  77. package/dist/collection/eds-docs-ui/colors/gradient-palette/secondary.js +7 -7
  78. package/dist/collection/eds-docs-ui/colors/gradient-palette/support.js +3 -3
  79. package/dist/collection/eds-docs-ui/colors/use-of-colors/correct-use-of-colors.js +1 -1
  80. package/dist/collection/eds-docs-ui/colors/use-of-colors/incorrect-use-of-colors.js +1 -5
  81. package/dist/collection/eds-docs-ui/design-tokens/token-list/token-list.js +1 -1
  82. package/dist/collection/eds-docs-ui/design-tokens/token-radii/token-radii.js +1 -1
  83. package/dist/collection/eds-docs-ui/design-tokens/token-ratios/token-ratios.js +1 -1
  84. package/dist/collection/eds-docs-ui/design-tokens/token-shadows/token-shadows.js +1 -1
  85. package/dist/collection/eds-docs-ui/design-tokens/token-spacing/token-spacing.js +1 -1
  86. package/dist/collection/eds-docs-ui/design-tokens/token-typography/token-typography.js +1 -1
  87. package/dist/collection/eds-docs-ui/eds-components-section/eds-components-section.js +3 -6
  88. package/dist/collection/eds-docs-ui/eds-docs-palettes/eds-docs-palettes.js +1 -1
  89. package/dist/collection/eds-docs-ui/eds-docs-tokens/eds-docs-tokens.js +1 -1
  90. package/dist/collection/eds-docs-ui/eds-logo-variations/eds-logo-variations.js +44 -0
  91. package/dist/collection/eds-docs-ui/eds-svg-repository/eds-svg-repository.js +7 -1
  92. package/dist/collection/eds-docs-ui/functional/angular.js +1 -1
  93. package/dist/collection/eds-docs-ui/functional/installation.js +1 -1
  94. package/dist/collection/eds-docs-ui/functional/overview.js +1 -1
  95. package/dist/collection/eds-docs-ui/functional/react.js +1 -1
  96. package/dist/collection/eds-docs-ui/functional/vue.js +1 -1
  97. package/dist/collection/eds-docs-ui/logo/logo-space/logo-space.js +1 -1
  98. package/dist/collection/eds-docs-ui/logo/logo-variations/horizontal/logo-variations-horizontal.css +21 -1
  99. package/dist/collection/eds-docs-ui/logo/logo-variations/horizontal/logo-variations-horizontal.js +2 -54
  100. package/dist/collection/eds-docs-ui/logo/logo-variations/vertical/logo-variations-vertical.js +4 -13
  101. package/dist/collection/eds-docs-ui/logo/logo-wrong-usage/logo-wrong-usage.css +4 -0
  102. package/dist/collection/eds-docs-ui/logo/logo-wrong-usage/logo-wrong-usage.js +1 -1
  103. package/dist/collection/shared-ui/eds-card-section/eds-card-section.js +22 -10
  104. package/dist/collection/shared-ui/eds-card-section/eds-card-section.stories.js +13 -11
  105. package/dist/collection/shared-ui/eds-footer/eds-footer.js +1 -1
  106. package/dist/collection/shared-ui/eds-fullscreen-menu/eds-fullscreen-menu.js +4 -3
  107. package/dist/collection/shared-ui/eds-fullscreen-menu/eds-fullscreen-menu.stories.js +77 -0
  108. package/dist/collection/shared-ui/eds-header/eds-header.js +9 -5
  109. package/dist/collection/shared-ui/eds-header/eds-header.stories.js +16 -10
  110. package/dist/collection/shared-ui/eds-login/eds-login.js +3 -2
  111. package/dist/collection/shared-ui/eds-social-networks/eds-social-networks.js +4 -4
  112. package/dist/collection/shared-ui/eds-social-networks/eds-social-networks.stories.js +21 -0
  113. package/dist/collection/shared-ui/eds-tabs/eds-tabs.js +29 -8
  114. package/dist/collection/shared-ui/eds-tabs/eds-tabs.stories.js +22 -4
  115. package/dist/collection/shared-ui/eds-tabs-content/eds-tabs-content.js +2 -2
  116. package/dist/collection/shared-ui/eds-toast-manager/eds-toast-manager.css +48 -34
  117. package/dist/collection/shared-ui/eds-toast-manager/eds-toast-manager.js +1 -1
  118. package/dist/collection/shared-ui/eds-user/eds-user.js +12 -6
  119. package/dist/collection/shared-ui/eds-user-modal/eds-user-modal.js +1 -11
  120. package/dist/components/analytics.js +2 -2
  121. package/dist/components/components.css +29 -10
  122. package/dist/components/components.esm.js +1 -1
  123. package/dist/components/correct-use-of-colors.js +1 -1
  124. package/dist/components/eds-accordion2.js +12 -20
  125. package/dist/components/eds-alert2.js +5 -7
  126. package/dist/components/eds-avatar2.js +1 -1
  127. package/dist/components/eds-block-break2.js +1 -1
  128. package/dist/components/eds-breadcrumb.js +14 -12
  129. package/dist/components/eds-button2.js +1 -1
  130. package/dist/components/eds-card-desc2.js +1 -1
  131. package/dist/components/eds-card-generic2.js +3 -3
  132. package/dist/components/eds-card-section.js +18 -7
  133. package/dist/components/eds-card-tags.js +1 -1
  134. package/dist/components/eds-card-title2.js +1 -1
  135. package/dist/components/eds-card-wrapper.js +1 -1
  136. package/dist/components/eds-code-block2.js +48 -1
  137. package/dist/components/eds-components-section.js +44 -24
  138. package/dist/components/eds-docs-palettes.js +1 -1
  139. package/dist/components/eds-docs-tokens.js +1 -1
  140. package/dist/components/eds-dropdown2.js +12 -21
  141. package/dist/components/eds-footer2.js +1 -1
  142. package/dist/components/eds-form.js +37 -12
  143. package/dist/components/eds-header.js +6 -2
  144. package/dist/components/eds-input-select2.js +70 -2
  145. package/dist/components/eds-link2.js +3 -4
  146. package/dist/components/eds-login.js +3 -2
  147. package/dist/components/eds-logo-variations.d.ts +11 -0
  148. package/dist/components/eds-logo-variations.js +60 -0
  149. package/dist/components/eds-modal.js +56 -30
  150. package/dist/components/eds-pagination2.js +13 -9
  151. package/dist/components/eds-rating.js +6 -8
  152. package/dist/components/eds-social-networks.js +2 -2
  153. package/dist/components/eds-social-networks2.js +6 -6
  154. package/dist/components/eds-svg-repository.js +7 -1
  155. package/dist/components/eds-table2.js +50 -14
  156. package/dist/components/eds-tabs-content.js +2 -2
  157. package/dist/components/eds-tabs.js +26 -5
  158. package/dist/components/eds-timeline.js +24 -10
  159. package/dist/components/eds-toast-manager.js +1 -1
  160. package/dist/components/eds-toast2.js +21 -0
  161. package/dist/components/eds-tooltip.js +11 -1
  162. package/dist/components/eds-trl.js +94 -15
  163. package/dist/components/eds-user-modal2.js +1 -5
  164. package/dist/components/eds-user2.js +12 -6
  165. package/dist/components/incorrect-use-of-colors.js +20 -2
  166. package/dist/components/logo-space.js +1 -1
  167. package/dist/components/logo-variations-horizontal.js +2 -50
  168. package/dist/components/logo-variations-horizontal2.js +37 -0
  169. package/dist/components/logo-variations-vertical.js +2 -50
  170. package/dist/components/logo-variations-vertical2.js +42 -0
  171. package/dist/components/logo-wrong-usage.js +2 -2
  172. package/dist/components/p-005de86f.entry.js +1 -0
  173. package/dist/components/{p-5eb32f03.entry.js → p-0910d733.entry.js} +1 -1
  174. package/dist/components/{p-c9c3cc49.entry.js → p-22e6d7d5.entry.js} +1 -1
  175. package/dist/components/p-2851ff44.entry.js +1 -0
  176. package/dist/components/p-29648b47.entry.js +1 -0
  177. package/dist/components/p-2dda1ec4.entry.js +1 -0
  178. package/dist/components/{p-d9788b54.entry.js → p-35ec730b.entry.js} +1 -1
  179. package/dist/components/{p-bb60412b.entry.js → p-435a14c1.entry.js} +1 -1
  180. package/dist/components/{p-e6bfbf51.entry.js → p-5398d652.entry.js} +2 -2
  181. package/dist/components/p-57c964c5.entry.js +1 -0
  182. package/dist/components/p-5a43503a.entry.js +1 -0
  183. package/dist/components/{p-e20ed2c7.entry.js → p-610db2b2.entry.js} +1 -1
  184. package/dist/components/p-6378fb3e.entry.js +1 -0
  185. package/dist/components/p-762c8c83.entry.js +1 -0
  186. package/dist/components/p-7802e966.entry.js +1 -0
  187. package/dist/components/p-832dc95a.entry.js +1 -0
  188. package/dist/components/p-855aa1a3.entry.js +1 -0
  189. package/dist/components/{p-1bcfbaf1.entry.js → p-87830085.entry.js} +1 -1
  190. package/dist/components/p-8ddc67a1.entry.js +1 -0
  191. package/dist/components/p-ab32b3fc.entry.js +1 -0
  192. package/dist/components/p-ac0112d5.entry.js +1 -0
  193. package/dist/components/p-acb16e1c.entry.js +1 -0
  194. package/dist/components/p-ae5dbd41.entry.js +1 -0
  195. package/dist/components/p-b04eff31.entry.js +1 -0
  196. package/dist/components/p-b86a4985.js +1 -0
  197. package/dist/components/{p-9722811d.entry.js → p-ba6bafef.entry.js} +1 -1
  198. package/dist/components/{p-6fc62452.entry.js → p-c3b294a0.entry.js} +1 -1
  199. package/dist/components/p-c6038449.entry.js +1 -0
  200. package/dist/components/p-c72c8fb0.entry.js +1 -0
  201. package/dist/components/p-d53b7a75.entry.js +1 -0
  202. package/dist/components/{p-b717f95a.entry.js → p-d571d530.entry.js} +1 -1
  203. package/dist/components/p-dd6daa96.entry.js +1 -0
  204. package/dist/components/{p-73bd0c97.entry.js → p-df94285c.entry.js} +1 -1
  205. package/dist/components/primary.js +1 -1
  206. package/dist/components/primary2.js +1 -1
  207. package/dist/components/secondary.js +1 -1
  208. package/dist/components/secondary2.js +7 -7
  209. package/dist/components/support.js +1 -1
  210. package/dist/components/support2.js +3 -3
  211. package/dist/components/token-list2.js +1 -1
  212. package/dist/components/token-radii2.js +1 -1
  213. package/dist/components/token-ratios.js +1 -1
  214. package/dist/components/token-shadows2.js +1 -1
  215. package/dist/components/token-spacing.js +1 -1
  216. package/dist/components/token-typography.js +1 -1
  217. package/dist/esm/{color-0ba8ed56.js → color-bb472c37.js} +2 -2
  218. package/dist/esm/color-primary-palette_6.entry.js +14 -14
  219. package/dist/esm/components.js +1 -1
  220. package/dist/esm/correct-use-of-colors.entry.js +1 -1
  221. package/dist/esm/{eds-alert_28.entry.js → eds-accordion_33.entry.js} +767 -161
  222. package/dist/esm/eds-card-project.entry.js +1 -1
  223. package/dist/esm/eds-card-section.entry.js +18 -7
  224. package/dist/esm/eds-card-tags.entry.js +1 -1
  225. package/dist/esm/eds-card-tool.entry.js +1 -1
  226. package/dist/esm/eds-card-wrapper.entry.js +1 -1
  227. package/dist/esm/eds-code-block.entry.js +49 -2
  228. package/dist/esm/eds-components-section.entry.js +44 -24
  229. package/dist/esm/eds-docs-palettes.entry.js +1 -1
  230. package/dist/esm/eds-docs-tokens.entry.js +1 -1
  231. package/dist/esm/eds-login.entry.js +1 -1
  232. package/dist/esm/eds-logo-variations.entry.js +23 -0
  233. package/dist/esm/eds-matomo-notice.entry.js +1 -1
  234. package/dist/esm/{eds-pagination.entry.js → eds-pagination_2.entry.js} +184 -10
  235. package/dist/esm/eds-progress-bar.entry.js +25 -0
  236. package/dist/esm/eds-rating.entry.js +5 -7
  237. package/dist/esm/eds-svg-repository.entry.js +8 -2
  238. package/dist/esm/eds-tabs-content.entry.js +3 -3
  239. package/dist/esm/eds-tabs.entry.js +27 -6
  240. package/dist/esm/eds-timeline.entry.js +73 -0
  241. package/dist/esm/eds-tooltip.entry.js +11 -1
  242. package/dist/esm/eds-trl.entry.js +47 -0
  243. package/dist/esm/incorrect-use-of-colors.entry.js +1 -1
  244. package/dist/esm/index-e96badea.js +20 -44
  245. package/dist/esm/loader.js +1 -1
  246. package/dist/esm/logo-space.entry.js +1 -1
  247. package/dist/esm/logo-variations-horizontal_2.entry.js +31 -0
  248. package/dist/esm/logo-wrong-usage.entry.js +2 -2
  249. package/dist/esm/token-list_3.entry.js +3 -3
  250. package/dist/esm/token-ratios.entry.js +1 -1
  251. package/dist/esm/token-spacing.entry.js +1 -1
  252. package/dist/esm/token-typography.entry.js +1 -1
  253. package/dist/hydrate/index.js +1116 -783
  254. package/dist/hydrate/index.mjs +1116 -783
  255. package/dist/types/components/eds-accordion/eds-accordion.d.ts +5 -12
  256. package/dist/types/components/eds-avatar/eds-avatar.stories.d.ts +0 -18
  257. package/dist/types/components/eds-breadcrump/eds-breadcrump.d.ts +1 -5
  258. package/dist/types/components/eds-button/eds-button.d.ts +2 -2
  259. package/dist/types/components/eds-cards/eds-card-composer/eds-card-desc/eds-card-desc.d.ts +8 -0
  260. package/dist/types/components/eds-cards/eds-card-generic/eds-card-generic.d.ts +6 -2
  261. package/dist/types/components/eds-code-block/eds-code-block.d.ts +43 -3
  262. package/dist/types/components/eds-code-block/eds-code-block.stories.d.ts +54 -0
  263. package/dist/types/components/eds-dropdown/eds-dropdown.d.ts +0 -7
  264. package/dist/types/components/eds-form/eds-form.d.ts +3 -6
  265. package/dist/types/components/eds-form/eds-form.stories.d.ts +0 -5
  266. package/dist/types/components/eds-frame/eds-frame.stories.d.ts +0 -2
  267. package/dist/types/components/eds-input-elements/eds-input-select/eds-input-select.d.ts +108 -2
  268. package/dist/types/components/eds-link/eds-link.d.ts +1 -1
  269. package/dist/types/components/eds-modal/eds-modal.d.ts +18 -3
  270. package/dist/types/components/eds-modal/eds-modal.stories.d.ts +9 -0
  271. package/dist/types/components/eds-rating/eds-rating.d.ts +4 -6
  272. package/dist/types/components/eds-section/eds-section-core/eds-section-core.stories.d.ts +0 -1
  273. package/dist/types/components/eds-table/eds-table.d.ts +9 -1
  274. package/dist/types/components/eds-table/eds-table.stories.d.ts +6 -67
  275. package/dist/types/components/eds-timeline/eds-timeline.d.ts +9 -12
  276. package/dist/types/components/eds-toast/eds-toast.d.ts +9 -0
  277. package/dist/types/components/eds-trl/eds-trl.d.ts +4 -1
  278. package/dist/types/components.d.ts +217 -56
  279. package/dist/types/eds-docs-ui/colors/use-of-colors/incorrect-use-of-colors.d.ts +0 -4
  280. package/dist/types/eds-docs-ui/eds-logo-variations/eds-logo-variations.d.ts +9 -0
  281. package/dist/types/eds-docs-ui/eds-svg-repository/eds-svg-repository.d.ts +2 -0
  282. package/dist/types/eds-docs-ui/logo/logo-variations/horizontal/logo-variations-horizontal.d.ts +1 -7
  283. package/dist/types/eds-docs-ui/logo/logo-variations/vertical/logo-variations-vertical.d.ts +1 -1
  284. package/dist/types/shared-ui/eds-card-section/eds-card-section.d.ts +1 -1
  285. package/dist/types/shared-ui/eds-card-section/eds-card-section.stories.d.ts +42 -2
  286. package/dist/types/shared-ui/eds-fullscreen-menu/eds-fullscreen-menu.d.ts +8 -2
  287. package/dist/types/shared-ui/eds-fullscreen-menu/eds-fullscreen-menu.stories.d.ts +29 -0
  288. package/dist/types/shared-ui/eds-header/eds-header.d.ts +7 -1
  289. package/dist/types/shared-ui/eds-header/eds-header.stories.d.ts +9 -1
  290. package/dist/types/shared-ui/eds-social-networks/eds-social-networks.d.ts +1 -1
  291. package/dist/types/shared-ui/eds-social-networks/eds-social-networks.stories.d.ts +13 -0
  292. package/dist/types/shared-ui/eds-tabs/eds-tabs.d.ts +18 -1
  293. package/dist/types/shared-ui/eds-user/eds-user.d.ts +1 -2
  294. package/package.json +3 -3
  295. package/dist/cjs/eds-accordion.cjs.entry.js +0 -93
  296. package/dist/cjs/eds-block-break.cjs.entry.js +0 -21
  297. package/dist/cjs/eds-breadcrumb.cjs.entry.js +0 -153
  298. package/dist/cjs/eds-footer.cjs.entry.js +0 -50
  299. package/dist/cjs/eds-frame.cjs.entry.js +0 -91
  300. package/dist/cjs/eds-fullscreen-menu.cjs.entry.js +0 -100
  301. package/dist/cjs/eds-modal.cjs.entry.js +0 -86
  302. package/dist/cjs/eds-social-networks.cjs.entry.js +0 -66
  303. package/dist/cjs/eds-table.cjs.entry.js +0 -143
  304. package/dist/cjs/logo-variations-horizontal.cjs.entry.js +0 -31
  305. package/dist/cjs/logo-variations-vertical.cjs.entry.js +0 -31
  306. package/dist/collection/components/eds-trl/eds-trl.css +0 -0
  307. package/dist/collection/shared-ui/eds-user-modal/eds-user-modal.css +0 -0
  308. package/dist/components/p-02e2a62f.entry.js +0 -1
  309. package/dist/components/p-04e47e04.entry.js +0 -1
  310. package/dist/components/p-0a3b2576.entry.js +0 -1
  311. package/dist/components/p-0c99ef81.entry.js +0 -1
  312. package/dist/components/p-272d249f.entry.js +0 -1
  313. package/dist/components/p-2d8508cd.entry.js +0 -1
  314. package/dist/components/p-32f282a9.entry.js +0 -1
  315. package/dist/components/p-373673ca.js +0 -1
  316. package/dist/components/p-3a2e8ef3.entry.js +0 -1
  317. package/dist/components/p-3afafa59.entry.js +0 -1
  318. package/dist/components/p-3b40559e.entry.js +0 -1
  319. package/dist/components/p-42b4ecff.entry.js +0 -1
  320. package/dist/components/p-49958f77.entry.js +0 -1
  321. package/dist/components/p-54c75346.entry.js +0 -1
  322. package/dist/components/p-551c0b58.entry.js +0 -1
  323. package/dist/components/p-559b6ec9.entry.js +0 -1
  324. package/dist/components/p-5ae9722b.entry.js +0 -1
  325. package/dist/components/p-79887c2c.entry.js +0 -1
  326. package/dist/components/p-9000b245.entry.js +0 -1
  327. package/dist/components/p-96c4deda.entry.js +0 -1
  328. package/dist/components/p-b14ef448.entry.js +0 -1
  329. package/dist/components/p-b203eb1b.entry.js +0 -1
  330. package/dist/components/p-b33941a0.entry.js +0 -1
  331. package/dist/components/p-bca40434.entry.js +0 -1
  332. package/dist/components/p-df93db96.entry.js +0 -1
  333. package/dist/components/p-ebed87b8.entry.js +0 -1
  334. package/dist/components/p-ff5de62c.entry.js +0 -1
  335. package/dist/components/p-ffec8755.entry.js +0 -1
  336. package/dist/esm/eds-accordion.entry.js +0 -89
  337. package/dist/esm/eds-block-break.entry.js +0 -17
  338. package/dist/esm/eds-breadcrumb.entry.js +0 -149
  339. package/dist/esm/eds-footer.entry.js +0 -46
  340. package/dist/esm/eds-frame.entry.js +0 -87
  341. package/dist/esm/eds-fullscreen-menu.entry.js +0 -96
  342. package/dist/esm/eds-modal.entry.js +0 -82
  343. package/dist/esm/eds-social-networks.entry.js +0 -62
  344. package/dist/esm/eds-table.entry.js +0 -139
  345. package/dist/esm/logo-variations-horizontal.entry.js +0 -27
  346. package/dist/esm/logo-variations-vertical.entry.js +0 -27
  347. /package/dist/collection/shared-ui/eds-social-networks/{eds-social-network.css → eds-social-networks.css} +0 -0
@@ -17,7 +17,7 @@ const EdsCardDesc = /*@__PURE__*/ proxyCustomElement(class EdsCardDesc extends H
17
17
  return this.truncate && this.truncateLines ? `line-clamp-${this.truncateLines}` : '';
18
18
  }
19
19
  render() {
20
- return (h("p", { key: '017c115ebff999c74cff1eaeb5c63f97e0f6554d', class: `text-light ${this.descClass}` }, h("span", { key: 'f87b9b3d593e417ef351882f426d24c0b206ccab', class: this.getTruncateClass() }, this.description)));
20
+ return (h("p", { key: 'ca38bcc0895d5a0c87fda782ef455e45c4b53263', class: `text-light ${this.descClass}` }, h("span", { key: '3108eec08a760b1db7ce1a7be05b68749f8f930b', class: this.getTruncateClass() }, this.description)));
21
21
  }
22
22
  static get style() { return EdsCardDescStyle0; }
23
23
  }, [1, "eds-card-desc", {
@@ -23,7 +23,7 @@ const EdsCardGeneric = /*@__PURE__*/ proxyCustomElement(class EdsCardGeneric ext
23
23
  this.avatar = undefined;
24
24
  this.shortAbbreviation = undefined;
25
25
  this.headingLevel = 'h3';
26
- this.tags = '';
26
+ this.tags = [];
27
27
  this.tiny = false;
28
28
  this.bg = true;
29
29
  this.withHover = true;
@@ -99,7 +99,7 @@ const EdsCardGeneric = /*@__PURE__*/ proxyCustomElement(class EdsCardGeneric ext
99
99
  });
100
100
  }
101
101
  render() {
102
- return (h("article", { key: '17d1f00f232a4436756fa3846684bbae8c716036', class: this.articleClasses(), onClick: () => this.handleClick() }, h("eds-card-title", { key: 'd99ee1716c4e308a3ea446f0f7cedfaeac30f2ed', "heading-level": this.headingLevel, titleClass: this.image ? 'f-ui-01' : undefined, "card-title": this.cardTitle, url: this.url, hierarchy: this.hierarchy }), this.description && (h("eds-card-desc", { key: 'c5bdc76e68a8d660609630aa8184ec3a9508ab61', class: "mt-8", "truncate-lines": "3", description: this.description })), this.parsedImage ? (h("eds-img", Object.assign({ class: "mt-8" }, this.parsedImage))) : this.avatar || this.shortAbbreviation ? (h("eds-avatar", { class: "order-first mb-12", picture: this.avatar, initials: this.shortAbbreviation })) : null, h("div", { key: 'fa993e3c60d357eb0d9a63e612bdd2bf026e7a85', class: "flex flex-wrap gap-y-4" }, this.parsedTags.map((tag, index) => (h("eds-tag", { key: index, intent: tag.style, label: tag.label })))), ' '));
102
+ return (h("article", { key: '5b498abfc65206fe89c9e54e673a81e1b6ed37d5', class: this.articleClasses(), onClick: () => this.handleClick() }, h("eds-card-title", { key: '61a0c6076957e39ab2a059c8587fc2e716e470bc', "heading-level": this.headingLevel, titleClass: this.image ? 'f-ui-01' : undefined, "card-title": this.cardTitle, url: this.url, hierarchy: this.hierarchy }), this.description && (h("eds-card-desc", { key: '6df3c08512acf60e22001867ab5691aa19f67961', class: "mt-8", "truncate-lines": "3", description: this.description })), this.parsedImage ? (h("eds-img", Object.assign({ class: "mt-8" }, this.parsedImage))) : this.avatar || this.shortAbbreviation ? (h("eds-avatar", { class: "order-first mb-12", picture: this.avatar, initials: this.shortAbbreviation })) : null, h("div", { key: '712193c8afac6744e2512d8b760daf2c850987b9', class: "flex flex-wrap gap-y-4" }, this.parsedTags.map((tag, index) => (h("eds-tag", { key: index, intent: tag.style, label: tag.label })))), ' '));
103
103
  }
104
104
  get el() { return this; }
105
105
  static get style() { return EdsCardGenericStyle0; }
@@ -111,7 +111,7 @@ const EdsCardGeneric = /*@__PURE__*/ proxyCustomElement(class EdsCardGeneric ext
111
111
  "avatar": [1],
112
112
  "shortAbbreviation": [1, "short-abbreviation"],
113
113
  "headingLevel": [1, "heading-level"],
114
- "tags": [8],
114
+ "tags": [1],
115
115
  "tiny": [4],
116
116
  "bg": [4],
117
117
  "withHover": [4, "with-hover"],
@@ -14,7 +14,7 @@ const EdsCardSection$1 = /*@__PURE__*/ proxyCustomElement(class EdsCardSection e
14
14
  super();
15
15
  this.__registerHost();
16
16
  this.__attachShadow();
17
- this.cards = undefined;
17
+ this.cards = [];
18
18
  this.cols = 4;
19
19
  }
20
20
  /**
@@ -24,13 +24,24 @@ const EdsCardSection$1 = /*@__PURE__*/ proxyCustomElement(class EdsCardSection e
24
24
  * @returns {any[]} An array of parsed card objects.
25
25
  */
26
26
  get parsedCards() {
27
- try {
28
- return JSON.parse(this.cards);
27
+ // If it's already an array, return it immediately.
28
+ if (Array.isArray(this.cards)) {
29
+ return this.cards;
29
30
  }
30
- catch (e) {
31
- //console.error('Error parsing links JSON', e);
32
- return [];
31
+ if (typeof this.cards === 'object') {
32
+ return this.cards;
33
33
  }
34
+ else if (typeof this.cards === 'string') {
35
+ try {
36
+ return JSON.parse(this.cards);
37
+ }
38
+ catch (e) {
39
+ // eslint-disable-next-line
40
+ console.error('Error parsing cards prop:', e);
41
+ return [];
42
+ }
43
+ }
44
+ return [];
34
45
  }
35
46
  /**
36
47
  * Renders the card section as a grid layout.
@@ -40,7 +51,7 @@ const EdsCardSection$1 = /*@__PURE__*/ proxyCustomElement(class EdsCardSection e
40
51
  * @returns {JSX.Element} The rendered section containing a list of cards.
41
52
  */
42
53
  render() {
43
- return (h("section", { key: 'f8e6a03e37677623fad3c53327f6260920a5e914', class: "w-full" }, h("ul", { key: '1da1bc3a5aecadd52b4d025d7d02dc252e47b34a', class: "grid-layout gap-y-8 md:gap-y-12 lg:gap-y-16" }, this.parsedCards.map((card) => (h("li", { class: `grid-col-span-12 md:grid-col-span-${this.cols} flex flex-col` }, h("eds-card-generic", { cardTitle: card.title, description: card.description, avatar: card.avatar, headingLevel: card.headingLevel, tags: card.tags, url: card.url, bg: card.bg, tiny: card.tiny, image: card.image, withHover: card.withHover })))))));
54
+ return (h("section", { key: 'da139da167230819e494a6426c2431f209a2e557', class: "w-full" }, h("ul", { key: '3e8affe5c9aee91c4487480c72c437339265101a', class: "grid-layout gap-y-8 md:gap-y-12 lg:gap-y-16" }, this.parsedCards.map((card) => (h("li", { class: `grid-col-span-12 md:grid-col-span-${this.cols} flex flex-col` }, h("eds-card-generic", { cardTitle: card.title, description: card.description, avatar: card.avatar, headingLevel: card.headingLevel, tags: card.tags, url: card.url, bg: card.bg, tiny: card.tiny, image: card.image, withHover: card.withHover })))))));
44
55
  }
45
56
  static get style() { return EdsCardSectionStyle0; }
46
57
  }, [1, "eds-card-section", {
@@ -13,7 +13,7 @@ const EdsCardTags$1 = /*@__PURE__*/ proxyCustomElement(class EdsCardTags extends
13
13
  this.tags = [];
14
14
  }
15
15
  render() {
16
- return (h("div", { key: 'b201dc6df5e809d828a055fb5f01fe798e228361', class: "flex flex-wrap gap-y-4" }, this.tags.map((tag, index) => (h("eds-tag", { key: index, intent: this.accent ? 'accent' : 'default', label: tag })))));
16
+ return (h("div", { key: '60a129de62d45736eba0884cc24c9738f3a0f55c', class: "flex flex-wrap gap-y-4" }, this.tags.map((tag, index) => (h("eds-tag", { key: index, intent: this.accent ? 'accent' : 'default', label: tag })))));
17
17
  }
18
18
  static get style() { return EdsCardTagsStyle0; }
19
19
  }, [1, "eds-card-tags", {
@@ -47,7 +47,7 @@ const EdsCardTitle = /*@__PURE__*/ proxyCustomElement(class EdsCardTitle extends
47
47
  render() {
48
48
  //const Tag = this.getTag();
49
49
  const Heading = this.headingLevel;
50
- return (h(Heading, { key: '8aee3bcb0e04508dd21a03ea0f695e040f37c767', class: this.getTitleClass() }, h("a", { key: 'c5fa27fe86037ed6b039c156aecdf1acc9c7c8bc', class: "break-words after:absolute after:inset-0 after:z-10 after:content-[''] focus:outline-none", href: this.url, target: this.externalLink ? '_blank' : undefined, rel: this.externalLink ? 'noopener noreferrer' : undefined }, this.cardTitle)));
50
+ return (h(Heading, { key: 'a654161b2c53e944eaefb21be7189a5e0acb06cf', class: this.getTitleClass() }, h("a", { key: '868fd911c1a8c366d726e886bfc7827487013e27', class: "break-words after:absolute after:inset-0 after:z-10 after:content-[''] focus:outline-none", href: this.url, target: this.externalLink ? '_blank' : undefined, rel: this.externalLink ? 'noopener noreferrer' : undefined }, this.cardTitle)));
51
51
  }
52
52
  static get style() { return EdsCardTitleStyle0; }
53
53
  }, [1, "eds-card-title", {
@@ -21,7 +21,7 @@ const EdsCardWrapper$1 = /*@__PURE__*/ proxyCustomElement(class EdsCardWrapper e
21
21
  this.withHover ? 'effect-shadow hover:shadow-hover cursor-pointer' : '',
22
22
  'border-softer effect-focus-within relative flex grow flex-col rounded-lg border-2 p-16'
23
23
  ].join(' ');
24
- return (h("article", { key: 'c52f6ad7873050c052b8c0e68b2c812d74f2ddf1', class: articleClasses }, h("slot", { key: 'dac6f9fe339c8baa191ee2fd622332ddf25ec08d' }), this.hasSlot('footer') && (h("div", { key: '301862515ba88f320d1af722bec6120bc3e7d723', class: "mt-auto" }, h("slot", { key: '85d939150663a4586934413c9965aa92a9babeef', name: "footer" })))));
24
+ return (h("article", { key: '7c12b1d147f061e189b5dda5d517ec4eae0c3691', class: articleClasses }, h("slot", { key: 'f506bad73ed38ae36931f88f7d7c5f5d94705e4f' }), this.hasSlot('footer') && (h("div", { key: '783f480be269e4a2f61aa8d4396e757fe41bfcc6', class: "mt-auto" }, h("slot", { key: 'f07ddaa2d930518a5c8ac82efab3cb0dd6647bdd', name: "footer" })))));
25
25
  }
26
26
  get el() { return this; }
27
27
  }, [4, "eds-card-wrapper", {
@@ -2418,12 +2418,58 @@ const EdsCodeBlock = /*@__PURE__*/ proxyCustomElement(class EdsCodeBlock extends
2418
2418
  this.language = undefined;
2419
2419
  this.copied = false;
2420
2420
  }
2421
+ /**
2422
+ * Copies the current code content to the clipboard and sets a temporary copied state.
2423
+ *
2424
+ * @private
2425
+ * @returns {void}
2426
+ */
2421
2427
  copyToClipboard() {
2422
2428
  navigator.clipboard.writeText(this.code).then(() => {
2423
2429
  this.copied = true;
2430
+ /*const analyticsName = this.createHumanFriendlyAnalyticsName(this.code, this.language);
2431
+ sendAnalytics({
2432
+ category: 'ui-component',
2433
+ parentContext: null,
2434
+ tag: this.el.tagName.toLowerCase(),
2435
+ name: analyticsName || '',
2436
+ action: 'copy'
2437
+ });*/
2424
2438
  setTimeout(() => (this.copied = false), 2000);
2425
2439
  });
2426
2440
  }
2441
+ /**
2442
+ * Utility function that creates a human-friendly analytics name based on the code and language.
2443
+ * It uses:
2444
+ * - The language (in uppercase)
2445
+ * - The number of non-empty lines in the code
2446
+ * - The first non-empty line of code (truncated to 30 characters, if needed)
2447
+ *
2448
+ * returns A descriptive analytics name.
2449
+ */
2450
+ /*private createHumanFriendlyAnalyticsName(code: string, language: string): string {
2451
+ // Count non-empty lines
2452
+ const lines = code.split('\n').filter(line => line.trim() !== '').length;
2453
+
2454
+ // Find the first non-empty line and trim it
2455
+ let firstNonEmptyLine = code.split('\n').find(line => line.trim() !== '');
2456
+ firstNonEmptyLine = firstNonEmptyLine ? firstNonEmptyLine.trim() : '';
2457
+
2458
+ // Truncate the snippet if it’s too long
2459
+ if (firstNonEmptyLine.length > 30) {
2460
+ firstNonEmptyLine = firstNonEmptyLine.substring(0, 30) + '...';
2461
+ }
2462
+
2463
+ return `CodeBlock:${language.toLowerCase()}|${lines}-line(s)|${firstNonEmptyLine.toLowerCase()}`;
2464
+ }*/
2465
+ /**
2466
+ * Returns the syntax-highlighted HTML for the code.
2467
+ * If the provided language is supported by Prism, this method returns the highlighted code.
2468
+ * Otherwise, it logs a warning and returns the raw code.
2469
+ *
2470
+ * @private
2471
+ * @returns {string} The highlighted HTML string for the code block.
2472
+ */
2427
2473
  getHighlightedCode() {
2428
2474
  if (this.language && Prism$1.languages[this.language]) {
2429
2475
  return Prism$1.highlight(this.code, Prism$1.languages[this.language], this.language);
@@ -2433,8 +2479,9 @@ const EdsCodeBlock = /*@__PURE__*/ proxyCustomElement(class EdsCodeBlock extends
2433
2479
  return this.code; // Fallback if language is not provided or unsupported
2434
2480
  }
2435
2481
  render() {
2436
- return (h("div", { key: 'a99c0c8b9546b80bb3f9e21cd53c29540e8b6e06', class: "relative bg-stronger rounded-sm" }, h("div", { key: '5856f9d30bb52f791e0d8bb03a6438bc01247f66', class: "text-inverse flex justify-between items-center p-8" }, this.language ? (h("span", { class: "f-ui-03" }, this.language.toUpperCase())) : (h("pre", { class: "bg-stronger pl-8", role: "region", "aria-label": "Code block without language" }, h("code", { innerHTML: this.getHighlightedCode() }))), h("span", { key: 'dfb0f69dbbd1032ace5afb7fe98d899816f36610', "aria-hidden": "true", class: "w-20 h-20 mt-8" }, h("eds-icon-wrapper", { key: 'b399384638265f9fcc9a824c47fe73c75bcade33', icon: this.copied ? 'success' : 'copy', onClick: () => this.copyToClipboard() })), h("span", { key: '47c2d00b2cf86b99522dbc438726e0fc57fb6a44', class: "sr-only" }, "Copy Code")), this.language && (h("pre", { key: '038321e9d3d2a38963857ab8b719653f3e8385e3', class: `language-${this.language} bg-stronger pl-8 pb-8`, role: "region", "aria-label": `Code block in ${this.language}` }, h("code", { key: '72be161dd9781d9bc2f4d9495969175f34c19249', innerHTML: this.getHighlightedCode() })))));
2482
+ return (h("div", { key: '00eba9265ee17605f699d1e5606013b68e900b29', class: "relative bg-stronger rounded-sm" }, h("div", { key: '1192584f04de5ff74e91c88597a3360b92053456', class: "text-inverse flex justify-between items-center p-8" }, this.language ? (h("span", { class: "f-ui-03" }, this.language.toUpperCase())) : (h("pre", { class: "bg-stronger pl-8", role: "region", "aria-label": "Code block without language" }, h("code", { innerHTML: this.getHighlightedCode() }))), h("span", { key: '3666b6529a16a8cc64f448527db4ddee08f977a3', "aria-hidden": "true", class: "w-20 h-20 mt-8" }, h("eds-icon-wrapper", { key: 'f222d95a2e548429f6c4de96a7646e3cef1f360f', icon: this.copied ? 'success' : 'copy', onClick: () => this.copyToClipboard() })), h("span", { key: '8c539deda773909c01a41eb04ee51380c0a9c4bb', class: "sr-only" }, "Copy Code")), this.language && (h("pre", { key: '99541dedb32c543da5e780ffee4460333fbb3724', class: `language-${this.language} bg-stronger pl-8 pb-8`, role: "region", "aria-label": `Code block in ${this.language}` }, h("code", { key: '4e6ae6fcfae3de8c1fe5ad9d22309e0c8bee0c2c', innerHTML: this.getHighlightedCode() })))));
2437
2483
  }
2484
+ get el() { return this; }
2438
2485
  static get style() { return EdsCodeBlockStyle0; }
2439
2486
  }, [1, "eds-code-block", {
2440
2487
  "code": [1],
@@ -7,54 +7,76 @@ import { d as defineCustomElement$3 } from './eds-section-core2.js';
7
7
  import { d as defineCustomElement$2 } from './eds-section-heading2.js';
8
8
 
9
9
  const EdsComponentsOverview = () => (h("div", { class: "static-content container" },
10
- h("eds-alert", { message: "EBRAINS Design System makes it easy to implement and use its components across any framework or no framework at all. We\n accomplish this by using standardized web platform APIs and Web Components.", intent: "default" }),
11
10
  h("h2", null, "Load the module"),
12
11
  h("p", null,
13
12
  "Integrating EDSs components to a project without a JavaScript framework is straight forward. If you\u2019re working on a simple HTML page, you can start using the components immediately by adding the tags below to the",
14
13
  ' ',
15
14
  h("code", null, "head"),
16
15
  "."),
17
- h("eds-code-block", { code: '<script type="module" href="https://unpkg.com/@ebrains/components@0.0.1/loader"/></script>', language: "javascript", "copy-label": "Copy Code" }),
16
+ h("eds-code-block", { code: "<script type='module'>\n import { defineCustomElements } from 'https://unpkg.com/@ebrains/components@latest/loader/index.js'; \n // Define custom elements\n defineCustomElements(window);\n</script>", language: "javascript", "copy-label": "Copy Code" }),
18
17
  h("h2", null, "Load the styles"),
19
18
  h("p", null,
20
19
  "To directly use the produced css framework with a few predefined custom utility classes, add the tag below to the",
21
20
  ' ',
22
21
  h("code", null, "head")),
23
- h("eds-code-block", { code: '<link rel="stylesheet" href="https://unpkg.com/@ebrains/assets@0.0.1/styles/output.css"/>', language: "css", "copy-label": "Copy Code" }),
22
+ h("eds-code-block", { code: '<link rel="stylesheet" href="https://unpkg.com/@ebrains/assets@latest/styles/output.css"/>', language: "css", "copy-label": "Copy Code" }),
23
+ h("div", { class: "my-4" },
24
+ h("eds-alert", { message: "Note that, loading the predefined CSS framework above, automatically loads the fonts so you can skip loading them separately.", intent: "warning" })),
24
25
  h("h2", null, "Load the fonts"),
25
26
  h("p", null,
26
- "To load the correct webfonts as well, add either one of these tags to the ",
27
+ "To load the webfonts, add the tag below to the ",
27
28
  h("code", null, "head")),
28
29
  h("eds-code-block", { code: '<link rel="stylesheet" href="https://unpkg.com/@ebrains/assets@0.0.1/styles/base/fonts.css"/>', language: "css", "copy-label": "Copy Code" }),
29
30
  h("h2", null, "Component Usage"),
30
31
  h("p", null, "Once included, components can be used in your markup like any other regular HTML elements:"),
31
- h("eds-code-block", { code: '<eds-button label="my bytton" intent="primary"></eds-button>', language: "html", "copy-label": "Copy Code" })));
32
+ h("eds-code-block", { code: '<eds-button \n label="my bytton" \n intent="primary">\n</eds-button>', language: "html", "copy-label": "Copy Code" })));
32
33
 
33
34
  const EdsDocsInstallation = () => (h("div", null,
34
- h("p", null, "To start using the EBRAINS Design System, include the following scripts and styles in your project. You can also install it via npm for use with modern build tools."),
35
- h("eds-code-block", { code: "npm install @ebrains/components", language: "html", "copy-label": "Copy Code" }),
36
- h("p", null, "TBD")));
37
-
38
- const EdsDocsUsage = () => (h("div", null,
39
- h("h1", null, "Usage with basic HTML "),
40
- h("p", null, "TBD")));
35
+ h("p", null, "Before proceeding, ensure that Node.js is installed on your machine\u2014you can download the latest version from the official website. If your project doesn\u2019t already use npm and you plan to integrate EBRAINS Components, you'll need to create a package.json file by running npm init and following the on-screen instructions."),
36
+ h("div", { class: "my-8" },
37
+ h("eds-code-block", { code: "npm install @ebrains/components", language: "html", "copy-label": "Copy Code" })),
38
+ h("div", { class: "my-8" },
39
+ h("eds-code-block", { code: "npm install @ebrains/assets", language: "html", "copy-label": "Copy Code" })),
40
+ h("div", { class: "my-8" },
41
+ h("eds-code-block", { code: "npm install @ebrains/react", language: "html", "copy-label": "Copy Code" }))));
41
42
 
42
43
  const EdsDocsReact = () => (h("div", null,
43
44
  h("h2", null, "React Wrappers"),
44
- h("p", null, "Learn how to use our components in a React Application."),
45
- "Simple install the package below and check out the examples",
46
- h("eds-code-block", { code: "npm install @ebrains/react", language: "javascript", "copy-label": "Copy Code" }),
45
+ h("p", null, "Learn how to use our components in a React Application.Simple install the package below and check out the examples"),
46
+ h("div", { class: "my-8" },
47
+ h("eds-code-block", { code: "npm install @ebrains/react", language: "javascript", "copy-label": "Copy Code" })),
47
48
  h("eds-section-core", { "section-title": "Example React App", "heading-level": "h3" },
48
- h("eds-code-block", { code: '\nimport { EdsHeader } from "@ebrains/react";\n\ninterface User {\n firstname: string;\n lastname: string;\n // Add any other properties your user object might have\n}\n\ninterface AuthStatus {\n authenticated: boolean;\n user: User | null;\n}\n\nimport { useEffect, useState } from "react";\n\nexport function App() {\n\n const [authStatus, setAuthStatus] = useState<AuthStatus>({\n authenticated: false,\n user: null,\n });\n \n const [activeTabIndex, setActiveTabIndex] = useState<number>(0);\n\n // Use useEffect to render Stencil components dynamically after the component mounts\n useEffect(() => {\n \n const handleAuthStatusChange = (event: CustomEvent) => {\n console.log(event.detail);\n setAuthStatus(event.detail); // Set the entire object\n };\n\n const handleTabChange = (\n event: CustomEvent<{ index: number; name: string }>,\n ) => {\n console.log(event.detail);\n setActiveTabIndex(event.detail.index);\n };\n\n document.addEventListener(\n "authStatusChanged",\n handleAuthStatusChange as EventListener,\n );\n document.addEventListener("tabChange", handleTabChange as EventListener);\n\n return () => {\n document.removeEventListener(\n "authStatusChanged",\n handleAuthStatusChange as EventListener,\n );\n document.removeEventListener(\n "tabChange",\n handleTabChange as EventListener,\n );\n };\n }, []); // Empty dependency array ensures this runs only once after mounting\n\n return (\n <div id="main">\n <EdsHeader\n home-url="/"\n user-feature={false}\n keycloak-url="http://localhost:8080"\n keycloak-realm="nigeor-realm"\n keycloak-client-id="stencil-app"\n links="[\n { "label": "About", "url": "/about" },\n { "label": "Focus Areas", "url": "/focus-areas" },\n { "label": "News & Events", "url": "/news-and-events" },\n { "label": "Contact", "url": "/contact" }\n ]"\n ></EdsHeader>\n\n <div> \n User is{" "} {authStatus.authenticated ? "authenticated" : "not authenticated"}\n </div>\n {authStatus.user && <div>Welcome, {authStatus.user.firstname}</div>}\n </div>\n </div>\n );\n}\n\nexport default App;\n', language: "javascript", "copy-label": "Copy Code" }))));
49
+ h("eds-code-block", { code: '\nimport { EdsHeader } from "@ebrains/react";\n\ninterface User {\n firstname: string;\n lastname: string;\n}\n\ninterface AuthStatus {\n authenticated: boolean;\n user: User | null;\n}\n\nimport { useEffect, useState } from "react";\n\nexport function App() {\n\n const [authStatus, setAuthStatus] = useState<AuthStatus>({\n authenticated: false,\n user: null,\n });\n \n const [activeTabIndex, setActiveTabIndex] = useState<number>(0);\n\n // Use useEffect to render Stencil components dynamically after the component mounts\n useEffect(() => {\n \n const handleAuthStatusChange = (event: CustomEvent) => {\n console.log(event.detail);\n setAuthStatus(event.detail); // Set the entire object\n };\n\n const handleTabChange = (\n event: CustomEvent<{ index: number; name: string }>,\n ) => {\n console.log(event.detail);\n setActiveTabIndex(event.detail.index);\n };\n\n document.addEventListener(\n "authStatusChanged",\n handleAuthStatusChange as EventListener,\n );\n document.addEventListener("tabChange", handleTabChange as EventListener);\n\n return () => {\n document.removeEventListener(\n "authStatusChanged",\n handleAuthStatusChange as EventListener,\n );\n document.removeEventListener(\n "tabChange",\n handleTabChange as EventListener,\n );\n };\n }, []); // Empty dependency array ensures this runs only once after mounting\n\n return (\n <div id="main">\n <EdsHeader\n home-url="/"\n user-feature={false}\n keycloak-url="http://localhost:8080"\n keycloak-realm="nigeor-realm"\n keycloak-client-id="stencil-app"\n links="[\n { "label": "About", "url": "/about" },\n { "label": "Focus Areas", "url": "/focus-areas" },\n { "label": "News & Events", "url": "/news-and-events" },\n { "label": "Contact", "url": "/contact" }\n ]"\n ></EdsHeader>\n\n <div> \n User is{" "} {authStatus.authenticated ? "authenticated" : "not authenticated"}\n </div>\n {authStatus.user && <div>Welcome, {authStatus.user.firstname}</div>}\n </div>\n </div>\n );\n}\n\nexport default App;\n', language: "javascript", "copy-label": "Copy Code" }))));
49
50
 
50
51
  const EdsDocsVue = () => (h("div", null,
51
52
  h("h2", null, "Vue Wrappers"),
52
53
  h("p", null, "Learn how to use our components in a Vue Application."),
54
+ h("p", null, "Simply install the latest version of our NPM package."),
53
55
  h("eds-code-block", { code: "npm install @ebrains/vue", language: "javascript", "copy-label": "Copy Code" }),
54
- h("p", null, "Define the custom elements"),
56
+ h("p", null, "Our NPM package already includes the custom elements definitions. However, you can use the components as they are by simply importing and executing the initialization command in your \"main.ts\" file."),
55
57
  h("eds-code-block", { code: "import { defineCustomElements } from '@ebrains/components/loader';\ndefineCustomElements();", language: "javascript", "copy-label": "Copy Code" }),
58
+ h("h2", null,
59
+ "Passing Properties to Custom Elements Using the ",
60
+ h("b", null, ".prop"),
61
+ " Modifier in Vue Wrappers"),
62
+ h("p", null, "When using Vue wrappers for Stencil components (or any custom elements), you might encounter issues with property names being altered due to HTML\u2019s attribute handling. By default, Vue binds values as HTML attributes, and HTML attributes are case-insensitive. This means that camelCase property names can be transformed into lowercase strings, which can prevent your component from receiving the correct data."),
63
+ h("h3", null,
64
+ "How to Use the ",
65
+ h("b", null, ".prop"),
66
+ " Modifier"),
67
+ h("p", null, "When using Vue wrappers, you can pass properties with the .prop modifier by adding it to your binding expression. Here\u2019s an example of how to do it:"),
68
+ h("div", { class: "mt-8" },
69
+ h("eds-alert", { message: "This may lead to issues because Vue binds these as attributes .", intent: "error" })),
70
+ h("eds-code-block", { code: '<EdsAlert\n message="This is a default informational alert."\n intent="default"\n :pressableLabel="Press Me"\n :pressableUrl="https://ebrains.eu"\n></EdsAlert>', language: "javascript", "copy-label": "Copy Code" }),
71
+ h("div", { class: "mt-8" },
72
+ h("eds-alert", { message: "Use the .prop modifier to ensure properties are passed correctly.", intent: "success" })),
73
+ h("eds-code-block", { code: '<EdsAlert\n message="This is a default informational alert."\n intent="default"\n :pressableLabel.prop="Press Me"\n :pressableUrl.prop="https://ebrains.eu"\n></EdsAlert>', language: "javascript", "copy-label": "Copy Code" }),
74
+ h("p", null,
75
+ "Using the ",
76
+ h("b", null, ".prop"),
77
+ " modifier in Vue ensures that the data you pass to your custom elements is received as intended. It prevents Vue (and the browser) from transforming camelCase property names into lowercase attributes, thereby maintaining the correct data mapping in your Stencil components."),
56
78
  h("eds-section-core", { "section-title": "Example Vue App", "heading-level": "h3" },
57
- h("eds-code-block", { code: '\n<template>\n <h1 className="f-heading-02">Vue App</h1>\n\n <EdsHeader \n home-url="/" \n user-feature=false \n keycloak-url="http://localhost:8080" \n keycloak-realm="nigeor-realm"\n keycloak-client-id="stencil-app" \n links="[\n { "label": "About", "url": "/about" },\n { "label": "Focus Areas", "url": "/focus-areas" },\n { "label": "News & Events", "url": "/news-and-events" },\n { "label": "Contact", "url": "/contact" }\n ]">\n </EdsHeader>\n\n</template>\n\n<script>\n\nimport { EdsHeader } from "@ebrains/vue";\n\nexport default {\n name: "App",\n components: {\n EdsHeader,\n }\n};\n</script>\n', language: "javascript", "copy-label": "Copy Code" }))));
79
+ h("eds-code-block", { code: '\n<template>\n <EdsHeader \n :inverseHeader.prop="true"\n :menuEnabled.prop="true">\n </EdsHeader>\n</template>\n\n<script>\n\nimport { EdsHeader } from "@ebrains/vue";\n\nexport default {\n name: "App",\n components: {\n EdsHeader,\n }\n};\n</script>\n', language: "javascript", "copy-label": "Copy Code" }))));
58
80
 
59
81
  const EdsDocsAngular = () => (h("div", null,
60
82
  h("h2", null, "Angular Wrappers"),
@@ -65,7 +87,7 @@ const EdsDocsAngular = () => (h("div", null,
65
87
  h("p", null, "Angular Custom Elements Schema"),
66
88
  h("eds-code-block", { code: 'import { CUSTOM_ELEMENTS_SCHEMA } from "@angular/core";', language: "javascript", "copy-label": "Copy Code" }),
67
89
  h("eds-section-core", { "section-title": "Example Angular App", "heading-level": "h3" },
68
- h("eds-code-block", { code: '\n<div class="container">\n <h1 class="f-heading-01">{{ title }}</h1>\n <eds-breadcrumb\n intent="tertiary"\n items="[\n { "label": "Home", "url": "#" },\n { "label": "Products", "url": "#" },\n ]">\n </eds-breadcrumb>\n <eds-footer></eds-footer>\n</div>', language: "javascript", "copy-label": "Copy Code" }))));
90
+ h("eds-code-block", { code: '\n<div class="container">\n <eds-breadcrumb\n intent="tertiary"\n items="[\n { "label": "Home", "url": "#" },\n { "label": "Products", "url": "#" },\n ]">\n </eds-breadcrumb>\n <eds-footer></eds-footer>\n</div>', language: "javascript", "copy-label": "Copy Code" }))));
69
91
 
70
92
  const EdsComponentsSection$1 = /*@__PURE__*/ proxyCustomElement(class EdsComponentsSection extends HTMLElement {
71
93
  constructor() {
@@ -80,19 +102,17 @@ const EdsComponentsSection$1 = /*@__PURE__*/ proxyCustomElement(class EdsCompone
80
102
  case 1:
81
103
  return h(EdsDocsInstallation, null);
82
104
  case 2:
83
- return h(EdsDocsUsage, null);
84
- case 3:
85
105
  return h(EdsDocsReact, null);
86
- case 4:
106
+ case 3:
87
107
  return h(EdsDocsVue, null);
88
- case 5:
108
+ case 4:
89
109
  return h(EdsDocsAngular, null);
90
110
  default:
91
111
  return h("p", null, "Content not available.");
92
112
  }
93
113
  }
94
114
  render() {
95
- return h("div", { key: 'faa14dc7bb5d966ea1328f60d8ca88b3c406ad51', class: "container" }, this.renderContent());
115
+ return h("div", { key: 'ce34514ab73daa5baa011bda56a13d6197f8bfd0', class: "container" }, this.renderContent());
96
116
  }
97
117
  }, [0, "eds-components-section", {
98
118
  "tabIndex": [2, "tab-index"]
@@ -26,7 +26,7 @@ const EdsDocsPalettes$1 = /*@__PURE__*/ proxyCustomElement(class EdsDocsPalettes
26
26
  }
27
27
  }
28
28
  render() {
29
- return h("div", { key: 'c11e0de66c41770e7ebca46d3fb7ab11b454511e', class: "container" }, this.renderContent());
29
+ return h("div", { key: '42f0a4598c64661d98054522e88366ec591a2cb3', class: "container" }, this.renderContent());
30
30
  }
31
31
  }, [0, "eds-docs-palettes", {
32
32
  "tabIndex": [2, "tab-index"]
@@ -30,7 +30,7 @@ const EdsDocsContent = /*@__PURE__*/ proxyCustomElement(class EdsDocsContent ext
30
30
  }
31
31
  }
32
32
  render() {
33
- return h("div", { key: 'ef9cf093af7bc730b73f3561b36187f70aea29a7', class: "container" }, this.renderContent());
33
+ return h("div", { key: '10708d591c4077e4e1fe94073322f01121253bdb', class: "container" }, this.renderContent());
34
34
  }
35
35
  }, [0, "eds-docs-tokens", {
36
36
  "tabIndex": [2, "tab-index"]
@@ -1,4 +1,6 @@
1
1
  import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
2
+ import './color.js';
3
+ import { s as sendAnalytics } from './analytics.js';
2
4
  import { d as defineCustomElement$2 } from './eds-button2.js';
3
5
  import { d as defineCustomElement$1 } from './eds-icon-wrapper2.js';
4
6
 
@@ -15,6 +17,7 @@ const EdsDropdown = /*@__PURE__*/ proxyCustomElement(class EdsDropdown extends H
15
17
  * Toggles the visibility of the dropdown and manages focus.
16
18
  */
17
19
  this.handleClick = () => {
20
+ var _a;
18
21
  this.isOpen = !this.isOpen;
19
22
  if (this.isOpen) {
20
23
  this.focusIndex = 0;
@@ -23,6 +26,13 @@ const EdsDropdown = /*@__PURE__*/ proxyCustomElement(class EdsDropdown extends H
23
26
  else {
24
27
  this.closeDropdown();
25
28
  }
29
+ sendAnalytics({
30
+ category: 'ui-component',
31
+ parentContext: null,
32
+ tag: this.host.tagName.toLowerCase(),
33
+ name: ((_a = this.label) === null || _a === void 0 ? void 0 : _a.toLowerCase()) || '',
34
+ action: this.isOpen ? 'expanded' : 'collapsed'
35
+ });
26
36
  };
27
37
  this.icon = 'chevron-down';
28
38
  this.label = undefined;
@@ -89,39 +99,20 @@ const EdsDropdown = /*@__PURE__*/ proxyCustomElement(class EdsDropdown extends H
89
99
  componentDidLoad() {
90
100
  var _a;
91
101
  this.focusableItems = Array.from(((_a = this.dropdownContent) === null || _a === void 0 ? void 0 : _a.querySelectorAll('a, button')) || []);
92
- const btns = this.host.shadowRoot.querySelectorAll('eds-button');
93
- btns.forEach((btn) => {
94
- this.emitContext(btn);
95
- });
96
- }
97
- /**
98
- * Emits a custom event called `parentContext` for a given button element.
99
- * Provides context information about the dropdown component.
100
- *
101
- * @param linkElement - The button element to which the event will be dispatched.
102
- */
103
- emitContext(linkElement) {
104
- const event = new CustomEvent('parentContext', {
105
- detail: {
106
- componentName: this.host.tagName.toLowerCase(),
107
- identifier: null
108
- }
109
- });
110
- linkElement.dispatchEvent(event);
111
102
  }
112
103
  /**
113
104
  * Renders the dropdown component and displays its content when open.
114
105
  * @returns {JSX.Element} The rendered dropdown component.
115
106
  */
116
107
  render() {
117
- return (h("div", { key: 'd49e23ee208cfb000baba83795899487e4d94af7', class: "z-focus relative", ref: (el) => (this.dropdownContent = el) }, h("eds-button", { key: '6647007c34b47558873e470890893ae4f8e18b5c', label: this.label, "aria-label": this.ariaLabel, icon: this.icon, intent: this.intent, onClick: this.handleClick, "aria-expanded": this.isOpen.toString(), "aria-haspopup": "menu" }), h("nav", { key: '41bbd4e2bf02345393aaa97101b2c3aca2fa4085', class: {
108
+ return (h("div", { key: '809cb733330db434f94f854ed4d1ee375f598297', class: "z-focus relative", ref: (el) => (this.dropdownContent = el) }, h("eds-button", { key: 'c80f2930b335708a2a01d06b565673597bd8d926', label: this.label, "aria-label": this.ariaLabel, icon: this.icon, intent: this.intent, onClick: this.handleClick, "aria-expanded": this.isOpen.toString(), "aria-haspopup": "menu" }), h("nav", { key: '7b3ccb2ab29474a4795d5491960e0713aefcd624', class: {
118
109
  'shadow-small bg-inverse border-softest z-10 z-on-top absolute top-full mt-4 flex flex-col gap-y-4 border-2 p-8': true,
119
110
  'left-4': this.dropdownPos === 'left' && this.dropdownOffset,
120
111
  'left-0': this.dropdownPos === 'left' && !this.dropdownOffset,
121
112
  'right-4': this.dropdownPos === 'right' && this.dropdownOffset,
122
113
  'right-0': this.dropdownPos === 'right' && !this.dropdownOffset,
123
114
  'rounded-lg': this.rounded
124
- }, style: { display: this.isOpen ? 'block' : 'none' }, "aria-label": "Dropdown", "aria-hidden": !this.isOpen }, h("slot", { key: '714bad9f5a8ddf6d5ea246044a83b0a5102494c4' }))));
115
+ }, style: { display: this.isOpen ? 'block' : 'none' }, "aria-label": "Dropdown", "aria-hidden": !this.isOpen }, h("slot", { key: 'c514c5dca893708fd1660a61cfeb1607229bbff5' }))));
125
116
  }
126
117
  get host() { return this; }
127
118
  static get style() { return EdsDropdownStyle0; }
@@ -44,7 +44,7 @@ const EdsFooter = /*@__PURE__*/ proxyCustomElement(class EdsFooter extends HTMLE
44
44
  * @returns {JSX.Element} The rendered JSX for the footer component.
45
45
  */
46
46
  render() {
47
- return (h("footer", { key: 'efffa9b96cc2a094255fcb6d08ec45c7c7f09ec4', class: `${this.extraClass} pb-banner` }, this.social ? (h("div", { class: "border-softest border-t-2 pt-20 pb-28 md:pt-28" }, h("div", { class: "container pb-20 xl:pb-40 " }, h("div", { class: "grid-layout" }, h("div", { class: "grid-col-span-12 lg:grid-col-span-5" }, h("eds-social-networks", { class: "mt-28" })), h("nav", { "aria-label": "Secondary nav", class: "grid-col-span-12 lg:grid-col-span-6 lg:grid-col-start-7 grid-layout mt-28 gap-y-12 lg:mt-0" }))))) : null, h("div", { key: 'c3942c635dff3dc8cb47a21f20aca52acfaa3e18', class: `border-softest ${this.social ? 'border-t-2' : ''} pt-20 pb-28 md:pt-28` }, h("div", { key: '57e963272659ce2e63294c969f3724a03aef667e', class: "container flex flex-wrap items-center gap-20 lg:flex-nowrap" }, h("div", { key: 'c3e5cfe07fe9eb90450f7a87be1b95ed00ef38ce', class: "flex items-center gap-x-12" }, h("a", { key: 'b0d0c65115b611f78d2b468559c16eb60f538907', target: "_blank", rel: "noopener noreferrer", class: "effect-focus focus-visible:rounded-xs flex w-[54px] ml-0", href: "https://research-and-innovation.ec.europa.eu/funding/funding-opportunities/funding-programmes-and-open-calls/horizon-2020_en" }, h("eds-img", { key: '6cb5d067f07b456a8d828f3f42f2730e3e5374e0', width: 54, height: 41, src: "https://www.ebrains.eu/flags/4x3/eu.svg" }))), h("div", { key: 'e5b768b0fb96fcdcb786d33fc808368005935491', class: "f-ui-04 text-light order-last w-full lg:order-none lg:w-auto" }, h("p", { key: '777263c2f4bde43d38690f41391eaf8e51d945fa' }, this.fundedBy), h("div", { key: 'a415687d08edf8f3e03a6edce9c45f58662c8595', class: "mt-4 flex flex-wrap gap-12 lg:flex-nowrap" }, h("span", { key: 'c0b6498ad4f5e1f4f1945ebb971f9dd81cc74c77', class: "effect-focus !no-underline decoration-2 underline-offset-4 hover:!underline" }, "\u00A9 ", this.rightsReserved), this.hasCookiesSetUp && (h("button", { key: '10133d180bfb0d8a6354ea2cbea318a2c46fc463', class: "effect-focus !no-underline underline-offset-4 hover:!underline", onClick: () => this.toggleCookiesPopup() }, this.cookiesPreference)))), h("div", { key: '917d0980f91a8c42a75bae301b0a18e3777dd021', class: "ml-auto pl-12" }, this.enableScrollTop ? (h("eds-button", { "aria-label": "Back to top", intent: "ghostInverse", icon: "chevron-up", onClick: this.backToTop })) : null)))));
47
+ return (h("footer", { key: '8d3d1b5d2acd76f56b2bc12539cb7d277b4dcd7f', class: `${this.extraClass} pb-banner` }, this.social ? (h("div", { class: "border-softest border-t-2 pt-20 pb-28 md:pt-28" }, h("div", { class: "container pb-20 xl:pb-40 " }, h("div", { class: "grid-layout" }, h("div", { class: "grid-col-span-12 lg:grid-col-span-5" }, h("eds-social-networks", { class: "mt-28" })), h("nav", { "aria-label": "Secondary nav", class: "grid-col-span-12 lg:grid-col-span-6 lg:grid-col-start-7 grid-layout mt-28 gap-y-12 lg:mt-0" }))))) : null, h("div", { key: '7d6e3a414ec8e8f8e2b795faf639948f8819f5cb', class: `border-softest ${this.social ? 'border-t-2' : ''} pt-20 pb-28 md:pt-28` }, h("div", { key: '9a475fd146ac0e1bc78c43940ee24ec31212fcb9', class: "container flex flex-wrap items-center gap-20 lg:flex-nowrap" }, h("div", { key: '4b465113cdb882f919fba15e944eb56edbe3c570', class: "flex items-center gap-x-12" }, h("a", { key: '1a8ad1ee5f4dfb77da036b03d0770cba8e5d725e', target: "_blank", rel: "noopener noreferrer", class: "effect-focus focus-visible:rounded-xs flex w-[54px] ml-0", href: "https://research-and-innovation.ec.europa.eu/funding/funding-opportunities/funding-programmes-and-open-calls/horizon-2020_en" }, h("eds-img", { key: '4714ea1a01b7b7eef8b3af0c04ffe793d51c4d5e', width: 54, height: 41, src: "https://www.ebrains.eu/flags/4x3/eu.svg" }))), h("div", { key: 'c4db6bab70e570e337c82136a0d9d6dad01c1039', class: "f-ui-04 text-light order-last w-full lg:order-none lg:w-auto" }, h("p", { key: '0b030a92c12a3a96fe2baacc13ac21f5bd708a50' }, this.fundedBy), h("div", { key: '4714d0ccf0e3912ae330a6f39ed3607caf2b51a4', class: "mt-4 flex flex-wrap gap-12 lg:flex-nowrap" }, h("span", { key: 'b4bc2d45871c7d1f9de1d6090959b12fd5246f01', class: "effect-focus !no-underline decoration-2 underline-offset-4 hover:!underline" }, "\u00A9 ", this.rightsReserved), this.hasCookiesSetUp && (h("button", { key: '98b56eee7be6bc1558821933cebf2853b3bb68fc', class: "effect-focus !no-underline underline-offset-4 hover:!underline", onClick: () => this.toggleCookiesPopup() }, this.cookiesPreference)))), h("div", { key: 'f4bf4a0c99f3be920dd15f68e6f7e390cd85ecce', class: "ml-auto pl-12" }, this.enableScrollTop ? (h("eds-button", { "aria-label": "Back to top", intent: "ghostInverse", icon: "chevron-up", onClick: this.backToTop })) : null)))));
48
48
  }
49
49
  static get style() { return EdsFooterStyle0; }
50
50
  }, [0, "eds-footer", {
@@ -129,7 +129,6 @@ const EdsForm$1 = /*@__PURE__*/ proxyCustomElement(class EdsForm extends HTMLEle
129
129
  this.formSubmitting.emit(this.isSubmitting);
130
130
  }
131
131
  };
132
- this.smallAlert = false;
133
132
  this.setFormUrl = true;
134
133
  this.submitBtn = true;
135
134
  this.submitBtnLabel = 'Submit';
@@ -138,7 +137,7 @@ const EdsForm$1 = /*@__PURE__*/ proxyCustomElement(class EdsForm extends HTMLEle
138
137
  this.submitBtnHintMessage = 'To participate, please sign in using your EBRAINS account. If you do not have an account yet, you can easily create one on the EBRAINS portal.';
139
138
  this.endpoint = undefined;
140
139
  this.name = 'form';
141
- this.fields = undefined;
140
+ this.fields = [];
142
141
  this.values = {};
143
142
  this.coupleAuth = false;
144
143
  this.formSubmitted = false;
@@ -148,6 +147,7 @@ const EdsForm$1 = /*@__PURE__*/ proxyCustomElement(class EdsForm extends HTMLEle
148
147
  this.alertMessage = null;
149
148
  this.isAuthenticated = false;
150
149
  this.authUser = undefined;
150
+ this.parsedFields = [];
151
151
  }
152
152
  onAuthStatusChanged(event) {
153
153
  var _a;
@@ -155,6 +155,7 @@ const EdsForm$1 = /*@__PURE__*/ proxyCustomElement(class EdsForm extends HTMLEle
155
155
  this.authUser = event.detail.user;
156
156
  }
157
157
  componentDidLoad() {
158
+ this.parseFields(this.fields);
158
159
  // Emit context for each eds-link element after the component is fully loaded
159
160
  const links = this.el.querySelectorAll('eds-button');
160
161
  links.forEach((link) => {
@@ -227,7 +228,7 @@ const EdsForm$1 = /*@__PURE__*/ proxyCustomElement(class EdsForm extends HTMLEle
227
228
  validateForm() {
228
229
  this.errors = {};
229
230
  this.hasError = false;
230
- this.parseFields.forEach((field) => {
231
+ this.parsedFields.forEach((field) => {
231
232
  if (field.type !== 'hidden') {
232
233
  if ((field.type === 'checkbox' || field.type === 'radio') && !field.options) {
233
234
  // Single checkbox validation
@@ -309,24 +310,45 @@ const EdsForm$1 = /*@__PURE__*/ proxyCustomElement(class EdsForm extends HTMLEle
309
310
  });
310
311
  return formData;
311
312
  }
312
- get parseFields() {
313
- return JSON.parse(this.fields);
313
+ parseFields(newValue) {
314
+ try {
315
+ if (typeof newValue === 'string') {
316
+ this.parsedFields = JSON.parse(newValue);
317
+ }
318
+ else if (Array.isArray(newValue)) {
319
+ this.parsedFields = newValue;
320
+ }
321
+ else if (newValue && typeof newValue === 'object') {
322
+ // In case a single object is passed, wrap it in an array.
323
+ this.parsedFields = newValue;
324
+ }
325
+ else {
326
+ this.parsedFields = [];
327
+ }
328
+ }
329
+ catch (error) {
330
+ // eslint-disable-next-line
331
+ console.error('Error parsing fields prop:', error);
332
+ this.parsedFields = [];
333
+ }
314
334
  }
315
335
  render() {
316
- const hiddenFields = this.parseFields.filter((field) => field.type === 'hidden');
317
- const otherFields = this.parseFields.filter((field) => field.type !== 'hidden');
318
- return (h("form", { key: 'fdb974998dfd27c0d857d0fbfbbe9e769e55d7bb', ref: (el) => (this.formEl = el), enctype: "multipart/form-data", autocomplete: "on", method: "post", onSubmit: this.handleSubmit }, h("div", { key: 'dfbe5adce9e5685736169e88408590088aba5b1e' }, h("slot", { key: 'f5c5356a8b87bf63fdd21901da81291c596f1487' }), hiddenFields.map((field, index) => (h("eds-input", { key: index, type: "hidden", name: field.name, value: field.value }))), otherFields.map((field, index) => {
336
+ const hiddenFields = this.parsedFields.filter((field) => field.type === 'hidden');
337
+ const otherFields = this.parsedFields.filter((field) => field.type !== 'hidden');
338
+ return (h("form", { key: '0a106caa8aa9f056b55acf6fecfbc7090c4411d2', ref: (el) => (this.formEl = el), enctype: "multipart/form-data", autocomplete: "on", method: "post", onSubmit: this.handleSubmit }, h("div", { key: '3478d82640378d9a1c0c09394453e2118b1b3ca9' }, h("slot", { key: '9bc37f54c03b2b0f831da917b6ce6bab2ec11084' }), hiddenFields.map((field, index) => (h("eds-input", { key: index, type: "hidden", name: field.name, value: field.value }))), otherFields.map((field, index) => {
319
339
  var _a, _b;
320
340
  if (!this.isFieldVisible(field)) {
321
341
  return null;
322
342
  }
323
343
  return (h("eds-input-field", { key: index, name: field.name, id: `${this.name}_${field.name}`, label: field.label, type: field.type, icon: field.icon || null, required: field.required, maxLength: field.maxlength, hint: field.hint, error: ((_a = this.errors[field.name]) === null || _a === void 0 ? void 0 : _a.length) > 0, errorMessage: (_b = this.errors[field.name]) === null || _b === void 0 ? void 0 : _b.join('<br />'), onInput: (e) => this.handleChange(e, field), class: index > 0 ? 'mt-20' : '', options: field.options }));
324
- })), this.submitBtn && (h("div", { key: '2c3165a56d5bec9135a8695cae1b87981167c949', class: "mt-20" }, h("eds-button", { key: 'f311628ff58cd03ebbd0f7ccb0623df817d416da', intent: "primary", label: this.submitBtnLabel, disabled: this.isSubmitting || (this.coupleAuth && !this.isAuthenticated), loading: this.isSubmitting, onClick: (e) => this.handleSubmit(e) }), this.coupleAuth && !this.isAuthenticated ? (h("p", { class: "f-ui-05 text-lighter mt-8 ml-8" }, this.submitBtnHintMessage)) : null)), this.alertMessage && (this.formSubmitted || this.hasError) && (h("div", { key: '1c7adc93081294eb86b71e808933215fe04fa033', class: "mt-20" }, h("eds-alert", { key: 'd221dd0674be734a8b7382ea2eeb97509f6bc3a6', message: this.alertMessage, intent: this.hasError ? 'error' : 'success', direction: "horizontal" })))));
344
+ })), this.submitBtn && (h("div", { key: 'ca221e8c5c18cf4a107581736728f84cea7831d0', class: "mt-20" }, h("eds-button", { key: 'eef3cf052beb62703c1df74d142650194d60c501', intent: "primary", label: this.submitBtnLabel, disabled: this.isSubmitting || (this.coupleAuth && !this.isAuthenticated), loading: this.isSubmitting, onClick: (e) => this.handleSubmit(e) }), this.coupleAuth && !this.isAuthenticated ? (h("p", { class: "f-ui-05 text-lighter mt-8 ml-8" }, this.submitBtnHintMessage)) : null)), this.alertMessage && (this.formSubmitted || this.hasError) && (h("div", { key: '69861c8776b99e26a08585a5a8c893c85a2d9999', class: "mt-20" }, h("eds-alert", { key: 'b4d225d8efcbe6cde95789c367f0ecf94f217c9c', message: this.alertMessage, intent: this.hasError ? 'error' : 'success', direction: "horizontal" })))));
325
345
  }
326
346
  get el() { return this; }
347
+ static get watchers() { return {
348
+ "fields": ["parseFields"]
349
+ }; }
327
350
  static get style() { return EdsFormStyle0; }
328
351
  }, [4, "eds-form", {
329
- "smallAlert": [4, "small-alert"],
330
352
  "setFormUrl": [4, "set-form-url"],
331
353
  "submitBtn": [4, "submit-btn"],
332
354
  "submitBtnLabel": [1, "submit-btn-label"],
@@ -344,8 +366,11 @@ const EdsForm$1 = /*@__PURE__*/ proxyCustomElement(class EdsForm extends HTMLEle
344
366
  "isSubmitting": [32],
345
367
  "alertMessage": [32],
346
368
  "isAuthenticated": [32],
347
- "authUser": [32]
348
- }, [[16, "authStatusChanged", "onAuthStatusChanged"]]]);
369
+ "authUser": [32],
370
+ "parsedFields": [32]
371
+ }, [[16, "authStatusChanged", "onAuthStatusChanged"]], {
372
+ "fields": ["parseFields"]
373
+ }]);
349
374
  function defineCustomElement$1() {
350
375
  if (typeof customElements === "undefined") {
351
376
  return;
@@ -77,6 +77,10 @@ const EdsHeader$1 = /*@__PURE__*/ proxyCustomElement(class EdsHeader extends HTM
77
77
  * @returns {any[]} Array of parsed link objects
78
78
  */
79
79
  get parsedLinks() {
80
+ // If it's already an array, return it immediately.
81
+ if (Array.isArray(this.links)) {
82
+ return this.links;
83
+ }
80
84
  if (typeof this.links === 'object') {
81
85
  return this.links;
82
86
  }
@@ -93,8 +97,8 @@ const EdsHeader$1 = /*@__PURE__*/ proxyCustomElement(class EdsHeader extends HTM
93
97
  return [];
94
98
  }
95
99
  render() {
96
- return (h("header", { key: 'bd3056a3d8ca0e8472e154eb3da9ba1aca6d1fa1', class: `flex items-center justify-between relative z-10
97
- ${this.inverseHeader ? 'text-inverse bg-strongest' : 'text-default bg-dark'}` }, h("div", { key: '55db7995eab812785789ecc8441079ee5e07af76', class: "mr-auto w-[200px] h-[85px]" }, h("eds-logo", { key: '0464d045dc59d0f78a021a14ffa0254579052529', type: this.inverseHeader ? 'color-white' : 'color', href: this.homeUrl })), this.parsedLinks && (h("nav", { key: '7ab1b2c20cf9d934a29480bd29736ced42ff5a20', class: "absolute left-1/2 top-1/2 grow -translate-x-1/2 -translate-y-1/2 justify-center hidden md:flex" }, h("ul", { key: '7dca9e2715f3831ee806b0e354c19b65deac1490', class: "flex gap-x-2" }, this.parsedLinks.map((link) => (h("eds-link", { label: link.label, "aria-label": link.label, url: link.url, intent: "ghost", size: "small", icon: link.icon, external: link.external, "extra-class": "after:effect-opacity aria-current-page:bg-darker whitespace-nowrap !text-current after:!border-transparent after:opacity-0 hover:after:!border-transparent hover:after:opacity-100" })))))), h("slot", { key: 'd49985a1074f2daed9cab42fa5af8b0ec8cb6ec9' }), this.userFeature ? (h("div", { class: "px-16" }, h("eds-user", { "keycloak-url": this.keycloakUrl, "keycloak-realm": this.keycloakRealm, "keycloak-client-id": this.keycloakClientId }))) : null, this.menuEnabled ? (h("div", { class: "md:hidden flex overflow-hidden px-16" }, h("eds-button", { "aria-label": "Menu", intent: "ghostInverse", icon: "menu", size: "small", onClick: () => this.handleToggleMenu() }))) : null));
100
+ return (h("header", { key: 'b16e5e84ba7565ebf4ea5892a9a1af84fc94769d', class: `flex items-center justify-between relative z-10
101
+ ${this.inverseHeader ? 'text-inverse bg-strongest' : 'text-default bg-dark'}` }, h("div", { key: '00206a2714dedfe205151002cc10c430e75814fb', class: "mr-auto w-[200px] h-[85px]" }, h("eds-logo", { key: '25fc6207d61bb4cc06877dd0b15bf56392b50255', type: this.inverseHeader ? 'color-white' : 'color', href: this.homeUrl })), this.parsedLinks && (h("nav", { key: '8d1ee2947db26e5acb556da845fe1b811a8d18b2', class: "absolute left-1/2 top-1/2 grow -translate-x-1/2 -translate-y-1/2 justify-center hidden md:flex" }, h("ul", { key: '5c70e48f3a617a6abe402659b37741e657440cbc', class: "flex gap-x-2" }, this.parsedLinks.map((link) => (h("eds-link", { label: link.label, "aria-label": link.label, url: link.url, intent: "ghost", size: "small", icon: link.icon, external: link.external, "extra-class": "after:effect-opacity aria-current-page:bg-darker whitespace-nowrap !text-current after:!border-transparent after:opacity-0 hover:after:!border-transparent hover:after:opacity-100" })))))), h("slot", { key: '773b60e90ecfe336fede86ea6e3b0ec2fd10bd72' }), this.userFeature ? (h("div", { class: "px-16" }, h("eds-user", { "keycloak-url": this.keycloakUrl, "keycloak-realm": this.keycloakRealm, "keycloak-client-id": this.keycloakClientId }))) : null, this.menuEnabled ? (h("div", { class: "md:hidden flex overflow-hidden px-16" }, h("eds-button", { "aria-label": "Menu", intent: "ghostInverse", icon: "menu", size: "small", onClick: () => this.handleToggleMenu() }))) : null));
98
102
  }
99
103
  get hostEl() { return this; }
100
104
  static get style() { return EdsHeaderStyle0; }