@atlaskit/navigation-system 0.182.0 → 1.0.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 (790) hide show
  1. package/CHANGELOG.md +29 -0
  2. package/dist/cjs/components/skip-links/skip-links-container.js +25 -17
  3. package/dist/cjs/context/skip-links/skip-links-data-context.js +28 -10
  4. package/dist/cjs/context/skip-links/skip-links-provider.js +17 -6
  5. package/dist/cjs/ui/menu-item/menu-item.js +1 -1
  6. package/dist/cjs/ui/page-layout/root.js +11 -1
  7. package/dist/es2019/components/skip-links/skip-links-container.js +24 -16
  8. package/dist/es2019/context/skip-links/skip-links-data-context.js +25 -8
  9. package/dist/es2019/context/skip-links/skip-links-provider.js +17 -6
  10. package/dist/es2019/ui/menu-item/menu-item.js +1 -1
  11. package/dist/es2019/ui/page-layout/root.js +11 -1
  12. package/dist/esm/components/skip-links/skip-links-container.js +23 -15
  13. package/dist/esm/context/skip-links/skip-links-data-context.js +26 -9
  14. package/dist/esm/context/skip-links/skip-links-provider.js +16 -5
  15. package/dist/esm/ui/menu-item/menu-item.js +1 -1
  16. package/dist/esm/ui/page-layout/root.js +11 -1
  17. package/dist/types/components/skip-links/skip-links-container.d.ts +13 -8
  18. package/dist/types/context/skip-links/skip-links-data-context.d.ts +15 -1
  19. package/dist/types/context/skip-links/skip-links-provider.d.ts +9 -4
  20. package/dist/types-ts4.5/components/skip-links/skip-links-container.d.ts +13 -8
  21. package/dist/types-ts4.5/context/skip-links/skip-links-data-context.d.ts +15 -1
  22. package/dist/types-ts4.5/context/skip-links/skip-links-provider.d.ts +9 -4
  23. package/package.json +9 -10
  24. package/afm-cc/tsconfig.json +0 -78
  25. package/afm-dev-agents/tsconfig.json +0 -78
  26. package/afm-jira/tsconfig.json +0 -78
  27. package/afm-passionfruit/tsconfig.json +0 -78
  28. package/afm-post-office/tsconfig.json +0 -78
  29. package/afm-rovo-extension/tsconfig.json +0 -78
  30. package/afm-townsquare/tsconfig.json +0 -78
  31. package/afm-volt/tsconfig.json +0 -78
  32. package/build/tsconfig.json +0 -23
  33. package/docs/00-intro.tsx +0 -14
  34. package/examples/advanced-layout.tsx +0 -144
  35. package/examples/button-menu-item.tsx +0 -426
  36. package/examples/company-hub-mock.tsx +0 -219
  37. package/examples/composition.tsx +0 -424
  38. package/examples/confluence-mock.tsx +0 -381
  39. package/examples/constellation/common/mock-content.tsx +0 -39
  40. package/examples/constellation/common/mock-top-bar.tsx +0 -20
  41. package/examples/constellation/layout/custom-skip-links.tsx +0 -12
  42. package/examples/constellation/layout/custom-theming--parse-hex.tsx +0 -19
  43. package/examples/constellation/layout/custom-theming--parse-hsl.tsx +0 -22
  44. package/examples/constellation/layout/custom-theming--parse-rgb.tsx +0 -22
  45. package/examples/constellation/layout/custom-theming--parse-user-color.tsx +0 -22
  46. package/examples/constellation/layout/custom-theming--rgb-object.tsx +0 -21
  47. package/examples/constellation/layout/expand-side-nav.tsx +0 -17
  48. package/examples/constellation/layout/toggle-side-nav-keyboard-shortcut.tsx +0 -25
  49. package/examples/constellation/side-nav-items/actions-and-actions-on-hover.tsx +0 -153
  50. package/examples/constellation/side-nav-items/button-menu-item.tsx +0 -133
  51. package/examples/constellation/side-nav-items/common/global-app-icon-tile.tsx +0 -43
  52. package/examples/constellation/side-nav-items/common/mock-side-nav.tsx +0 -18
  53. package/examples/constellation/side-nav-items/container-avatar.tsx +0 -32
  54. package/examples/constellation/side-nav-items/elem-after.tsx +0 -60
  55. package/examples/constellation/side-nav-items/elem-before.tsx +0 -116
  56. package/examples/constellation/side-nav-items/expandable-menu-item-default-variant.tsx +0 -219
  57. package/examples/constellation/side-nav-items/expandable-menu-item-link-variant.tsx +0 -278
  58. package/examples/constellation/side-nav-items/flyout-menu-item.tsx +0 -156
  59. package/examples/constellation/side-nav-items/link-menu-item.tsx +0 -161
  60. package/examples/constellation/side-nav-items/menu-divider.tsx +0 -114
  61. package/examples/constellation/side-nav-items/menu-section.tsx +0 -177
  62. package/examples/constellation/side-nav-items/right-to-left.tsx +0 -144
  63. package/examples/constellation/side-nav-items/top-level-spacer.tsx +0 -82
  64. package/examples/constellation/side-nav-items/truncation.tsx +0 -58
  65. package/examples/constellation/top-nav-items/app-logo.tsx +0 -19
  66. package/examples/constellation/top-nav-items/custom-logo.tsx +0 -28
  67. package/examples/constellation/top-nav-items/custom-theming--buttons.tsx +0 -27
  68. package/examples/constellation/top-nav-items/custom-theming--logo.tsx +0 -27
  69. package/examples/constellation/top-nav-items/custom-theming--search.tsx +0 -28
  70. package/examples/constellation/top-nav-items/custom-title.tsx +0 -20
  71. package/examples/constellation/top-nav-items/end-item.tsx +0 -23
  72. package/examples/constellation/top-nav-items/top-nav-button.tsx +0 -34
  73. package/examples/constellation/top-nav-items/top-nav-end.tsx +0 -25
  74. package/examples/constellation/top-nav-items/top-nav-middle.tsx +0 -19
  75. package/examples/constellation/top-nav-items/top-nav-start.tsx +0 -31
  76. package/examples/drag-and-drop/jira/data.tsx +0 -320
  77. package/examples/drag-and-drop/jira/entry.tsx +0 -89
  78. package/examples/drag-and-drop/jira/filters/filter-move-modal.tsx +0 -171
  79. package/examples/drag-and-drop/jira/filters/filter-tree-utils.tsx +0 -134
  80. package/examples/drag-and-drop/jira/filters/filters-menu-item.tsx +0 -470
  81. package/examples/drag-and-drop/jira/for-you/for-you-menu-item.tsx +0 -74
  82. package/examples/drag-and-drop/jira/projects/project-tile.tsx +0 -37
  83. package/examples/drag-and-drop/jira/projects/project.tsx +0 -257
  84. package/examples/drag-and-drop/jira/projects/projects-menu-item.tsx +0 -120
  85. package/examples/drag-and-drop/jira/recent/recent-menu-item.tsx +0 -30
  86. package/examples/drag-and-drop/jira/reducer.tsx +0 -78
  87. package/examples/drag-and-drop/jira/registry.tsx +0 -52
  88. package/examples/drag-and-drop/jira/reorder-actions.tsx +0 -75
  89. package/examples/drag-and-drop/jira/shared-top-level-flyout.tsx +0 -144
  90. package/examples/drag-and-drop/jira/sidebar.tsx +0 -361
  91. package/examples/drag-and-drop/jira/starred/starred-menu-item.tsx +0 -29
  92. package/examples/drag-and-drop/jira/state-context.tsx +0 -34
  93. package/examples/drag-and-drop/jira/top-level-shared-more-menu.tsx +0 -99
  94. package/examples/drag-and-drop/sidebar-example-container.tsx +0 -38
  95. package/examples/drag-and-drop/simple.tsx +0 -653
  96. package/examples/drag-and-drop/standalone-jira-sidebar-centered.tsx +0 -27
  97. package/examples/drag-and-drop/standalone-jira-sidebar.tsx +0 -18
  98. package/examples/drag-and-drop-in-the-sidebar-flyout.tsx +0 -161
  99. package/examples/drag-and-drop-jira-scaling-vr.tsx +0 -25
  100. package/examples/drag-and-drop-jira-sidebar-centered.tsx +0 -1
  101. package/examples/drag-and-drop-jira-sidebar-standalone.tsx +0 -1
  102. package/examples/drag-and-drop-jira.tsx +0 -1
  103. package/examples/drag-and-drop.tsx +0 -1
  104. package/examples/expandable-menu-item.tsx +0 -775
  105. package/examples/flyout-menu-item-async-content.tsx +0 -118
  106. package/examples/flyout-menu-item-multiple.tsx +0 -180
  107. package/examples/flyout-menu-item.tsx +0 -269
  108. package/examples/images/200x20.png +0 -0
  109. package/examples/images/200x200.png +0 -0
  110. package/examples/images/20x20.png +0 -0
  111. package/examples/images/20x200.png +0 -0
  112. package/examples/images/cd.svg +0 -9
  113. package/examples/images/koala.png +0 -0
  114. package/examples/images/koala.svg +0 -9
  115. package/examples/images/money.svg +0 -9
  116. package/examples/images/science.svg +0 -20
  117. package/examples/interactive-layout.tsx +0 -286
  118. package/examples/layers-in-main.tsx +0 -294
  119. package/examples/legacy-var-testing.tsx +0 -173
  120. package/examples/link-menu-item.tsx +0 -383
  121. package/examples/main-content-border.tsx +0 -148
  122. package/examples/menu-item-avatar.tsx +0 -41
  123. package/examples/menu-item-conditional-tooltip.tsx +0 -304
  124. package/examples/menu-item-focus-ring-bleed.tsx +0 -50
  125. package/examples/menu-item-integration.tsx +0 -207
  126. package/examples/menu-item-narrow.tsx +0 -290
  127. package/examples/menu-item-scroll-into-view.tsx +0 -283
  128. package/examples/menu-items-deeply-nested.tsx +0 -330
  129. package/examples/menu-list.tsx +0 -62
  130. package/examples/menu-section.tsx +0 -78
  131. package/examples/page-layout-all-slots-banner-height-zero.tsx +0 -3
  132. package/examples/page-layout-all-slots-custom-sizes.tsx +0 -3
  133. package/examples/page-layout-all-slots-rtl.tsx +0 -3
  134. package/examples/page-layout-all-slots-scrollable.tsx +0 -3
  135. package/examples/page-layout-all-slots.tsx +0 -3
  136. package/examples/page-layout-aside-border.tsx +0 -149
  137. package/examples/page-layout-content-is-iframes.tsx +0 -3
  138. package/examples/page-layout-edge-case-absolute-positioned-collapsed-custom-sizes.tsx +0 -3
  139. package/examples/page-layout-edge-case-absolute-positioned-collapsed.tsx +0 -3
  140. package/examples/page-layout-edge-case-absolute-positioned-panel-visible.tsx +0 -3
  141. package/examples/page-layout-edge-case-absolute-positioned-resizable.tsx +0 -3
  142. package/examples/page-layout-edge-case-absolute-positioned.tsx +0 -3
  143. package/examples/page-layout-edge-case-using-legacy-vars.tsx +0 -3
  144. package/examples/page-layout-full-screen.tsx +0 -251
  145. package/examples/page-layout-implicit-rows.tsx +0 -33
  146. package/examples/page-layout-main-aside-scrollable.tsx +0 -3
  147. package/examples/page-layout-main-aside.tsx +0 -3
  148. package/examples/page-layout-panel-aside-default-widths.tsx +0 -241
  149. package/examples/page-layout-resizable-rtl.tsx +0 -3
  150. package/examples/page-layout-resizable.tsx +0 -3
  151. package/examples/page-layout-side-nav-collapse-shortcut.tsx +0 -47
  152. package/examples/page-layout-side-nav-content-scroll-with-sticky.tsx +0 -135
  153. package/examples/page-layout-side-nav-custom-width-greater-than-max.tsx +0 -3
  154. package/examples/page-layout-side-nav-custom-width-smaller-than-min.tsx +0 -3
  155. package/examples/page-layout-side-nav-main-aside-scrollable.tsx +0 -3
  156. package/examples/page-layout-side-nav-main-aside.tsx +0 -3
  157. package/examples/page-layout-side-nav-onboarding.tsx +0 -155
  158. package/examples/page-layout-side-nav-overflowing-children.tsx +0 -3
  159. package/examples/page-layout-side-nav-slots.tsx +0 -173
  160. package/examples/page-layout-side-nav-with-menu-items.tsx +0 -3
  161. package/examples/page-layout-top-bar-side-nav-main-aside-scrollable.tsx +0 -3
  162. package/examples/page-layout-top-bar-side-nav-main-aside.tsx +0 -3
  163. package/examples/page-layout-top-bar-side-nav-main-scrollable.tsx +0 -3
  164. package/examples/page-layout-top-bar-side-nav-main.tsx +0 -3
  165. package/examples/page-layout.tsx +0 -941
  166. package/examples/panel-splitter.tsx +0 -199
  167. package/examples/resizable-slots.tsx +0 -357
  168. package/examples/side-nav-flyout.tsx +0 -256
  169. package/examples/stand-alone-iframe.tsx +0 -23
  170. package/examples/temp-icons/app-switcher-legacy.tsx +0 -14
  171. package/examples/temp-icons/atlassian-intelligence.tsx +0 -14
  172. package/examples/temp-icons/help.tsx +0 -18
  173. package/examples/temp-icons/menu.tsx +0 -14
  174. package/examples/temp-icons/settings.tsx +0 -14
  175. package/examples/top-level-spacer.tsx +0 -55
  176. package/examples/top-nav-custom-profile-image.tsx +0 -71
  177. package/examples/top-nav-side-nav-collapsed.tsx +0 -74
  178. package/examples/top-nav-with-long-name.tsx +0 -63
  179. package/examples/top-nav-with-temp-nav-app-icon-app-logo.tsx +0 -65
  180. package/examples/top-nav-with-temp-nav-app-icon-custom-logo.tsx +0 -63
  181. package/examples/top-navigation-custom-logo.tsx +0 -108
  182. package/examples/top-navigation-stress.tsx +0 -244
  183. package/examples/top-navigation-themed-buttons.tsx +0 -63
  184. package/examples/top-navigation-theming-logged-out.tsx +0 -75
  185. package/examples/top-navigation-theming-with-picker.tsx +0 -128
  186. package/examples/top-navigation-theming.tsx +0 -197
  187. package/examples/top-navigation.tsx +0 -126
  188. package/examples/utils/example-utils.tsx +0 -14
  189. package/examples/utils/long-placeholder-content.tsx +0 -161
  190. package/examples/utils/mock-root.tsx +0 -19
  191. package/examples/utils/mock-search.tsx +0 -67
  192. package/src/__tests__/informational-vr-tests/__snapshots__/layering/layers-in-main-slot--desktop--platform-dst-nav4-layering-in-main-slot-fixes-false.png +0 -0
  193. package/src/__tests__/informational-vr-tests/__snapshots__/layering/layers-in-main-slot--desktop--platform-dst-nav4-layering-in-main-slot-fixes-true.png +0 -0
  194. package/src/__tests__/informational-vr-tests/__snapshots__/layering/layers-in-main-slot-short-viewport--desktop--platform-dst-nav4-layering-in-main-slot-fixes-false.png +0 -0
  195. package/src/__tests__/informational-vr-tests/__snapshots__/layering/layers-in-main-slot-short-viewport--desktop--platform-dst-nav4-layering-in-main-slot-fixes-true.png +0 -0
  196. package/src/__tests__/informational-vr-tests/__snapshots__/layering/side-nav-expanded-on-mobile--mobile.png +0 -0
  197. package/src/__tests__/informational-vr-tests/__snapshots__/layering/side-nav-expanded-on-mobile-without-panel--mobile.png +0 -0
  198. package/src/__tests__/informational-vr-tests/__snapshots__/menu-items-deeply-nested/side-nav-with-deeply-nested-menu-items---nested-menu-item-selected--default.png +0 -0
  199. package/src/__tests__/informational-vr-tests/__snapshots__/menu-items-deeply-nested/side-nav-with-deeply-nested-menu-items---scrolled-to-the-end--default.png +0 -0
  200. package/src/__tests__/informational-vr-tests/__snapshots__/menu-items-deeply-nested/side-nav-with-deeply-nested-menu-items--default.png +0 -0
  201. package/src/__tests__/informational-vr-tests/__snapshots__/sidebar-drag-and-drop/sidebar-drag-and-drop---hover-bug--desktop-chrome.png +0 -0
  202. package/src/__tests__/informational-vr-tests/__snapshots__/sidebar-drag-and-drop/sidebar-drag-and-drop---hover-bug--desktop-firefox.png +0 -0
  203. package/src/__tests__/informational-vr-tests/__snapshots__/sidebar-drag-and-drop/sidebar-drag-and-drop---hover-bug--desktop-webkit.png +0 -0
  204. package/src/__tests__/informational-vr-tests/__snapshots__/sidebar-drag-and-drop/sidebar-drag-and-drop--desktop-chrome.png +0 -0
  205. package/src/__tests__/informational-vr-tests/__snapshots__/sidebar-drag-and-drop/sidebar-drag-and-drop--desktop-firefox.png +0 -0
  206. package/src/__tests__/informational-vr-tests/__snapshots__/sidebar-drag-and-drop/sidebar-drag-and-drop--desktop-webkit.png +0 -0
  207. package/src/__tests__/informational-vr-tests/layering.vr.tsx +0 -76
  208. package/src/__tests__/informational-vr-tests/menu-items-deeply-nested.vr.tsx +0 -33
  209. package/src/__tests__/informational-vr-tests/sidebar-drag-and-drop.vr.tsx +0 -100
  210. package/src/__tests__/playwright/drag-and-drop-in-the-sidebar-flyout.spec.tsx +0 -235
  211. package/src/__tests__/playwright/expandable-menu-item.spec.tsx +0 -20
  212. package/src/__tests__/playwright/flyout-menu-item.spec.tsx +0 -22
  213. package/src/__tests__/playwright/legacy-vars.spec.tsx +0 -298
  214. package/src/__tests__/playwright/menu-item-in-sidebar-drag-and-drop.spec.tsx +0 -70
  215. package/src/__tests__/playwright/page-layout.spec.tsx +0 -23
  216. package/src/__tests__/playwright/panel.spec.tsx +0 -241
  217. package/src/__tests__/playwright/resizing.spec.tsx +0 -541
  218. package/src/__tests__/playwright/side-nav-flyout.spec.tsx +0 -223
  219. package/src/__tests__/playwright/side-nav-responsiveness.spec.tsx +0 -208
  220. package/src/__tests__/playwright/skip-links.spec.tsx +0 -111
  221. package/src/__tests__/playwright/top-nav-end.spec.tsx +0 -96
  222. package/src/__tests__/vr-tests/__snapshots__/a11y-scaling/app--desktop.png +0 -0
  223. package/src/__tests__/vr-tests/__snapshots__/layering/scrollable-no-panel-vr--desktop-large.png +0 -0
  224. package/src/__tests__/vr-tests/__snapshots__/layering/scrollable-no-panel-vr--desktop.png +0 -0
  225. package/src/__tests__/vr-tests/__snapshots__/layering/scrollable-no-panel-vr--mobile.png +0 -0
  226. package/src/__tests__/vr-tests/__snapshots__/layering/scrollable-scrolled-vr--desktop-large.png +0 -0
  227. package/src/__tests__/vr-tests/__snapshots__/layering/scrollable-scrolled-vr--desktop.png +0 -0
  228. package/src/__tests__/vr-tests/__snapshots__/layering/scrollable-scrolled-vr--mobile.png +0 -0
  229. package/src/__tests__/vr-tests/__snapshots__/layering/scrollable-vr--desktop-large-splitter.png +0 -0
  230. package/src/__tests__/vr-tests/__snapshots__/layering/scrollable-vr--desktop-large.png +0 -0
  231. package/src/__tests__/vr-tests/__snapshots__/layering/scrollable-vr--desktop.png +0 -0
  232. package/src/__tests__/vr-tests/__snapshots__/layering/scrollable-vr--mobile.png +0 -0
  233. package/src/__tests__/vr-tests/__snapshots__/layering/unscrollable-no-panel-vr--desktop-large.png +0 -0
  234. package/src/__tests__/vr-tests/__snapshots__/layering/unscrollable-no-panel-vr--desktop.png +0 -0
  235. package/src/__tests__/vr-tests/__snapshots__/layering/unscrollable-no-panel-vr--mobile.png +0 -0
  236. package/src/__tests__/vr-tests/__snapshots__/layering/unscrollable-vr--desktop-large.png +0 -0
  237. package/src/__tests__/vr-tests/__snapshots__/layering/unscrollable-vr--desktop.png +0 -0
  238. package/src/__tests__/vr-tests/__snapshots__/layering/unscrollable-vr--mobile.png +0 -0
  239. package/src/__tests__/vr-tests/__snapshots__/skip-links/skip-links--light-mode.png +0 -0
  240. package/src/__tests__/vr-tests/a11y-scaling.vr.tsx +0 -12
  241. package/src/__tests__/vr-tests/layering.vr.tsx +0 -82
  242. package/src/__tests__/vr-tests/skip-links.vr.tsx +0 -14
  243. package/src/components/__tests__/unit/badge-container.test.tsx +0 -62
  244. package/src/components/__tests__/unit/list.test.tsx +0 -74
  245. package/src/components/badge-container.tsx +0 -72
  246. package/src/components/forward-ref-with-generic.tsx +0 -8
  247. package/src/components/list-item.tsx +0 -39
  248. package/src/components/list.tsx +0 -44
  249. package/src/components/skip-links/__tests__/unit/skip-links-container.test.tsx +0 -411
  250. package/src/components/skip-links/skip-link.tsx +0 -140
  251. package/src/components/skip-links/skip-links-container.tsx +0 -112
  252. package/src/context/skip-links/skip-links-context.tsx +0 -74
  253. package/src/context/skip-links/skip-links-data-context.tsx +0 -41
  254. package/src/context/skip-links/skip-links-provider.tsx +0 -74
  255. package/src/context/skip-links/types.tsx +0 -29
  256. package/src/context/top-nav-start/top-nav-start-context-provider.tsx +0 -26
  257. package/src/context/top-nav-start/top-nav-start-context.tsx +0 -21
  258. package/src/entry-points/experimental/color-utils/parse-hex.tsx +0 -1
  259. package/src/entry-points/experimental/color-utils/parse-hsl.tsx +0 -1
  260. package/src/entry-points/experimental/color-utils/parse-rgb.tsx +0 -1
  261. package/src/entry-points/experimental/color-utils/parse-user-color.tsx +0 -1
  262. package/src/entry-points/experimental/top-nav-button.tsx +0 -6
  263. package/src/entry-points/experimental/use-has-custom-theme.tsx +0 -1
  264. package/src/entry-points/experimental/use-legacy-search-theme.tsx +0 -1
  265. package/src/entry-points/layout/aside.tsx +0 -1
  266. package/src/entry-points/layout/banner.tsx +0 -1
  267. package/src/entry-points/layout/main.tsx +0 -7
  268. package/src/entry-points/layout/panel-splitter.tsx +0 -3
  269. package/src/entry-points/layout/panel.tsx +0 -1
  270. package/src/entry-points/layout/root.tsx +0 -1
  271. package/src/entry-points/layout/side-nav.tsx +0 -7
  272. package/src/entry-points/layout/skip-links.tsx +0 -2
  273. package/src/entry-points/layout/top-nav.tsx +0 -4
  274. package/src/entry-points/side-nav-items/button-menu-item.tsx +0 -3
  275. package/src/entry-points/side-nav-items/container-avatar.tsx +0 -1
  276. package/src/entry-points/side-nav-items/drag-and-drop/drag-preview.tsx +0 -1
  277. package/src/entry-points/side-nav-items/drag-and-drop/drop-indicator.tsx +0 -5
  278. package/src/entry-points/side-nav-items/drag-and-drop/group-drop-indicator.tsx +0 -1
  279. package/src/entry-points/side-nav-items/drag-and-drop/hitbox.tsx +0 -7
  280. package/src/entry-points/side-nav-items/drag-and-drop/use-menu-item-drag-and-drop.tsx +0 -4
  281. package/src/entry-points/side-nav-items/expandable-menu-item.tsx +0 -13
  282. package/src/entry-points/side-nav-items/flyout-menu-item.tsx +0 -13
  283. package/src/entry-points/side-nav-items/link-menu-item.tsx +0 -3
  284. package/src/entry-points/side-nav-items/menu-list-item.tsx +0 -1
  285. package/src/entry-points/side-nav-items/menu-list.tsx +0 -1
  286. package/src/entry-points/side-nav-items/menu-section.tsx +0 -3
  287. package/src/entry-points/side-nav-items/top-level-spacer.tsx +0 -1
  288. package/src/entry-points/top-nav-items/create-button.tsx +0 -1
  289. package/src/entry-points/top-nav-items/custom-title.tsx +0 -1
  290. package/src/entry-points/top-nav-items/help.tsx +0 -1
  291. package/src/entry-points/top-nav-items/index.tsx +0 -14
  292. package/src/entry-points/top-nav-items/log-in.tsx +0 -1
  293. package/src/entry-points/top-nav-items/notifications.tsx +0 -1
  294. package/src/entry-points/top-nav-items/profile.tsx +0 -1
  295. package/src/entry-points/top-nav-items/settings.tsx +0 -1
  296. package/src/index.tsx +0 -74
  297. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/flyout-menu-item-async-content/long-content-after-short-skeleton--default.png +0 -0
  298. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/flyout-menu-item-async-content/long-skeleton--default.png +0 -0
  299. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/flyout-menu-item-async-content/short-content-after-long-skeleton--default.png +0 -0
  300. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/flyout-menu-item-async-content/short-skeleton--default.png +0 -0
  301. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item/button-menu-item---disabled---pressed--default.png +0 -0
  302. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item/button-menu-item---pressed--default.png +0 -0
  303. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item/expandable-menu-item---not-selectable---pressed--default.png +0 -0
  304. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item/expandable-menu-item---selectable---pressed--default.png +0 -0
  305. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item/expandable-menu-item---selected---pressed--default.png +0 -0
  306. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item/flyout-menu-item---pressed--default.png +0 -0
  307. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item/flyout-menu-item---selected---pressed--default.png +0 -0
  308. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item/link-menu-item---pressed--default.png +0 -0
  309. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item/link-menu-item---scroll-into-view-behavior--desktop-chrome.png +0 -0
  310. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item/link-menu-item---scroll-into-view-behavior--desktop-firefox.png +0 -0
  311. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item/link-menu-item---scroll-into-view-behavior--desktop-safari.png +0 -0
  312. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item/link-menu-item---selected---pressed--default.png +0 -0
  313. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item-increased-hitbox/increasing-hitbox-for-nested-items-click-target---desktop-chrome.png +0 -0
  314. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item-increased-hitbox/increasing-hitbox-for-nested-items-click-target---desktop-firefox.png +0 -0
  315. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item-increased-hitbox/increasing-hitbox-for-nested-items-click-target---desktop-webkit.png +0 -0
  316. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item-increased-hitbox/increasing-hitbox-for-nested-items-hover---desktop-chrome.png +0 -0
  317. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item-increased-hitbox/increasing-hitbox-for-nested-items-hover---desktop-firefox.png +0 -0
  318. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item-increased-hitbox/increasing-hitbox-for-nested-items-hover---desktop-webkit.png +0 -0
  319. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item-increased-hitbox/increasing-hitbox-for-nested-items-too-far-back---desktop-chrome.png +0 -0
  320. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item-increased-hitbox/increasing-hitbox-for-nested-items-too-far-back---desktop-firefox.png +0 -0
  321. package/src/ui/menu-item/__tests__/informational-vr-tests/__snapshots__/menu-item-increased-hitbox/increasing-hitbox-for-nested-items-too-far-back---desktop-webkit.png +0 -0
  322. package/src/ui/menu-item/__tests__/informational-vr-tests/flyout-menu-item-async-content.vr.tsx +0 -33
  323. package/src/ui/menu-item/__tests__/informational-vr-tests/menu-item-increased-hitbox.vr.tsx +0 -79
  324. package/src/ui/menu-item/__tests__/informational-vr-tests/menu-item.vr.tsx +0 -151
  325. package/src/ui/menu-item/__tests__/playwright/flyout-menu-item.spec.tsx +0 -38
  326. package/src/ui/menu-item/__tests__/playwright/scroll-into-view.spec.tsx +0 -91
  327. package/src/ui/menu-item/__tests__/unit/_util.tsx +0 -40
  328. package/src/ui/menu-item/__tests__/unit/expandable-menu-item.test.tsx +0 -1119
  329. package/src/ui/menu-item/__tests__/unit/flyout-menu-item.test.tsx +0 -545
  330. package/src/ui/menu-item/__tests__/unit/menu-item.test.tsx +0 -649
  331. package/src/ui/menu-item/__tests__/unit/top-level-spacer.test.tsx +0 -94
  332. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/button-menu-item--desktop-chrome.png +0 -0
  333. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/button-menu-item--desktop-webkit.png +0 -0
  334. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/button-menu-item-combine--desktop-chrome.png +0 -0
  335. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/button-menu-item-combine--desktop-webkit.png +0 -0
  336. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/button-menu-item-reorder-after--desktop-chrome.png +0 -0
  337. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/button-menu-item-reorder-after--desktop-webkit.png +0 -0
  338. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/button-menu-item-reorder-before--desktop-chrome.png +0 -0
  339. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/button-menu-item-reorder-before--desktop-webkit.png +0 -0
  340. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/expandable-menu-item-combine--desktop-chrome.png +0 -0
  341. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/expandable-menu-item-combine--desktop-webkit.png +0 -0
  342. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/expandable-menu-item-reorder-after--desktop-chrome.png +0 -0
  343. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/expandable-menu-item-reorder-after--desktop-webkit.png +0 -0
  344. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/expandable-menu-item-reorder-before--desktop-chrome.png +0 -0
  345. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/expandable-menu-item-reorder-before--desktop-webkit.png +0 -0
  346. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/expandable-menu-item-trigger--desktop-chrome.png +0 -0
  347. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/expandable-menu-item-trigger--desktop-webkit.png +0 -0
  348. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/flyout-menu-item-combine--desktop-chrome.png +0 -0
  349. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/flyout-menu-item-combine--desktop-webkit.png +0 -0
  350. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/flyout-menu-item-reorder-after--desktop-chrome.png +0 -0
  351. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/flyout-menu-item-reorder-after--desktop-webkit.png +0 -0
  352. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/flyout-menu-item-reorder-before--desktop-chrome.png +0 -0
  353. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/flyout-menu-item-reorder-before--desktop-webkit.png +0 -0
  354. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/flyout-menu-item-trigger--desktop-chrome.png +0 -0
  355. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/flyout-menu-item-trigger--desktop-webkit.png +0 -0
  356. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item--desktop-chrome.png +0 -0
  357. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item--desktop-webkit.png +0 -0
  358. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item-combine--desktop-chrome.png +0 -0
  359. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item-combine--desktop-webkit.png +0 -0
  360. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item-combine-blocked--desktop-chrome.png +0 -0
  361. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item-combine-blocked--desktop-webkit.png +0 -0
  362. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item-reorder-after--desktop-chrome.png +0 -0
  363. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item-reorder-after--desktop-webkit.png +0 -0
  364. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item-reorder-after-blocked--desktop-chrome.png +0 -0
  365. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item-reorder-after-blocked--desktop-webkit.png +0 -0
  366. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item-reorder-before--desktop-chrome.png +0 -0
  367. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item-reorder-before--desktop-webkit.png +0 -0
  368. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item-reorder-before-blocked--desktop-chrome.png +0 -0
  369. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/drag-and-drop/link-menu-item-reorder-before-blocked--desktop-webkit.png +0 -0
  370. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item---custom-elembefore---action-focused--default.png +0 -0
  371. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item---custom-elembefore---action-hovered--default.png +0 -0
  372. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item---custom-elembefore---default-state--default.png +0 -0
  373. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item---custom-elembefore---elembefore-focused--default.png +0 -0
  374. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item---custom-elembefore---elembefore-hovered--default.png +0 -0
  375. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item---custom-elembefore---menu-item-focused--default.png +0 -0
  376. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item---custom-elembefore---menu-item-hovered--default.png +0 -0
  377. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item---selected-with-dropdown-action-open--default.png +0 -0
  378. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item---with-dropdown-action-open--default.png +0 -0
  379. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item---with-dropdown-action-open-and-hovered--default.png +0 -0
  380. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-collapsed-with-selected-child--default.png +0 -0
  381. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-expanded-with-actions-on-hover--default.png +0 -0
  382. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-expanded-with-actions-on-hover-and-elem-after--default.png +0 -0
  383. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-expanded-with-elem-after--default.png +0 -0
  384. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-nested--default.png +0 -0
  385. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-nested-rtl--default.png +0 -0
  386. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-selected--default.png +0 -0
  387. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-selected-with-icon--default.png +0 -0
  388. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-with-actions--default.png +0 -0
  389. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-with-actions-on-hover---hovered--default.png +0 -0
  390. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-with-actions-on-hover---selected-and-hovered--default.png +0 -0
  391. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-with-actions-on-hover--default.png +0 -0
  392. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-with-actions-on-hover-and-elem-after---hovered--default.png +0 -0
  393. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/expandable/expandable-menu-item-with-actions-on-hover-and-elem-after--default.png +0 -0
  394. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/flyout-menu-item/a-flyout-menu-with-a-nested-popup-using-shouldrendertoparent---default.png +0 -0
  395. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/flyout-menu-item/flyout-menu-item-default-open-example--default.png +0 -0
  396. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/flyout-menu-item/flyout-menu-item-default-open-rtl--default.png +0 -0
  397. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/flyout-menu-item/flyout-menu-item-default-open-selected-vr--default.png +0 -0
  398. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/flyout-menu-item/flyout-menu-item-example--default.png +0 -0
  399. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/flyout-menu-item/flyout-menu-item-rtl--default.png +0 -0
  400. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item---disabled---hovered--desktop-chrome.png +0 -0
  401. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item---disabled---hovered--desktop-firefox.png +0 -0
  402. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item---disabled---hovered--desktop-webkit.png +0 -0
  403. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item---disabled--desktop-chrome.png +0 -0
  404. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item---disabled--desktop-firefox.png +0 -0
  405. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item---disabled--desktop-webkit.png +0 -0
  406. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item---disabled-with-actions--desktop-chrome.png +0 -0
  407. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item---disabled-with-actions--desktop-firefox.png +0 -0
  408. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item---disabled-with-actions--desktop-webkit.png +0 -0
  409. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item---with-dropdown-action-open--desktop-chrome.png +0 -0
  410. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item---with-dropdown-action-open--desktop-firefox.png +0 -0
  411. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item---with-dropdown-action-open--desktop-webkit.png +0 -0
  412. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-example--desktop-chrome.png +0 -0
  413. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-example--desktop-firefox.png +0 -0
  414. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-example--desktop-webkit.png +0 -0
  415. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-rtlexample--desktop-chrome.png +0 -0
  416. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-rtlexample--desktop-firefox.png +0 -0
  417. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-rtlexample--desktop-webkit.png +0 -0
  418. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-with-actions-on-hover-appearing-on-focus--desktop-chrome.png +0 -0
  419. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-with-actions-on-hover-appearing-on-focus--desktop-firefox.png +0 -0
  420. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-with-actions-on-hover-appearing-on-focus--desktop-webkit.png +0 -0
  421. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-with-actions-on-hover-appearing-on-hover--desktop-chrome.png +0 -0
  422. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-with-actions-on-hover-appearing-on-hover--desktop-firefox.png +0 -0
  423. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-with-actions-on-hover-appearing-on-hover--desktop-webkit.png +0 -0
  424. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-with-elem-after-and-hovered--desktop-chrome.png +0 -0
  425. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-with-elem-after-and-hovered--desktop-firefox.png +0 -0
  426. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-with-elem-after-and-hovered--desktop-webkit.png +0 -0
  427. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-with-popup--desktop-chrome.png +0 -0
  428. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-with-popup--desktop-firefox.png +0 -0
  429. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/button-menu-item-with-popup--desktop-webkit.png +0 -0
  430. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item---with-dropdown-action-open--desktop-chrome.png +0 -0
  431. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item---with-dropdown-action-open--desktop-firefox.png +0 -0
  432. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item---with-dropdown-action-open--desktop-webkit.png +0 -0
  433. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-bleed--desktop-chrome.png +0 -0
  434. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-bleed--desktop-firefox.png +0 -0
  435. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-bleed--desktop-webkit.png +0 -0
  436. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-example--desktop-chrome.png +0 -0
  437. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-example--desktop-firefox.png +0 -0
  438. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-example--desktop-webkit.png +0 -0
  439. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-rtlexample--desktop-chrome.png +0 -0
  440. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-rtlexample--desktop-firefox.png +0 -0
  441. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-rtlexample--desktop-webkit.png +0 -0
  442. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-with-actions-on-hover-appearing-on-focus--desktop-chrome.png +0 -0
  443. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-with-actions-on-hover-appearing-on-focus--desktop-firefox.png +0 -0
  444. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-with-actions-on-hover-appearing-on-focus--desktop-webkit.png +0 -0
  445. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-with-actions-on-hover-appearing-on-hover--desktop-chrome.png +0 -0
  446. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-with-actions-on-hover-appearing-on-hover--desktop-firefox.png +0 -0
  447. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-with-actions-on-hover-appearing-on-hover--desktop-webkit.png +0 -0
  448. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-with-elem-after-and-hovered--desktop-chrome.png +0 -0
  449. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-with-elem-after-and-hovered--desktop-firefox.png +0 -0
  450. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/link-menu-item-with-elem-after-and-hovered--desktop-webkit.png +0 -0
  451. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/menu-item-avatar-example--desktop-chrome.png +0 -0
  452. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/menu-item-avatar-example--desktop-firefox.png +0 -0
  453. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/menu-item-avatar-example--desktop-webkit.png +0 -0
  454. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/menu-items-in-a-narrow-container--desktop-chrome.png +0 -0
  455. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/menu-items-in-a-narrow-container--desktop-firefox.png +0 -0
  456. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item/menu-items-in-a-narrow-container--desktop-webkit.png +0 -0
  457. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/button-menu-item--content-long---description-long---default.png +0 -0
  458. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/button-menu-item--content-long---description-none---default.png +0 -0
  459. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/button-menu-item--content-long---description-short---default.png +0 -0
  460. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/button-menu-item--content-short---description-long---default.png +0 -0
  461. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/button-menu-item--content-short---description-none---default.png +0 -0
  462. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/button-menu-item--content-short---description-short---default.png +0 -0
  463. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/button-menu-item-add-action-button--default.png +0 -0
  464. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/button-menu-item-with-tooltip-disabled--default.png +0 -0
  465. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/expandable-menu-item--content-long---default.png +0 -0
  466. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/expandable-menu-item--content-short---default.png +0 -0
  467. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/expandable-menu-item-with-tooltip-disabled--default.png +0 -0
  468. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/flyout-menu-item--content-long---default.png +0 -0
  469. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/flyout-menu-item--content-short---default.png +0 -0
  470. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/flyout-menu-item-with-tooltip-disabled--default.png +0 -0
  471. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/link-menu-item--content-long---description-long---default.png +0 -0
  472. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/link-menu-item--content-long---description-none---default.png +0 -0
  473. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/link-menu-item--content-long---description-short---default.png +0 -0
  474. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/link-menu-item--content-short---description-long---default.png +0 -0
  475. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/link-menu-item--content-short---description-none---default.png +0 -0
  476. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/link-menu-item--content-short---description-short---default.png +0 -0
  477. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/link-menu-item-with-tooltip-disabled--default.png +0 -0
  478. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/menu-item-conditional-tooltip/menu-item-button-with-nested-children--default.png +0 -0
  479. package/src/ui/menu-item/__tests__/vr-tests/__snapshots__/top-level-spacer/top-level-spacer-example--default.png +0 -0
  480. package/src/ui/menu-item/__tests__/vr-tests/drag-and-drop.vr.tsx +0 -172
  481. package/src/ui/menu-item/__tests__/vr-tests/expandable.vr.tsx +0 -248
  482. package/src/ui/menu-item/__tests__/vr-tests/flyout-menu-item.vr.tsx +0 -46
  483. package/src/ui/menu-item/__tests__/vr-tests/menu-item-conditional-tooltip.vr.tsx +0 -312
  484. package/src/ui/menu-item/__tests__/vr-tests/menu-item.vr.tsx +0 -210
  485. package/src/ui/menu-item/__tests__/vr-tests/top-level-spacer.vr.tsx +0 -17
  486. package/src/ui/menu-item/button-menu-item.tsx +0 -87
  487. package/src/ui/menu-item/constants.tsx +0 -15
  488. package/src/ui/menu-item/container-avatar.tsx +0 -39
  489. package/src/ui/menu-item/drag-and-drop/drag-preview.tsx +0 -98
  490. package/src/ui/menu-item/drag-and-drop/drop-indicator.tsx +0 -11
  491. package/src/ui/menu-item/drag-and-drop/group-drop-indicator.tsx +0 -7
  492. package/src/ui/menu-item/drag-and-drop/hitbox.tsx +0 -13
  493. package/src/ui/menu-item/drag-and-drop/use-menu-item-drag-and-drop.tsx +0 -243
  494. package/src/ui/menu-item/drag-handle.tsx +0 -42
  495. package/src/ui/menu-item/expandable-menu-item/expandable-menu-item-content.tsx +0 -84
  496. package/src/ui/menu-item/expandable-menu-item/expandable-menu-item-context.tsx +0 -61
  497. package/src/ui/menu-item/expandable-menu-item/expandable-menu-item-level-context.tsx +0 -9
  498. package/src/ui/menu-item/expandable-menu-item/expandable-menu-item-trigger.tsx +0 -334
  499. package/src/ui/menu-item/expandable-menu-item/expandable-menu-item.tsx +0 -114
  500. package/src/ui/menu-item/flyout-menu-item/flyout-menu-item-content.tsx +0 -188
  501. package/src/ui/menu-item/flyout-menu-item/flyout-menu-item-context.tsx +0 -19
  502. package/src/ui/menu-item/flyout-menu-item/flyout-menu-item-trigger.tsx +0 -124
  503. package/src/ui/menu-item/flyout-menu-item/flyout-menu-item.tsx +0 -98
  504. package/src/ui/menu-item/link-menu-item.tsx +0 -119
  505. package/src/ui/menu-item/menu-item-signals.tsx +0 -6
  506. package/src/ui/menu-item/menu-item.tsx +0 -848
  507. package/src/ui/menu-item/menu-list-item.tsx +0 -12
  508. package/src/ui/menu-item/menu-list.tsx +0 -12
  509. package/src/ui/menu-item/top-level-spacer.tsx +0 -49
  510. package/src/ui/menu-item/types.tsx +0 -181
  511. package/src/ui/menu-item/use-scroll-menu-item-into-view.tsx +0 -78
  512. package/src/ui/menu-section/__tests__/unit/menu-section.test.tsx +0 -96
  513. package/src/ui/menu-section/__tests__/vr-tests/__snapshots__/divider/divider--default.png +0 -0
  514. package/src/ui/menu-section/__tests__/vr-tests/__snapshots__/menu-section/menu-section-example--default.png +0 -0
  515. package/src/ui/menu-section/__tests__/vr-tests/divider.vr.tsx +0 -14
  516. package/src/ui/menu-section/__tests__/vr-tests/menu-section.vr.tsx +0 -14
  517. package/src/ui/menu-section/divider.tsx +0 -33
  518. package/src/ui/menu-section/menu-section-context.tsx +0 -15
  519. package/src/ui/menu-section/menu-section-heading.tsx +0 -43
  520. package/src/ui/menu-section/menu-section.tsx +0 -70
  521. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/page-layout/large-panel-default-width-on-mobile--desktop--platform-design-system-nav4-panel-mobile-width-fix-false.png +0 -0
  522. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/page-layout/large-panel-default-width-on-mobile--desktop--platform-design-system-nav4-panel-mobile-width-fix-true.png +0 -0
  523. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/page-layout/small-panel-default-width-on-mobile--desktop--platform-design-system-nav4-panel-mobile-width-fix-false.png +0 -0
  524. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/page-layout/small-panel-default-width-on-mobile--desktop--platform-design-system-nav4-panel-mobile-width-fix-true.png +0 -0
  525. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/slot-borders/above-md-breakpoint---side-nav-expanded--default--platform-design-system-nav4-panel-default-border-false-platform-design-system-nav4-sidenav-border-false.png +0 -0
  526. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/slot-borders/above-md-breakpoint---side-nav-expanded--default--platform-design-system-nav4-panel-default-border-false-platform-design-system-nav4-sidenav-border-true.png +0 -0
  527. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/slot-borders/above-md-breakpoint---side-nav-expanded--default--platform-design-system-nav4-panel-default-border-true-platform-design-system-nav4-sidenav-border-false.png +0 -0
  528. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/slot-borders/above-md-breakpoint---side-nav-expanded--default--platform-design-system-nav4-panel-default-border-true-platform-design-system-nav4-sidenav-border-true.png +0 -0
  529. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/slot-borders/above-md-breakpoint---side-nav-flyout--default--platform-design-system-nav4-panel-default-border-false-platform-design-system-nav4-sidenav-border-false.png +0 -0
  530. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/slot-borders/above-md-breakpoint---side-nav-flyout--default--platform-design-system-nav4-panel-default-border-false-platform-design-system-nav4-sidenav-border-true.png +0 -0
  531. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/slot-borders/above-md-breakpoint---side-nav-flyout--default--platform-design-system-nav4-panel-default-border-true-platform-design-system-nav4-sidenav-border-false.png +0 -0
  532. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/slot-borders/above-md-breakpoint---side-nav-flyout--default--platform-design-system-nav4-panel-default-border-true-platform-design-system-nav4-sidenav-border-true.png +0 -0
  533. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/slot-borders/below-md-breakpoint---side-nav-expanded--default--platform-design-system-nav4-panel-default-border-false-platform-design-system-nav4-sidenav-border-false.png +0 -0
  534. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/slot-borders/below-md-breakpoint---side-nav-expanded--default--platform-design-system-nav4-panel-default-border-false-platform-design-system-nav4-sidenav-border-true.png +0 -0
  535. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/slot-borders/below-md-breakpoint---side-nav-expanded--default--platform-design-system-nav4-panel-default-border-true-platform-design-system-nav4-sidenav-border-false.png +0 -0
  536. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/slot-borders/below-md-breakpoint---side-nav-expanded--default--platform-design-system-nav4-panel-default-border-true-platform-design-system-nav4-sidenav-border-true.png +0 -0
  537. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/top-nav/breakpoint-lg---composition--firefox.png +0 -0
  538. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/top-nav/breakpoint-lg---with-min-widths--firefox.png +0 -0
  539. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/top-nav/breakpoint-lg--firefox.png +0 -0
  540. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/top-nav/breakpoint-md---composition--firefox.png +0 -0
  541. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/top-nav/breakpoint-md---with-min-widths--firefox.png +0 -0
  542. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/top-nav/breakpoint-md--firefox.png +0 -0
  543. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/top-nav/breakpoint-sm---with-min-widths--firefox.png +0 -0
  544. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/top-nav/breakpoint-sm--firefox.png +0 -0
  545. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/top-nav/breakpoint-xl---composition--firefox.png +0 -0
  546. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/top-nav/breakpoint-xl---with-min-widths--firefox.png +0 -0
  547. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/top-nav/breakpoint-xl--firefox.png +0 -0
  548. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/top-nav/breakpoint-xs---with-min-widths--firefox.png +0 -0
  549. package/src/ui/page-layout/__tests__/informational-vr-tests/__snapshots__/top-nav/breakpoint-xs--firefox.png +0 -0
  550. package/src/ui/page-layout/__tests__/informational-vr-tests/page-layout.vr.tsx +0 -53
  551. package/src/ui/page-layout/__tests__/informational-vr-tests/slot-borders.vr.tsx +0 -54
  552. package/src/ui/page-layout/__tests__/informational-vr-tests/top-nav.vr.tsx +0 -170
  553. package/src/ui/page-layout/__tests__/unit/_test-utils.tsx +0 -185
  554. package/src/ui/page-layout/__tests__/unit/aside.test.tsx +0 -21
  555. package/src/ui/page-layout/__tests__/unit/banner.test.tsx +0 -31
  556. package/src/ui/page-layout/__tests__/unit/get-width.test.tsx +0 -12
  557. package/src/ui/page-layout/__tests__/unit/hoist-utils.test.tsx +0 -85
  558. package/src/ui/page-layout/__tests__/unit/page-layout.test.tsx +0 -300
  559. package/src/ui/page-layout/__tests__/unit/panel-splitter-and-suspense.test.tsx +0 -43
  560. package/src/ui/page-layout/__tests__/unit/panel-splitter.test.tsx +0 -885
  561. package/src/ui/page-layout/__tests__/unit/panel.test.tsx +0 -63
  562. package/src/ui/page-layout/__tests__/unit/react-safety.test.tsx +0 -30
  563. package/src/ui/page-layout/__tests__/unit/resizing.test.tsx +0 -714
  564. package/src/ui/page-layout/__tests__/unit/side-nav-flyout.test.tsx +0 -1154
  565. package/src/ui/page-layout/__tests__/unit/side-nav.test.tsx +0 -771
  566. package/src/ui/page-layout/__tests__/unit/sticky-header.test.tsx +0 -43
  567. package/src/ui/page-layout/__tests__/unit/top-nav-end.test.tsx +0 -132
  568. package/src/ui/page-layout/__tests__/unit/top-nav.test.tsx +0 -28
  569. package/src/ui/page-layout/__tests__/unit/use-expand-side-nav.test.tsx +0 -278
  570. package/src/ui/page-layout/__tests__/unit/use-toggle-side-nav.test.tsx +0 -233
  571. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/main-content-border/main-content-border---theming-disabled--desktop.png +0 -0
  572. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/main-content-border/main-content-border---theming-disabled--mobile.png +0 -0
  573. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/main-content-border/main-content-border---theming-disabled-side-nav-collapsed--desktop.png +0 -0
  574. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/main-content-border/main-content-border---theming-disabled-side-nav-collapsed--mobile.png +0 -0
  575. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/main-content-border/main-content-border---theming-enabled--desktop.png +0 -0
  576. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/main-content-border/main-content-border---theming-enabled--mobile.png +0 -0
  577. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/main-content-border/main-content-border---theming-enabled-full-screen-mode--desktop.png +0 -0
  578. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/main-content-border/main-content-border---theming-enabled-full-screen-mode--mobile.png +0 -0
  579. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/main-content-border/main-content-border---theming-enabled-side-nav-collapsed--desktop.png +0 -0
  580. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/main-content-border/main-content-border---theming-enabled-side-nav-collapsed--mobile.png +0 -0
  581. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/all-slots--desktop.png +0 -0
  582. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/all-slots--mobile.png +0 -0
  583. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/all-slots-banner-height-zero--desktop.png +0 -0
  584. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/all-slots-banner-height-zero--mobile.png +0 -0
  585. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/all-slots-custom-sizes--desktop.png +0 -0
  586. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/all-slots-custom-sizes--mobile.png +0 -0
  587. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/all-slots-rtl--desktop.png +0 -0
  588. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/all-slots-rtl--mobile.png +0 -0
  589. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/all-slots-scrollable--desktop.png +0 -0
  590. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/all-slots-scrollable--mobile.png +0 -0
  591. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/aside-composed-with-border--desktop.png +0 -0
  592. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/aside-composed-with-border--mobile.png +0 -0
  593. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/edge-case-sibling-absolute-positioned--desktop.png +0 -0
  594. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/edge-case-sibling-absolute-positioned--mobile.png +0 -0
  595. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/edge-case-sibling-absolute-positioned-collapsed--desktop.png +0 -0
  596. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/edge-case-sibling-absolute-positioned-collapsed--mobile.png +0 -0
  597. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/edge-case-sibling-absolute-positioned-custom-sizes--desktop.png +0 -0
  598. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/edge-case-sibling-absolute-positioned-custom-sizes--mobile.png +0 -0
  599. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/edge-case-sibling-absolute-positioned-panel-visible--desktop.png +0 -0
  600. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/edge-case-sibling-absolute-positioned-panel-visible--mobile.png +0 -0
  601. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/edge-case-sibling-absolute-positioned-resizable--desktop.png +0 -0
  602. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/edge-case-sibling-absolute-positioned-resizable--mobile.png +0 -0
  603. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/edge-case-using-legacy-vars--desktop.png +0 -0
  604. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/edge-case-using-legacy-vars--mobile.png +0 -0
  605. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/main-aside--desktop.png +0 -0
  606. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/main-aside--mobile.png +0 -0
  607. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/main-aside-scrollable--desktop.png +0 -0
  608. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/main-aside-scrollable--mobile.png +0 -0
  609. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/page-layout-implicit-rows--desktop.png +0 -0
  610. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/page-layout-implicit-rows--mobile.png +0 -0
  611. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/panel-and-aside---default-widths--desktop.png +0 -0
  612. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/panel-and-aside---default-widths--mobile.png +0 -0
  613. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/panel-and-aside---zero-widths--desktop.png +0 -0
  614. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/panel-and-aside---zero-widths--mobile.png +0 -0
  615. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/panel-default-background-color--desktop.png +0 -0
  616. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/panel-default-background-color--mobile.png +0 -0
  617. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/panel-should-have-correct-width-when-there-is-no-sidenav-mounted--desktop.png +0 -0
  618. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/resizable--desktop.png +0 -0
  619. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/side-nav-content-slot---scroll-with-sticky-child--desktop.png +0 -0
  620. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/side-nav-custom-width-greater-than-max-width--desktop.png +0 -0
  621. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/side-nav-custom-width-smaller-than-min-width--desktop.png +0 -0
  622. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/side-nav-main-aside--desktop.png +0 -0
  623. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/side-nav-main-aside--mobile.png +0 -0
  624. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/side-nav-main-aside-scrollable--desktop.png +0 -0
  625. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/side-nav-main-aside-scrollable--mobile.png +0 -0
  626. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/side-nav-overflowing-children--desktop.png +0 -0
  627. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/side-nav-slots--desktop.png +0 -0
  628. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/side-nav-with-menu-items--desktop.png +0 -0
  629. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/side-nav-with-menu-items--mobile.png +0 -0
  630. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/top-bar-side-nav-main--desktop.png +0 -0
  631. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/top-bar-side-nav-main--mobile.png +0 -0
  632. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/top-bar-side-nav-main-aside--desktop.png +0 -0
  633. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/top-bar-side-nav-main-aside--mobile.png +0 -0
  634. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/top-bar-side-nav-main-aside-scrollable--desktop.png +0 -0
  635. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/top-bar-side-nav-main-aside-scrollable--mobile.png +0 -0
  636. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/top-bar-side-nav-main-scrollable--desktop.png +0 -0
  637. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/page-layout/top-bar-side-nav-main-scrollable--mobile.png +0 -0
  638. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/panel-splitter/focused-panel-splitter-with-position-end--default.png +0 -0
  639. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/panel-splitter/focused-panel-splitter-with-position-start--default.png +0 -0
  640. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/panel-splitter/hovered-panel-splitter-with-position-end--default--platform-nav4-panel-splitter-keyboard-a11y-false.png +0 -0
  641. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/panel-splitter/hovered-panel-splitter-with-position-end--default--platform-nav4-panel-splitter-keyboard-a11y-true.png +0 -0
  642. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/panel-splitter/hovered-panel-splitter-with-position-start--default--platform-nav4-panel-splitter-keyboard-a11y-false.png +0 -0
  643. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/panel-splitter/hovered-panel-splitter-with-position-start--default--platform-nav4-panel-splitter-keyboard-a11y-true.png +0 -0
  644. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-collapsed--desktop.png +0 -0
  645. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-collapsed--mobile.png +0 -0
  646. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-collapsed-toggle-button-hovered--desktop.png +0 -0
  647. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-collapsed-toggle-button-hovered--mobile.png +0 -0
  648. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-collapsed-with-open-child-layer--desktop.png +0 -0
  649. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-collapsed-with-open-child-layer--mobile.png +0 -0
  650. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-collapsed-with-open-child-layer-toggle-button-hovered--desktop.png +0 -0
  651. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-collapsed-with-open-child-layer-toggle-button-hovered--mobile.png +0 -0
  652. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-expanded--desktop.png +0 -0
  653. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-expanded--mobile.png +0 -0
  654. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-expanded-toggle-button-hovered--desktop.png +0 -0
  655. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-expanded-toggle-button-hovered--mobile.png +0 -0
  656. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-expanded-with-open-child-layer--desktop.png +0 -0
  657. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-expanded-with-open-child-layer--mobile.png +0 -0
  658. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-expanded-with-open-child-layer-toggle-button-hovered--desktop.png +0 -0
  659. package/src/ui/page-layout/__tests__/vr-tests/__snapshots__/side-nav-flyout/side-nav-default-expanded-with-open-child-layer-toggle-button-hovered--mobile.png +0 -0
  660. package/src/ui/page-layout/__tests__/vr-tests/main-content-border.vr.tsx +0 -47
  661. package/src/ui/page-layout/__tests__/vr-tests/page-layout.vr.tsx +0 -266
  662. package/src/ui/page-layout/__tests__/vr-tests/panel-splitter.vr.tsx +0 -72
  663. package/src/ui/page-layout/__tests__/vr-tests/side-nav-flyout.vr.tsx +0 -170
  664. package/src/ui/page-layout/aside.tsx +0 -210
  665. package/src/ui/page-layout/banner.tsx +0 -91
  666. package/src/ui/page-layout/constants.tsx +0 -56
  667. package/src/ui/page-layout/hoist-slot-sizes-context.tsx +0 -7
  668. package/src/ui/page-layout/hoist-utils.tsx +0 -64
  669. package/src/ui/page-layout/id-utils.tsx +0 -33
  670. package/src/ui/page-layout/main/main-sticky-header.tsx +0 -45
  671. package/src/ui/page-layout/main/main.tsx +0 -93
  672. package/src/ui/page-layout/panel-splitter/context.tsx +0 -60
  673. package/src/ui/page-layout/panel-splitter/convert-resize-bound-to-pixels.tsx +0 -20
  674. package/src/ui/page-layout/panel-splitter/get-percentage-within-pixel-bounds.tsx +0 -35
  675. package/src/ui/page-layout/panel-splitter/get-width.tsx +0 -33
  676. package/src/ui/page-layout/panel-splitter/keyboard-resize-manager.tsx +0 -89
  677. package/src/ui/page-layout/panel-splitter/panel-splitter.tsx +0 -560
  678. package/src/ui/page-layout/panel-splitter/provider.tsx +0 -66
  679. package/src/ui/page-layout/panel-splitter/types.tsx +0 -25
  680. package/src/ui/page-layout/panel.tsx +0 -308
  681. package/src/ui/page-layout/root.tsx +0 -162
  682. package/src/ui/page-layout/side-nav/element-context.tsx +0 -18
  683. package/src/ui/page-layout/side-nav/flyout-close-delay-ms.tsx +0 -12
  684. package/src/ui/page-layout/side-nav/side-nav-content.tsx +0 -57
  685. package/src/ui/page-layout/side-nav/side-nav-footer.tsx +0 -48
  686. package/src/ui/page-layout/side-nav/side-nav-header.tsx +0 -32
  687. package/src/ui/page-layout/side-nav/side-nav.tsx +0 -876
  688. package/src/ui/page-layout/side-nav/toggle-button-context.tsx +0 -21
  689. package/src/ui/page-layout/side-nav/toggle-button-provider.tsx +0 -28
  690. package/src/ui/page-layout/side-nav/toggle-button.tsx +0 -166
  691. package/src/ui/page-layout/side-nav/types.tsx +0 -18
  692. package/src/ui/page-layout/side-nav/use-expand-side-nav.tsx +0 -57
  693. package/src/ui/page-layout/side-nav/use-side-nav-visibility-callbacks.tsx +0 -75
  694. package/src/ui/page-layout/side-nav/use-side-nav-visibility.tsx +0 -43
  695. package/src/ui/page-layout/side-nav/use-toggle-side-nav.tsx +0 -47
  696. package/src/ui/page-layout/side-nav/visibility-context.tsx +0 -17
  697. package/src/ui/page-layout/side-nav/visibility-provider.tsx +0 -20
  698. package/src/ui/page-layout/top-nav/top-nav-end.tsx +0 -155
  699. package/src/ui/page-layout/top-nav/top-nav-middle.tsx +0 -90
  700. package/src/ui/page-layout/top-nav/top-nav-start.tsx +0 -82
  701. package/src/ui/page-layout/top-nav/top-nav.tsx +0 -127
  702. package/src/ui/page-layout/types.tsx +0 -20
  703. package/src/ui/page-layout/use-resizing-width-css-var-on-root-element.tsx +0 -70
  704. package/src/ui/top-nav-items/__tests__/informational-vr-tests/__snapshots__/top-navigation/long-product-name-tooltip--default.png +0 -0
  705. package/src/ui/top-nav-items/__tests__/informational-vr-tests/__snapshots__/top-navigation/nav-logo-hover---custom-theming--desktop.png +0 -0
  706. package/src/ui/top-nav-items/__tests__/informational-vr-tests/__snapshots__/top-navigation/nav-logo-hover---custom-theming--mobile.png +0 -0
  707. package/src/ui/top-nav-items/__tests__/informational-vr-tests/__snapshots__/top-navigation/nav-logo-hover--desktop.png +0 -0
  708. package/src/ui/top-nav-items/__tests__/informational-vr-tests/__snapshots__/top-navigation/nav-logo-hover--mobile.png +0 -0
  709. package/src/ui/top-nav-items/__tests__/informational-vr-tests/__snapshots__/top-navigation/nav-logo-pressed---custom-theming--desktop.png +0 -0
  710. package/src/ui/top-nav-items/__tests__/informational-vr-tests/__snapshots__/top-navigation/nav-logo-pressed---custom-theming--mobile.png +0 -0
  711. package/src/ui/top-nav-items/__tests__/informational-vr-tests/__snapshots__/top-navigation/nav-logo-pressed--desktop.png +0 -0
  712. package/src/ui/top-nav-items/__tests__/informational-vr-tests/__snapshots__/top-navigation/nav-logo-pressed--mobile.png +0 -0
  713. package/src/ui/top-nav-items/__tests__/informational-vr-tests/__snapshots__/top-navigation/responsive-menu-items--mobile.png +0 -0
  714. package/src/ui/top-nav-items/__tests__/informational-vr-tests/__snapshots__/top-navigation/responsive-menu-items-on-click--mobile.png +0 -0
  715. package/src/ui/top-nav-items/__tests__/informational-vr-tests/top-navigation.vr.tsx +0 -120
  716. package/src/ui/top-nav-items/__tests__/playwright/theming.spec.tsx +0 -21
  717. package/src/ui/top-nav-items/__tests__/unit/chat-button.test.tsx +0 -40
  718. package/src/ui/top-nav-items/__tests__/unit/create-button.test.tsx +0 -34
  719. package/src/ui/top-nav-items/__tests__/unit/end-item.test.tsx +0 -43
  720. package/src/ui/top-nav-items/__tests__/unit/help.test.tsx +0 -101
  721. package/src/ui/top-nav-items/__tests__/unit/notifications.test.tsx +0 -63
  722. package/src/ui/top-nav-items/__tests__/unit/profile.test.tsx +0 -65
  723. package/src/ui/top-nav-items/__tests__/unit/settings.test.tsx +0 -51
  724. package/src/ui/top-nav-items/__tests__/unit/theming.test.tsx +0 -76
  725. package/src/ui/top-nav-items/__tests__/unit/top-nav-items.test.tsx +0 -181
  726. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/log-in-button--desktop.png +0 -0
  727. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/search-right-elem--default.png +0 -0
  728. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/theme-is-applied-with-an-hsl-color--desktop.png +0 -0
  729. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/theme-is-applied-with-an-rgb-color--desktop.png +0 -0
  730. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/theme-is-applied-with-customlogo--desktop.png +0 -0
  731. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/themed-button-focus-state--default.png +0 -0
  732. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/themed-button-hover-state--default.png +0 -0
  733. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/themed-create-button-hover-state--desktop.png +0 -0
  734. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/themed-link-button-focus-state--default.png +0 -0
  735. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/themed-link-button-hover-state--default.png +0 -0
  736. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/themed-search-focus-state--default.png +0 -0
  737. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/theming-is-enabled--desktop.png +0 -0
  738. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-nav-custom-profile-image--default.png +0 -0
  739. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-nav-side-nav-collapsed--desktop.png +0 -0
  740. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-nav-side-nav-collapsed--mobile.png +0 -0
  741. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-navigation-custom-logo-example--desktop.png +0 -0
  742. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-navigation-custom-logo-example--mobile.png +0 -0
  743. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-navigation-custom-logo-image200x200example--desktop.png +0 -0
  744. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-navigation-custom-logo-image200x200example--mobile.png +0 -0
  745. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-navigation-custom-logo-image200x20example--desktop.png +0 -0
  746. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-navigation-custom-logo-image200x20example--mobile.png +0 -0
  747. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-navigation-custom-logo-image20x200example--desktop.png +0 -0
  748. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-navigation-custom-logo-image20x200example--mobile.png +0 -0
  749. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-navigation-custom-logo-image20x20example--desktop.png +0 -0
  750. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-navigation-custom-logo-image20x20example--mobile.png +0 -0
  751. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-navigation-example--desktop.png +0 -0
  752. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-navigation-example--mobile.png +0 -0
  753. package/src/ui/top-nav-items/__tests__/vr-tests/__snapshots__/top-navigation/top-navigation-with-a-large-search-input-in-focus-state--default.png +0 -0
  754. package/src/ui/top-nav-items/__tests__/vr-tests/top-navigation.vr.tsx +0 -160
  755. package/src/ui/top-nav-items/app-switcher.tsx +0 -81
  756. package/src/ui/top-nav-items/chat-button.tsx +0 -49
  757. package/src/ui/top-nav-items/create-button.tsx +0 -51
  758. package/src/ui/top-nav-items/custom-title.tsx +0 -83
  759. package/src/ui/top-nav-items/end-item.tsx +0 -120
  760. package/src/ui/top-nav-items/help.tsx +0 -69
  761. package/src/ui/top-nav-items/log-in.tsx +0 -66
  762. package/src/ui/top-nav-items/nav-logo/app-logo.tsx +0 -203
  763. package/src/ui/top-nav-items/nav-logo/custom-logo.tsx +0 -252
  764. package/src/ui/top-nav-items/nav-logo/logo-renderer.tsx +0 -66
  765. package/src/ui/top-nav-items/notifications.tsx +0 -67
  766. package/src/ui/top-nav-items/profile.tsx +0 -26
  767. package/src/ui/top-nav-items/search.tsx +0 -124
  768. package/src/ui/top-nav-items/settings.tsx +0 -16
  769. package/src/ui/top-nav-items/themed/__tests__/unit/button.test.tsx +0 -57
  770. package/src/ui/top-nav-items/themed/__tests__/unit/use-custom-theme.test.tsx +0 -43
  771. package/src/ui/top-nav-items/themed/button.tsx +0 -576
  772. package/src/ui/top-nav-items/themed/color-utils/__tests__/unit/hex.test.tsx +0 -131
  773. package/src/ui/top-nav-items/themed/color-utils/__tests__/unit/hsl.test.tsx +0 -117
  774. package/src/ui/top-nav-items/themed/color-utils/__tests__/unit/rgb.test.tsx +0 -88
  775. package/src/ui/top-nav-items/themed/color-utils/__tests__/unit/try-parse-user-color.test.tsx +0 -35
  776. package/src/ui/top-nav-items/themed/color-utils/formats/hex.tsx +0 -47
  777. package/src/ui/top-nav-items/themed/color-utils/formats/hsl.tsx +0 -112
  778. package/src/ui/top-nav-items/themed/color-utils/formats/rgb.tsx +0 -41
  779. package/src/ui/top-nav-items/themed/color-utils/index.tsx +0 -111
  780. package/src/ui/top-nav-items/themed/color-utils/parse-user-color.tsx +0 -31
  781. package/src/ui/top-nav-items/themed/color-utils/types.tsx +0 -6
  782. package/src/ui/top-nav-items/themed/get-custom-theme-styles.tsx +0 -186
  783. package/src/ui/top-nav-items/themed/has-custom-theme-context.tsx +0 -13
  784. package/src/ui/top-nav-items/themed/migration.tsx +0 -70
  785. package/src/ui/top-nav-items/themed/palette.tsx +0 -53
  786. package/src/ui/top-nav-items/themed/search.tsx +0 -70
  787. package/src/ui/top-nav-items/themed/use-custom-theme.tsx +0 -51
  788. package/tsconfig.app.json +0 -91
  789. package/tsconfig.dev.json +0 -175
  790. package/tsconfig.json +0 -20
