@siemens/ix 2.1.0 → 2.1.1-beta.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 (602) hide show
  1. package/components/burger-menu.js +2 -2
  2. package/components/burger-menu.js.map +1 -1
  3. package/components/dropdown.js +23 -15
  4. package/components/dropdown.js.map +1 -1
  5. package/components/ix-menu-category.js +19 -7
  6. package/components/ix-menu-category.js.map +1 -1
  7. package/components/ix-menu-settings-item.js +1 -1
  8. package/components/ix-menu.js +2 -2
  9. package/components/ix-menu.js.map +1 -1
  10. package/components/ix-message-bar.js +2 -2
  11. package/components/ix-message-bar.js.map +1 -1
  12. package/components/ix-modal-example.js +1 -1
  13. package/components/ix-modal-footer.js +1 -1
  14. package/components/ix-modal-loading.js +1 -1
  15. package/components/ix-modal.js +6 -3
  16. package/components/ix-modal.js.map +1 -1
  17. package/components/ix-pagination.js +2 -2
  18. package/components/ix-pane-layout.js +9 -1
  19. package/components/ix-pane-layout.js.map +1 -1
  20. package/components/ix-pane.js +51 -22
  21. package/components/ix-pane.js.map +1 -1
  22. package/components/ix-pill.js +4 -4
  23. package/components/ix-playground-internal.js +1 -1
  24. package/components/ix-split-button-item.js +1 -1
  25. package/components/ix-tile.js +4 -4
  26. package/components/ix-toast-container.js +1 -1
  27. package/components/ix-toggle-button.js +2 -2
  28. package/components/ix-toggle.js +2 -2
  29. package/components/ix-tree.js +1 -1
  30. package/components/ix-upload.js +3 -3
  31. package/components/ix-validation-tooltip.js +2 -2
  32. package/components/ix-workflow-step.js +3 -3
  33. package/components/ix-workflow-steps.js +1 -1
  34. package/components/menu-item.js +29 -6
  35. package/components/menu-item.js.map +1 -1
  36. package/components/modal-content.js +1 -1
  37. package/components/modal-header.js +1 -1
  38. package/components/modal.js +1 -1
  39. package/components/modal.js.map +1 -1
  40. package/components/row.js +1 -1
  41. package/components/select-item.js +1 -1
  42. package/components/select.js +6 -6
  43. package/components/spinner.js +1 -1
  44. package/components/tabs.js +2 -2
  45. package/components/toast.js +2 -2
  46. package/components/tooltip.js +17 -22
  47. package/components/tooltip.js.map +1 -1
  48. package/components/tree-item.js +4 -4
  49. package/dist/cjs/{base-button-86ed26da.js → base-button-2d5bec30.js} +2 -2
  50. package/dist/cjs/{base-button-86ed26da.js.map → base-button-2d5bec30.js.map} +1 -1
  51. package/dist/cjs/{base-icon-button-66351850.js → base-icon-button-b5fdb62e.js} +3 -3
  52. package/dist/cjs/{base-icon-button-66351850.js.map → base-icon-button-b5fdb62e.js.map} +1 -1
  53. package/dist/cjs/{index-ace435aa.js → index-7bcb694d.js} +35 -22
  54. package/dist/cjs/index-7bcb694d.js.map +1 -0
  55. package/dist/cjs/{index-5689c2a0.js → index-c4629a8d.js} +2 -2
  56. package/dist/cjs/{index-5689c2a0.js.map → index-c4629a8d.js.map} +1 -1
  57. package/dist/cjs/index.cjs.js +1 -1
  58. package/dist/cjs/ix-action-card.cjs.entry.js +1 -1
  59. package/dist/cjs/ix-application-header.cjs.entry.js +3 -3
  60. package/dist/cjs/ix-application-sidebar.cjs.entry.js +1 -1
  61. package/dist/cjs/ix-application-switch-modal.cjs.entry.js +2 -2
  62. package/dist/cjs/ix-application.cjs.entry.js +1 -1
  63. package/dist/cjs/ix-avatar_2.cjs.entry.js +2 -2
  64. package/dist/cjs/ix-basic-navigation.cjs.entry.js +1 -1
  65. package/dist/cjs/ix-blind.cjs.entry.js +1 -1
  66. package/dist/cjs/ix-breadcrumb-item.cjs.entry.js +2 -2
  67. package/dist/cjs/ix-breadcrumb.cjs.entry.js +1 -1
  68. package/dist/cjs/ix-burger-menu.cjs.entry.js +4 -4
  69. package/dist/cjs/ix-burger-menu.cjs.entry.js.map +1 -1
  70. package/dist/cjs/ix-button.cjs.entry.js +2 -2
  71. package/dist/cjs/ix-card-accordion_2.cjs.entry.js +1 -1
  72. package/dist/cjs/ix-card-list.cjs.entry.js +1 -1
  73. package/dist/cjs/ix-card_2.cjs.entry.js +1 -1
  74. package/dist/cjs/ix-category-filter.cjs.entry.js +2 -2
  75. package/dist/cjs/ix-chip.cjs.entry.js +1 -1
  76. package/dist/cjs/ix-col_4.cjs.entry.js +3 -3
  77. package/dist/cjs/ix-content-header.cjs.entry.js +1 -1
  78. package/dist/cjs/ix-content.cjs.entry.js +1 -1
  79. package/dist/cjs/ix-css-grid-item.cjs.entry.js +1 -1
  80. package/dist/cjs/ix-css-grid.cjs.entry.js +1 -1
  81. package/dist/cjs/ix-date-dropdown.cjs.entry.js +1 -1
  82. package/dist/cjs/ix-date-time-card.cjs.entry.js +1 -1
  83. package/dist/cjs/ix-datetime-picker.cjs.entry.js +1 -1
  84. package/dist/cjs/ix-divider.cjs.entry.js +1 -1
  85. package/dist/cjs/ix-drawer.cjs.entry.js +1 -1
  86. package/dist/cjs/ix-dropdown-button.cjs.entry.js +1 -1
  87. package/dist/cjs/ix-dropdown-header.cjs.entry.js +1 -1
  88. package/dist/cjs/ix-dropdown-item.cjs.entry.js +1 -1
  89. package/dist/cjs/ix-dropdown-quick-actions.cjs.entry.js +1 -1
  90. package/dist/cjs/ix-dropdown.cjs.entry.js +22 -14
  91. package/dist/cjs/ix-dropdown.cjs.entry.js.map +1 -1
  92. package/dist/cjs/ix-empty-state.cjs.entry.js +1 -1
  93. package/dist/cjs/ix-event-list-item.cjs.entry.js +1 -1
  94. package/dist/cjs/ix-event-list.cjs.entry.js +1 -1
  95. package/dist/cjs/ix-expanding-search.cjs.entry.js +1 -1
  96. package/dist/cjs/ix-filter-chip_2.cjs.entry.js +2 -2
  97. package/dist/cjs/ix-flip-tile-content.cjs.entry.js +1 -1
  98. package/dist/cjs/ix-flip-tile.cjs.entry.js +1 -1
  99. package/dist/cjs/ix-form-field.cjs.entry.js +1 -1
  100. package/dist/cjs/ix-group-context-menu_2.cjs.entry.js +1 -1
  101. package/dist/cjs/ix-group.cjs.entry.js +1 -1
  102. package/dist/cjs/ix-icon-button_2.cjs.entry.js +4 -4
  103. package/dist/cjs/ix-icon-toggle-button.cjs.entry.js +3 -3
  104. package/dist/cjs/ix-input-group.cjs.entry.js +1 -1
  105. package/dist/cjs/ix-key-value-list.cjs.entry.js +1 -1
  106. package/dist/cjs/ix-key-value.cjs.entry.js +1 -1
  107. package/dist/cjs/ix-kpi.cjs.entry.js +1 -1
  108. package/dist/cjs/ix-link-button.cjs.entry.js +1 -1
  109. package/dist/cjs/ix-map-navigation-overlay.cjs.entry.js +1 -1
  110. package/dist/cjs/ix-map-navigation.cjs.entry.js +1 -1
  111. package/dist/cjs/ix-menu-about-item.cjs.entry.js +1 -1
  112. package/dist/cjs/ix-menu-about-news.cjs.entry.js +1 -1
  113. package/dist/cjs/ix-menu-about.cjs.entry.js +2 -2
  114. package/dist/cjs/ix-menu-avatar.cjs.entry.js +1 -1
  115. package/dist/cjs/ix-menu-category.cjs.entry.js +20 -8
  116. package/dist/cjs/ix-menu-category.cjs.entry.js.map +1 -1
  117. package/dist/cjs/ix-menu-item.cjs.entry.js +25 -5
  118. package/dist/cjs/ix-menu-item.cjs.entry.js.map +1 -1
  119. package/dist/cjs/ix-menu-settings-item.cjs.entry.js +2 -2
  120. package/dist/cjs/ix-menu-settings.cjs.entry.js +2 -2
  121. package/dist/cjs/ix-menu.cjs.entry.js +5 -5
  122. package/dist/cjs/ix-menu.cjs.entry.js.map +1 -1
  123. package/dist/cjs/ix-message-bar.cjs.entry.js +3 -3
  124. package/dist/cjs/ix-message-bar.cjs.entry.js.map +1 -1
  125. package/dist/cjs/ix-modal-content_2.cjs.entry.js +3 -3
  126. package/dist/cjs/ix-modal-example.cjs.entry.js +3 -3
  127. package/dist/cjs/ix-modal-footer.cjs.entry.js +2 -2
  128. package/dist/cjs/ix-modal-loading.cjs.entry.js +2 -2
  129. package/dist/cjs/ix-modal.cjs.entry.js +8 -5
  130. package/dist/cjs/ix-modal.cjs.entry.js.map +1 -1
  131. package/dist/cjs/ix-pagination.cjs.entry.js +4 -4
  132. package/dist/cjs/ix-pane-layout.cjs.entry.js +10 -2
  133. package/dist/cjs/ix-pane-layout.cjs.entry.js.map +1 -1
  134. package/dist/cjs/ix-pane.cjs.entry.js +52 -23
  135. package/dist/cjs/ix-pane.cjs.entry.js.map +1 -1
  136. package/dist/cjs/ix-pill.cjs.entry.js +5 -5
  137. package/dist/cjs/ix-playground-internal.cjs.entry.js +2 -2
  138. package/dist/cjs/ix-push-card.cjs.entry.js +1 -1
  139. package/dist/cjs/ix-select.cjs.entry.js +8 -8
  140. package/dist/cjs/ix-slider.cjs.entry.js +2 -2
  141. package/dist/cjs/ix-split-button-item.cjs.entry.js +2 -2
  142. package/dist/cjs/ix-split-button.cjs.entry.js +1 -1
  143. package/dist/cjs/ix-tab-item_2.cjs.entry.js +3 -3
  144. package/dist/cjs/ix-tile.cjs.entry.js +5 -5
  145. package/dist/cjs/ix-time-picker.cjs.entry.js +1 -1
  146. package/dist/cjs/ix-toast-container.cjs.entry.js +2 -2
  147. package/dist/cjs/ix-toast.cjs.entry.js +3 -3
  148. package/dist/cjs/ix-toggle-button.cjs.entry.js +4 -4
  149. package/dist/cjs/ix-toggle.cjs.entry.js +3 -3
  150. package/dist/cjs/ix-tooltip.cjs.entry.js +19 -24
  151. package/dist/cjs/ix-tooltip.cjs.entry.js.map +1 -1
  152. package/dist/cjs/ix-tree-item.cjs.entry.js +5 -5
  153. package/dist/cjs/ix-tree.cjs.entry.js +2 -2
  154. package/dist/cjs/ix-typography.cjs.entry.js +1 -1
  155. package/dist/cjs/ix-upload.cjs.entry.js +4 -4
  156. package/dist/cjs/ix-validation-tooltip.cjs.entry.js +3 -3
  157. package/dist/cjs/ix-workflow-step.cjs.entry.js +4 -4
  158. package/dist/cjs/ix-workflow-steps.cjs.entry.js +2 -2
  159. package/dist/cjs/{listener-ad035304.js → listener-c0d191a7.js} +2 -2
  160. package/dist/cjs/{listener-ad035304.js.map → listener-c0d191a7.js.map} +1 -1
  161. package/dist/cjs/loader.cjs.js +4 -4
  162. package/dist/cjs/loader.cjs.js.map +1 -1
  163. package/dist/cjs/{menu-tabs-fc-78915307.js → menu-tabs-fc-b6a9af97.js} +2 -2
  164. package/dist/cjs/{menu-tabs-fc-78915307.js.map → menu-tabs-fc-b6a9af97.js.map} +1 -1
  165. package/dist/cjs/{modal-bf597938.js → modal-828cb80a.js} +2 -2
  166. package/dist/cjs/modal-828cb80a.js.map +1 -0
  167. package/dist/cjs/siemens-ix.cjs.js +5 -5
  168. package/dist/cjs/siemens-ix.cjs.js.map +1 -1
  169. package/dist/collection/collection-manifest.json +1 -1
  170. package/dist/collection/components/dropdown/dropdown-controller.js +13 -6
  171. package/dist/collection/components/dropdown/dropdown-controller.js.map +1 -1
  172. package/dist/collection/components/dropdown/dropdown.js +8 -7
  173. package/dist/collection/components/dropdown/dropdown.js.map +1 -1
  174. package/dist/collection/components/dropdown/test/dropdown-controller.spec.js +21 -0
  175. package/dist/collection/components/dropdown/test/dropdown-controller.spec.js.map +1 -0
  176. package/dist/collection/components/menu/burger-menu.css +0 -3
  177. package/dist/collection/components/menu/burger-menu.js +1 -1
  178. package/dist/collection/components/menu/burger-menu.js.map +1 -1
  179. package/dist/collection/components/menu/menu.js +2 -2
  180. package/dist/collection/components/menu/menu.js.map +1 -1
  181. package/dist/collection/components/menu/test/menu.ct.js +11 -0
  182. package/dist/collection/components/menu/test/menu.ct.js.map +1 -1
  183. package/dist/collection/components/menu-avatar-item/test/menu-avatar-item.ct.js +47 -0
  184. package/dist/collection/components/menu-avatar-item/test/menu-avatar-item.ct.js.map +1 -0
  185. package/dist/collection/components/menu-category/menu-category.css +22 -3
  186. package/dist/collection/components/menu-category/menu-category.js +18 -6
  187. package/dist/collection/components/menu-category/menu-category.js.map +1 -1
  188. package/dist/collection/components/menu-category/test/menu-category.ct.js +50 -2
  189. package/dist/collection/components/menu-category/test/menu-category.ct.js.map +1 -1
  190. package/dist/collection/components/menu-item/menu-item.css +18 -1
  191. package/dist/collection/components/menu-item/menu-item.js +31 -7
  192. package/dist/collection/components/menu-item/menu-item.js.map +1 -1
  193. package/dist/collection/components/menu-settings-item/menu-settings-item.js +1 -1
  194. package/dist/collection/components/message-bar/message-bar.css +2 -2
  195. package/dist/collection/components/message-bar/message-bar.js +1 -1
  196. package/dist/collection/components/modal/modal.js +6 -3
  197. package/dist/collection/components/modal/modal.js.map +1 -1
  198. package/dist/collection/components/modal/test/modal.ct.js +76 -0
  199. package/dist/collection/components/modal/test/modal.ct.js.map +1 -1
  200. package/dist/collection/components/modal-content/modal-content.js +1 -1
  201. package/dist/collection/components/modal-footer/modal-footer.js +1 -1
  202. package/dist/collection/components/modal-header/modal-header.js +1 -1
  203. package/dist/collection/components/modal-loading/modal-loading.js +1 -1
  204. package/dist/collection/components/pagination/pagination.js +2 -2
  205. package/dist/collection/components/pane/pane.css +7 -9
  206. package/dist/collection/components/pane/pane.js +50 -21
  207. package/dist/collection/components/pane/pane.js.map +1 -1
  208. package/dist/collection/components/pane-layout/pane-layout.js +9 -1
  209. package/dist/collection/components/pane-layout/pane-layout.js.map +1 -1
  210. package/dist/collection/components/pane-layout/test/pane-layout.ct.js +2 -0
  211. package/dist/collection/components/pane-layout/test/pane-layout.ct.js.map +1 -1
  212. package/dist/collection/components/pill/pill.js +4 -4
  213. package/dist/collection/components/playground/example-modal.js +1 -1
  214. package/dist/collection/components/playground/playground.js +1 -1
  215. package/dist/collection/components/row/row.js +1 -1
  216. package/dist/collection/components/select/select.js +6 -6
  217. package/dist/collection/components/select-item/select-item.js +1 -1
  218. package/dist/collection/components/spinner/spinner.js +1 -1
  219. package/dist/collection/components/split-button-item/split-button-item.js +1 -1
  220. package/dist/collection/components/tabs/tabs.js +2 -2
  221. package/dist/collection/components/tile/tile.js +4 -4
  222. package/dist/collection/components/toast/toast-container.js +1 -1
  223. package/dist/collection/components/toast/toast.js +2 -2
  224. package/dist/collection/components/toggle/toggle.js +2 -2
  225. package/dist/collection/components/toggle-button/toggle-button.js +2 -2
  226. package/dist/collection/components/tooltip/test/tooltip.ct.js +0 -18
  227. package/dist/collection/components/tooltip/test/tooltip.ct.js.map +1 -1
  228. package/dist/collection/components/tooltip/tooltip.js +17 -22
  229. package/dist/collection/components/tooltip/tooltip.js.map +1 -1
  230. package/dist/collection/components/tree/tree.js +1 -1
  231. package/dist/collection/components/tree-item/tree-item.js +4 -4
  232. package/dist/collection/components/upload/upload.js +3 -3
  233. package/dist/collection/components/utils/modal/modal.js +1 -1
  234. package/dist/collection/components/utils/modal/modal.js.map +1 -1
  235. package/dist/collection/components/validation-tooltip/validation-tooltip.js +2 -2
  236. package/dist/collection/components/workflow-step/workflow-step.js +3 -3
  237. package/dist/collection/components/workflow-steps/workflow-steps.js +1 -1
  238. package/dist/collection/tests/menu/menu.e2e.js +63 -38
  239. package/dist/collection/tests/menu/menu.e2e.js.map +1 -1
  240. package/dist/collection/tests/panes/panes.e2e.js +6 -0
  241. package/dist/collection/tests/panes/panes.e2e.js.map +1 -1
  242. package/dist/esm/{base-button-355ac631.js → base-button-c4987907.js} +2 -2
  243. package/dist/esm/{base-button-355ac631.js.map → base-button-c4987907.js.map} +1 -1
  244. package/dist/esm/{base-icon-button-030bd50c.js → base-icon-button-caf73c1d.js} +3 -3
  245. package/dist/esm/{base-icon-button-030bd50c.js.map → base-icon-button-caf73c1d.js.map} +1 -1
  246. package/dist/esm/{index-38dea61d.js → index-0d053ada.js} +35 -22
  247. package/dist/esm/index-0d053ada.js.map +1 -0
  248. package/dist/esm/{index-ff9bfca4.js → index-76b9c8de.js} +2 -2
  249. package/dist/esm/{index-ff9bfca4.js.map → index-76b9c8de.js.map} +1 -1
  250. package/dist/esm/index.js +2 -2
  251. package/dist/esm/ix-action-card.entry.js +1 -1
  252. package/dist/esm/ix-application-header.entry.js +3 -3
  253. package/dist/esm/ix-application-sidebar.entry.js +1 -1
  254. package/dist/esm/ix-application-switch-modal.entry.js +2 -2
  255. package/dist/esm/ix-application.entry.js +1 -1
  256. package/dist/esm/ix-avatar_2.entry.js +2 -2
  257. package/dist/esm/ix-basic-navigation.entry.js +1 -1
  258. package/dist/esm/ix-blind.entry.js +1 -1
  259. package/dist/esm/ix-breadcrumb-item.entry.js +2 -2
  260. package/dist/esm/ix-breadcrumb.entry.js +1 -1
  261. package/dist/esm/ix-burger-menu.entry.js +4 -4
  262. package/dist/esm/ix-burger-menu.entry.js.map +1 -1
  263. package/dist/esm/ix-button.entry.js +2 -2
  264. package/dist/esm/ix-card-accordion_2.entry.js +1 -1
  265. package/dist/esm/ix-card-list.entry.js +1 -1
  266. package/dist/esm/ix-card_2.entry.js +1 -1
  267. package/dist/esm/ix-category-filter.entry.js +2 -2
  268. package/dist/esm/ix-chip.entry.js +1 -1
  269. package/dist/esm/ix-col_4.entry.js +3 -3
  270. package/dist/esm/ix-content-header.entry.js +1 -1
  271. package/dist/esm/ix-content.entry.js +1 -1
  272. package/dist/esm/ix-css-grid-item.entry.js +1 -1
  273. package/dist/esm/ix-css-grid.entry.js +1 -1
  274. package/dist/esm/ix-date-dropdown.entry.js +1 -1
  275. package/dist/esm/ix-date-time-card.entry.js +1 -1
  276. package/dist/esm/ix-datetime-picker.entry.js +1 -1
  277. package/dist/esm/ix-divider.entry.js +1 -1
  278. package/dist/esm/ix-drawer.entry.js +1 -1
  279. package/dist/esm/ix-dropdown-button.entry.js +1 -1
  280. package/dist/esm/ix-dropdown-header.entry.js +1 -1
  281. package/dist/esm/ix-dropdown-item.entry.js +1 -1
  282. package/dist/esm/ix-dropdown-quick-actions.entry.js +1 -1
  283. package/dist/esm/ix-dropdown.entry.js +22 -14
  284. package/dist/esm/ix-dropdown.entry.js.map +1 -1
  285. package/dist/esm/ix-empty-state.entry.js +1 -1
  286. package/dist/esm/ix-event-list-item.entry.js +1 -1
  287. package/dist/esm/ix-event-list.entry.js +1 -1
  288. package/dist/esm/ix-expanding-search.entry.js +1 -1
  289. package/dist/esm/ix-filter-chip_2.entry.js +2 -2
  290. package/dist/esm/ix-flip-tile-content.entry.js +1 -1
  291. package/dist/esm/ix-flip-tile.entry.js +1 -1
  292. package/dist/esm/ix-form-field.entry.js +1 -1
  293. package/dist/esm/ix-group-context-menu_2.entry.js +1 -1
  294. package/dist/esm/ix-group.entry.js +1 -1
  295. package/dist/esm/ix-icon-button_2.entry.js +4 -4
  296. package/dist/esm/ix-icon-toggle-button.entry.js +3 -3
  297. package/dist/esm/ix-input-group.entry.js +1 -1
  298. package/dist/esm/ix-key-value-list.entry.js +1 -1
  299. package/dist/esm/ix-key-value.entry.js +1 -1
  300. package/dist/esm/ix-kpi.entry.js +1 -1
  301. package/dist/esm/ix-link-button.entry.js +1 -1
  302. package/dist/esm/ix-map-navigation-overlay.entry.js +1 -1
  303. package/dist/esm/ix-map-navigation.entry.js +1 -1
  304. package/dist/esm/ix-menu-about-item.entry.js +1 -1
  305. package/dist/esm/ix-menu-about-news.entry.js +1 -1
  306. package/dist/esm/ix-menu-about.entry.js +2 -2
  307. package/dist/esm/ix-menu-avatar.entry.js +1 -1
  308. package/dist/esm/ix-menu-category.entry.js +20 -8
  309. package/dist/esm/ix-menu-category.entry.js.map +1 -1
  310. package/dist/esm/ix-menu-item.entry.js +25 -5
  311. package/dist/esm/ix-menu-item.entry.js.map +1 -1
  312. package/dist/esm/ix-menu-settings-item.entry.js +2 -2
  313. package/dist/esm/ix-menu-settings.entry.js +2 -2
  314. package/dist/esm/ix-menu.entry.js +5 -5
  315. package/dist/esm/ix-menu.entry.js.map +1 -1
  316. package/dist/esm/ix-message-bar.entry.js +3 -3
  317. package/dist/esm/ix-message-bar.entry.js.map +1 -1
  318. package/dist/esm/ix-modal-content_2.entry.js +3 -3
  319. package/dist/esm/ix-modal-example.entry.js +3 -3
  320. package/dist/esm/ix-modal-footer.entry.js +2 -2
  321. package/dist/esm/ix-modal-loading.entry.js +2 -2
  322. package/dist/esm/ix-modal.entry.js +8 -5
  323. package/dist/esm/ix-modal.entry.js.map +1 -1
  324. package/dist/esm/ix-pagination.entry.js +4 -4
  325. package/dist/esm/ix-pane-layout.entry.js +10 -2
  326. package/dist/esm/ix-pane-layout.entry.js.map +1 -1
  327. package/dist/esm/ix-pane.entry.js +52 -23
  328. package/dist/esm/ix-pane.entry.js.map +1 -1
  329. package/dist/esm/ix-pill.entry.js +5 -5
  330. package/dist/esm/ix-playground-internal.entry.js +2 -2
  331. package/dist/esm/ix-push-card.entry.js +1 -1
  332. package/dist/esm/ix-select.entry.js +8 -8
  333. package/dist/esm/ix-slider.entry.js +2 -2
  334. package/dist/esm/ix-split-button-item.entry.js +2 -2
  335. package/dist/esm/ix-split-button.entry.js +1 -1
  336. package/dist/esm/ix-tab-item_2.entry.js +3 -3
  337. package/dist/esm/ix-tile.entry.js +5 -5
  338. package/dist/esm/ix-time-picker.entry.js +1 -1
  339. package/dist/esm/ix-toast-container.entry.js +2 -2
  340. package/dist/esm/ix-toast.entry.js +3 -3
  341. package/dist/esm/ix-toggle-button.entry.js +4 -4
  342. package/dist/esm/ix-toggle.entry.js +3 -3
  343. package/dist/esm/ix-tooltip.entry.js +19 -24
  344. package/dist/esm/ix-tooltip.entry.js.map +1 -1
  345. package/dist/esm/ix-tree-item.entry.js +5 -5
  346. package/dist/esm/ix-tree.entry.js +2 -2
  347. package/dist/esm/ix-typography.entry.js +1 -1
  348. package/dist/esm/ix-upload.entry.js +4 -4
  349. package/dist/esm/ix-validation-tooltip.entry.js +3 -3
  350. package/dist/esm/ix-workflow-step.entry.js +4 -4
  351. package/dist/esm/ix-workflow-steps.entry.js +2 -2
  352. package/dist/esm/{listener-23c93aa7.js → listener-cf8cb0b2.js} +2 -2
  353. package/dist/esm/{listener-23c93aa7.js.map → listener-cf8cb0b2.js.map} +1 -1
  354. package/dist/esm/loader.js +5 -5
  355. package/dist/esm/loader.js.map +1 -1
  356. package/dist/esm/{menu-tabs-fc-efc49c04.js → menu-tabs-fc-7b7acc8b.js} +2 -2
  357. package/dist/esm/{menu-tabs-fc-efc49c04.js.map → menu-tabs-fc-7b7acc8b.js.map} +1 -1
  358. package/dist/esm/{modal-8bc5477b.js → modal-54740f80.js} +2 -2
  359. package/dist/esm/modal-54740f80.js.map +1 -0
  360. package/dist/esm/siemens-ix.js +6 -6
  361. package/dist/esm/siemens-ix.js.map +1 -1
  362. package/dist/siemens-ix/index.esm.js +1 -1
  363. package/dist/siemens-ix/{p-ad01ee70.js → p-004cade9.js} +2 -2
  364. package/dist/siemens-ix/{p-6e0a8877.entry.js → p-050f482a.entry.js} +2 -2
  365. package/dist/siemens-ix/{p-31748d33.entry.js → p-064a1a47.entry.js} +2 -2
  366. package/dist/siemens-ix/{p-7c2c24ff.entry.js → p-06b783a7.entry.js} +2 -2
  367. package/dist/siemens-ix/p-0ca3528f.js +2 -0
  368. package/dist/siemens-ix/{p-90f69373.entry.js → p-0e0e5f67.entry.js} +2 -2
  369. package/dist/siemens-ix/{p-0fc4bda8.entry.js → p-0e51828d.entry.js} +2 -2
  370. package/dist/siemens-ix/p-0e51828d.entry.js.map +1 -0
  371. package/dist/siemens-ix/{p-26ed3dec.entry.js → p-14d2576e.entry.js} +2 -2
  372. package/dist/siemens-ix/{p-98d1e861.entry.js → p-196d2cef.entry.js} +2 -2
  373. package/dist/siemens-ix/p-1aa9c005.entry.js +2 -0
  374. package/dist/siemens-ix/p-1aa9c005.entry.js.map +1 -0
  375. package/dist/siemens-ix/p-1e5e042b.entry.js +2 -0
  376. package/dist/siemens-ix/p-1e5e042b.entry.js.map +1 -0
  377. package/dist/siemens-ix/{p-0d5ae5ed.entry.js → p-22a792da.entry.js} +2 -2
  378. package/dist/siemens-ix/p-232bee46.entry.js +2 -0
  379. package/dist/siemens-ix/{p-6605180d.entry.js → p-2462fc76.entry.js} +2 -2
  380. package/dist/siemens-ix/{p-9808e98a.entry.js → p-26355e12.entry.js} +2 -2
  381. package/dist/siemens-ix/{p-247099fc.entry.js → p-27118d3b.entry.js} +2 -2
  382. package/dist/siemens-ix/{p-5f9bb7c9.entry.js → p-2cdd0028.entry.js} +2 -2
  383. package/dist/siemens-ix/{p-aeb745b9.entry.js → p-2deed888.entry.js} +2 -2
  384. package/dist/siemens-ix/{p-bf2ac29f.entry.js → p-31bfd5ff.entry.js} +2 -2
  385. package/dist/siemens-ix/p-3214478e.entry.js +2 -0
  386. package/dist/siemens-ix/p-3214478e.entry.js.map +1 -0
  387. package/dist/siemens-ix/p-34ccbe57.entry.js +2 -0
  388. package/dist/siemens-ix/{p-40fc3093.entry.js.map → p-34ccbe57.entry.js.map} +1 -1
  389. package/dist/siemens-ix/{p-89eb95bd.entry.js → p-353e2dd5.entry.js} +2 -2
  390. package/dist/siemens-ix/{p-9f03e475.entry.js → p-37d299a4.entry.js} +2 -2
  391. package/dist/siemens-ix/{p-92768144.entry.js → p-3bc095f3.entry.js} +2 -2
  392. package/dist/siemens-ix/{p-95642364.entry.js → p-3c0425f3.entry.js} +2 -2
  393. package/dist/siemens-ix/p-3c6e6130.entry.js +2 -0
  394. package/dist/siemens-ix/{p-69c97e5d.entry.js → p-3ead4fed.entry.js} +2 -2
  395. package/dist/siemens-ix/{p-a76b2311.entry.js → p-40335e7c.entry.js} +2 -2
  396. package/dist/siemens-ix/{p-3ef64d06.entry.js → p-42f7289e.entry.js} +2 -2
  397. package/dist/siemens-ix/{p-96e50b3a.entry.js → p-47919d43.entry.js} +2 -2
  398. package/dist/siemens-ix/{p-e0a04248.entry.js → p-4bb08459.entry.js} +2 -2
  399. package/dist/siemens-ix/{p-85a34aff.entry.js → p-4c29feb5.entry.js} +2 -2
  400. package/dist/siemens-ix/{p-b10cfca0.entry.js → p-4dad31fa.entry.js} +2 -2
  401. package/dist/siemens-ix/{p-cee05d4a.entry.js → p-50f12507.entry.js} +2 -2
  402. package/dist/siemens-ix/{p-cf14d460.entry.js → p-535ee46b.entry.js} +2 -2
  403. package/dist/siemens-ix/{p-ce88799e.entry.js → p-572455df.entry.js} +2 -2
  404. package/dist/siemens-ix/{p-f0be2cd7.entry.js → p-58f51cce.entry.js} +2 -2
  405. package/dist/siemens-ix/{p-cc3ea7bf.entry.js → p-5ca2ef74.entry.js} +2 -2
  406. package/dist/siemens-ix/{p-5df4d3f6.entry.js → p-5d3975c8.entry.js} +2 -2
  407. package/dist/siemens-ix/{p-b9bc0b4c.entry.js → p-5dd97d39.entry.js} +2 -2
  408. package/dist/siemens-ix/{p-5db56877.entry.js → p-5f74fc83.entry.js} +2 -2
  409. package/dist/siemens-ix/{p-b79b8967.entry.js → p-6a8d50c3.entry.js} +2 -2
  410. package/dist/siemens-ix/{p-b79b8967.entry.js.map → p-6a8d50c3.entry.js.map} +1 -1
  411. package/dist/siemens-ix/{p-340a7dcf.entry.js → p-6cd2b4d4.entry.js} +2 -2
  412. package/dist/siemens-ix/{p-06ac510a.js → p-6e5beede.js} +2 -2
  413. package/dist/siemens-ix/p-6e6efb4c.js +2 -0
  414. package/dist/siemens-ix/{p-2679a484.js.map → p-6e6efb4c.js.map} +1 -1
  415. package/dist/siemens-ix/{p-2a48e3c2.entry.js → p-73d5ea4a.entry.js} +2 -2
  416. package/dist/siemens-ix/{p-ba379675.entry.js → p-75050430.entry.js} +2 -2
  417. package/dist/siemens-ix/{p-0ff62c64.entry.js → p-75943110.entry.js} +2 -2
  418. package/dist/siemens-ix/p-75943110.entry.js.map +1 -0
  419. package/dist/siemens-ix/{p-3c043135.entry.js → p-782b33d3.entry.js} +2 -2
  420. package/dist/siemens-ix/p-78e332f4.entry.js +2 -0
  421. package/dist/siemens-ix/{p-830cada0.entry.js → p-81b570f5.entry.js} +2 -2
  422. package/dist/siemens-ix/p-8493da96.entry.js +2 -0
  423. package/dist/siemens-ix/{p-350f0c29.entry.js.map → p-8493da96.entry.js.map} +1 -1
  424. package/dist/siemens-ix/{p-da641f25.entry.js → p-8b1add8f.entry.js} +2 -2
  425. package/dist/siemens-ix/{p-44ff88dd.entry.js → p-8b51637c.entry.js} +2 -2
  426. package/dist/siemens-ix/{p-5ebe2601.entry.js → p-8be3bc6d.entry.js} +2 -2
  427. package/dist/siemens-ix/{p-73064959.entry.js → p-8c01fea2.entry.js} +2 -2
  428. package/dist/siemens-ix/p-8efe88e8.entry.js +2 -0
  429. package/dist/siemens-ix/p-8efe88e8.entry.js.map +1 -0
  430. package/dist/siemens-ix/{p-48268ca1.entry.js → p-92fc6ba1.entry.js} +2 -2
  431. package/dist/siemens-ix/p-975cb736.entry.js +2 -0
  432. package/dist/siemens-ix/{p-c7311667.entry.js → p-988d23ac.entry.js} +2 -2
  433. package/dist/siemens-ix/{p-91331a62.entry.js → p-9ceabb5f.entry.js} +2 -2
  434. package/dist/siemens-ix/{p-c56c1f11.entry.js → p-a3431d63.entry.js} +2 -2
  435. package/dist/siemens-ix/{p-3763fb0e.entry.js → p-a643ad05.entry.js} +2 -2
  436. package/dist/siemens-ix/{p-94e82b85.entry.js → p-ab282d03.entry.js} +2 -2
  437. package/dist/siemens-ix/{p-cb61d053.entry.js → p-b4e3a4fd.entry.js} +2 -2
  438. package/dist/siemens-ix/p-b4e3a4fd.entry.js.map +1 -0
  439. package/dist/siemens-ix/{p-64ee9c6b.entry.js → p-b62e2edf.entry.js} +2 -2
  440. package/dist/siemens-ix/{p-db227cd4.entry.js → p-c0bf9382.entry.js} +2 -2
  441. package/dist/siemens-ix/{p-8482064b.entry.js → p-ca53ecd8.entry.js} +2 -2
  442. package/dist/siemens-ix/{p-596f9406.entry.js → p-ca8407f5.entry.js} +2 -2
  443. package/dist/siemens-ix/p-cfc7a9ac.entry.js +2 -0
  444. package/dist/siemens-ix/p-cfc7a9ac.entry.js.map +1 -0
  445. package/dist/siemens-ix/{p-0f679fd8.entry.js → p-d277e7e2.entry.js} +2 -2
  446. package/dist/siemens-ix/{p-6504d262.entry.js → p-d445b333.entry.js} +2 -2
  447. package/dist/siemens-ix/{p-488055c0.entry.js → p-d464b60e.entry.js} +2 -2
  448. package/dist/siemens-ix/{p-731a81c6.entry.js → p-d59b3f31.entry.js} +2 -2
  449. package/dist/siemens-ix/{p-7d06e487.entry.js → p-d6e7e5da.entry.js} +2 -2
  450. package/dist/siemens-ix/p-da9f8709.entry.js +2 -0
  451. package/dist/siemens-ix/{p-d42d4c2e.entry.js → p-db47293b.entry.js} +2 -2
  452. package/dist/siemens-ix/{p-74472b15.entry.js → p-ddf93bce.entry.js} +2 -2
  453. package/dist/siemens-ix/{p-a4c02371.entry.js → p-e1b790d3.entry.js} +2 -2
  454. package/dist/siemens-ix/{p-6ebf07ba.entry.js → p-e1d7c7fa.entry.js} +2 -2
  455. package/dist/siemens-ix/{p-a5496783.entry.js → p-e345d0d2.entry.js} +2 -2
  456. package/dist/siemens-ix/p-ea80cb61.js +3 -0
  457. package/dist/siemens-ix/p-ea80cb61.js.map +1 -0
  458. package/dist/siemens-ix/{p-9c6df184.entry.js → p-eb6ea42d.entry.js} +2 -2
  459. package/dist/siemens-ix/p-ef38f3a0.js +2 -0
  460. package/dist/siemens-ix/{p-657fc30d.js → p-f0e7e035.js} +2 -2
  461. package/dist/siemens-ix/{p-7f66d83d.entry.js → p-f10824af.entry.js} +2 -2
  462. package/dist/siemens-ix/{p-0fa87626.entry.js → p-f1635e06.entry.js} +2 -2
  463. package/dist/siemens-ix/{p-1582a3c6.entry.js → p-f1e94d25.entry.js} +2 -2
  464. package/dist/siemens-ix/{p-2634d651.entry.js → p-f2ee640a.entry.js} +2 -2
  465. package/dist/siemens-ix/{p-3b3caf9a.entry.js → p-f56686c9.entry.js} +2 -2
  466. package/dist/siemens-ix/{p-8f6e4b39.entry.js → p-f5a108d5.entry.js} +2 -2
  467. package/dist/siemens-ix/{p-794bfde0.entry.js → p-f5af5a9f.entry.js} +2 -2
  468. package/dist/siemens-ix/{p-1f67076b.entry.js → p-f6691728.entry.js} +2 -2
  469. package/dist/siemens-ix/{p-757b8af2.entry.js → p-f8169051.entry.js} +2 -2
  470. package/dist/siemens-ix/{p-97cb6155.entry.js → p-fc5fd951.entry.js} +2 -2
  471. package/dist/siemens-ix/{p-9a19d0ba.entry.js → p-fcbe42c4.entry.js} +2 -2
  472. package/dist/siemens-ix/{p-52a89d75.entry.js → p-fdccc402.entry.js} +2 -2
  473. package/dist/siemens-ix/p-fe760d17.entry.js +2 -0
  474. package/dist/siemens-ix/siemens-ix.esm.js +1 -1
  475. package/dist/siemens-ix/siemens-ix.esm.js.map +1 -1
  476. package/dist/types/components/dropdown/dropdown-controller.d.ts +1 -1
  477. package/dist/types/components/menu-avatar-item/test/menu-avatar-item.ct.d.ts +1 -0
  478. package/dist/types/components/menu-category/menu-category.d.ts +2 -0
  479. package/dist/types/components/menu-item/menu-item.d.ts +2 -0
  480. package/dist/types/components/pane/pane.d.ts +4 -0
  481. package/dist/types/components/pane-layout/pane-layout.d.ts +1 -0
  482. package/dist/types/components/tooltip/tooltip.d.ts +1 -3
  483. package/package.json +2 -2
  484. package/scss/theme/classic-dark/_borderRadius.scss +1 -1
  485. package/scss/theme/classic-dark/_borderWidth.scss +1 -1
  486. package/scss/theme/classic-light/_borderRadius.scss +1 -1
  487. package/scss/theme/classic-light/_borderWidth.scss +1 -1
  488. package/dist/cjs/index-ace435aa.js.map +0 -1
  489. package/dist/cjs/modal-bf597938.js.map +0 -1
  490. package/dist/esm/index-38dea61d.js.map +0 -1
  491. package/dist/esm/modal-8bc5477b.js.map +0 -1
  492. package/dist/siemens-ix/p-03e4b68a.entry.js +0 -2
  493. package/dist/siemens-ix/p-0fc4bda8.entry.js.map +0 -1
  494. package/dist/siemens-ix/p-0ff62c64.entry.js.map +0 -1
  495. package/dist/siemens-ix/p-2679a484.js +0 -2
  496. package/dist/siemens-ix/p-3082ad93.entry.js +0 -2
  497. package/dist/siemens-ix/p-3082ad93.entry.js.map +0 -1
  498. package/dist/siemens-ix/p-350f0c29.entry.js +0 -2
  499. package/dist/siemens-ix/p-3c03baf3.entry.js +0 -2
  500. package/dist/siemens-ix/p-3c03baf3.entry.js.map +0 -1
  501. package/dist/siemens-ix/p-40fc3093.entry.js +0 -2
  502. package/dist/siemens-ix/p-7b9c848c.entry.js +0 -2
  503. package/dist/siemens-ix/p-8b1e1c0b.entry.js +0 -2
  504. package/dist/siemens-ix/p-8b7c8f71.entry.js +0 -2
  505. package/dist/siemens-ix/p-97b19267.js +0 -2
  506. package/dist/siemens-ix/p-98b3368c.js +0 -2
  507. package/dist/siemens-ix/p-a2bb9a69.entry.js +0 -2
  508. package/dist/siemens-ix/p-a2bb9a69.entry.js.map +0 -1
  509. package/dist/siemens-ix/p-a9cf5eb2.js +0 -3
  510. package/dist/siemens-ix/p-a9cf5eb2.js.map +0 -1
  511. package/dist/siemens-ix/p-abc9c138.entry.js +0 -2
  512. package/dist/siemens-ix/p-abc9c138.entry.js.map +0 -1
  513. package/dist/siemens-ix/p-b4ca36ac.entry.js +0 -2
  514. package/dist/siemens-ix/p-c5965787.entry.js +0 -2
  515. package/dist/siemens-ix/p-c5965787.entry.js.map +0 -1
  516. package/dist/siemens-ix/p-c65dca4b.entry.js +0 -2
  517. package/dist/siemens-ix/p-cb61d053.entry.js.map +0 -1
  518. /package/dist/siemens-ix/{p-ad01ee70.js.map → p-004cade9.js.map} +0 -0
  519. /package/dist/siemens-ix/{p-6e0a8877.entry.js.map → p-050f482a.entry.js.map} +0 -0
  520. /package/dist/siemens-ix/{p-31748d33.entry.js.map → p-064a1a47.entry.js.map} +0 -0
  521. /package/dist/siemens-ix/{p-7c2c24ff.entry.js.map → p-06b783a7.entry.js.map} +0 -0
  522. /package/dist/siemens-ix/{p-98b3368c.js.map → p-0ca3528f.js.map} +0 -0
  523. /package/dist/siemens-ix/{p-90f69373.entry.js.map → p-0e0e5f67.entry.js.map} +0 -0
  524. /package/dist/siemens-ix/{p-26ed3dec.entry.js.map → p-14d2576e.entry.js.map} +0 -0
  525. /package/dist/siemens-ix/{p-98d1e861.entry.js.map → p-196d2cef.entry.js.map} +0 -0
  526. /package/dist/siemens-ix/{p-0d5ae5ed.entry.js.map → p-22a792da.entry.js.map} +0 -0
  527. /package/dist/siemens-ix/{p-b4ca36ac.entry.js.map → p-232bee46.entry.js.map} +0 -0
  528. /package/dist/siemens-ix/{p-6605180d.entry.js.map → p-2462fc76.entry.js.map} +0 -0
  529. /package/dist/siemens-ix/{p-9808e98a.entry.js.map → p-26355e12.entry.js.map} +0 -0
  530. /package/dist/siemens-ix/{p-247099fc.entry.js.map → p-27118d3b.entry.js.map} +0 -0
  531. /package/dist/siemens-ix/{p-5f9bb7c9.entry.js.map → p-2cdd0028.entry.js.map} +0 -0
  532. /package/dist/siemens-ix/{p-aeb745b9.entry.js.map → p-2deed888.entry.js.map} +0 -0
  533. /package/dist/siemens-ix/{p-bf2ac29f.entry.js.map → p-31bfd5ff.entry.js.map} +0 -0
  534. /package/dist/siemens-ix/{p-89eb95bd.entry.js.map → p-353e2dd5.entry.js.map} +0 -0
  535. /package/dist/siemens-ix/{p-9f03e475.entry.js.map → p-37d299a4.entry.js.map} +0 -0
  536. /package/dist/siemens-ix/{p-92768144.entry.js.map → p-3bc095f3.entry.js.map} +0 -0
  537. /package/dist/siemens-ix/{p-95642364.entry.js.map → p-3c0425f3.entry.js.map} +0 -0
  538. /package/dist/siemens-ix/{p-7b9c848c.entry.js.map → p-3c6e6130.entry.js.map} +0 -0
  539. /package/dist/siemens-ix/{p-69c97e5d.entry.js.map → p-3ead4fed.entry.js.map} +0 -0
  540. /package/dist/siemens-ix/{p-a76b2311.entry.js.map → p-40335e7c.entry.js.map} +0 -0
  541. /package/dist/siemens-ix/{p-3ef64d06.entry.js.map → p-42f7289e.entry.js.map} +0 -0
  542. /package/dist/siemens-ix/{p-96e50b3a.entry.js.map → p-47919d43.entry.js.map} +0 -0
  543. /package/dist/siemens-ix/{p-e0a04248.entry.js.map → p-4bb08459.entry.js.map} +0 -0
  544. /package/dist/siemens-ix/{p-85a34aff.entry.js.map → p-4c29feb5.entry.js.map} +0 -0
  545. /package/dist/siemens-ix/{p-b10cfca0.entry.js.map → p-4dad31fa.entry.js.map} +0 -0
  546. /package/dist/siemens-ix/{p-cee05d4a.entry.js.map → p-50f12507.entry.js.map} +0 -0
  547. /package/dist/siemens-ix/{p-cf14d460.entry.js.map → p-535ee46b.entry.js.map} +0 -0
  548. /package/dist/siemens-ix/{p-ce88799e.entry.js.map → p-572455df.entry.js.map} +0 -0
  549. /package/dist/siemens-ix/{p-f0be2cd7.entry.js.map → p-58f51cce.entry.js.map} +0 -0
  550. /package/dist/siemens-ix/{p-cc3ea7bf.entry.js.map → p-5ca2ef74.entry.js.map} +0 -0
  551. /package/dist/siemens-ix/{p-5df4d3f6.entry.js.map → p-5d3975c8.entry.js.map} +0 -0
  552. /package/dist/siemens-ix/{p-b9bc0b4c.entry.js.map → p-5dd97d39.entry.js.map} +0 -0
  553. /package/dist/siemens-ix/{p-5db56877.entry.js.map → p-5f74fc83.entry.js.map} +0 -0
  554. /package/dist/siemens-ix/{p-340a7dcf.entry.js.map → p-6cd2b4d4.entry.js.map} +0 -0
  555. /package/dist/siemens-ix/{p-06ac510a.js.map → p-6e5beede.js.map} +0 -0
  556. /package/dist/siemens-ix/{p-2a48e3c2.entry.js.map → p-73d5ea4a.entry.js.map} +0 -0
  557. /package/dist/siemens-ix/{p-ba379675.entry.js.map → p-75050430.entry.js.map} +0 -0
  558. /package/dist/siemens-ix/{p-3c043135.entry.js.map → p-782b33d3.entry.js.map} +0 -0
  559. /package/dist/siemens-ix/{p-8b7c8f71.entry.js.map → p-78e332f4.entry.js.map} +0 -0
  560. /package/dist/siemens-ix/{p-830cada0.entry.js.map → p-81b570f5.entry.js.map} +0 -0
  561. /package/dist/siemens-ix/{p-da641f25.entry.js.map → p-8b1add8f.entry.js.map} +0 -0
  562. /package/dist/siemens-ix/{p-44ff88dd.entry.js.map → p-8b51637c.entry.js.map} +0 -0
  563. /package/dist/siemens-ix/{p-5ebe2601.entry.js.map → p-8be3bc6d.entry.js.map} +0 -0
  564. /package/dist/siemens-ix/{p-73064959.entry.js.map → p-8c01fea2.entry.js.map} +0 -0
  565. /package/dist/siemens-ix/{p-48268ca1.entry.js.map → p-92fc6ba1.entry.js.map} +0 -0
  566. /package/dist/siemens-ix/{p-c65dca4b.entry.js.map → p-975cb736.entry.js.map} +0 -0
  567. /package/dist/siemens-ix/{p-c7311667.entry.js.map → p-988d23ac.entry.js.map} +0 -0
  568. /package/dist/siemens-ix/{p-91331a62.entry.js.map → p-9ceabb5f.entry.js.map} +0 -0
  569. /package/dist/siemens-ix/{p-c56c1f11.entry.js.map → p-a3431d63.entry.js.map} +0 -0
  570. /package/dist/siemens-ix/{p-3763fb0e.entry.js.map → p-a643ad05.entry.js.map} +0 -0
  571. /package/dist/siemens-ix/{p-94e82b85.entry.js.map → p-ab282d03.entry.js.map} +0 -0
  572. /package/dist/siemens-ix/{p-64ee9c6b.entry.js.map → p-b62e2edf.entry.js.map} +0 -0
  573. /package/dist/siemens-ix/{p-db227cd4.entry.js.map → p-c0bf9382.entry.js.map} +0 -0
  574. /package/dist/siemens-ix/{p-8482064b.entry.js.map → p-ca53ecd8.entry.js.map} +0 -0
  575. /package/dist/siemens-ix/{p-596f9406.entry.js.map → p-ca8407f5.entry.js.map} +0 -0
  576. /package/dist/siemens-ix/{p-0f679fd8.entry.js.map → p-d277e7e2.entry.js.map} +0 -0
  577. /package/dist/siemens-ix/{p-6504d262.entry.js.map → p-d445b333.entry.js.map} +0 -0
  578. /package/dist/siemens-ix/{p-488055c0.entry.js.map → p-d464b60e.entry.js.map} +0 -0
  579. /package/dist/siemens-ix/{p-731a81c6.entry.js.map → p-d59b3f31.entry.js.map} +0 -0
  580. /package/dist/siemens-ix/{p-7d06e487.entry.js.map → p-d6e7e5da.entry.js.map} +0 -0
  581. /package/dist/siemens-ix/{p-8b1e1c0b.entry.js.map → p-da9f8709.entry.js.map} +0 -0
  582. /package/dist/siemens-ix/{p-d42d4c2e.entry.js.map → p-db47293b.entry.js.map} +0 -0
  583. /package/dist/siemens-ix/{p-74472b15.entry.js.map → p-ddf93bce.entry.js.map} +0 -0
  584. /package/dist/siemens-ix/{p-a4c02371.entry.js.map → p-e1b790d3.entry.js.map} +0 -0
  585. /package/dist/siemens-ix/{p-6ebf07ba.entry.js.map → p-e1d7c7fa.entry.js.map} +0 -0
  586. /package/dist/siemens-ix/{p-a5496783.entry.js.map → p-e345d0d2.entry.js.map} +0 -0
  587. /package/dist/siemens-ix/{p-9c6df184.entry.js.map → p-eb6ea42d.entry.js.map} +0 -0
  588. /package/dist/siemens-ix/{p-97b19267.js.map → p-ef38f3a0.js.map} +0 -0
  589. /package/dist/siemens-ix/{p-657fc30d.js.map → p-f0e7e035.js.map} +0 -0
  590. /package/dist/siemens-ix/{p-7f66d83d.entry.js.map → p-f10824af.entry.js.map} +0 -0
  591. /package/dist/siemens-ix/{p-0fa87626.entry.js.map → p-f1635e06.entry.js.map} +0 -0
  592. /package/dist/siemens-ix/{p-1582a3c6.entry.js.map → p-f1e94d25.entry.js.map} +0 -0
  593. /package/dist/siemens-ix/{p-2634d651.entry.js.map → p-f2ee640a.entry.js.map} +0 -0
  594. /package/dist/siemens-ix/{p-3b3caf9a.entry.js.map → p-f56686c9.entry.js.map} +0 -0
  595. /package/dist/siemens-ix/{p-8f6e4b39.entry.js.map → p-f5a108d5.entry.js.map} +0 -0
  596. /package/dist/siemens-ix/{p-794bfde0.entry.js.map → p-f5af5a9f.entry.js.map} +0 -0
  597. /package/dist/siemens-ix/{p-1f67076b.entry.js.map → p-f6691728.entry.js.map} +0 -0
  598. /package/dist/siemens-ix/{p-757b8af2.entry.js.map → p-f8169051.entry.js.map} +0 -0
  599. /package/dist/siemens-ix/{p-97cb6155.entry.js.map → p-fc5fd951.entry.js.map} +0 -0
  600. /package/dist/siemens-ix/{p-9a19d0ba.entry.js.map → p-fcbe42c4.entry.js.map} +0 -0
  601. /package/dist/siemens-ix/{p-52a89d75.entry.js.map → p-fdccc402.entry.js.map} +0 -0
  602. /package/dist/siemens-ix/{p-03e4b68a.entry.js.map → p-fe760d17.entry.js.map} +0 -0
@@ -409,14 +409,14 @@ export class Menu {
409
409
  'internal-tab': true,
410
410
  'bottom-tab': true,
411
411
  active: this.showAbout,
412
- }, icon: 'info', onClick: async () => this.toggleAbout(!this.showAbout) }, this.i18nLegal)) : null, this.enableToggleTheme ? (h("ix-menu-item", { disabled: this.isHiddenFromViewport(), id: "toggleTheme", onClick: () => themeSwitcher.toggleMode(), class: "internal-tab bottom-tab", icon: 'bulb' }, this.i18nToggleTheme)) : null, this.enableMapExpand || ((_a = this.applicationLayoutContext) === null || _a === void 0 ? void 0 : _a.sidebar) ? (h("ix-menu-item", { disabled: this.isHiddenFromViewport(), id: "menu-collapse", onClick: () => this.sidebarToggle(), class: "internal-tab bottom-tab", icon: `${this.getCollapseIcon()}` }, this.getCollapseText())) : null), h("div", { key: 'ee4db379f8d07738ce3c1fa6f71292a659de314f', class: {
412
+ }, icon: 'info', onClick: async () => this.toggleAbout(!this.showAbout) }, this.i18nLegal)) : null, this.enableToggleTheme ? (h("ix-menu-item", { disabled: this.isHiddenFromViewport(), id: "toggleTheme", onClick: () => themeSwitcher.toggleMode(), class: "internal-tab bottom-tab", icon: 'light-dark' }, this.i18nToggleTheme)) : null, this.enableMapExpand || ((_a = this.applicationLayoutContext) === null || _a === void 0 ? void 0 : _a.sidebar) ? (h("ix-menu-item", { disabled: this.isHiddenFromViewport(), id: "menu-collapse", onClick: () => this.sidebarToggle(), class: "internal-tab bottom-tab", icon: `${this.getCollapseIcon()}` }, this.getCollapseText())) : null), h("div", { key: 'cc7443de9d327194cc7aff083033111642440efc', class: {
413
413
  'menu-overlay': true,
414
414
  visible: this.isOverlayVisible(),
415
415
  expanded: this.expand,
416
416
  }, onTransitionEnd: () => {
417
417
  this.isTransitionDisabled = true;
418
418
  this.checkTransition();
419
- } }, h("div", { key: 'b3b166add6d5635863d6b6c665cf073b020ec6d6', class: 'menu-overlay-container' }, this.showSettings ? h("slot", { name: "ix-menu-settings" }) : null), h("div", { key: '9e899a47dd33eaf9e78d3150ccc4f078e1ab212f', class: 'menu-overlay-container' }, this.showAbout ? h("slot", { name: "ix-menu-about" }) : null))));
419
+ } }, h("div", { key: '5a166f1447115082d0578b42768b9bf79f8df406', class: 'menu-overlay-container' }, this.showSettings ? h("slot", { name: "ix-menu-settings" }) : null), h("div", { key: '0f29a9bbb6a2acc42744818a1813329220ce5c54', class: 'menu-overlay-container' }, this.showAbout ? h("slot", { name: "ix-menu-about" }) : null))));
420
420
  }