@@ -1,848 +0,0 @@
1
- /**
2
- * @jsxFrag
3
- * @jsxRuntime classic
4
- * @jsx jsx
5
- */
6
- import React, { forwardRef, lazy, Suspense, useCallback, useRef } from 'react';
7
-
8
- import { cssMap, cx, jsx, keyframes } from '@compiled/react';
9
-
10
- import type { UIAnalyticsEvent } from '@atlaskit/analytics-next';
11
- import { AvatarContext, type AvatarContextProps } from '@atlaskit/avatar';
12
- import mergeRefs from '@atlaskit/ds-lib/merge-refs';
13
- import { Anchor, Pressable, Text, type TextColor } from '@atlaskit/primitives/compiled';
14
- import { token } from '@atlaskit/tokens';
15
- import Tooltip, {
16
- TooltipPrimitive,
17
- type TooltipPrimitiveProps,
18
- type TooltipProps,
19
- } from '@atlaskit/tooltip';
20
-
21
- import { forwardRefWithGeneric } from '../../components/forward-ref-with-generic';
22
-
23
- import { expandableMenuItemIndentation } from './constants';
24
- import { useLevel } from './expandable-menu-item/expandable-menu-item-context';
25
- import {
26
- useFlyoutMenuOpen,
27
- useSetFlyoutMenuOpen,
28
- } from './flyout-menu-item/flyout-menu-item-context';
29
- import { COLLAPSE_ELEM_BEFORE } from './menu-item-signals';
30
- import type { MenuItemLinkOrButtonCommonProps, MenuItemOnClick } from './types';
31
-
32
- // Using `lazy` so that only consumers who want drag and drop
33
- // need to include code for the drag handle.
34
- const LazyDragHandle = lazy(
35
- () =>
36
- import(
37
- /* webpackChunkName: "@atlaskit-internal_nav4-menu-item-drag-handle" */
38
- './drag-handle'
39
- ),
40
- );
41
-
42
- const tooltipStyles = cssMap({
43
- root: {
44
- // Unique styles for our tooltip
45
- display: 'flex',
46
- flexDirection: 'column',
47
- justifyContent: 'center',
48
- // matching the height of standard items
49
- minHeight: '32px',
50
- // increased max width from standard tooltip
51
- maxWidth: '420px',
52
-
53
- // Mostly copied styles from `tooltip/src/tooltip-container.tsx`
54
- // Could likely use `TooltipContainer` from Tooltip and override styles,
55
- // but that could lead to some unexpected results as Tooltip is styled
56
- // using emotion.
57
- boxSizing: 'border-box',
58
- paddingBlockStart: token('space.025'),
59
- paddingInlineEnd: token('space.075'),
60
- paddingBlockEnd: token('space.025'),
61
- paddingInlineStart: token('space.075'),
62
- backgroundColor: token('color.background.neutral.bold'),
63
- borderRadius: token('border.radius'),
64
- color: token('color.text.inverse'),
65
- font: token('font.body.UNSAFE_small'),
66
- insetBlockStart: token('space.0'),
67
- insetInlineStart: token('space.0'),
68
- overflowWrap: 'break-word',
69
- wordWrap: 'break-word',
70
- },
71
- });
72
-
73
- const MenuItemTooltip = forwardRef<HTMLDivElement, TooltipPrimitiveProps>(function MenuItemTooltip(
74
- { children, className, ...rest },
75
- ref,
76
- ) {
77
- return (
78
- <TooltipPrimitive
79
- {...rest}
80
- // Manually passing on `className` so it gets merged correctly in the build output.
81
- // The passed classname is mostly used for integration testing (`.Tooltip`)
82
- // eslint-disable-next-line @atlaskit/design-system/no-unsafe-style-overrides, @atlaskit/ui-styling-standard/no-classname-prop
83
- className={className}
84
- // "css" does not "exist" - it gets transformed into "className" by compiled
85
- css={tooltipStyles.root}
86
- ref={ref}
87
- >
88
- {children}
89
- </TooltipPrimitive>
90
- );
91
- });
92
-
93
- function isTextClamped(element: HTMLElement): boolean {
94
- // Checking for vertical height rather than horizontal height.
95
- // When text is "clamped", it's technically being clamped vertically! 🤯
96
- return element.scrollHeight > element.clientHeight;
97
- }
98
-
99
- const defaultAvatarValues: AvatarContextProps = {
100
- size: 'small',
101
- };
102
-
103
- const elemAfterDisplayVar = '--elem-after-display';
104
- const actionsOnHoverDisplayVar = '--actions-on-hover-display';
105
- const notchColorVar = '--notch-color';
106
-
107
- // Note: this is also used in `drag-handle.tsx`
108
- const dragHandleDisplayVar = '--drag-handle-display';
109
-
110
- const dragCursorAnimation = keyframes({
111
- to: {
112
- cursor: 'grab',
113
- },
114
- });
115
-
116
- /**
117
- * ## 🤹 `position:relative`
118
- *
119
- * We need `position:relative` on an element that takes
120
- * up the full size of the interactive element so we
121
- * can correctly use `position:absolute` to place:
122
- * 1. the notch for links
123
- * 2. drop indicators for drag and drop
124
- * 3. a child of button / anchor to stretch it out to
125
- * increase it's pressable area.
126
- *
127
- * ⛔️ We cannot add `position:relative` _only_ on the
128
- * button / anchor as that will cause sibling elements
129
- * to be rendered under the button / anchor when setting
130
- * a background color on the button / anchor.
131
- *
132
- * 📖 Note: `position:relative` elements are painted after
133
- * elements with `position:static` (the default)
134
- * https://drafts.csswg.org/css-position-4/#painting-order
135
- *
136
- * ⛔️ We cannot add `position:relative` to the container
137
- * element, as then the `:focus` ring styles on the
138
- * button / anchor can be cut off by the next sibling if it has
139
- * has a background color set (eg when selected)
140
- *
141
- * ✅ Add `position:relative` to all first level descendants
142
- * of the container element so that we don't impact DOM ordered
143
- * paint ordering within the item and the button / anchor focus
144
- * ring can still bleed over siblings
145
- *
146
- * 📖 We could use `> * { position: relative; }` on the container,
147
- * but that would violate our styling standard.
148
- */
149
- const topLevelSiblingStyles = cssMap({
150
- root: {
151
- position: 'relative',
152
- },
153
- });
154
-
155
- /**
156
- * All slots on the menu item (eg `elemBefore`) are rendered as siblings
157
- * of our main button / anchor element and they are visually placed on
158
- * top of the main button / anchor.
159
- *
160
- * 📖 This is done so that we don't nest interactive elements in our markup.
161
- *
162
- * ✅ This is great when element in the slot is an interactive element
163
- * as we don't want the main menu item button / anchor to be triggered
164
- * when interacting with the element in the slot.
165
- *
166
- * ⛔️ When the element in the slot is static content (eg an `<Icon>`) it will
167
- * prevent the main button / anchor (that is visually behind the element in
168
- * the slot) from being clicked. The element in the slot is a sibling of our
169
- * main button / anchor (not a child of it) so clicking on the element in the
170
- * slot will not bubble up to the button / anchor.
171
- *
172
- * 🚀 We set `pointer-events:none` on a slot if it does not contain and interactive
173
- * element so that static content in a slot does not prevent clicking on the main
174
- * button / anchor.
175
- */
176
- const onTopOfButtonOrAnchorStyles = cssMap({
177
- root: {
178
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
179
- '&:not(:has(button,a))': {
180
- pointerEvents: 'none',
181
- },
182
- },
183
- });
184
-
185
- /**
186
- * This is being _internally_ exported so it can be used in other menu item wrapper components, like
187
- * ExpandableMenuItemTrigger.
188
- *
189
- * This selector is used to apply hover styling on the menu item if it contains an open nested popup.
190
- * It's looking for a popup trigger with `aria-hasexpanded` and `aria-haspopup` attributes. The
191
- * reason for targeting the _trigger_ instead of the popup itself, is the popup might be rendered
192
- * outside the menu item, e.g. if rendered in a portal.
193
- *
194
- * An alternative solution might involve wrapping it with a popup context and listening to the popup
195
- * events through it (and applying the hover style when the popup is open). Exploring this has been
196
- * captured in [BLU-3354](https://jplat.atlassian.net/browse/BLU-3354).
197
- */
198
- export const nestedOpenPopupCSSSelector = '&:has([aria-expanded="true"][aria-haspopup="true"])';
199
-
200
- const containerStyles = cssMap({
201
- root: {
202
- boxSizing: 'border-box',
203
- display: 'grid',
204
- /**
205
- * Slot 1: elemBefore (collapse last)
206
- * Slot 2: interactive element content (collapse first)
207
- * Slot 3: elemAfter (collapse last) [also for actionsOnHover]
208
- * Slot 4: actions (collapse last)
209
- */
210
- gridTemplateColumns: 'minmax(0, auto) 1fr minmax(0, auto) minmax(0, auto)',
211
- gridTemplateRows: '1fr', // a single row grid
212
- gridTemplateAreas: '"elem-before interactive elem-after actions"',
213
- /**
214
- * A min-width is set to ensure that the menu items do not completely collapse when deeply nested.
215
- * Otherwise, the menu items progressively shrink as they get into deeper levels of expandable menu items, until they
216
- * are unusable.
217
- */
218
- minWidth: '72px',
219
- // Using rem so it scales with browser font size and rem-based spacing/typography
220
- height: '2rem',
221
- alignItems: 'center',
222
- userSelect: 'none',
223
- borderRadius: token('border.radius'),
224
- color: token('color.text.subtle'),
225
- [actionsOnHoverDisplayVar]: 'none',
226
- [notchColorVar]: 'transparent',
227
- [elemAfterDisplayVar]: 'flex',
228
- // Applying :hover styles on the container rather than on
229
- // just the button / anchor so that we will still trigger the
230
- // :hover styles when over action buttons
231
- '&:hover': {
232
- backgroundColor: token('elevation.surface.hovered'),
233
- },
234
- '&:hover, &:focus-within': {
235
- [actionsOnHoverDisplayVar]: 'flex',
236
- },
237
- // If there is a nested open popup, we want to apply hover styling, and display the `actionsOnHover` slot.
238
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-values
239
- [nestedOpenPopupCSSSelector]: {
240
- backgroundColor: token('elevation.surface.hovered'),
241
- [actionsOnHoverDisplayVar]: 'flex',
242
- },
243
- },
244
- removeElemAfter: {
245
- [elemAfterDisplayVar]: 'none',
246
- },
247
- showHoverActions: {
248
- [actionsOnHoverDisplayVar]: 'flex',
249
- },
250
- removeElemAfterOnHoverOrOpenNestedPopup: {
251
- // On hover of the menu item, remove the elemAfter
252
- '&:hover, &:focus-within': {
253
- [elemAfterDisplayVar]: 'none',
254
- },
255
- // If there is a nested open popup, and both `actionsOnHover` and `elemAfter` exist, we want to hide the `elemAfter`.
256
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-values
257
- [nestedOpenPopupCSSSelector]: {
258
- [elemAfterDisplayVar]: 'none',
259
- },
260
- },
261
- selected: {
262
- backgroundColor: token('color.background.selected'),
263
- color: token('color.text.selected'),
264
- [notchColorVar]: token('color.background.selected.bold'),
265
- '&:hover': {
266
- color: token('color.text.selected'),
267
- backgroundColor: token('color.background.selected.hovered'),
268
- },
269
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-values
270
- [nestedOpenPopupCSSSelector]: {
271
- backgroundColor: token('color.background.selected.hovered'),
272
- },
273
- },
274
- disabled: {
275
- // Setting the color here to allow icons with "currentColor" to inherit the disabled color.
276
- color: token('color.text.disabled'),
277
- '&:hover': {
278
- // Removing the background color that gets applied on hover
279
- backgroundColor: 'unset',
280
- },
281
- },
282
- hasDescription: {
283
- /* Standard 32px + another 16px for the description */
284
- height: '3rem',
285
- },
286
- dragging: {
287
- opacity: 0.4,
288
- },
289
- });
290
-
291
- const buttonOrAnchorStyles = cssMap({
292
- // This button / anchor is positioned to produce the visual appearance of nested
293
- // buttons whilst the elements are actually siblings in the DOM structure.
294
- root: {
295
- display: 'grid',
296
- // Extend the button to the full width of container
297
- gridColumn: '1 / -1',
298
- // Each grid item is placed on the same row and stacks on top of each other.
299
- gridRow: '1',
300
- gridTemplateColumns: 'subgrid',
301
- gridTemplateRows: 'subgrid',
302
- paddingInlineEnd: token('space.050'),
303
- paddingInlineStart: token('space.050'),
304
- // Notes:
305
- // - block padding is not strictly needed.
306
- // - it does cause some issues with "combine" styling on firefox@125; but not
307
- // on firefox@137
308
- paddingBlockStart: token('space.050'),
309
- paddingBlockEnd: token('space.050'),
310
- backgroundColor: 'transparent',
311
- borderRadius: token('border.radius'),
312
- color: token('color.text.subtle'),
313
- alignItems: 'center',
314
- textAlign: 'start',
315
- // :active styles are applied on the button / anchor rather
316
- // than on the container so that pressing on actions does not
317
- // trigger the :active styles on the whole element.
318
- // We are excluding the disabled state, so we don't respond to
319
- // presses when disabled.
320
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
321
- '&:active:not(:disabled)': {
322
- backgroundColor: token('elevation.surface.pressed'),
323
- },
324
- },
325
- selected: {
326
- color: token('color.text.selected'),
327
- // We are excluding the disabled state, so we don't respond to
328
- // presses when disabled.
329
- // We also need to match the :active selector in the non-selected styles
330
- // to ensure it doesn't have a higher specificity
331
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
332
- '&:active:not(:disabled)': {
333
- backgroundColor: token('color.background.selected.pressed'),
334
- },
335
- },
336
- // Only applying on interactive element as we are not enabling
337
- // dragging from nested interactive elements
338
- hasDragIndicator: {
339
- /**
340
- * Opting out of long press actions on iOS as they don't work well with drag and drop.
341
- *
342
- * If you don't opt out, anchors can get a context menu including a link preview and actions
343
- * (eg "open in new tab"). While it's still possible to do drag and drop operations with this
344
- * context menu, it's a pain as you need to close the context menu while keeping your dragging
345
- * finger depressed, then you can continue with the drag operation.
346
- *
347
- * TODO: could consider adding this to all menu items for a consistent experience.
348
- */
349
- '-webkit-touch-callout': 'none',
350
- // change cursor on hover
351
- [dragHandleDisplayVar]: 'none',
352
- '&:hover': {
353
- [dragHandleDisplayVar]: 'flex',
354
- animationDuration: '0s',
355
- animationName: dragCursorAnimation,
356
- // 800ms taken from drag and drop guidelines
357
- animationDelay: '800ms',
358
- animationFillMode: 'forwards',
359
- },
360
- },
361
- });
362
-
363
- const extendButtonOrAnchorStyles = cssMap({
364
- root: {
365
- position: 'absolute',
366
- inset: token('space.0'),
367
- },
368
- });
369
-
370
- const notchStyles = cssMap({
371
- root: {
372
- position: 'absolute',
373
- insetBlockStart: '50%',
374
- insetInlineStart: token('space.0'),
375
- width: '2px',
376
- height: '12px',
377
- transform: 'translateY(-50%)',
378
- backgroundColor: `var(${notchColorVar})`,
379
- },
380
- });
381
-
382
- const actionStyles = cssMap({
383
- root: {
384
- display: 'flex',
385
- alignItems: 'center',
386
- gap: token('space.050'),
387
- gridArea: 'actions',
388
- paddingInlineEnd: token('space.050'),
389
- // Hiding overflowing slot content to prevent content from adjacent slots overlapping when the menu item is constrained to a narrow width.
390
- overflow: 'hidden',
391
- '&:focus-within': {
392
- // To prevent the focus ring from being clipped, we are allowing content to overflow while focus is within the slot.
393
- overflow: 'initial',
394
- },
395
- },
396
- });
397
-
398
- const actionsOnHoverStyles = cssMap({
399
- root: {
400
- display: `var(${actionsOnHoverDisplayVar})`,
401
- // When actionsOnHover are displayed, the elemAfter is hidden
402
- // and these actions are rendered in it's place.
403
- gridArea: 'elem-after',
404
- alignItems: 'center',
405
- gap: token('space.050'),
406
- paddingInlineEnd: token('space.050'),
407
- // Hiding overflowing slot content to prevent content from adjacent slots overlapping when the menu item is constrained to a narrow width.
408
- overflow: 'hidden',
409
- '&:focus-within': {
410
- // To prevent the focus ring from being clipped, we are allowing content to overflow while focus is within the slot.
411
- overflow: 'initial',
412
- },
413
- },
414
- });
415
-
416
- const textStyles = cssMap({
417
- root: {
418
- paddingInlineEnd: token('space.050'),
419
- paddingInlineStart: token('space.050'),
420
- display: 'flex',
421
- flexDirection: 'column',
422
- gap: token('space.025'),
423
- // Allowing at least one character to be seen at all times, even when the menu item has been shrunk down
424
- minWidth: '1ch',
425
- // Hiding overflowing slot content to prevent content from adjacent slots overlapping when the menu item is constrained to a narrow width.
426
- overflow: 'hidden',
427
- '&:focus-within': {
428
- // To prevent the focus ring from being clipped, we are allowing content to overflow while focus is within the slot.
429
- overflow: 'initial',
430
- },
431
- },
432
- noElemBeforeIndent: {
433
- paddingInlineStart: token('space.075'),
434
- },
435
- });
436
-
437
- const elemBeforeStyles = cssMap({
438
- root: {
439
- gridArea: 'elem-before',
440
- display: 'flex',
441
- flexShrink: 0,
442
- width: '24px',
443
- height: '24px',
444
- alignItems: 'center',
445
- justifyContent: 'center',
446
- paddingInlineStart: token('space.050'),
447
- // Box sizing must be explicit because we set a size AND padding on the same axis
448
- // Otherwise the resulting size can be inconsistent depending on the global reset used
449
- boxSizing: 'content-box',
450
- // Hiding overflowing slot content to prevent content from adjacent slots overlapping when the menu item is constrained to a narrow width.
451
- overflow: 'hidden',
452
- '&:focus-within': {
453
- // To prevent the focus ring from being clipped, we are allowing content to overflow while focus is within the slot.
454
- overflow: 'initial',
455
- },
456
- },
457
- });
458
-
459
- const elemAfterStyles = cssMap({
460
- root: {
461
- display: `var(${elemAfterDisplayVar})`,
462
- gridArea: 'elem-after',
463
- flexShrink: 0,
464
- height: '24px',
465
- alignItems: 'center',
466
- paddingInlineEnd: token('space.050'),
467
- // Hiding overflowing slot content to prevent content from adjacent slots overlapping when the menu item is constrained to a narrow width.
468
- overflow: 'hidden',
469
- '&:focus-within': {
470
- // To prevent the focus ring from being clipped, we are allowing content to overflow while focus is within the slot.
471
- overflow: 'initial',
472
- },
473
- },
474
- });
475
-
476
- /**
477
- * We are using a wrapping element for our interactive content
478
- * even though only the `Text` element is the only thing not using `position:absolute`
479
- *
480
- * Rationale:
481
- * - Super clear that everything inside the interactive content should be in a specific slot in the grid
482
- * - To work around a browser bug in Safari where it does not work well with `position:absolute`
483
- * on a subgrid child.
484
- * Safari bug: https://bugs.webkit.org/show_bug.cgi?id=292516
485
- */
486
- const interactiveContentStyles = cssMap({
487
- root: {
488
- gridArea: 'interactive',
489
- // Make content full height
490
- display: 'flex',
491
- flexDirection: 'column',
492
- alignContent: 'center',
493
- },
494
- });
495
-
496
- function getTextColor({
497
- isDisabled,
498
- isSelected,
499
- }: {
500
- isDisabled?: boolean;
501
- isSelected?: boolean;
502
- }): TextColor {
503
- if (isDisabled) {
504
- return 'color.text.disabled';
505
- }
506
-
507
- if (isSelected) {
508
- return 'color.text.selected';
509
- }
510
-
511
- return 'color.text.subtle';
512
- }
513
-
514
- /**
515
- * Includes all props that are used by any menu item, as MenuItembase is the base component for all menu item components.
516
- *
517
- * We also include additional `aria` props to support the menu item being a trigger for the FlyoutMenuItem popup and for the
518
- * expanded content for ExpandableMenuItem.
519
- */
520
- type MenuItemBaseProps<T extends HTMLAnchorElement | HTMLButtonElement> =
521
- MenuItemLinkOrButtonCommonProps & {
522
- /**
523
- * ID attribute, passed to the interactive element (anchor/button). This is not publicly exposed, and is currently only
524
- * used internally by `ExpandableMenuItemTrigger` for the `aria-labelledby` attribute.
525
- */
526
- id?: string;
527
- href?: string | Record<string, any>;
528
- target?: HTMLAnchorElement['target'];
529
- isDisabled?: boolean;
530
- isSelected?: boolean;
531
- // eslint-disable-next-line @repo/internal/react/consistent-props-definitions
532
- ariaControls?: string;
533
- // eslint-disable-next-line @repo/internal/react/boolean-prop-naming-convention, @repo/internal/react/consistent-props-definitions
534
- ariaExpanded?: boolean;
535
- // eslint-disable-next-line @repo/internal/react/consistent-props-definitions
536
- ariaHasPopup?: boolean | 'dialog';
537
- onClick?: MenuItemOnClick<T>;
538
- };
539
-
540
- /**
541
- * This is the internal version of the component, to be passed into `forwardRef`.
542
- *
543
- * It contains a type argument `<T>`, to specify the type of the interactive element (`button` or `a`).
544
- * This can be inferred from the type of the `onClick` prop.
545
- */
546
- const MenuItemBaseNoRef = <T extends HTMLAnchorElement | HTMLButtonElement>(
547
- {
548
- id,
549
- testId,
550
- actions,
551
- actionsOnHover,
552
- children,
553
- description,
554
- elemAfter,
555
- elemBefore,
556
- href,
557
- target,
558
- isDisabled,
559
- isSelected,
560
- onClick,
561
- ariaControls,
562
- ariaExpanded,
563
- ariaHasPopup,
564
- interactionName,
565
- isContentTooltipDisabled,
566
- visualContentRef,
567
- isDragging,
568
- hasDragIndicator,
569
- dropIndicator,
570
- }: MenuItemBaseProps<T>,
571
- forwardedRef: React.ForwardedRef<T>,
572
- ) => {
573
- const level = useLevel();
574
- const setFlyoutMenuOpen = useSetFlyoutMenuOpen();
575
- const isFlyoutMenuOpen = useFlyoutMenuOpen();
576
- const isLink = typeof href !== 'undefined';
577
- const labelRef = useRef<T | null>(null);
578
- const descriptionRef = useRef<T | null>(null);
579
- const tooltipOnClick = useRef<React.MouseEventHandler<HTMLElement> | null>(null);
580
-
581
- const handleClick = useCallback(
582
- (event: React.MouseEvent<T>, analyticsEvent: UIAnalyticsEvent) => {
583
- onClick?.(event, analyticsEvent);
584
- // Toggle flyout menu open state when inside a flyout context provider
585
- setFlyoutMenuOpen(!isFlyoutMenuOpen);
586
-
587
- tooltipOnClick.current?.(event);
588
- },
589
- [onClick, setFlyoutMenuOpen, isFlyoutMenuOpen],
590
- );
591
-
592
- /**
593
- * Show the tooltip if _either_ label or description is truncated
594
- */
595
- const canTooltipAppear = useCallback((): boolean => {
596
- if (isContentTooltipDisabled) {
597
- return false;
598
- }
599
-
600
- // Show tooltip if _either_ label or description are clamped
601
-
602
- const label = labelRef.current;
603
- const description = descriptionRef.current;
604
-
605
- if (label && isTextClamped(label)) {
606
- return true;
607
- }
608
-
609
- return Boolean(description && isTextClamped(description));
610
- }, [isContentTooltipDisabled]);
611
-
612
- // By default provide the spacing for `elemBefore` to have good
613
- // vertical alignment of labels and to give clear indentation between levels
614
- // in the side navigation (even when items don't use elemBefore).
615
- const showElemBefore = elemBefore !== COLLAPSE_ELEM_BEFORE;
616
-
617
- const interactiveElemContent = (
618
- <div css={interactiveContentStyles.root}>
619
- {/**
620
- * We are creating a hidden element to increase the interactive area of our menu items.
621
- * This enables users to only need to move their pointers vertically to be able to access
622
- * nested menu items.
623
- *
624
- * 📺 More context: https://www.youtube.com/watch?v=zVFJAwrCQCM
625
- *
626
- * Notes:
627
- *
628
- * - We cannot use `::before` on the interactive element itself as you
629
- * cannot drag a `button` element from `::before` in Firefox
630
- * https://bugzilla.mozilla.org/show_bug.cgi?id=1967645
631
- * - The hidden element uses `position:absolute` so it won't impact layout
632
- *
633
- */}
634
- <div
635
- css={extendButtonOrAnchorStyles.root}
636
- // This extends the clickable area of nested menu items to the width
637
- // of the root level menu items, while being visually indented.
638
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
639
- style={{ insetInlineStart: `calc(-1 * ${level} * ${expandableMenuItemIndentation})` }}
640
- aria-hidden="true"
641
- />
642
- <div css={[textStyles.root, !showElemBefore && textStyles.noElemBeforeIndent]}>
643
- <Text
644
- weight="medium"
645
- maxLines={1}
646
- color={getTextColor({ isDisabled, isSelected })}
647
- ref={labelRef}
648
- >
649
- {children}
650
- </Text>
651
- {description && (
652
- <Text
653
- color={isDisabled ? 'color.text.disabled' : 'color.text.subtle'}
654
- size="small"
655
- maxLines={1}
656
- ref={descriptionRef}
657
- >
658
- {description}
659
- </Text>
660
- )}
661
- </div>
662
- {/**
663
- * Both the drop indicator and drag handle use `position:absolute`
664
- * Both rely on `position:relative` on a parent for positioning.
665
- */}
666
-
667
- {/**
668
- * Wrapping `LazyDragHandle` in it's own `Suspense` boundary, so that it's loading won't block
669
- * the rendering of the rest of the menu item.
670
- * We put the `Suspense` in the conditional branch to avoid putting a `Suspense` in the react
671
- * tree for consumers who don't need it
672
- */}
673
- {hasDragIndicator ? (
674
- <Suspense fallback={null}>
675
- <LazyDragHandle />
676
- </Suspense>
677
- ) : null}
678
-
679
- {dropIndicator}
680
- </div>
681
- );
682
-
683
- /**
684
- * If the [expandable] menu item is expanded, show hover actions even when *not* hovered.
685
- *
686
- * Note: we also remove the `elemAfter` when showing `actionsOnHover`
687
- */
688
- const showHoverActionsWhenNotHovered = Boolean(ariaExpanded && actionsOnHover);
689
-
690
- return (
691
- <AvatarContext.Provider value={defaultAvatarValues}>
692
- <div
693
- ref={visualContentRef}
694
- css={[
695
- containerStyles.root,
696
- isSelected && containerStyles.selected,
697
- isDragging && containerStyles.dragging,
698
- description && containerStyles.hasDescription,
699
- // If the menu item has actionsOnHover and is expanded, show hover actions even when not hovered
700
- showHoverActionsWhenNotHovered && containerStyles.showHoverActions,
701
- // If the menu item has both actionsOnHover and elemAfter and is expanded, remove elemAfter to make more space for actionsOnHover.
702
- showHoverActionsWhenNotHovered && elemAfter && containerStyles.removeElemAfter,
703
- // If the menu item has both actionsOnHover and elemAfter, remove elemAfter to make more space for actionsOnHover, when:
704
- // - menu item is hovered, or
705
- // - there is an open nested popup (as we apply hover styles when there is an open nested popup)
706
- actionsOnHover && elemAfter && containerStyles.removeElemAfterOnHoverOrOpenNestedPopup,
707
- isDisabled && containerStyles.disabled,
708
- ]}
709
- data-testid={testId ? `${testId}-container` : undefined}
710
- data-selected={isSelected}
711
- >
712
- <Tooltip
713
- content={() => (
714
- <>
715
- <div>{children}</div>
716
- {description ? <div>{description}</div> : null}
717
- </>
718
- )}
719
- position="right"
720
- // NOTE: Types in React 18 have changed and `forwardRef(() => <TooltipPrimitive>)` no longer appears to match 100%
721
- component={MenuItemTooltip as TooltipProps['component']}
722
- ignoreTooltipPointerEvents
723
- hideTooltipOnMouseDown
724
- // We don't need a duplicate hidden element containing tooltip content
725
- // as the content of the tooltip matches what is rendered for the menu item.
726
- isScreenReaderAnnouncementDisabled
727
- canAppear={canTooltipAppear}
728
- >
729
- {(tooltipProps) => {
730
- // Putting the tooltip onClick into a ref.
731
- // This way we don't need to create a new `onClick` function on each
732
- // render (as we would need to merge `tooltipProps.onClick` and our `handleClick`)
733
- tooltipOnClick.current = tooltipProps.onClick;
734
-
735
- const sharedProps = {
736
- ...tooltipProps,
737
- 'aria-controls': ariaControls,
738
- 'aria-haspopup': ariaHasPopup,
739
- ref: mergeRefs([forwardedRef, tooltipProps.ref]),
740
- id,
741
- testId,
742
- interactionName,
743
- };
744
-
745
- return isLink ? (
746
- <Anchor
747
- {...sharedProps}
748
- onClick={handleClick as MenuItemOnClick<HTMLAnchorElement>}
749
- xcss={cx(
750
- buttonOrAnchorStyles.root,
751
- topLevelSiblingStyles.root,
752
- isSelected && buttonOrAnchorStyles.selected,
753
- hasDragIndicator && buttonOrAnchorStyles.hasDragIndicator,
754
- )}
755
- // Needed to override Anchor style due to a compiled/emotion conflict
756
- // eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop
757
- style={{ textDecoration: 'none' }}
758
- aria-current={isSelected ? 'page' : undefined}
759
- href={href}
760
- target={target}
761
- /**
762
- * For anchors we don't want to have the standard drag and drop behaviour.
763
- *
764
- * Thinking on the topic:
765
- *
766
- * - Anchors look visually similar to buttons in the sidenav
767
- * - Why should some menu items be natively draggable, while others are not?
768
- * - A user cannot know which menu items are "natively" draggable (ie anchors)
769
- * - If you wire up an anchor to be draggable using our standard affordances
770
- * it will have a different preview experience to native anchor dragging.
771
- *
772
- * To promote consistency, all elements need to use the same visual affordances.
773
- *
774
- * Anchor elements will automatically attach URL information
775
- * to the native data store.
776
- *
777
- * When `hasDragIndicator` is `true` we are expecting consumers to register
778
- * the element as draggable through the `draggable()` Pragmatic drag and drop function.
779
- * The `draggable()` function will add `draggable="true"` to the element.
780
- */
781
- draggable={hasDragIndicator ? undefined : false}
782
- >
783
- {/* Won't be a "grid child" */}
784
- <div css={notchStyles.root} aria-hidden="true" />
785
- {interactiveElemContent}
786
- </Anchor>
787
- ) : (
788
- <Pressable
789
- {...sharedProps}
790
- onClick={handleClick as MenuItemOnClick<HTMLButtonElement>}
791
- xcss={cx(
792
- buttonOrAnchorStyles.root,
793
- topLevelSiblingStyles.root,
794
- isSelected && buttonOrAnchorStyles.selected,
795
- hasDragIndicator && buttonOrAnchorStyles.hasDragIndicator,
796
- )}
797
- aria-expanded={ariaExpanded}
798
- isDisabled={isDisabled}
799
- >
800
- {interactiveElemContent}
801
- </Pressable>
802
- );
803
- }}
804
- </Tooltip>
805
- {showElemBefore && (
806
- <div
807
- css={[
808
- elemBeforeStyles.root,
809
- topLevelSiblingStyles.root,
810
- onTopOfButtonOrAnchorStyles.root,
811
- ]}
812
- >
813
- {elemBefore}
814
- </div>
815
- )}
816
- {actionsOnHover && <div css={actionsOnHoverStyles.root}>{actionsOnHover}</div>}
817
- {elemAfter && (
818
- <div
819
- css={[
820
- elemAfterStyles.root,
821
- topLevelSiblingStyles.root,
822
- onTopOfButtonOrAnchorStyles.root,
823
- ]}
824
- >
825
- {elemAfter}
826
- </div>
827
- )}
828
- {actions && (
829
- <div
830
- css={[actionStyles.root, topLevelSiblingStyles.root, onTopOfButtonOrAnchorStyles.root]}
831
- >
832
- {actions}
833
- </div>
834
- )}
835
- </div>
836
- </AvatarContext.Provider>
837
- );
838
- };
839
-
840
- /**
841
- * __MenuItemBase__
842
- *
843
- * The base menu item component used to compose ButtonMenuItem and LinkMenuItem.
844
- *
845
- * It contains a type argument `<T>`, to specify the type of the interactive element (`button` or `a`).
846
- * This can be inferred from the type of the `onClick` prop.
847
- */
848
- export const MenuItemBase = forwardRefWithGeneric(MenuItemBaseNoRef);