421
421
  static get is() { return "ix-menu"; }
422
422
  static get encapsulation() { return "shadow"; }
@@ -1 +1 @@
1
- {"version":3,"file":"menu.js","sourceRoot":"","sources":["../../../src/components/menu/menu.tsx"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EACL,SAAS,EACT,OAAO,EACP,KAAK,EAEL,CAAC,EACD,IAAI,EACJ,MAAM,EACN,MAAM,EACN,IAAI,EACJ,KAAK,EACL,KAAK,GACN,MAAM,eAAe,CAAC;AACvB,OAAO,KAAK,MAAM,SAAS,CAAC;AAC5B,OAAO,EAAE,6BAA6B,EAAE,MAAM,+BAA+B,CAAC;AAC9E,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AACpD,OAAO,EAAE,wBAAwB,EAAE,MAAM,qCAAqC,CAAC;AAC/E,OAAO,EAAE,wBAAwB,EAAE,MAAM,qCAAqC,CAAC;AAE/E,OAAO,EAAe,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AACnE,OAAO,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AACpE,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AACvD,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAOxD,MAAM,OAAO,IAAI;;QAkHP,yBAAoB,GAAG,KAAK,CAAC;QAErC,0BAA0B;QACT,cAAS,GAAG,CAAC,GAAgB,EAAE,EAAE;;YAChD,OAAO,CACL,GAAG,CAAC,KAAK,CAAC,OAAO,KAAK,MAAM;gBAC5B,CAAA,MAAA,MAAA,GAAG,CAAC,aAAa,0CAAE,aAAa,0CAAE,KAAK,CAAC,OAAO,MAAK,MAAM,CAC3D,CAAC;QACJ,CAAC,CAAC;4BApHsC,KAAK;yBAKR,KAAK;iCAKd,KAAK;8BAKR,IAAI;+BAKH,KAAK;;sCAUE,EAAE;mCAQL,CA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AC,kBAAkB,GAAQ,CAAC,CAAC,CAAC,IAAI,CAC7D;gBACN,4DAAK,KAAK,EAAE,wBAAwB,IACjC,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,YAAM,IAAI,EAAC,eAAe,GAAQ,CAAC,CAAC,CAAC,IAAI,CACvD,CACF,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["/*\n * SPDX-FileCopyrightText: 2023 Siemens AG\n *\n * SPDX-License-Identifier: MIT\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport {\n Component,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Listen,\n Method,\n Prop,\n State,\n Watch,\n} from '@stencil/core';\nimport anime from 'animejs';\nimport { ApplicationSidebarToggleEvent } from '../application-sidebar/events';\nimport { showAppSwitch } from '../utils/app-switch';\nimport { ApplicationLayoutContext } from '../utils/application-layout/context';\nimport { applicationLayoutService } from '../utils/application-layout/service';\nimport { Breakpoint } from '../utils/breakpoints';\nimport { ContextType, useContextConsumer } from '../utils/context';\nimport { menuController } from '../utils/menu-service/menu-service';\nimport { convertToRemString } from '../utils/rwd.util';\nimport { themeSwitcher } from '../utils/theme-switcher';\n\n@Component({\n tag: 'ix-menu',\n styleUrl: 'menu.scss',\n shadow: true,\n})\nexport class Menu {\n @Element() hostElement!: HTMLIxMenuElement;\n\n /**\n * Is settings tab visible\n */\n @Prop({ mutable: true }) showSettings = false;\n\n /**\n * Is about tab visible\n */\n @Prop({ mutable: true }) showAbout = false;\n\n /**\n * Show toggle between light and dark variant. Only if the provided theme have implemented both!\n */\n @Prop() enableToggleTheme = false;\n\n /**\n * Is settings tab is visible\n */\n @Prop() enableSettings = true;\n\n /**\n * Internal\n */\n @Prop() enableMapExpand = false;\n\n /**\n * Should only be set if you use ix-menu standalone\n */\n @Prop() applicationName: string;\n\n /**\n * Should only be set if you use ix-menu standalone\n */\n @Prop() applicationDescription = '';\n\n /**\n * Maximum number of menu items to show in case enough vertical space is available.\n * Extra menu items will be collapsed to 'show more' menu item.\n *\n * @deprecated - Has no effect on component. Will get removed with next major release (v3)\n */\n @Prop() maxVisibleMenuItems = 9;\n\n /**\n * Accessibility i18n label for the burger menu of the sidebar\n */\n @Prop() i18nExpandSidebar = 'Expand sidebar';\n\n /**\n */\n @Prop({ mutable: true, reflect: true }) expand = false;\n\n /**\n * Menu stays pinned to the left\n */\n @Prop() pinned = false;\n @Watch('pinned')\n pinnedChange(newPinned: boolean) {\n if (this.applicationLayoutContext?.host === 'map-navigation') {\n console.warn('ix-map-navigation does not support pinning of the menu');\n return;\n }\n this.setPinned(this.pinned);\n if (newPinned) {\n applicationLayoutService.disableBreakpointDetection();\n applicationLayoutService.setBreakpoint('lg');\n return;\n }\n\n applicationLayoutService.enableBreakpointDetection();\n }\n\n /**\n */\n @Prop() i18nLegal = 'About & legal information';\n\n /**\n */\n @Prop() i18nSettings = 'Settings';\n\n /**\n */\n @Prop() i18nToggleTheme = 'Toggle theme';\n\n /**\n */\n @Prop() i18nExpand = ' Expand';\n\n /**\n */\n @Prop() i18nCollapse = 'Collapse';\n\n /**\n * Menu expanded\n */\n @Event() expandChange: EventEmitter<boolean>;\n\n /**\n * Map Sidebar expanded\n */\n @Event() mapExpandChange: EventEmitter<boolean>;\n\n @State() showPinned = false;\n @State() mapExpand = true;\n @State() activeTab: HTMLIxMenuItemElement | null;\n @State() breakpoint: Breakpoint = 'lg';\n @State() itemsScrollShadowTop = false;\n @State() itemsScrollShadowBottom = false;\n @State() applicationLayoutContext: ContextType<\n typeof ApplicationLayoutContext\n >;\n private isTransitionDisabled = false;\n\n // FBC IAM workaround #488\n private readonly isVisible = (elm: HTMLElement) => {\n return (\n elm.style.display !== 'none' &&\n elm.parentElement?.parentElement?.style.display !== 'none'\n );\n };\n\n get popoverArea() {\n return this.hostElement.shadowRoot!.querySelector('#popover-area');\n }\n\n get menu() {\n return this.hostElement.shadowRoot!.querySelector('.menu');\n }\n\n get menuItemsContainer(): HTMLDivElement {\n return this.menu!.querySelector('.tabs')!;\n }\n\n get overlayContainer() {\n return this.hostElement.shadowRoot.querySelector(\n '.menu-overlay'\n ) as HTMLDivElement;\n }\n\n get menuItems() {\n return Array.from(\n this.hostElement.querySelectorAll(\n 'ix-menu-item:not(.internal-tab):not(.home-tab):not(.bottom-tab):not([slot=\"bottom\"])'\n )\n ).filter(this.isVisible);\n }\n\n get menuBottomItems() {\n return Array.from(\n this.hostElement.querySelectorAll(\n 'ix-menu-item.bottom-tab:not(.internal-tab):not(.home-tab)'\n )\n ).filter(this.isVisible);\n }\n\n get homeTab() {\n return this.hostElement.querySelector('ix-menu-item.home-tab');\n }\n\n get moreItemsDropdown(): HTMLElement {\n return this.hostElement.shadowRoot!.querySelector(\n '.internal-tab ix-dropdown'\n )!;\n }\n\n get isMoreItemsDropdownEmpty(): boolean {\n return (\n this.hostElement.shadowRoot!.querySelectorAll(\n '.internal-tab ix-dropdown .appended'\n ).length === 0\n );\n }\n\n get moreItemsDropdownItems() {\n return this.hostElement.shadowRoot!.querySelectorAll(\n '.internal-tab ix-dropdown ix-menu-item'\n );\n }\n\n get activeMoreTabContainer() {\n return this.hostElement.shadowRoot!.querySelector('.active-more-tab');\n }\n\n get activeMoreTab() {\n return this.hostElement.shadowRoot!.querySelector(\n '.active-more-tab ix-menu-item'\n );\n }\n\n get aboutPopoverContainer(): HTMLElement {\n return this.hostElement.querySelector('.about-news')!;\n }\n\n get aboutNewsPopover(): HTMLIxMenuAboutNewsElement {\n return (\n document.querySelector('ix-menu-about-news') ??\n this.hostElement.querySelector('ix-menu-about-news')!\n );\n }\n\n get aboutTab(): HTMLElement {\n return this.hostElement.shadowRoot!.querySelector('#aboutAndLegal');\n }\n\n get about(): HTMLIxMenuAboutElement | null {\n return this.hostElement.querySelector('ix-menu-about');\n }\n\n get settings(): HTMLIxMenuSettingsElement | null {\n return this.hostElement.querySelector('ix-menu-settings');\n }\n\n get isSettingsEmpty(): boolean {\n return (\n Array.from(\n this.hostElement.shadowRoot!.querySelectorAll('ix-menu-settings-item')\n ).length === 0\n );\n }\n\n get tabsContainer() {\n return this.hostElement;\n }\n\n componentDidLoad() {\n requestAnimationFrame(() => {\n this.handleOverflowIndicator();\n });\n\n if (this.pinned) {\n this.pinnedChange(this.pinned);\n }\n }\n\n componentWillLoad() {\n useContextConsumer(\n this.hostElement,\n ApplicationLayoutContext,\n (ctx) => {\n this.applicationLayoutContext = ctx;\n if (ctx.hideHeader === true) {\n this.onBreakpointChange('md');\n return;\n }\n\n this.onBreakpointChange(applicationLayoutService.breakpoint);\n },\n true\n );\n\n menuController.register(this.hostElement);\n applicationLayoutService.onChange.on((breakpoint) =>\n this.onBreakpointChange(breakpoint)\n );\n this.onBreakpointChange(applicationLayoutService.breakpoint);\n }\n\n componentWillRender() {\n this.appendTabs();\n }\n\n componentDidRender() {\n this.appendFragments();\n }\n\n private setPinned(pinned: boolean) {\n this.showPinned = pinned;\n menuController.setIsPinned(pinned);\n }\n\n private onBreakpointChange(mode: Breakpoint) {\n if (!this.applicationLayoutContext && mode === 'sm') {\n return;\n }\n if (this.applicationLayoutContext?.host === 'map-navigation') {\n this.breakpoint = 'md';\n return;\n }\n if (!this.applicationLayoutContext) {\n return;\n }\n\n if (this.applicationLayoutContext.hideHeader && mode === 'sm') {\n return;\n }\n\n this.breakpoint = mode;\n\n if (this.breakpoint === 'lg') {\n this.setPinned(true);\n this.toggleMenu(true);\n return;\n }\n\n this.setPinned(false);\n this.toggleMenu(false);\n }\n\n private appendFragments() {\n this.appendAboutNewsPopover();\n }\n\n private resetActiveTab() {\n this.activeTab = null;\n }\n\n private appendTabs() {\n this.activeTab = null;\n }\n\n private getAboutPopoverVerticalPosition() {\n const heightArrow = 12;\n const offsetArrow = 6;\n const rectAbout = this.aboutTab.getBoundingClientRect();\n const offset =\n window.innerHeight -\n (rectAbout.bottom - rectAbout.height / 2 + heightArrow / 2 + offsetArrow);\n return convertToRemString(offset);\n }\n\n private appendAboutNewsPopover() {\n if (!this.aboutNewsPopover) {\n return;\n }\n\n this.aboutNewsPopover.style.bottom = this.getAboutPopoverVerticalPosition();\n\n if (!this.popoverArea?.contains(this.aboutNewsPopover)) {\n const showMore = () => {\n if (this.aboutNewsPopover?.aboutItemLabel && this.about) {\n this.about.activeTabLabel = this.aboutNewsPopover.aboutItemLabel;\n this.toggleAbout(true);\n }\n };\n\n this.aboutNewsPopover.addEventListener('showMore', showMore.bind(this));\n document.body.appendChild(this.aboutNewsPopover);\n }\n }\n\n /**\n * Toggle map sidebar expand\n * @param show\n */\n @Method()\n async toggleMapExpand(show?: boolean) {\n if (show !== undefined) {\n this.mapExpand = show;\n } else {\n this.mapExpand = !this.mapExpand;\n }\n }\n\n /**\n * Toggle menu\n * @param show\n */\n @Method()\n async toggleMenu(show?: boolean) {\n if (show !== undefined) {\n this.expand = show;\n } else {\n this.expand = !this.expand;\n }\n\n if (this.aboutNewsPopover) {\n this.aboutNewsPopover.expanded = this.expand;\n }\n\n this.expandChange.emit(this.expand);\n\n this.isTransitionDisabled = false;\n this.checkTransition();\n }\n\n /**\n * Disable transition of overlay while menu animation is running.\n */\n private checkTransition() {\n const container = this.overlayContainer;\n\n if (!container) {\n return;\n }\n\n if (this.isTransitionDisabled) {\n container.style.transitionProperty = 'left';\n } else {\n container.style.transitionProperty = 'all';\n }\n }\n\n private isOverlayVisible() {\n return this.showAbout || this.showSettings;\n }\n\n /**\n * Toggle Settings tabs\n * @param show\n */\n @Method()\n async toggleSettings(show: boolean) {\n if (!this.settings) {\n return;\n }\n\n if (!this.isOverlayVisible()) {\n this.animateOverlayFadeIn();\n }\n\n if (show) {\n this.resetOverlay();\n this.showSettings = show;\n this.settings.show = this.showSettings;\n } else {\n this.onOverlayClose();\n }\n }\n\n /**\n * Toggle About tabs\n * @param show\n */\n @Method()\n async toggleAbout(show: boolean) {\n if (!this.about) {\n return;\n }\n\n if (!this.isOverlayVisible()) {\n this.animateOverlayFadeIn();\n }\n\n if (show) {\n this.resetOverlay();\n this.showAbout = show;\n this.about.show = this.showAbout;\n } else {\n this.onOverlayClose();\n }\n }\n\n private resetOverlay() {\n this.showSettings = false;\n this.showAbout = false;\n\n if (this.settings) {\n this.settings.show = false;\n }\n\n if (this.about) {\n this.about.show = false;\n }\n }\n\n private getCollapseText() {\n return this.mapExpand ? this.i18nCollapse : this.i18nExpand;\n }\n\n private getCollapseIcon() {\n return this.mapExpand ? 'navigation-left' : 'navigation-right';\n }\n\n private isMenuItemClicked(event: Event) {\n if (event.target instanceof HTMLElement) {\n return event.target.tagName === 'IX-MENU-ITEM';\n }\n\n return false;\n }\n\n @Listen('resize', { target: 'window' })\n private handleOverflowIndicator() {\n const { clientHeight, scrollTop, scrollHeight } = this.menuItemsContainer;\n this.itemsScrollShadowTop = scrollTop > 0;\n this.itemsScrollShadowBottom =\n Math.round(scrollTop + clientHeight) < scrollHeight;\n }\n\n @Listen('close')\n onOverlayClose() {\n this.animateOverlayFadeOut(() => {\n this.resetOverlay();\n });\n }\n\n private animateOverlayFadeIn() {\n requestAnimationFrame(() => {\n anime({\n targets: this.overlayContainer,\n duration: 300,\n backdropFilter: [0, 'blur(1rem)'],\n translateX: ['-4rem', 0],\n opacity: [0, 1],\n easing: 'easeInSine',\n begin: () => {\n if (this.showPinned) {\n return;\n }\n\n this.toggleMenu(false);\n },\n });\n });\n }\n\n private animateOverlayFadeOut(onComplete: Function) {\n requestAnimationFrame(() => {\n anime({\n targets: this.overlayContainer,\n duration: 300,\n backdropFilter: ['blur(1rem)', 0],\n translateX: [0, '-4rem'],\n opacity: [1, 0],\n easing: 'easeInSine',\n complete: () => onComplete(),\n });\n });\n }\n\n private onMenuItemsClick(event: Event) {\n if (this.isMenuItemClicked(event)) {\n if (!this.showPinned) {\n this.toggleMenu(false);\n }\n this.onOverlayClose();\n }\n }\n\n private isHiddenFromViewport() {\n return this.breakpoint === 'sm' && this.expand === false;\n }\n\n private sidebarToggle() {\n this.mapExpandChange.emit(this.mapExpand);\n\n this.hostElement.dispatchEvent(\n new ApplicationSidebarToggleEvent(this.mapExpand)\n );\n }\n\n render() {\n return (\n <Host\n class={{\n expanded: this.expand,\n [`breakpoint-${this.breakpoint}`]: true,\n }}\n slot=\"menu\"\n >\n <aside\n class={{\n menu: true,\n expanded: this.expand,\n }}\n onClick={() => {\n this.resetActiveTab();\n }}\n >\n <div class={'menu-buttons'}>\n <ix-burger-menu\n onClick={async () => this.toggleMenu()}\n expanded={this.expand}\n ixAriaLabel={this.i18nExpandSidebar}\n pinned={this.showPinned}\n class={{\n 'burger-menu': true,\n }}\n ></ix-burger-menu>\n {this.breakpoint === 'sm' &&\n this.applicationLayoutContext.appSwitchConfig && (\n <ix-icon-button\n onClick={() =>\n showAppSwitch(this.applicationLayoutContext.appSwitchConfig)\n }\n icon=\"apps\"\n ghost\n class=\"app-switch\"\n ></ix-icon-button>\n )}\n </div>\n <div class=\"menu-avatar\">\n <slot name=\"ix-menu-avatar\"></slot>\n </div>\n\n <div\n id=\"menu-tabs\"\n style={{\n display: 'contents',\n }}\n onClick={(e) => this.onMenuItemsClick(e)}\n >\n <div class=\"tabs-top\">\n <slot name=\"home\"></slot>\n </div>\n <div class=\"tabs-shadow-container\">\n <div\n class={{\n 'tabs--shadow': true,\n 'tabs--shadow-top': true,\n 'tabs--shadow--show': this.itemsScrollShadowTop,\n }}\n ></div>\n <div class=\"tabs\" onScroll={() => this.handleOverflowIndicator()}>\n {this.breakpoint !== 'sm' || !this.isHiddenFromViewport() ? (\n <slot></slot>\n ) : null}\n </div>\n <div\n class={{\n 'tabs--shadow': true,\n 'tabs--shadow-bottom': true,\n 'tabs--shadow--show': this.itemsScrollShadowBottom,\n }}\n ></div>\n </div>\n </div>\n <div class=\"bottom-tab-divider\"></div>\n {this.settings ? (\n <ix-menu-item\n disabled={this.isHiddenFromViewport()}\n id=\"settings\"\n class={{\n 'internal-tab': true,\n 'bottom-tab': true,\n active: this.showSettings,\n }}\n icon={'cogwheel'}\n onClick={async () => this.toggleSettings(!this.showSettings)}\n >\n {this.i18nSettings}\n </ix-menu-item>\n ) : null}\n <div onClick={(e) => this.onMenuItemsClick(e)}>\n <slot name=\"bottom\"></slot>\n </div>\n\n <div id=\"popover-area\"></div>\n {this.about ? (\n <ix-menu-item\n disabled={this.isHiddenFromViewport()}\n id=\"aboutAndLegal\"\n class={{\n 'internal-tab': true,\n 'bottom-tab': true,\n active: this.showAbout,\n }}\n icon={'info'}\n onClick={async () => this.toggleAbout(!this.showAbout)}\n >\n {this.i18nLegal}\n </ix-menu-item>\n ) : null}\n {this.enableToggleTheme ? (\n <ix-menu-item\n disabled={this.isHiddenFromViewport()}\n id=\"toggleTheme\"\n onClick={() => themeSwitcher.toggleMode()}\n class=\"internal-tab bottom-tab\"\n icon={'bulb'}\n >\n {this.i18nToggleTheme}\n </ix-menu-item>\n ) : null}\n {this.enableMapExpand || this.applicationLayoutContext?.sidebar ? (\n <ix-menu-item\n disabled={this.isHiddenFromViewport()}\n id=\"menu-collapse\"\n onClick={() => this.sidebarToggle()}\n class=\"internal-tab bottom-tab\"\n icon={`${this.getCollapseIcon()}`}\n >\n {this.getCollapseText()}\n </ix-menu-item>\n ) : null}\n </aside>\n <div\n class={{\n 'menu-overlay': true,\n visible: this.isOverlayVisible(),\n expanded: this.expand,\n }}\n onTransitionEnd={() => {\n this.isTransitionDisabled = true;\n this.checkTransition();\n }}\n >\n <div class={'menu-overlay-container'}>\n {this.showSettings ? <slot name=\"ix-menu-settings\"></slot> : null}\n </div>\n <div class={'menu-overlay-container'}>\n {this.showAbout ? <slot name=\"ix-menu-about\"></slot> : null}\n </div>\n </div>\n </Host>\n );\n }\n}\n"]}
1
+ {"version":3,"file":"menu.js","sourceRoot":"","sources":["../../../src/components/menu/menu.tsx"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EACL,SAAS,EACT,OAAO,EACP,KAAK,EAEL,CAAC,EACD,IAAI,EACJ,MAAM,EACN,MAAM,EACN,IAAI,EACJ,KAAK,EACL,KAAK,GACN,MAAM,eAAe,CAAC;AACvB,OAAO,KAAK,MAAM,SAAS,CAAC;AAC5B,OAAO,EAAE,6BAA6B,EAAE,MAAM,+BAA+B,CAAC;AAC9E,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AACpD,OAAO,EAAE,wBAAwB,EAAE,MAAM,qCAAqC,CAAC;AAC/E,OAAO,EAAE,wBAAwB,EAAE,MAAM,qCAAqC,CAAC;AAE/E,OAAO,EAAe,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AACnE,OAAO,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AACpE,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AACvD,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAOxD,MAAM,OAAO,IAAI;;QAkHP,yBAAoB,GAAG,KAAK,CAAC;QAErC,0BAA0B;QACT,cAAS,GAAG,CAAC,GAAgB,EAAE,EAAE;;YAChD,OAAO,CACL,GAAG,CAAC,KAAK,CAAC,OAAO,KAAK,MAAM;gBAC5B,CAAA,MAAA,MAAA,GAAG,CAAC,aAAa,0CAA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C,oBAAoB,GAAG,IAAI,CAAC;oBACjC,IAAI,CAAC,eAAe,EAAE,CAAC;gBACzB,CAAC;gBAED,4DAAK,KAAK,EAAE,wBAAwB,IACjC,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,YAAM,IAAI,EAAC,kBAAkB,GAAQ,CAAC,CAAC,CAAC,IAAI,CAC7D;gBACN,4DAAK,KAAK,EAAE,wBAAwB,IACjC,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,YAAM,IAAI,EAAC,eAAe,GAAQ,CAAC,CAAC,CAAC,IAAI,CACvD,CACF,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["/*\n * SPDX-FileCopyrightText: 2023 Siemens AG\n *\n * SPDX-License-Identifier: MIT\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport {\n Component,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Listen,\n Method,\n Prop,\n State,\n Watch,\n} from '@stencil/core';\nimport anime from 'animejs';\nimport { ApplicationSidebarToggleEvent } from '../application-sidebar/events';\nimport { showAppSwitch } from '../utils/app-switch';\nimport { ApplicationLayoutContext } from '../utils/application-layout/context';\nimport { applicationLayoutService } from '../utils/application-layout/service';\nimport { Breakpoint } from '../utils/breakpoints';\nimport { ContextType, useContextConsumer } from '../utils/context';\nimport { menuController } from '../utils/menu-service/menu-service';\nimport { convertToRemString } from '../utils/rwd.util';\nimport { themeSwitcher } from '../utils/theme-switcher';\n\n@Component({\n tag: 'ix-menu',\n styleUrl: 'menu.scss',\n shadow: true,\n})\nexport class Menu {\n @Element() hostElement!: HTMLIxMenuElement;\n\n /**\n * Is settings tab visible\n */\n @Prop({ mutable: true }) showSettings = false;\n\n /**\n * Is about tab visible\n */\n @Prop({ mutable: true }) showAbout = false;\n\n /**\n * Show toggle between light and dark variant. Only if the provided theme have implemented both!\n */\n @Prop() enableToggleTheme = false;\n\n /**\n * Is settings tab is visible\n */\n @Prop() enableSettings = true;\n\n /**\n * Internal\n */\n @Prop() enableMapExpand = false;\n\n /**\n * Should only be set if you use ix-menu standalone\n */\n @Prop() applicationName: string;\n\n /**\n * Should only be set if you use ix-menu standalone\n */\n @Prop() applicationDescription = '';\n\n /**\n * Maximum number of menu items to show in case enough vertical space is available.\n * Extra menu items will be collapsed to 'show more' menu item.\n *\n * @deprecated - Has no effect on component. Will get removed with next major release (v3)\n */\n @Prop() maxVisibleMenuItems = 9;\n\n /**\n * Accessibility i18n label for the burger menu of the sidebar\n */\n @Prop() i18nExpandSidebar = 'Expand sidebar';\n\n /**\n */\n @Prop({ mutable: true, reflect: true }) expand = false;\n\n /**\n * Menu stays pinned to the left\n */\n @Prop() pinned = false;\n @Watch('pinned')\n pinnedChange(newPinned: boolean) {\n if (this.applicationLayoutContext?.host === 'map-navigation') {\n console.warn('ix-map-navigation does not support pinning of the menu');\n return;\n }\n this.setPinned(this.pinned);\n if (newPinned) {\n applicationLayoutService.disableBreakpointDetection();\n applicationLayoutService.setBreakpoint('lg');\n return;\n }\n\n applicationLayoutService.enableBreakpointDetection();\n }\n\n /**\n */\n @Prop() i18nLegal = 'About & legal information';\n\n /**\n */\n @Prop() i18nSettings = 'Settings';\n\n /**\n */\n @Prop() i18nToggleTheme = 'Toggle theme';\n\n /**\n */\n @Prop() i18nExpand = ' Expand';\n\n /**\n */\n @Prop() i18nCollapse = 'Collapse';\n\n /**\n * Menu expanded\n */\n @Event() expandChange: EventEmitter<boolean>;\n\n /**\n * Map Sidebar expanded\n */\n @Event() mapExpandChange: EventEmitter<boolean>;\n\n @State() showPinned = false;\n @State() mapExpand = true;\n @State() activeTab: HTMLIxMenuItemElement | null;\n @State() breakpoint: Breakpoint = 'lg';\n @State() itemsScrollShadowTop = false;\n @State() itemsScrollShadowBottom = false;\n @State() applicationLayoutContext: ContextType<\n typeof ApplicationLayoutContext\n >;\n private isTransitionDisabled = false;\n\n // FBC IAM workaround #488\n private readonly isVisible = (elm: HTMLElement) => {\n return (\n elm.style.display !== 'none' &&\n elm.parentElement?.parentElement?.style.display !== 'none'\n );\n };\n\n get popoverArea() {\n return this.hostElement.shadowRoot!.querySelector('#popover-area');\n }\n\n get menu() {\n return this.hostElement.shadowRoot!.querySelector('.menu');\n }\n\n get menuItemsContainer(): HTMLDivElement {\n return this.menu!.querySelector('.tabs')!;\n }\n\n get overlayContainer() {\n return this.hostElement.shadowRoot.querySelector(\n '.menu-overlay'\n ) as HTMLDivElement;\n }\n\n get menuItems() {\n return Array.from(\n this.hostElement.querySelectorAll(\n 'ix-menu-item:not(.internal-tab):not(.home-tab):not(.bottom-tab):not([slot=\"bottom\"])'\n )\n ).filter(this.isVisible);\n }\n\n get menuBottomItems() {\n return Array.from(\n this.hostElement.querySelectorAll(\n 'ix-menu-item.bottom-tab:not(.internal-tab):not(.home-tab)'\n )\n ).filter(this.isVisible);\n }\n\n get homeTab() {\n return this.hostElement.querySelector('ix-menu-item.home-tab');\n }\n\n get moreItemsDropdown(): HTMLElement {\n return this.hostElement.shadowRoot!.querySelector(\n '.internal-tab ix-dropdown'\n )!;\n }\n\n get isMoreItemsDropdownEmpty(): boolean {\n return (\n this.hostElement.shadowRoot!.querySelectorAll(\n '.internal-tab ix-dropdown .appended'\n ).length === 0\n );\n }\n\n get moreItemsDropdownItems() {\n return this.hostElement.shadowRoot!.querySelectorAll(\n '.internal-tab ix-dropdown ix-menu-item'\n );\n }\n\n get activeMoreTabContainer() {\n return this.hostElement.shadowRoot!.querySelector('.active-more-tab');\n }\n\n get activeMoreTab() {\n return this.hostElement.shadowRoot!.querySelector(\n '.active-more-tab ix-menu-item'\n );\n }\n\n get aboutPopoverContainer(): HTMLElement {\n return this.hostElement.querySelector('.about-news')!;\n }\n\n get aboutNewsPopover(): HTMLIxMenuAboutNewsElement {\n return (\n document.querySelector('ix-menu-about-news') ??\n this.hostElement.querySelector('ix-menu-about-news')!\n );\n }\n\n get aboutTab(): HTMLElement {\n return this.hostElement.shadowRoot!.querySelector('#aboutAndLegal');\n }\n\n get about(): HTMLIxMenuAboutElement | null {\n return this.hostElement.querySelector('ix-menu-about');\n }\n\n get settings(): HTMLIxMenuSettingsElement | null {\n return this.hostElement.querySelector('ix-menu-settings');\n }\n\n get isSettingsEmpty(): boolean {\n return (\n Array.from(\n this.hostElement.shadowRoot!.querySelectorAll('ix-menu-settings-item')\n ).length === 0\n );\n }\n\n get tabsContainer() {\n return this.hostElement;\n }\n\n componentDidLoad() {\n requestAnimationFrame(() => {\n this.handleOverflowIndicator();\n });\n\n if (this.pinned) {\n this.pinnedChange(this.pinned);\n }\n }\n\n componentWillLoad() {\n useContextConsumer(\n this.hostElement,\n ApplicationLayoutContext,\n (ctx) => {\n this.applicationLayoutContext = ctx;\n if (ctx.hideHeader === true) {\n this.onBreakpointChange('md');\n return;\n }\n\n this.onBreakpointChange(applicationLayoutService.breakpoint);\n },\n true\n );\n\n menuController.register(this.hostElement);\n applicationLayoutService.onChange.on((breakpoint) =>\n this.onBreakpointChange(breakpoint)\n );\n this.onBreakpointChange(applicationLayoutService.breakpoint);\n }\n\n componentWillRender() {\n this.appendTabs();\n }\n\n componentDidRender() {\n this.appendFragments();\n }\n\n private setPinned(pinned: boolean) {\n this.showPinned = pinned;\n menuController.setIsPinned(pinned);\n }\n\n private onBreakpointChange(mode: Breakpoint) {\n if (!this.applicationLayoutContext && mode === 'sm') {\n return;\n }\n if (this.applicationLayoutContext?.host === 'map-navigation') {\n this.breakpoint = 'md';\n return;\n }\n if (!this.applicationLayoutContext) {\n return;\n }\n\n if (this.applicationLayoutContext.hideHeader && mode === 'sm') {\n return;\n }\n\n this.breakpoint = mode;\n\n if (this.breakpoint === 'lg') {\n this.setPinned(true);\n this.toggleMenu(true);\n return;\n }\n\n this.setPinned(false);\n this.toggleMenu(false);\n }\n\n private appendFragments() {\n this.appendAboutNewsPopover();\n }\n\n private resetActiveTab() {\n this.activeTab = null;\n }\n\n private appendTabs() {\n this.activeTab = null;\n }\n\n private getAboutPopoverVerticalPosition() {\n const heightArrow = 12;\n const offsetArrow = 6;\n const rectAbout = this.aboutTab.getBoundingClientRect();\n const offset =\n window.innerHeight -\n (rectAbout.bottom - rectAbout.height / 2 + heightArrow / 2 + offsetArrow);\n return convertToRemString(offset);\n }\n\n private appendAboutNewsPopover() {\n if (!this.aboutNewsPopover) {\n return;\n }\n\n this.aboutNewsPopover.style.bottom = this.getAboutPopoverVerticalPosition();\n\n if (!this.popoverArea?.contains(this.aboutNewsPopover)) {\n const showMore = () => {\n if (this.aboutNewsPopover?.aboutItemLabel && this.about) {\n this.about.activeTabLabel = this.aboutNewsPopover.aboutItemLabel;\n this.toggleAbout(true);\n }\n };\n\n this.aboutNewsPopover.addEventListener('showMore', showMore.bind(this));\n document.body.appendChild(this.aboutNewsPopover);\n }\n }\n\n /**\n * Toggle map sidebar expand\n * @param show\n */\n @Method()\n async toggleMapExpand(show?: boolean) {\n if (show !== undefined) {\n this.mapExpand = show;\n } else {\n this.mapExpand = !this.mapExpand;\n }\n }\n\n /**\n * Toggle menu\n * @param show\n */\n @Method()\n async toggleMenu(show?: boolean) {\n if (show !== undefined) {\n this.expand = show;\n } else {\n this.expand = !this.expand;\n }\n\n if (this.aboutNewsPopover) {\n this.aboutNewsPopover.expanded = this.expand;\n }\n\n this.expandChange.emit(this.expand);\n\n this.isTransitionDisabled = false;\n this.checkTransition();\n }\n\n /**\n * Disable transition of overlay while menu animation is running.\n */\n private checkTransition() {\n const container = this.overlayContainer;\n\n if (!container) {\n return;\n }\n\n if (this.isTransitionDisabled) {\n container.style.transitionProperty = 'left';\n } else {\n container.style.transitionProperty = 'all';\n }\n }\n\n private isOverlayVisible() {\n return this.showAbout || this.showSettings;\n }\n\n /**\n * Toggle Settings tabs\n * @param show\n */\n @Method()\n async toggleSettings(show: boolean) {\n if (!this.settings) {\n return;\n }\n\n if (!this.isOverlayVisible()) {\n this.animateOverlayFadeIn();\n }\n\n if (show) {\n this.resetOverlay();\n this.showSettings = show;\n this.settings.show = this.showSettings;\n } else {\n this.onOverlayClose();\n }\n }\n\n /**\n * Toggle About tabs\n * @param show\n */\n @Method()\n async toggleAbout(show: boolean) {\n if (!this.about) {\n return;\n }\n\n if (!this.isOverlayVisible()) {\n this.animateOverlayFadeIn();\n }\n\n if (show) {\n this.resetOverlay();\n this.showAbout = show;\n this.about.show = this.showAbout;\n } else {\n this.onOverlayClose();\n }\n }\n\n private resetOverlay() {\n this.showSettings = false;\n this.showAbout = false;\n\n if (this.settings) {\n this.settings.show = false;\n }\n\n if (this.about) {\n this.about.show = false;\n }\n }\n\n private getCollapseText() {\n return this.mapExpand ? this.i18nCollapse : this.i18nExpand;\n }\n\n private getCollapseIcon() {\n return this.mapExpand ? 'navigation-left' : 'navigation-right';\n }\n\n private isMenuItemClicked(event: Event) {\n if (event.target instanceof HTMLElement) {\n return event.target.tagName === 'IX-MENU-ITEM';\n }\n\n return false;\n }\n\n @Listen('resize', { target: 'window' })\n private handleOverflowIndicator() {\n const { clientHeight, scrollTop, scrollHeight } = this.menuItemsContainer;\n this.itemsScrollShadowTop = scrollTop > 0;\n this.itemsScrollShadowBottom =\n Math.round(scrollTop + clientHeight) < scrollHeight;\n }\n\n @Listen('close')\n onOverlayClose() {\n this.animateOverlayFadeOut(() => {\n this.resetOverlay();\n });\n }\n\n private animateOverlayFadeIn() {\n requestAnimationFrame(() => {\n anime({\n targets: this.overlayContainer,\n duration: 300,\n backdropFilter: [0, 'blur(1rem)'],\n translateX: ['-4rem', 0],\n opacity: [0, 1],\n easing: 'easeInSine',\n begin: () => {\n if (this.showPinned) {\n return;\n }\n\n this.toggleMenu(false);\n },\n });\n });\n }\n\n private animateOverlayFadeOut(onComplete: Function) {\n requestAnimationFrame(() => {\n anime({\n targets: this.overlayContainer,\n duration: 300,\n backdropFilter: ['blur(1rem)', 0],\n translateX: [0, '-4rem'],\n opacity: [1, 0],\n easing: 'easeInSine',\n complete: () => onComplete(),\n });\n });\n }\n\n private onMenuItemsClick(event: Event) {\n if (this.isMenuItemClicked(event)) {\n if (!this.showPinned) {\n this.toggleMenu(false);\n }\n this.onOverlayClose();\n }\n }\n\n private isHiddenFromViewport() {\n return this.breakpoint === 'sm' && this.expand === false;\n }\n\n private sidebarToggle() {\n this.mapExpandChange.emit(this.mapExpand);\n\n this.hostElement.dispatchEvent(\n new ApplicationSidebarToggleEvent(this.mapExpand)\n );\n }\n\n render() {\n return (\n <Host\n class={{\n expanded: this.expand,\n [`breakpoint-${this.breakpoint}`]: true,\n }}\n slot=\"menu\"\n >\n <aside\n class={{\n menu: true,\n expanded: this.expand,\n }}\n onClick={() => {\n this.resetActiveTab();\n }}\n >\n <div class={'menu-buttons'}>\n <ix-burger-menu\n onClick={async () => this.toggleMenu()}\n expanded={this.expand}\n ixAriaLabel={this.i18nExpandSidebar}\n pinned={this.showPinned}\n class={{\n 'burger-menu': true,\n }}\n ></ix-burger-menu>\n {this.breakpoint === 'sm' &&\n this.applicationLayoutContext.appSwitchConfig && (\n <ix-icon-button\n onClick={() =>\n showAppSwitch(this.applicationLayoutContext.appSwitchConfig)\n }\n icon=\"apps\"\n ghost\n class=\"app-switch\"\n ></ix-icon-button>\n )}\n </div>\n <div class=\"menu-avatar\">\n <slot name=\"ix-menu-avatar\"></slot>\n </div>\n\n <div\n id=\"menu-tabs\"\n style={{\n display: 'contents',\n }}\n onClick={(e) => this.onMenuItemsClick(e)}\n >\n <div class=\"tabs-top\">\n <slot name=\"home\"></slot>\n </div>\n <div class=\"tabs-shadow-container\">\n <div\n class={{\n 'tabs--shadow': true,\n 'tabs--shadow-top': true,\n 'tabs--shadow--show': this.itemsScrollShadowTop,\n }}\n ></div>\n <div class=\"tabs\" onScroll={() => this.handleOverflowIndicator()}>\n {this.breakpoint !== 'sm' || !this.isHiddenFromViewport() ? (\n <slot></slot>\n ) : null}\n </div>\n <div\n class={{\n 'tabs--shadow': true,\n 'tabs--shadow-bottom': true,\n 'tabs--shadow--show': this.itemsScrollShadowBottom,\n }}\n ></div>\n </div>\n </div>\n <div class=\"bottom-tab-divider\"></div>\n {this.settings ? (\n <ix-menu-item\n disabled={this.isHiddenFromViewport()}\n id=\"settings\"\n class={{\n 'internal-tab': true,\n 'bottom-tab': true,\n active: this.showSettings,\n }}\n icon={'cogwheel'}\n onClick={async () => this.toggleSettings(!this.showSettings)}\n >\n {this.i18nSettings}\n </ix-menu-item>\n ) : null}\n <div onClick={(e) => this.onMenuItemsClick(e)}>\n <slot name=\"bottom\"></slot>\n </div>\n\n <div id=\"popover-area\"></div>\n {this.about ? (\n <ix-menu-item\n disabled={this.isHiddenFromViewport()}\n id=\"aboutAndLegal\"\n class={{\n 'internal-tab': true,\n 'bottom-tab': true,\n active: this.showAbout,\n }}\n icon={'info'}\n onClick={async () => this.toggleAbout(!this.showAbout)}\n >\n {this.i18nLegal}\n </ix-menu-item>\n ) : null}\n {this.enableToggleTheme ? (\n <ix-menu-item\n disabled={this.isHiddenFromViewport()}\n id=\"toggleTheme\"\n onClick={() => themeSwitcher.toggleMode()}\n class=\"internal-tab bottom-tab\"\n icon={'light-dark'}\n >\n {this.i18nToggleTheme}\n </ix-menu-item>\n ) : null}\n {this.enableMapExpand || this.applicationLayoutContext?.sidebar ? (\n <ix-menu-item\n disabled={this.isHiddenFromViewport()}\n id=\"menu-collapse\"\n onClick={() => this.sidebarToggle()}\n class=\"internal-tab bottom-tab\"\n icon={`${this.getCollapseIcon()}`}\n >\n {this.getCollapseText()}\n </ix-menu-item>\n ) : null}\n </aside>\n <div\n class={{\n 'menu-overlay': true,\n visible: this.isOverlayVisible(),\n expanded: this.expand,\n }}\n onTransitionEnd={() => {\n this.isTransitionDisabled = true;\n this.checkTransition();\n }}\n >\n <div class={'menu-overlay-container'}>\n {this.showSettings ? <slot name=\"ix-menu-settings\"></slot> : null}\n </div>\n <div class={'menu-overlay-container'}>\n {this.showAbout ? <slot name=\"ix-menu-about\"></slot> : null}\n </div>\n </div>\n </Host>\n );\n }\n}\n"]}
@@ -169,6 +169,17 @@ test('should close menu by bottom icon click', async ({ mount, page }) => {
169
169
  await expect(innerMenu).not.toHaveClass(/expanded/);
170
170
  await expect(element).toBeVisible();
171
171
  });
172
+ test('should have correct aria label', async ({ mount, page }) => {
173
+ await mount(`
174
+ <ix-menu pinned>
175
+ </ix-menu>
176
+ `);
177
+ await page.locator('ix-menu');
178
+ const chevronButton = page.locator('ix-icon-button button');
179
+ await expect(chevronButton).toHaveAttribute('aria-label', 'Double Chevron Right');
180
+ chevronButton.click();
181
+ await expect(chevronButton).toHaveAttribute('aria-label', 'Double Chevron Left');
182
+ });
172
183
  async function clickAboutButton(element, page) {
173
184
  const aboutButton = element.locator('ix-menu-item#aboutAndLegal');
174
185
  await aboutButton.click();
@@ -1 +1 @@
1
- {"version":3,"file":"menu.ct.js","sourceRoot":"","sources":["../../../../src/components/menu/test/menu.ct.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,EAAE,MAAM,EAAiB,MAAM,kBAAkB,CAAC;AACzD,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AAEnC,IAAI,CAAC,SAAS,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,EA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B,EAAE,IAAU;IAC7D,MAAM,cAAc,GAAG,OAAO,CAAC,OAAO,CAAC,uBAAuB,CAAC,CAAC;IAChE,MAAM,cAAc,CAAC,KAAK,EAAE,CAAC;IAC7B,MAAM,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;AAClC,CAAC","sourcesContent":["/*\n * SPDX-FileCopyrightText: 2023 Siemens AG\n *\n * SPDX-License-Identifier: MIT\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\nimport { expect, Locator, Page } from '@playwright/test';\nimport { test } from '@utils/test';\n\ntest('renders', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n const element = page.locator('ix-menu');\n await expect(element).toHaveClass(/hydrated/);\n await expect(element).toHaveClass(/breakpoint-lg/);\n});\n\ntest('should stay close after menu click when NOT pinned', async ({\n mount,\n page,\n}) => {\n await mount(`\n <ix-basic-navigation>\n <ix-menu>\n <ix-menu-item>Item</ix-menu-item>\n </ix-menu>\n </ix-basic-navigation>\n `);\n const menu = page.locator('ix-menu');\n await page\n .locator('ix-basic-navigation')\n .evaluate(\n (menu: HTMLIxBasicNavigationElement) => (menu.breakpoints = ['md'])\n );\n const menuButton = menu.locator('ix-burger-menu');\n await menuButton.click();\n\n await expect(menu).toHaveClass(/expanded/);\n await page.locator('ix-menu-item').click();\n await expect(menu).not.toHaveClass(/expanded/);\n});\n\ntest('should stay open after menu click when pinned', async ({\n mount,\n page,\n}) => {\n await mount(`\n <ix-basic-navigation>\n <ix-menu pinned>\n <ix-menu-item>Item</ix-menu-item>\n </ix-menu>\n </ix-basic-navigation>\n `);\n const menu = page.locator('ix-menu');\n const menuButton = menu.locator('ix-burger-menu');\n await menuButton.click();\n\n await expect(menu).not.toHaveClass(/expanded/);\n\n await page.locator('ix-menu-item').click();\n\n await expect(menu).not.toHaveClass(/expanded/);\n});\n\ntest('should open and close settings', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n const element = page.locator('ix-menu');\n\n await clickSettingsButton(element, page);\n let settings = page.locator('ix-menu-settings');\n await expect(settings).toBeVisible();\n\n const closeButton = settings.getByRole('button');\n await closeButton.click();\n await expect(settings).not.toBeVisible();\n\n // Click same button twice\n await clickSettingsButton(element, page);\n await clickSettingsButton(element, page);\n await expect(settings).not.toBeVisible();\n});\n\ntest('should close settings by about', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n const element = page.locator('ix-menu');\n\n await clickSettingsButton(element, page);\n let about = page.locator('ix-menu-about');\n let settings = page.locator('ix-menu-settings');\n\n await clickAboutButton(element, page);\n await expect(about).toBeVisible();\n await expect(settings).not.toBeVisible();\n});\n\ntest('should open and close about', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n const element = page.locator('ix-menu');\n\n await clickAboutButton(element, page);\n let about = page.locator('ix-menu-about');\n await expect(about).toBeVisible();\n\n const closeButton = about.getByRole('button');\n await closeButton.click();\n await expect(about).not.toBeVisible();\n\n // Click same button twice\n await clickAboutButton(element, page);\n await clickAboutButton(element, page);\n await expect(about).not.toBeVisible();\n});\n\ntest('should close about by settings', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n const element = page.locator('ix-menu');\n\n await clickAboutButton(element, page);\n let about = page.locator('ix-menu-about');\n let settings = page.locator('ix-menu-settings');\n\n await clickSettingsButton(element, page);\n await expect(about).not.toBeVisible();\n await expect(settings).toBeVisible();\n});\n\ntest('should close about by item click', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-item>Random</ix-menu-item>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n const element = page.locator('ix-menu');\n\n await clickAboutButton(element, page);\n let about = page.locator('ix-menu-about');\n let settings = page.locator('ix-menu-settings');\n const menuItem = page.locator('ix-menu-item').filter({ hasText: 'Random' });\n\n await menuItem.click();\n await expect(about).not.toBeVisible();\n await expect(settings).not.toBeVisible();\n});\n\ntest('should close menu by bottom icon click', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-item>Random</ix-menu-item>\n <ix-menu-item slot=\"bottom\">BottomMenuItem</ix-menu-item>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n\n const element = page.locator('ix-menu');\n await element.getByRole('button', { name: 'Expand sidebar' }).click();\n const innerMenu = element.locator('.menu');\n await expect(innerMenu).toHaveClass(/expanded/);\n\n const bottomMenu = element.locator('ix-menu-item[slot=\"bottom\"]');\n await bottomMenu.click();\n\n await expect(innerMenu).not.toHaveClass(/expanded/);\n await expect(element).toBeVisible();\n});\n\nasync function clickAboutButton(element: Locator, page: Page) {\n const aboutButton = element.locator('ix-menu-item#aboutAndLegal');\n await aboutButton.click();\n await page.waitForTimeout(1000);\n}\n\nasync function clickSettingsButton(element: Locator, page: Page) {\n const settingsButton = element.locator('ix-menu-item#settings');\n await settingsButton.click();\n await page.waitForTimeout(1000);\n}\n"]}
1
+ {"version":3,"file":"menu.ct.js","sourceRoot":"","sources":["../../../../src/components/menu/test/menu.ct.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,EAAE,MAAM,EAAiB,MAAM,kBAAkB,CAAC;AACzD,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AAEnC,IAAI,CAAC,SAAS,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE,EAAE;IACx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,aAAa,CAAC,CAAC,eAAe,CACzC,YAAY,EACZ,sBAAsB,CACvB,CAAC;IAEF,aAAa,CAAC,KAAK,EAAE,CAAC;IAEtB,MAAM,MAAM,CAAC,aAAa,CAAC,CAAC,eAAe,CACzC,YAAY,EACZ,qBAAqB,CACtB,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,KAAK,UAAU,gBAAgB,CAAC,OAAgB,EAAE,IAAU;IAC1D,MAAM,WAAW,GAAG,OAAO,CAAC,OAAO,CAAC,4BAA4B,CAAC,CAAC;IAClE,MAAM,WAAW,CAAC,KAAK,EAAE,CAAC;IAC1B,MAAM,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;AAClC,CAAC;AAED,KAAK,UAAU,mBAAmB,CAAC,OAAgB,EAAE,IAAU;IAC7D,MAAM,cAAc,GAAG,OAAO,CAAC,OAAO,CAAC,uBAAuB,CAAC,CAAC;IAChE,MAAM,cAAc,CAAC,KAAK,EAAE,CAAC;IAC7B,MAAM,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;AAClC,CAAC","sourcesContent":["/*\n * SPDX-FileCopyrightText: 2023 Siemens AG\n *\n * SPDX-License-Identifier: MIT\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\nimport { expect, Locator, Page } from '@playwright/test';\nimport { test } from '@utils/test';\n\ntest('renders', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n const element = page.locator('ix-menu');\n await expect(element).toHaveClass(/hydrated/);\n await expect(element).toHaveClass(/breakpoint-lg/);\n});\n\ntest('should stay close after menu click when NOT pinned', async ({\n mount,\n page,\n}) => {\n await mount(`\n <ix-basic-navigation>\n <ix-menu>\n <ix-menu-item>Item</ix-menu-item>\n </ix-menu>\n </ix-basic-navigation>\n `);\n const menu = page.locator('ix-menu');\n await page\n .locator('ix-basic-navigation')\n .evaluate(\n (menu: HTMLIxBasicNavigationElement) => (menu.breakpoints = ['md'])\n );\n const menuButton = menu.locator('ix-burger-menu');\n await menuButton.click();\n\n await expect(menu).toHaveClass(/expanded/);\n await page.locator('ix-menu-item').click();\n await expect(menu).not.toHaveClass(/expanded/);\n});\n\ntest('should stay open after menu click when pinned', async ({\n mount,\n page,\n}) => {\n await mount(`\n <ix-basic-navigation>\n <ix-menu pinned>\n <ix-menu-item>Item</ix-menu-item>\n </ix-menu>\n </ix-basic-navigation>\n `);\n const menu = page.locator('ix-menu');\n const menuButton = menu.locator('ix-burger-menu');\n await menuButton.click();\n\n await expect(menu).not.toHaveClass(/expanded/);\n\n await page.locator('ix-menu-item').click();\n\n await expect(menu).not.toHaveClass(/expanded/);\n});\n\ntest('should open and close settings', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n const element = page.locator('ix-menu');\n\n await clickSettingsButton(element, page);\n let settings = page.locator('ix-menu-settings');\n await expect(settings).toBeVisible();\n\n const closeButton = settings.getByRole('button');\n await closeButton.click();\n await expect(settings).not.toBeVisible();\n\n // Click same button twice\n await clickSettingsButton(element, page);\n await clickSettingsButton(element, page);\n await expect(settings).not.toBeVisible();\n});\n\ntest('should close settings by about', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n const element = page.locator('ix-menu');\n\n await clickSettingsButton(element, page);\n let about = page.locator('ix-menu-about');\n let settings = page.locator('ix-menu-settings');\n\n await clickAboutButton(element, page);\n await expect(about).toBeVisible();\n await expect(settings).not.toBeVisible();\n});\n\ntest('should open and close about', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n const element = page.locator('ix-menu');\n\n await clickAboutButton(element, page);\n let about = page.locator('ix-menu-about');\n await expect(about).toBeVisible();\n\n const closeButton = about.getByRole('button');\n await closeButton.click();\n await expect(about).not.toBeVisible();\n\n // Click same button twice\n await clickAboutButton(element, page);\n await clickAboutButton(element, page);\n await expect(about).not.toBeVisible();\n});\n\ntest('should close about by settings', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n const element = page.locator('ix-menu');\n\n await clickAboutButton(element, page);\n let about = page.locator('ix-menu-about');\n let settings = page.locator('ix-menu-settings');\n\n await clickSettingsButton(element, page);\n await expect(about).not.toBeVisible();\n await expect(settings).toBeVisible();\n});\n\ntest('should close about by item click', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-item>Random</ix-menu-item>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n const element = page.locator('ix-menu');\n\n await clickAboutButton(element, page);\n let about = page.locator('ix-menu-about');\n let settings = page.locator('ix-menu-settings');\n const menuItem = page.locator('ix-menu-item').filter({ hasText: 'Random' });\n\n await menuItem.click();\n await expect(about).not.toBeVisible();\n await expect(settings).not.toBeVisible();\n});\n\ntest('should close menu by bottom icon click', async ({ mount, page }) => {\n await mount(`\n <ix-menu>\n <ix-menu-item>Random</ix-menu-item>\n <ix-menu-item slot=\"bottom\">BottomMenuItem</ix-menu-item>\n <ix-menu-about>\n </ix-menu-about>\n <ix-menu-settings>\n </ix-menu-settings>\n </ix-menu>\n `);\n\n const element = page.locator('ix-menu');\n await element.getByRole('button', { name: 'Expand sidebar' }).click();\n const innerMenu = element.locator('.menu');\n await expect(innerMenu).toHaveClass(/expanded/);\n\n const bottomMenu = element.locator('ix-menu-item[slot=\"bottom\"]');\n await bottomMenu.click();\n\n await expect(innerMenu).not.toHaveClass(/expanded/);\n await expect(element).toBeVisible();\n});\n\ntest('should have correct aria label', async ({ mount, page }) => {\n await mount(`\n <ix-menu pinned>\n </ix-menu>\n `);\n\n await page.locator('ix-menu');\n const chevronButton = page.locator('ix-icon-button button');\n\n await expect(chevronButton).toHaveAttribute(\n 'aria-label',\n 'Double Chevron Right'\n );\n\n chevronButton.click();\n\n await expect(chevronButton).toHaveAttribute(\n 'aria-label',\n 'Double Chevron Left'\n );\n});\n\nasync function clickAboutButton(element: Locator, page: Page) {\n const aboutButton = element.locator('ix-menu-item#aboutAndLegal');\n await aboutButton.click();\n await page.waitForTimeout(1000);\n}\n\nasync function clickSettingsButton(element: Locator, page: Page) {\n const settingsButton = element.locator('ix-menu-item#settings');\n await settingsButton.click();\n await page.waitForTimeout(1000);\n}\n"]}
@@ -0,0 +1,47 @@
1
+ /*
2
+ * SPDX-FileCopyrightText: 2023 Siemens AG
3
+ *
4
+ * SPDX-License-Identifier: MIT
5
+ *
6
+ * This source code is licensed under the MIT license found in the
7
+ * LICENSE file in the root directory of this source tree.
8
+ */
9
+ import { expect } from "@playwright/test";
10
+ import { test } from "../../../tests/utils/test/index";
11
+ const html = String.raw;
12
+ test('Nested dropdowns', async ({ mount, page }) => {
13
+ await mount(html `
14
+ <ix-menu>
15
+ <ix-menu-avatar>
16
+ <ix-menu-avatar-item label="test" id="submenu-01"></ix-menu-avatar-item>
17
+ </ix-menu-avatar>
18
+ </ix-menu>
19
+ <ix-dropdown trigger="submenu-01" id="d1">
20
+ <ix-dropdown-item>SubMenuItem 1</ix-dropdown-item>
21
+ <ix-dropdown-item>SubMenuItem 2</ix-dropdown-item>
22
+ <ix-dropdown-item>SubMenuItem 3</ix-dropdown-item>
23
+ <ix-dropdown-item id="submenu-02">SubMenuItem 4</ix-dropdown-item>
24
+ </ix-dropdown>
25
+ <ix-dropdown trigger="submenu-02" id="d2">
26
+ <ix-dropdown-item>SubMenuItem 1</ix-dropdown-item>
27
+ <ix-dropdown-item>SubMenuItem 2</ix-dropdown-item>
28
+ <ix-dropdown-item>SubMenuItem 3</ix-dropdown-item>
29
+ <ix-dropdown-item>SubMenuItem 4</ix-dropdown-item>
30
+ </ix-dropdown>
31
+ `);
32
+ const menuAvatar = page.locator('ix-menu-avatar');
33
+ await expect(menuAvatar).toBeVisible();
34
+ await menuAvatar.click();
35
+ await expect(menuAvatar.locator('ix-dropdown')).toBeVisible();
36
+ const menuAvatarItem = menuAvatar.locator('ix-menu-avatar-item').nth(0);
37
+ await menuAvatarItem.click();
38
+ const dropdown1 = page.locator('#d1');
39
+ const dropdown2 = page.locator('#d2');
40
+ await expect(dropdown1).toBeVisible();
41
+ const dropdown2Trigger = dropdown1
42
+ .locator('ix-dropdown-item')
43
+ .filter({ hasText: 'SubMenuItem 4' });
44
+ await dropdown2Trigger.click();
45
+ await expect(dropdown2).toBeVisible();
46
+ });
47
+ //# sourceMappingURL=menu-avatar-item.ct.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"menu-avatar-item.ct.js","sourceRoot":"","sources":["../../../../src/components/menu-avatar-item/test/menu-avatar-item.ct.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAC1C,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AAEnC,MAAM,IAAI,GAAG,MAAM,CAAC,GAAG,CAAC;AAExB,IAAI,CAAC,kBAAkB,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE,EAAE;IACjD,MAAM,KAAK,CAAC,IAAI,CAAA;;;;;;;;;;;;;;;;;;GAkBf,CAAC,CAAC;IAEH,MAAM,UAAU,GAAG,IAAI,CAAC,OAAO,CAAC,gBAAgB,CAAC,CAAC;IAClD,MAAM,MAAM,CAAC,UAAU,CAAC,CAAC,WAAW,EAAE,CAAC;IACvC,MAAM,UAAU,CAAC,KAAK,EAAE,CAAC;IAEzB,MAAM,MAAM,CAAC,UAAU,CAAC,OAAO,CAAC,aAAa,CAAC,CAAC,CAAC,WAAW,EAAE,CAAC;IAE9D,MAAM,cAAc,GAAG,UAAU,CAAC,OAAO,CAAC,qBAAqB,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;IACxE,MAAM,cAAc,CAAC,KAAK,EAAE,CAAC;IAE7B,MAAM,SAAS,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IACtC,MAAM,SAAS,GAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IAEtC,MAAM,MAAM,CAAC,SAAS,CAAC,CAAC,WAAW,EAAE,CAAC;IAEtC,MAAM,gBAAgB,GAAG,SAAS;SAC/B,OAAO,CAAC,kBAAkB,CAAC;SAC3B,MAAM,CAAC,EAAE,OAAO,EAAE,eAAe,EAAE,CAAC,CAAC;IACxC,MAAM,gBAAgB,CAAC,KAAK,EAAE,CAAC;IAE/B,MAAM,MAAM,CAAC,SAAS,CAAC,CAAC,WAAW,EAAE,CAAC;AACxC,CAAC,CAAC,CAAC","sourcesContent":["/*\n * SPDX-FileCopyrightText: 2023 Siemens AG\n *\n * SPDX-License-Identifier: MIT\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\nimport { expect } from '@playwright/test';\nimport { test } from '@utils/test';\n\nconst html = String.raw;\n\ntest('Nested dropdowns', async ({ mount, page }) => {\n await mount(html`\n <ix-menu>\n <ix-menu-avatar>\n <ix-menu-avatar-item label=\"test\" id=\"submenu-01\"></ix-menu-avatar-item>\n </ix-menu-avatar>\n </ix-menu>\n <ix-dropdown trigger=\"submenu-01\" id=\"d1\">\n <ix-dropdown-item>SubMenuItem 1</ix-dropdown-item>\n <ix-dropdown-item>SubMenuItem 2</ix-dropdown-item>\n <ix-dropdown-item>SubMenuItem 3</ix-dropdown-item>\n <ix-dropdown-item id=\"submenu-02\">SubMenuItem 4</ix-dropdown-item>\n </ix-dropdown>\n <ix-dropdown trigger=\"submenu-02\" id=\"d2\">\n <ix-dropdown-item>SubMenuItem 1</ix-dropdown-item>\n <ix-dropdown-item>SubMenuItem 2</ix-dropdown-item>\n <ix-dropdown-item>SubMenuItem 3</ix-dropdown-item>\n <ix-dropdown-item>SubMenuItem 4</ix-dropdown-item>\n </ix-dropdown>\n `);\n\n const menuAvatar = page.locator('ix-menu-avatar');\n await expect(menuAvatar).toBeVisible();\n await menuAvatar.click();\n\n await expect(menuAvatar.locator('ix-dropdown')).toBeVisible();\n\n const menuAvatarItem = menuAvatar.locator('ix-menu-avatar-item').nth(0);\n await menuAvatarItem.click();\n\n const dropdown1 = page.locator('#d1');\n const dropdown2 = page.locator('#d2');\n\n await expect(dropdown1).toBeVisible();\n\n const dropdown2Trigger = dropdown1\n .locator('ix-dropdown-item')\n .filter({ hasText: 'SubMenuItem 4' });\n await dropdown2Trigger.click();\n\n await expect(dropdown2).toBeVisible();\n});\n"]}
@@ -22,6 +22,14 @@
22
22
  * This source code is licensed under the MIT license found in the
23
23
  * LICENSE file in the root directory of this source tree.
24
24
  */
25
+ /*
26
+ * SPDX-FileCopyrightText: 2023 Siemens AG
27
+ *
28
+ * SPDX-License-Identifier: MIT
29
+ *
30
+ * This source code is licensed under the MIT license found in the
31
+ * LICENSE file in the root directory of this source tree.
32
+ */
25
33
  :host {
26
34
  /* width */
27
35
  /* Track */
@@ -67,9 +75,16 @@
67
75
  width: 100%;
68
76
  height: 100%;
69
77
  }
78
+ :host .category-text {
79
+ width: 100%;
80
+ padding-right: 0.25rem;
81
+ overflow: hidden;
82
+ text-overflow: ellipsis;
83
+ white-space: nowrap;
84
+ }
70
85
  :host .category-chevron {
71
86
  margin-left: auto;
72
- margin-right: 0px;
87
+ margin-right: 0;
73
88
  transition: var(--theme-default-time) transform ease-in-out;
74
89
  }
75
90
  :host .category-chevron--open {
@@ -77,18 +92,22 @@
77
92
  }
78
93
  :host .menu-items {
79
94
  overflow: hidden;
80
- max-height: 0px;
95
+ max-height: 0;
81
96
  transition: var(--theme-default-time) max-height ease-in-out;
82
- padding: 0.25rem 0 0.25rem 1.625rem;
83
97
  }
84
98
  :host .menu-items--expanded {
85
99
  max-height: 999999999px;
100
+ padding: 0.25rem 0 0.25rem 1.625rem;
101
+ }
102
+ :host .menu-items--collapsed {
103
+ display: none;
86
104
  }
87
105
  :host .category-dropdown ::slotted(ix-menu-item) {
88
106
  --ix-menu-item-height: 2.5rem;
89
107
  }
90
108
  :host .category-dropdown-header {
91
109
  pointer-events: none;
110
+ padding-left: 0.125rem;
92
111
  min-width: 256px;
93
112
  }
94
113
  :host ::slotted(ix-menu-item) {
@@ -86,12 +86,16 @@ export class MenuCategory {
86
86
  isCategoryItemListVisible() {
87
87
  return this.menuExpand && (this.showItems || this.isNestedItemActive());
88
88
  }
89
- componentDidLoad() {
89
+ componentWillLoad() {
90
90
  const closestMenu = closestIxMenu(this.hostElement);
91
91
  if (!closestMenu) {
92
92
  throw Error('ix-menu-category can only be used as a child of ix-menu');
93
93
  }
94
94
  this.ixMenu = closestMenu;
95
+ this.menuExpand = this.ixMenu.expand;
96
+ this.showItems = this.isCategoryItemListVisible();
97
+ }
98
+ componentDidLoad() {
95
99
  this.observer = createMutationObserver(() => this.onNestedItemsChanged());
96
100
  this.observer.observe(this.hostElement, {
97
101
  attributes: true,
@@ -103,24 +107,32 @@ export class MenuCategory {
103
107
  });
104
108
  this.ixMenu.addEventListener('expandChange', ({ detail: menuExpand }) => {
105
109
  this.menuExpand = menuExpand;
110
+ if (!menuExpand) {
111
+ this.clearMenuItemStyles();
112
+ }
106
113
  this.showItems = this.isCategoryItemListVisible();
107
114
  });
108
115
  }
116
+ clearMenuItemStyles() {
117
+ this.menuItemsContainer.style.removeProperty('max-height');
118
+ this.menuItemsContainer.style.removeProperty('opacity');
119
+ }
109
120
  disconnectedCallback() {
110
121
  if (this.observer) {
111
122
  this.observer.disconnect();
112
123
  }
113
124
  }
114
125
  render() {
115
- return (h(Host, { key: '200bff1a548044f19fb8f2280dfbfafe1e5cfcdd', class: {
126
+ return (h(Host, { key: '3f5dfce349405ecd3798a5dfd952ac42f8487e6d', class: {
116
127
  expanded: this.showItems,
117
- } }, h("ix-menu-item", { key: '447015d4ad34f0c2a37ea1c676abb71c062f475c', class: 'category-parent', active: this.isNestedItemActive(), notifications: this.notifications, icon: this.icon, onClick: (e) => this.onCategoryClicked(e) }, h("div", { key: 'e0a548b93ea0286298d7d05aa2df2fcafc648fdc', class: "category" }, this.label, h("ix-icon", { key: '1df8ba182dfed3a4b0ce676a4a1e796749d2dacb', name: 'chevron-down-small', class: {
128
+ } }, h("ix-menu-item", { key: '6cd75627b0929758afa3c0cb931ba0c32df13bd2', class: 'category-parent', active: this.isNestedItemActive(), notifications: this.notifications, icon: this.icon, onClick: (e) => this.onCategoryClicked(e) }, h("div", { key: 'c0022335362c681a5d9bf3ddd688439ea865d20d', class: "category" }, h("div", { key: '77a3681c6bd3a7c8f5dbad2a7527fc91af0c2d3a', class: "category-text" }, this.label), h("ix-icon", { key: '06f46b6d5f1ba7ad020126f297d37972f972bee4', name: 'chevron-down-small', class: {
118
129
  'category-chevron': true,
119
130
  'category-chevron--open': this.showItems,
120
- } }))), h("div", { key: 'ade480e9fb57aa93a4796c9c685c1af80db170eb', ref: (ref) => (this.menuItemsContainer = ref), class: {
131
+ } }))), h("div", { key: 'd442db2f892f10fd430334664260cd657da22cb8', ref: (ref) => (this.menuItemsContainer = ref), class: {
121
132
  'menu-items': true,
122
133
  'menu-items--expanded': this.showItems,
123
- } }, this.showItems ? h("slot", null) : null), h("ix-dropdown", { key: '8c0c5c2a17314bf9da36dfc6d0c147ee67c7ac16', closeBehavior: 'both', show: this.showDropdown, onShowChanged: ({ detail: dropdownShown }) => {
134
+ 'menu-items--collapsed': !this.showItems,
135
+ } }, this.showItems ? h("slot", null) : null), h("ix-dropdown", { key: '3c0d16c043a3f453ce879bae38a35eb02ae646a4', closeBehavior: 'both', show: this.showDropdown, onShowChanged: ({ detail: dropdownShown }) => {
124
136
  this.showDropdown = dropdownShown;
125
137
  }, class: 'category-dropdown', anchor: this.hostElement, placement: "right-start", offset: {
126
138
  mainAxis: 3,
@@ -130,7 +142,7 @@ export class MenuCategory {
130
142
  this.showDropdown = false;
131
143
  }
132
144
  }
133
- } }, h("ix-dropdown-item", { key: 'd85fdf6132b7214c478547f95ecb28be7b11c3ae', class: 'category-dropdown-header' }, h("ix-typography", { key: 'b41ede61c366cf9ca189f19ccf1b7369bc3907bd', variant: "default-title-single", color: "std" }, this.label)), h("ix-divider", { key: '5a354c66b93f5f630f75b519234c8f167a15aec9' }), h("slot", { key: '505699faf4ef92aeaea9a8b098b82b8900c56128' }))));
145
+ } }, h("ix-dropdown-item", { key: '26f3d0e5bab44a7dbf86a23743f252916887c56a', class: 'category-dropdown-header' }, h("ix-typography", { key: 'd8f1724a07a9b3d050d8e215a6a321e57b54cc82', variant: "default-title-single", color: "std" }, this.label)), h("ix-divider", { key: '67b72bfdacc3db1127cf21accce402bf3f10d5b7' }), h("slot", { key: 'bf8ed74c15b32d89ff13509678e7a735ab3f73e0' }))));
134
146
  }
135
147
  static get is() { return "ix-menu-category"; }
136
148
  static get encapsulation() { return "shadow"; }
@@ -1 +1 @@
1
- {"version":3,"file":"menu-category.js","sourceRoot":"","sources":["../../../src/components/menu-category/menu-category.tsx"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACzE,OAAO,KAAK,MAAM,SAAS,CAAC;AAC5B,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AACpE,OAAO,EAAE,sBAAsB,EAAE,MAAM,4BAA4B,CAAC;AAEpE,MAAM,uBAAuB,GAAG,EAAE,CAAC;AACnC,MAAM,uBAAuB,GAAG,GAAG,CAAC;AAEpC;;GAEG;AAMH,MAAM,OAAO,YAAY;;;;;0BAkBD,KAAK;yBACN,KAAK;4BACF,KAAK;2BACmB,EAAE;;IAM1C,kBAAkB;QACxB,OAAO,IAAI,CAAC,cAAc,E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AC,CAAC,eAAa,CAAC,CAAC,CAAC,IAAI,CAClC;YACN,oEACE,aAAa,EAAE,MAAM,EACrB,IAAI,EAAE,IAAI,CAAC,YAAY,EACvB,aAAa,EAAE,CAAC,EAAE,MAAM,EAAE,aAAa,EAAwB,EAAE,EAAE;oBACjE,IAAI,CAAC,YAAY,GAAG,aAAa,CAAC;gBACpC,CAAC,EACD,KAAK,EAAE,mBAAmB,EAC1B,MAAM,EAAE,IAAI,CAAC,WAAW,EACxB,SAAS,EAAC,aAAa,EACvB,MAAM,EAAE;oBACN,QAAQ,EAAE,CAAC;iBACZ,EACD,OAAO,EAAE,CAAC,CAAC,EAAE,EAAE;oBACb,IAAI,CAAC,CAAC,MAAM,YAAY,WAAW,EAAE,CAAC;wBACpC,IAAI,CAAC,CAAC,MAAM,CAAC,OAAO,KAAK,cAAc,EAAE,CAAC;4BACxC,IAAI,CAAC,YAAY,GAAG,KAAK,CAAC;wBAC5B,CAAC;oBACH,CAAC;gBACH,CAAC;gBAED,yEAAkB,KAAK,EAAE,0BAA0B;oBACjD,sEAAe,OAAO,EAAC,sBAAsB,EAAC,KAAK,EAAC,KAAK,IACtD,IAAI,CAAC,KAAK,CACG,CACC;gBACnB,oEAAyB;gBACzB,8DAAa,CACD,CACT,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["/*\n * SPDX-FileCopyrightText: 2023 Siemens AG\n *\n * SPDX-License-Identifier: MIT\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\nimport { Component, Element, h, Host, Prop, State } from '@stencil/core';\nimport anime from 'animejs';\nimport { closestIxMenu } from '../utils/application-layout/context';\nimport { createMutationObserver } from '../utils/mutation-observer';\n\nconst DefaultIxMenuItemHeight = 40;\nconst DefaultAnimationTimeout = 150;\n\n/**\n * @since 2.0.0\n */\n@Component({\n tag: 'ix-menu-category',\n styleUrl: 'menu-category.scss',\n shadow: true,\n})\nexport class MenuCategory {\n @Element() hostElement: HTMLIxMenuCategoryElement;\n\n /**\n * Display name of the category\n */\n @Prop() label: string;\n\n /**\n * Icon of the category\n */\n @Prop() icon: string;\n\n /**\n * Show notification count on the category\n */\n @Prop() notifications: number;\n\n @State() menuExpand = false;\n @State() showItems = false;\n @State() showDropdown = false;\n @State() nestedItems: HTMLIxMenuItemElement[] = [];\n\n private observer: MutationObserver;\n private menuItemsContainer: HTMLDivElement;\n private ixMenu: HTMLIxMenuElement;\n\n private isNestedItemActive() {\n return this.getNestedItems().some((item) => item.active);\n }\n\n private getNestedItems() {\n return Array.from(\n this.hostElement.querySelectorAll(':scope ix-menu-item')\n ) as HTMLIxMenuItemElement[];\n }\n\n private getNestedItemsHeight() {\n const items = this.getNestedItems();\n\n return items.length * DefaultIxMenuItemHeight;\n }\n\n private onExpandCategory(showItems: boolean) {\n if (showItems) {\n this.animateFadeIn();\n } else {\n this.animateFadeOut();\n }\n }\n\n private animateFadeOut() {\n const slotHideThresholdMs = 25;\n anime({\n targets: this.menuItemsContainer,\n duration: DefaultAnimationTimeout,\n easing: 'easeInSine',\n opacity: [1, 0],\n maxHeight: [this.getNestedItemsHeight() + DefaultIxMenuItemHeight, 0],\n complete: () => {\n setTimeout(() => {\n this.showItems = false;\n this.showDropdown = false;\n }, DefaultAnimationTimeout + slotHideThresholdMs);\n },\n });\n }\n\n private animateFadeIn() {\n anime({\n targets: this.menuItemsContainer,\n duration: DefaultAnimationTimeout,\n easing: 'easeInSine',\n opacity: [0, 1],\n maxHeight: [0, this.getNestedItemsHeight() + DefaultIxMenuItemHeight],\n begin: () => {\n this.showItems = true;\n this.showDropdown = false;\n },\n });\n }\n\n private onCategoryClicked(e?: MouseEvent) {\n if (this.ixMenu.expand) {\n e?.stopPropagation();\n this.onExpandCategory(!this.showItems);\n return;\n }\n\n this.showDropdown = !this.showDropdown;\n }\n\n private onNestedItemsChanged() {\n this.nestedItems = this.getNestedItems();\n }\n\n private isCategoryItemListVisible() {\n return this.menuExpand && (this.showItems || this.isNestedItemActive());\n }\n\n componentDidLoad() {\n const closestMenu = closestIxMenu(this.hostElement);\n if (!closestMenu) {\n throw Error('ix-menu-category can only be used as a child of ix-menu');\n }\n this.ixMenu = closestMenu;\n\n this.observer = createMutationObserver(() => this.onNestedItemsChanged());\n this.observer.observe(this.hostElement, {\n attributes: true,\n childList: true,\n subtree: true,\n });\n\n requestAnimationFrame(() => {\n this.onNestedItemsChanged();\n });\n\n this.ixMenu.addEventListener(\n 'expandChange',\n ({ detail: menuExpand }: CustomEvent<boolean>) => {\n this.menuExpand = menuExpand;\n\n this.showItems = this.isCategoryItemListVisible();\n }\n );\n }\n\n disconnectedCallback() {\n if (this.observer) {\n this.observer.disconnect();\n }\n }\n\n render() {\n return (\n <Host\n class={{\n expanded: this.showItems,\n }}\n >\n <ix-menu-item\n class={'category-parent'}\n active={this.isNestedItemActive()}\n notifications={this.notifications}\n icon={this.icon}\n onClick={(e) => this.onCategoryClicked(e)}\n >\n <div class=\"category\">\n {this.label}\n <ix-icon\n name={'chevron-down-small'}\n class={{\n 'category-chevron': true,\n 'category-chevron--open': this.showItems,\n }}\n ></ix-icon>\n </div>\n </ix-menu-item>\n <div\n ref={(ref) => (this.menuItemsContainer = ref!)}\n class={{\n 'menu-items': true,\n 'menu-items--expanded': this.showItems,\n }}\n >\n {this.showItems ? <slot></slot> : null}\n </div>\n <ix-dropdown\n closeBehavior={'both'}\n show={this.showDropdown}\n onShowChanged={({ detail: dropdownShown }: CustomEvent<boolean>) => {\n this.showDropdown = dropdownShown;\n }}\n class={'category-dropdown'}\n anchor={this.hostElement}\n placement=\"right-start\"\n offset={{\n mainAxis: 3,\n }}\n onClick={(e) => {\n if (e.target instanceof HTMLElement) {\n if (e.target.tagName === 'IX-MENU-ITEM') {\n this.showDropdown = false;\n }\n }\n }}\n >\n <ix-dropdown-item class={'category-dropdown-header'}>\n <ix-typography variant=\"default-title-single\" color=\"std\">\n {this.label}\n </ix-typography>\n </ix-dropdown-item>\n <ix-divider></ix-divider>\n <slot></slot>\n </ix-dropdown>\n </Host>\n );\n }\n}\n"]}
1
+ {"version":3,"file":"menu-category.js","sourceRoot":"","sources":["../../../src/components/menu-category/menu-category.tsx"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACzE,OAAO,KAAK,MAAM,SAAS,CAAC;AAC5B,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AACpE,OAAO,EAAE,sBAAsB,EAAE,MAAM,4BAA4B,CAAC;AAEpE,MAAM,uBAAuB,GAAG,EAAE,CAAC;AACnC,MAAM,uBAAuB,GAAG,GAAG,CAAC;AAEpC;;GAEG;AAMH,MAAM,OAAO,YAAY;;;;;0BAkBD,KAAK;yBACN,KAAK;4BACF,KAAK;2BACmB,EAAE;;IAM1C,kBAAkB;QACxB,OAAO,IAAI,CAAC,cAAc,EAAE,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;IAC3D,CAAC;IAEO,cAAc;QACpB,OAAO,KAAK,CAAC,IAAI,CACf,IAAI,CAAC,WAAW,CAAC,gBAAgB,CAAC,qBAAqB,CAAC,CAC9B,CAAC;IAC/B,CAAC;IAEO,oBAAoB;QAC1B,MAAM,KAAK,GAAG,IAAI,CAAC,cAAc,EAAE,CAAC;QAEpC,OAAO,KAAK,CAAC,MAAM,GAAG,uBAAuB,CAAC;IAChD,CAAC;IAEO,gBAAgB,CAAC,SAAkB;QACzC,IAAI,SAAS,EAAE,CAAC;YACd,IAAI,CAAC,aAAa,EAAE,CAAC;QACvB,CAAC;aAAM,CAAC;YACN,IAAI,CAAC,cAAc,EAAE,CAAC;QACxB,CAAC;IACH,CAAC;IAEO,cAAc;QACpB,MAAM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oEACE,aAAa,EAAE,MAAM,EACrB,IAAI,EAAE,IAAI,CAAC,YAAY,EACvB,aAAa,EAAE,CAAC,EAAE,MAAM,EAAE,aAAa,EAAwB,EAAE,EAAE;oBACjE,IAAI,CAAC,YAAY,GAAG,aAAa,CAAC;gBACpC,CAAC,EACD,KAAK,EAAE,mBAAmB,EAC1B,MAAM,EAAE,IAAI,CAAC,WAAW,EACxB,SAAS,EAAC,aAAa,EACvB,MAAM,EAAE;oBACN,QAAQ,EAAE,CAAC;iBACZ,EACD,OAAO,EAAE,CAAC,CAAC,EAAE,EAAE;oBACb,IAAI,CAAC,CAAC,MAAM,YAAY,WAAW,EAAE,CAAC;wBACpC,IAAI,CAAC,CAAC,MAAM,CAAC,OAAO,KAAK,cAAc,EAAE,CAAC;4BACxC,IAAI,CAAC,YAAY,GAAG,KAAK,CAAC;wBAC5B,CAAC;oBACH,CAAC;gBACH,CAAC;gBAED,yEAAkB,KAAK,EAAE,0BAA0B;oBACjD,sEAAe,OAAO,EAAC,sBAAsB,EAAC,KAAK,EAAC,KAAK,IACtD,IAAI,CAAC,KAAK,CACG,CACC;gBACnB,oEAAyB;gBACzB,8DAAa,CACD,CACT,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["/*\n * SPDX-FileCopyrightText: 2023 Siemens AG\n *\n * SPDX-License-Identifier: MIT\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\nimport { Component, Element, h, Host, Prop, State } from '@stencil/core';\nimport anime from 'animejs';\nimport { closestIxMenu } from '../utils/application-layout/context';\nimport { createMutationObserver } from '../utils/mutation-observer';\n\nconst DefaultIxMenuItemHeight = 40;\nconst DefaultAnimationTimeout = 150;\n\n/**\n * @since 2.0.0\n */\n@Component({\n tag: 'ix-menu-category',\n styleUrl: 'menu-category.scss',\n shadow: true,\n})\nexport class MenuCategory {\n @Element() hostElement: HTMLIxMenuCategoryElement;\n\n /**\n * Display name of the category\n */\n @Prop() label: string;\n\n /**\n * Icon of the category\n */\n @Prop() icon: string;\n\n /**\n * Show notification count on the category\n */\n @Prop() notifications: number;\n\n @State() menuExpand = false;\n @State() showItems = false;\n @State() showDropdown = false;\n @State() nestedItems: HTMLIxMenuItemElement[] = [];\n\n private observer: MutationObserver;\n private menuItemsContainer: HTMLDivElement;\n private ixMenu: HTMLIxMenuElement;\n\n private isNestedItemActive() {\n return this.getNestedItems().some((item) => item.active);\n }\n\n private getNestedItems() {\n return Array.from(\n this.hostElement.querySelectorAll(':scope ix-menu-item')\n ) as HTMLIxMenuItemElement[];\n }\n\n private getNestedItemsHeight() {\n const items = this.getNestedItems();\n\n return items.length * DefaultIxMenuItemHeight;\n }\n\n private onExpandCategory(showItems: boolean) {\n if (showItems) {\n this.animateFadeIn();\n } else {\n this.animateFadeOut();\n }\n }\n\n private animateFadeOut() {\n const slotHideThresholdMs = 25;\n anime({\n targets: this.menuItemsContainer,\n duration: DefaultAnimationTimeout,\n easing: 'easeInSine',\n opacity: [1, 0],\n maxHeight: [this.getNestedItemsHeight() + DefaultIxMenuItemHeight, 0],\n complete: () => {\n setTimeout(() => {\n this.showItems = false;\n this.showDropdown = false;\n }, DefaultAnimationTimeout + slotHideThresholdMs);\n },\n });\n }\n\n private animateFadeIn() {\n anime({\n targets: this.menuItemsContainer,\n duration: DefaultAnimationTimeout,\n easing: 'easeInSine',\n opacity: [0, 1],\n maxHeight: [0, this.getNestedItemsHeight() + DefaultIxMenuItemHeight],\n begin: () => {\n this.showItems = true;\n this.showDropdown = false;\n },\n });\n }\n\n private onCategoryClicked(e?: MouseEvent) {\n if (this.ixMenu.expand) {\n e?.stopPropagation();\n this.onExpandCategory(!this.showItems);\n return;\n }\n\n this.showDropdown = !this.showDropdown;\n }\n\n private onNestedItemsChanged() {\n this.nestedItems = this.getNestedItems();\n }\n\n private isCategoryItemListVisible() {\n return this.menuExpand && (this.showItems || this.isNestedItemActive());\n }\n\n componentWillLoad() {\n const closestMenu = closestIxMenu(this.hostElement);\n if (!closestMenu) {\n throw Error('ix-menu-category can only be used as a child of ix-menu');\n }\n this.ixMenu = closestMenu;\n\n this.menuExpand = this.ixMenu.expand;\n this.showItems = this.isCategoryItemListVisible();\n }\n\n componentDidLoad() {\n this.observer = createMutationObserver(() => this.onNestedItemsChanged());\n this.observer.observe(this.hostElement, {\n attributes: true,\n childList: true,\n subtree: true,\n });\n\n requestAnimationFrame(() => {\n this.onNestedItemsChanged();\n });\n\n this.ixMenu.addEventListener(\n 'expandChange',\n ({ detail: menuExpand }: CustomEvent<boolean>) => {\n this.menuExpand = menuExpand;\n if (!menuExpand) {\n this.clearMenuItemStyles();\n }\n this.showItems = this.isCategoryItemListVisible();\n }\n );\n }\n\n clearMenuItemStyles() {\n this.menuItemsContainer.style.removeProperty('max-height');\n this.menuItemsContainer.style.removeProperty('opacity');\n }\n\n disconnectedCallback() {\n if (this.observer) {\n this.observer.disconnect();\n }\n }\n\n render() {\n return (\n <Host\n class={{\n expanded: this.showItems,\n }}\n >\n <ix-menu-item\n class={'category-parent'}\n active={this.isNestedItemActive()}\n notifications={this.notifications}\n icon={this.icon}\n onClick={(e) => this.onCategoryClicked(e)}\n >\n <div class=\"category\">\n <div class=\"category-text\">{this.label}</div>\n <ix-icon\n name={'chevron-down-small'}\n class={{\n 'category-chevron': true,\n 'category-chevron--open': this.showItems,\n }}\n ></ix-icon>\n </div>\n </ix-menu-item>\n <div\n ref={(ref) => (this.menuItemsContainer = ref!)}\n class={{\n 'menu-items': true,\n 'menu-items--expanded': this.showItems,\n 'menu-items--collapsed': !this.showItems,\n }}\n >\n {this.showItems ? <slot></slot> : null}\n </div>\n <ix-dropdown\n closeBehavior={'both'}\n show={this.showDropdown}\n onShowChanged={({ detail: dropdownShown }: CustomEvent<boolean>) => {\n this.showDropdown = dropdownShown;\n }}\n class={'category-dropdown'}\n anchor={this.hostElement}\n placement=\"right-start\"\n offset={{\n mainAxis: 3,\n }}\n onClick={(e) => {\n if (e.target instanceof HTMLElement) {\n if (e.target.tagName === 'IX-MENU-ITEM') {\n this.showDropdown = false;\n }\n }\n }}\n >\n <ix-dropdown-item class={'category-dropdown-header'}>\n <ix-typography variant=\"default-title-single\" color=\"std\">\n {this.label}\n </ix-typography>\n </ix-dropdown-item>\n <ix-divider></ix-divider>\n <slot></slot>\n </ix-dropdown>\n </Host>\n );\n }\n}\n"]}
@@ -89,7 +89,7 @@ test('should show items as dropdown', async ({ mount, page }) => {
89
89
  await menuCategory.click();
90
90
  const dropdown = menuCategory.locator('ix-dropdown');
91
91
  await expect(dropdown).toBeVisible();
92
- await expect(menuCategory.locator('.menu-items')).toHaveClass('menu-items');
92
+ await expect(menuCategory.locator('.menu-items')).toHaveClass('menu-items menu-items--collapsed');
93
93
  const dropdownHeader = dropdown.locator('ix-dropdown-item');
94
94
  await expect(dropdownHeader).toHaveText('Category label');
95
95
  const itemOne = page.locator('ix-menu-item').nth(0);
@@ -119,6 +119,54 @@ test('should collapse category after collapse menu', async ({ mount, page, }) =>
119
119
  await menuCategory.click();
120
120
  await expect(menuCategory.locator('.menu-items')).toHaveClass('menu-items menu-items--expanded');
121
121
  await menuButton.click();
122
- await expect(menuCategory.locator('.menu-items')).toHaveClass('menu-items');
122
+ await expect(menuCategory.locator('.menu-items')).toHaveClass('menu-items menu-items--collapsed');
123
+ });
124
+ test('should hide menu-items when collapsed', async ({ mount, page }) => {
125
+ await mount(`
126
+ <ix-basic-navigation>
127
+ <ix-menu>
128
+ <ix-menu-category label="Category label">
129
+ <ix-menu-item>Test Item 1</ix-menu-item>
130
+ <ix-menu-item>Test Item 2</ix-menu-item>
131
+ </ix-menu-category>
132
+ </ix-menu>
133
+ </ix-basic-navigation>
134
+ `);
135
+ await page.waitForSelector('ix-menu');
136
+ const menu = page.locator('ix-menu');
137
+ await page
138
+ .locator('ix-basic-navigation')
139
+ .evaluate((menu) => (menu.breakpoints = ['md']));
140
+ const menuButton = menu.locator('ix-burger-menu');
141
+ await menuButton.click();
142
+ const menuCategory = page.locator('ix-menu-category');
143
+ await expect(menuCategory.locator('.menu-items')).toHaveClass('menu-items menu-items--collapsed');
144
+ await expect(menuCategory.locator('.menu-items')).toBeHidden();
145
+ });
146
+ test('should open category when collapsed initially and active', async ({ mount, page, }) => {
147
+ await mount(`
148
+ <ix-basic-navigation>
149
+ <ix-menu>
150
+ <ix-menu-category label="Category label">
151
+ <ix-menu-item active="true">Test Item 1</ix-menu-item>
152
+ <ix-menu-item>Test Item 2</ix-menu-item>
153
+ </ix-menu-category>
154
+ </ix-menu>
155
+ </ix-basic-navigation>
156
+ `);
157
+ await page.waitForSelector('ix-menu');
158
+ const menu = page.locator('ix-menu');
159
+ await page
160
+ .locator('ix-basic-navigation')
161
+ .evaluate((menu) => (menu.breakpoints = ['md']));
162
+ const menuButton = menu.locator('ix-burger-menu');
163
+ await menuButton.click();
164
+ const menuCategory = page.locator('ix-menu-category');
165
+ await expect(menuCategory.locator('.menu-items')).toHaveClass('menu-items menu-items--expanded');
166
+ await menuCategory.locator('.category-parent').click();
167
+ await expect(menuCategory.locator('.menu-items')).toHaveClass(/menu-items/);
168
+ await menuButton.click();
169
+ await menuButton.click();
170
+ await expect(menuCategory.locator('.menu-items')).toHaveClass('menu-items menu-items--expanded');
123
171
  });
124
172
  //# sourceMappingURL=menu-category.ct.js.map