@okta/odyssey-react-mui 1.35.0 → 1.35.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (145) hide show
  1. package/dist/cjs/DatePickers/useOdysseyDateFields.cjs +2 -2
  2. package/dist/cjs/DatePickers/useOdysseyDateFields.cjs.map +1 -1
  3. package/dist/cjs/Field.cjs +1 -1
  4. package/dist/cjs/Field.cjs.map +1 -1
  5. package/dist/cjs/Pagination/Pagination.cjs +0 -6
  6. package/dist/cjs/Pagination/Pagination.cjs.map +1 -1
  7. package/dist/cjs/inputUtils.cjs +1 -1
  8. package/dist/cjs/inputUtils.cjs.map +1 -1
  9. package/dist/cjs/labs/DataFilters.cjs +4 -4
  10. package/dist/cjs/labs/DataFilters.cjs.map +1 -1
  11. package/dist/cjs/labs/DataView/DataCard.cjs +18 -18
  12. package/dist/cjs/labs/DataView/DataCard.cjs.map +1 -1
  13. package/dist/cjs/labs/DataView/DataView.cjs +10 -10
  14. package/dist/cjs/labs/DataView/DataView.cjs.map +1 -1
  15. package/dist/cjs/labs/DataView/TableLayoutContent.cjs +4 -1
  16. package/dist/cjs/labs/DataView/TableLayoutContent.cjs.map +1 -1
  17. package/dist/cjs/labs/DataView/useFilterConversion.cjs +1 -1
  18. package/dist/cjs/labs/DataView/useFilterConversion.cjs.map +1 -1
  19. package/dist/cjs/theme/StringWithValue.cjs +6 -0
  20. package/dist/cjs/theme/StringWithValue.cjs.map +1 -0
  21. package/dist/cjs/theme/components.cjs +2590 -2592
  22. package/dist/cjs/theme/components.cjs.map +1 -1
  23. package/dist/cjs/theme/useMediaQuery.cjs +4 -4
  24. package/dist/cjs/theme/useMediaQuery.cjs.map +1 -1
  25. package/dist/cjs/ui-shell/InnerAppContainer.cjs +60 -0
  26. package/dist/cjs/ui-shell/InnerAppContainer.cjs.map +1 -0
  27. package/dist/cjs/ui-shell/NarrowUiShellContent.cjs +6 -1
  28. package/dist/cjs/ui-shell/NarrowUiShellContent.cjs.map +1 -1
  29. package/dist/cjs/ui-shell/SideNav/SideNav.cjs +79 -48
  30. package/dist/cjs/ui-shell/SideNav/SideNav.cjs.map +1 -1
  31. package/dist/cjs/ui-shell/SideNav/SideNavToggleButton.cjs +84 -112
  32. package/dist/cjs/ui-shell/SideNav/SideNavToggleButton.cjs.map +1 -1
  33. package/dist/cjs/ui-shell/TopNav/TopNav.cjs +1 -6
  34. package/dist/cjs/ui-shell/TopNav/TopNav.cjs.map +1 -1
  35. package/dist/cjs/ui-shell/UiShell.cjs +6 -5
  36. package/dist/cjs/ui-shell/UiShell.cjs.map +1 -1
  37. package/dist/cjs/ui-shell/WideUiShellContent.cjs +10 -4
  38. package/dist/cjs/ui-shell/WideUiShellContent.cjs.map +1 -1
  39. package/dist/cjs/ui-shell/index.cjs +29 -9
  40. package/dist/cjs/ui-shell/index.cjs.map +1 -1
  41. package/dist/cjs/ui-shell/renderUiShell.cjs +2 -0
  42. package/dist/cjs/ui-shell/renderUiShell.cjs.map +1 -1
  43. package/dist/cjs/ui-shell/useMatchAppElementToUiShellAppArea.cjs +3 -2
  44. package/dist/cjs/ui-shell/useMatchAppElementToUiShellAppArea.cjs.map +1 -1
  45. package/dist/cjs/ui-shell/useScrollState.cjs +71 -21
  46. package/dist/cjs/ui-shell/useScrollState.cjs.map +1 -1
  47. package/dist/cjs/ui-shell/useUiShellBreakpoints.cjs +20 -15
  48. package/dist/cjs/ui-shell/useUiShellBreakpoints.cjs.map +1 -1
  49. package/dist/cjs/web-component/createReactRootElements.cjs +5 -3
  50. package/dist/cjs/web-component/createReactRootElements.cjs.map +1 -1
  51. package/dist/cjs/web-component/renderReactInWebComponent.cjs +21 -7
  52. package/dist/cjs/web-component/renderReactInWebComponent.cjs.map +1 -1
  53. package/dist/esm/DatePickers/useOdysseyDateFields.js +2 -2
  54. package/dist/esm/DatePickers/useOdysseyDateFields.js.map +1 -1
  55. package/dist/esm/Field.js +1 -1
  56. package/dist/esm/Field.js.map +1 -1
  57. package/dist/esm/Pagination/Pagination.js +0 -6
  58. package/dist/esm/Pagination/Pagination.js.map +1 -1
  59. package/dist/esm/inputUtils.js +1 -1
  60. package/dist/esm/inputUtils.js.map +1 -1
  61. package/dist/esm/labs/DataFilters.js +4 -4
  62. package/dist/esm/labs/DataFilters.js.map +1 -1
  63. package/dist/esm/labs/DataView/DataCard.js +18 -18
  64. package/dist/esm/labs/DataView/DataCard.js.map +1 -1
  65. package/dist/esm/labs/DataView/DataView.js +10 -10
  66. package/dist/esm/labs/DataView/DataView.js.map +1 -1
  67. package/dist/esm/labs/DataView/TableLayoutContent.js +4 -1
  68. package/dist/esm/labs/DataView/TableLayoutContent.js.map +1 -1
  69. package/dist/esm/labs/DataView/useFilterConversion.js +1 -1
  70. package/dist/esm/labs/DataView/useFilterConversion.js.map +1 -1
  71. package/dist/esm/theme/StringWithValue.js +2 -0
  72. package/dist/esm/theme/StringWithValue.js.map +1 -0
  73. package/dist/esm/theme/components.js +2607 -2609
  74. package/dist/esm/theme/components.js.map +1 -1
  75. package/dist/esm/theme/useMediaQuery.js +5 -5
  76. package/dist/esm/theme/useMediaQuery.js.map +1 -1
  77. package/dist/esm/ui-shell/InnerAppContainer.js +56 -0
  78. package/dist/esm/ui-shell/InnerAppContainer.js.map +1 -0
  79. package/dist/esm/ui-shell/NarrowUiShellContent.js +6 -1
  80. package/dist/esm/ui-shell/NarrowUiShellContent.js.map +1 -1
  81. package/dist/esm/ui-shell/SideNav/SideNav.js +80 -49
  82. package/dist/esm/ui-shell/SideNav/SideNav.js.map +1 -1
  83. package/dist/esm/ui-shell/SideNav/SideNavToggleButton.js +85 -113
  84. package/dist/esm/ui-shell/SideNav/SideNavToggleButton.js.map +1 -1
  85. package/dist/esm/ui-shell/TopNav/TopNav.js +1 -6
  86. package/dist/esm/ui-shell/TopNav/TopNav.js.map +1 -1
  87. package/dist/esm/ui-shell/UiShell.js +6 -5
  88. package/dist/esm/ui-shell/UiShell.js.map +1 -1
  89. package/dist/esm/ui-shell/WideUiShellContent.js +10 -4
  90. package/dist/esm/ui-shell/WideUiShellContent.js.map +1 -1
  91. package/dist/esm/ui-shell/index.js +3 -1
  92. package/dist/esm/ui-shell/index.js.map +1 -1
  93. package/dist/esm/ui-shell/renderUiShell.js +2 -0
  94. package/dist/esm/ui-shell/renderUiShell.js.map +1 -1
  95. package/dist/esm/ui-shell/useMatchAppElementToUiShellAppArea.js +3 -2
  96. package/dist/esm/ui-shell/useMatchAppElementToUiShellAppArea.js.map +1 -1
  97. package/dist/esm/ui-shell/useScrollState.js +67 -21
  98. package/dist/esm/ui-shell/useScrollState.js.map +1 -1
  99. package/dist/esm/ui-shell/useUiShellBreakpoints.js +19 -14
  100. package/dist/esm/ui-shell/useUiShellBreakpoints.js.map +1 -1
  101. package/dist/esm/web-component/createReactRootElements.js +4 -2
  102. package/dist/esm/web-component/createReactRootElements.js.map +1 -1
  103. package/dist/esm/web-component/renderReactInWebComponent.js +19 -5
  104. package/dist/esm/web-component/renderReactInWebComponent.js.map +1 -1
  105. package/dist/index.cjs +1 -1
  106. package/dist/index.mjs +1 -1
  107. package/dist/index.scss +1 -1
  108. package/dist/tsconfig.production.tsbuildinfo +1 -1
  109. package/dist/tsconfig.tsbuildinfo +1 -1
  110. package/dist/types/DatePickers/useOdysseyDateFields.d.ts.map +1 -1
  111. package/dist/types/Pagination/Pagination.d.ts.map +1 -1
  112. package/dist/types/labs/DataView/DataCard.d.ts.map +1 -1
  113. package/dist/types/labs/DataView/DataView.d.ts.map +1 -1
  114. package/dist/types/labs/DataView/TableLayoutContent.d.ts.map +1 -1
  115. package/dist/types/theme/StringWithValue.d.ts +13 -0
  116. package/dist/types/theme/StringWithValue.d.ts.map +1 -0
  117. package/dist/types/theme/components.d.ts.map +1 -1
  118. package/dist/types/theme/useMediaQuery.d.ts +2 -1
  119. package/dist/types/theme/useMediaQuery.d.ts.map +1 -1
  120. package/dist/types/ui-shell/InnerAppContainer.d.ts +35 -0
  121. package/dist/types/ui-shell/InnerAppContainer.d.ts.map +1 -0
  122. package/dist/types/ui-shell/NarrowUiShellContent.d.ts.map +1 -1
  123. package/dist/types/ui-shell/SideNav/SideNav.d.ts +2 -0
  124. package/dist/types/ui-shell/SideNav/SideNav.d.ts.map +1 -1
  125. package/dist/types/ui-shell/SideNav/SideNavToggleButton.d.ts +15 -8
  126. package/dist/types/ui-shell/SideNav/SideNavToggleButton.d.ts.map +1 -1
  127. package/dist/types/ui-shell/TopNav/TopNav.d.ts +1 -1
  128. package/dist/types/ui-shell/TopNav/TopNav.d.ts.map +1 -1
  129. package/dist/types/ui-shell/UiShell.d.ts +8 -1
  130. package/dist/types/ui-shell/UiShell.d.ts.map +1 -1
  131. package/dist/types/ui-shell/WideUiShellContent.d.ts.map +1 -1
  132. package/dist/types/ui-shell/index.d.ts +3 -1
  133. package/dist/types/ui-shell/index.d.ts.map +1 -1
  134. package/dist/types/ui-shell/renderUiShell.d.ts +2 -2
  135. package/dist/types/ui-shell/renderUiShell.d.ts.map +1 -1
  136. package/dist/types/ui-shell/useMatchAppElementToUiShellAppArea.d.ts.map +1 -1
  137. package/dist/types/ui-shell/useScrollState.d.ts +9 -1
  138. package/dist/types/ui-shell/useScrollState.d.ts.map +1 -1
  139. package/dist/types/ui-shell/useUiShellBreakpoints.d.ts +15 -5
  140. package/dist/types/ui-shell/useUiShellBreakpoints.d.ts.map +1 -1
  141. package/dist/types/web-component/createReactRootElements.d.ts +2 -0
  142. package/dist/types/web-component/createReactRootElements.d.ts.map +1 -1
  143. package/dist/types/web-component/renderReactInWebComponent.d.ts +1 -1
  144. package/dist/types/web-component/renderReactInWebComponent.d.ts.map +1 -1
  145. package/package.json +17 -14
@@ -10,18 +10,18 @@
10
10
  * See the License for the specific language governing permissions and limitations under the License.
11
11
  */
12
12
 
13
- import { useEffect, useState } from "react";
13
+ import { useCallback, useEffect, useMemo, useState } from "react";
14
14
  export const useMediaQuery = mediaQuery => {
15
- const [hasMatches, setHasMatches] = useState(false);
15
+ const mediaQueryList = useMemo(() => window.matchMedia(mediaQuery), [mediaQuery]);
16
+ const [hasMatches, setHasMatches] = useState(() => mediaQueryList.matches);
17
+ const updateHasMatches = useCallback(event => setHasMatches(event.matches), []);
16
18
  useEffect(() => {
17
- const mediaQueryList = window.matchMedia(mediaQuery);
18
- const updateHasMatches = event => setHasMatches(event.matches);
19
19
  mediaQueryList.addEventListener("change", updateHasMatches);
20
20
  updateHasMatches(mediaQueryList);
21
21
  return () => {
22
22
  mediaQueryList.removeEventListener("change", updateHasMatches);
23
23
  };
24
- }, [hasMatches, mediaQuery]);
24
+ }, [mediaQueryList, updateHasMatches]);
25
25
  return hasMatches;
26
26
  };
27
27
  //# sourceMappingURL=useMediaQuery.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"useMediaQuery.js","names":["useEffect","useState","useMediaQuery","mediaQuery","hasMatches","setHasMatches","mediaQueryList","window","matchMedia","updateHasMatches","event","matches","addEventListener","removeEventListener"],"sources":["../../../src/theme/useMediaQuery.ts"],"sourcesContent":["/*!\n * Copyright (c) 2025-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nimport { useEffect, useState } from \"react\";\n\nexport const useMediaQuery = (mediaQuery: string) => {\n const [hasMatches, setHasMatches] = useState(false);\n\n useEffect(() => {\n const mediaQueryList = window.matchMedia(mediaQuery);\n\n const updateHasMatches = (event: MediaQueryListEvent | MediaQueryList) =>\n setHasMatches(event.matches);\n\n mediaQueryList.addEventListener(\"change\", updateHasMatches);\n\n updateHasMatches(mediaQueryList);\n\n return () => {\n mediaQueryList.removeEventListener(\"change\", updateHasMatches);\n };\n }, [hasMatches, mediaQuery]);\n\n return hasMatches;\n};\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,SAASA,SAAS,EAAEC,QAAQ,QAAQ,OAAO;AAE3C,OAAO,MAAMC,aAAa,GAAIC,UAAkB,IAAK;EACnD,MAAM,CAACC,UAAU,EAAEC,aAAa,CAAC,GAAGJ,QAAQ,CAAC,KAAK,CAAC;EAEnDD,SAAS,CAAC,MAAM;IACd,MAAMM,cAAc,GAAGC,MAAM,CAACC,UAAU,CAACL,UAAU,CAAC;IAEpD,MAAMM,gBAAgB,GAAIC,KAA2C,IACnEL,aAAa,CAACK,KAAK,CAACC,OAAO,CAAC;IAE9BL,cAAc,CAACM,gBAAgB,CAAC,QAAQ,EAAEH,gBAAgB,CAAC;IAE3DA,gBAAgB,CAACH,cAAc,CAAC;IAEhC,OAAO,MAAM;MACXA,cAAc,CAACO,mBAAmB,CAAC,QAAQ,EAAEJ,gBAAgB,CAAC;IAChE,CAAC;EACH,CAAC,EAAE,CAACL,UAAU,EAAED,UAAU,CAAC,CAAC;EAE5B,OAAOC,UAAU;AACnB,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"useMediaQuery.js","names":["useCallback","useEffect","useMemo","useState","useMediaQuery","mediaQuery","mediaQueryList","window","matchMedia","hasMatches","setHasMatches","matches","updateHasMatches","event","addEventListener","removeEventListener"],"sources":["../../../src/theme/useMediaQuery.ts"],"sourcesContent":["/*!\n * Copyright (c) 2025-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nimport { useCallback, useEffect, useMemo, useState } from \"react\";\n\nimport { StringWithValue } from \"./StringWithValue.js\";\n\nexport const useMediaQuery = <MediaQuery extends string>(\n mediaQuery: StringWithValue<MediaQuery>,\n) => {\n const mediaQueryList = useMemo(\n () => window.matchMedia(mediaQuery),\n [mediaQuery],\n );\n\n const [hasMatches, setHasMatches] = useState(() => mediaQueryList.matches);\n\n const updateHasMatches = useCallback(\n (event: MediaQueryListEvent | MediaQueryList) =>\n setHasMatches(event.matches),\n [],\n );\n\n useEffect(() => {\n mediaQueryList.addEventListener(\"change\", updateHasMatches);\n\n updateHasMatches(mediaQueryList);\n\n return () => {\n mediaQueryList.removeEventListener(\"change\", updateHasMatches);\n };\n }, [mediaQueryList, updateHasMatches]);\n\n return hasMatches;\n};\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,SAASA,WAAW,EAAEC,SAAS,EAAEC,OAAO,EAAEC,QAAQ,QAAQ,OAAO;AAIjE,OAAO,MAAMC,aAAa,GACxBC,UAAuC,IACpC;EACH,MAAMC,cAAc,GAAGJ,OAAO,CAC5B,MAAMK,MAAM,CAACC,UAAU,CAACH,UAAU,CAAC,EACnC,CAACA,UAAU,CACb,CAAC;EAED,MAAM,CAACI,UAAU,EAAEC,aAAa,CAAC,GAAGP,QAAQ,CAAC,MAAMG,cAAc,CAACK,OAAO,CAAC;EAE1E,MAAMC,gBAAgB,GAAGZ,WAAW,CACjCa,KAA2C,IAC1CH,aAAa,CAACG,KAAK,CAACF,OAAO,CAAC,EAC9B,EACF,CAAC;EAEDV,SAAS,CAAC,MAAM;IACdK,cAAc,CAACQ,gBAAgB,CAAC,QAAQ,EAAEF,gBAAgB,CAAC;IAE3DA,gBAAgB,CAACN,cAAc,CAAC;IAEhC,OAAO,MAAM;MACXA,cAAc,CAACS,mBAAmB,CAAC,QAAQ,EAAEH,gBAAgB,CAAC;IAChE,CAAC;EACH,CAAC,EAAE,CAACN,cAAc,EAAEM,gBAAgB,CAAC,CAAC;EAEtC,OAAOH,UAAU;AACnB,CAAC","ignoreList":[]}
@@ -0,0 +1,56 @@
1
+ /*!
2
+ * Copyright (c) 2025-present, Okta, Inc. and/or its affiliates. All rights reserved.
3
+ * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the "License.")
4
+ *
5
+ * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.
6
+ * Unless required by applicable law or agreed to in writing, software
7
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
8
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
9
+ *
10
+ * See the License for the specific language governing permissions and limitations under the License.
11
+ */
12
+
13
+ import styled from "@emotion/styled";
14
+ import { memo } from "react";
15
+ import { UI_SHELL_BASE_Z_INDEX } from "./uiShellSharedConstants.js";
16
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
17
+ const StyledAppContainerShadowShared = styled("div")({
18
+ left: 0,
19
+ position: "absolute",
20
+ top: 0,
21
+ width: "100%",
22
+ zIndex: UI_SHELL_BASE_Z_INDEX
23
+ });
24
+ export const StyledAppContainerShadow1 = styled(StyledAppContainerShadowShared)({
25
+ background: `linear-gradient(
26
+ to bottom,
27
+ rgba(39, 39, 39, 0.08) 0%,
28
+ transparent 100%
29
+ )`,
30
+ height: "4px"
31
+ });
32
+ export const StyledAppContainerShadow2 = styled(StyledAppContainerShadowShared)({
33
+ background: `linear-gradient(
34
+ to bottom,
35
+ rgba(39, 39, 39, 0.01) 0%,
36
+ transparent 100%
37
+ )`,
38
+ height: "6px"
39
+ });
40
+ export const StyledAppContainerShadow3 = styled(StyledAppContainerShadowShared)({
41
+ background: `linear-gradient(
42
+ to bottom,
43
+ rgba(39, 39, 39, 0.05) 0%,
44
+ transparent 100%
45
+ )`,
46
+ height: "15px"
47
+ });
48
+ const InnerAppContainer = ({
49
+ isContentScrolled
50
+ }) => isContentScrolled ? _jsxs(_Fragment, {
51
+ children: [_jsx(StyledAppContainerShadow1, {}), _jsx(StyledAppContainerShadow2, {}), _jsx(StyledAppContainerShadow3, {})]
52
+ }) : null;
53
+ const MemoizedInnerAppContainer = memo(InnerAppContainer);
54
+ MemoizedInnerAppContainer.displayName = "InnerAppContainer";
55
+ export { MemoizedInnerAppContainer as InnerAppContainer };
56
+ //# sourceMappingURL=InnerAppContainer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InnerAppContainer.js","names":["styled","memo","UI_SHELL_BASE_Z_INDEX","jsx","_jsx","Fragment","_Fragment","jsxs","_jsxs","StyledAppContainerShadowShared","left","position","top","width","zIndex","StyledAppContainerShadow1","background","height","StyledAppContainerShadow2","StyledAppContainerShadow3","InnerAppContainer","isContentScrolled","children","MemoizedInnerAppContainer","displayName"],"sources":["../../../src/ui-shell/InnerAppContainer.tsx"],"sourcesContent":["/*!\n * Copyright (c) 2025-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nimport styled from \"@emotion/styled\";\nimport { memo } from \"react\";\nimport { UI_SHELL_BASE_Z_INDEX } from \"./uiShellSharedConstants.js\";\n\n// Shared styles for fake inset shadow. Not rendered anywhere.\nconst StyledAppContainerShadowShared = styled(\"div\")({\n left: 0,\n position: \"absolute\",\n top: 0,\n width: \"100%\",\n zIndex: UI_SHELL_BASE_Z_INDEX,\n});\n\nexport const StyledAppContainerShadow1 = styled(StyledAppContainerShadowShared)(\n {\n background: `linear-gradient(\n to bottom,\n rgba(39, 39, 39, 0.08) 0%,\n transparent 100%\n )`,\n height: \"4px\",\n },\n);\n\nexport const StyledAppContainerShadow2 = styled(StyledAppContainerShadowShared)(\n {\n background: `linear-gradient(\n to bottom,\n rgba(39, 39, 39, 0.01) 0%,\n transparent 100%\n )`,\n height: \"6px\",\n },\n);\n\nexport const StyledAppContainerShadow3 = styled(StyledAppContainerShadowShared)(\n {\n background: `linear-gradient(\n to bottom,\n rgba(39, 39, 39, 0.05) 0%,\n transparent 100%\n )`,\n height: \"15px\",\n },\n);\n\nexport type InnerAppContainerProps = {\n isContentScrolled: boolean;\n};\n\nconst InnerAppContainer = ({ isContentScrolled }: InnerAppContainerProps) =>\n isContentScrolled ? (\n <>\n <StyledAppContainerShadow1 />\n <StyledAppContainerShadow2 />\n <StyledAppContainerShadow3 />\n </>\n ) : null;\n\nconst MemoizedInnerAppContainer = memo(InnerAppContainer);\nMemoizedInnerAppContainer.displayName = \"InnerAppContainer\";\n\nexport { MemoizedInnerAppContainer as InnerAppContainer };\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAOA,MAAM,MAAM,iBAAiB;AACpC,SAASC,IAAI,QAAQ,OAAO;AAC5B,SAASC,qBAAqB,QAAQ,6BAA6B;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,QAAA,IAAAC,SAAA,EAAAC,IAAA,IAAAC,KAAA;AAGpE,MAAMC,8BAA8B,GAAGT,MAAM,CAAC,KAAK,CAAC,CAAC;EACnDU,IAAI,EAAE,CAAC;EACPC,QAAQ,EAAE,UAAU;EACpBC,GAAG,EAAE,CAAC;EACNC,KAAK,EAAE,MAAM;EACbC,MAAM,EAAEZ;AACV,CAAC,CAAC;AAEF,OAAO,MAAMa,yBAAyB,GAAGf,MAAM,CAACS,8BAA8B,CAAC,CAC7E;EACEO,UAAU,EAAE;AAChB;AACA;AACA;AACA,MAAM;EACFC,MAAM,EAAE;AACV,CACF,CAAC;AAED,OAAO,MAAMC,yBAAyB,GAAGlB,MAAM,CAACS,8BAA8B,CAAC,CAC7E;EACEO,UAAU,EAAE;AAChB;AACA;AACA;AACA,MAAM;EACFC,MAAM,EAAE;AACV,CACF,CAAC;AAED,OAAO,MAAME,yBAAyB,GAAGnB,MAAM,CAACS,8BAA8B,CAAC,CAC7E;EACEO,UAAU,EAAE;AAChB;AACA;AACA;AACA,MAAM;EACFC,MAAM,EAAE;AACV,CACF,CAAC;AAMD,MAAMG,iBAAiB,GAAGA,CAAC;EAAEC;AAA0C,CAAC,KACtEA,iBAAiB,GACfb,KAAA,CAAAF,SAAA;EAAAgB,QAAA,GACElB,IAAA,CAACW,yBAAyB,IAAE,CAAC,EAC7BX,IAAA,CAACc,yBAAyB,IAAE,CAAC,EAC7Bd,IAAA,CAACe,yBAAyB,IAAE,CAAC;AAAA,CAC7B,CAAC,GACD,IAAI;AAEV,MAAMI,yBAAyB,GAAGtB,IAAI,CAACmB,iBAAiB,CAAC;AACzDG,yBAAyB,CAACC,WAAW,GAAG,mBAAmB;AAE3D,SAASD,yBAAyB,IAAIH,iBAAiB","ignoreList":[]}
@@ -17,6 +17,7 @@ import { ErrorBoundary } from "react-error-boundary";
17
17
  import { Button } from "../Buttons/Button.js";
18
18
  import { CloseIcon } from "../icons.generated/Close.js";
19
19
  import { MoreIcon } from "../icons.generated/More.js";
20
+ import { InnerAppContainer } from "./InnerAppContainer.js";
20
21
  import { useOdysseyDesignTokens } from "../OdysseyDesignTokensContext.js";
21
22
  import { SideNav } from "./SideNav/SideNav.js";
22
23
  import { SideNavLogo } from "./SideNav/SideNavLogo.js";
@@ -38,6 +39,7 @@ const StyledAppContentArea = styled("div")({
38
39
  gridTemplateColumns: "auto 1fr auto",
39
40
  gridTemplateRows: "1fr",
40
41
  height: "100%",
42
+ pointerEvents: "none",
41
43
  width: "100%"
42
44
  });
43
45
  const StyledAppContainer = styled("div", {
@@ -335,7 +337,10 @@ const NarrowUiShellContent = ({
335
337
  }), _jsx(StyledAppContainer, {
336
338
  appBackgroundColor: uiShellContext?.appBackgroundColor,
337
339
  tabIndex: 0,
338
- ref: uiShellAppAreaRef
340
+ ref: uiShellAppAreaRef,
341
+ children: _jsx(InnerAppContainer, {
342
+ isContentScrolled: isContentScrolled
343
+ })
339
344
  })]
340
345
  })]
341
346
  })]
@@ -1 +1 @@
1
- {"version":3,"file":"NarrowUiShellContent.js","names":["styled","memo","useCallback","useEffect","useRef","useState","ErrorBoundary","Button","CloseIcon","MoreIcon","useOdysseyDesignTokens","SideNav","SideNavLogo","HamburgerMenuIcon","useUiShellContext","emptySideNavItems","SIDE_NAV_WIDTH","TOP_NAV_HEIGHT","UI_SHELL_BASE_Z_INDEX","useScrollState","useMatchAppElementToUiShellAppArea","hexToRgb","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","StyledAppContentArea","gridArea","position","display","gridGap","gridTemplateAreas","gridTemplateColumns","gridTemplateRows","height","width","StyledAppContainer","shouldForwardProp","prop","appBackgroundColor","backgroundColor","overflow","StyledBannersContainer","zIndex","StyledLeftSideContainer","isOpen","overflowY","StyledRightSideContainer","odysseyDesignTokens","HueNeutralWhite","maxWidth","right","StyledMenuLogo","alignItems","gap","Spacing3","StyledLogoContainer","paddingBlock","Spacing4","maxHeight","StyledPageOverlay","HueNeutral900","asFormattedString","replace","left","top","StyledSideNavContainer","StyledUiShellContainer","HueNeutral50","StyledTopNav","isContentScrolled","topNavBackgroundColor","boxShadow","DepthMedium","undefined","clipPath","flexDirection","justifyContent","transition","TransitionDurationMain","TransitionTimingMain","StyledTopNavMenu","minHeight","Spacing2","paddingInline","borderBottomColor","HueNeutral100","borderBottomStyle","BorderStyleMain","borderBottomWidth","BorderWidthMain","StyledTopNavSearch","NarrowUiShellContent","appElement","appElementScrollingMode","hasStandardAppContentPadding","initialVisibleSections","onError","console","error","optionalComponents","sideNavProps","topNavProps","uiShellContext","sideNavContainerRef","topNavContainerRef","uiShellAppAreaRef","isLeftSideMenuOpen","setIsLeftSideMenuOpen","isRightSideMenuOpen","setIsRightSideMenuOpen","closeSideMenus","unsubscribeFromCloseRightSideMenu","subscribeToCloseRightSideMenu","unsubscribeFromSideNavItemClicked","subscribeToCloseSideNavMenu","toggleLeftSideMenu","toggleRightSideMenu","parentContainerRef","paddingMode","uiShellResizableRefs","children","onClick","ref","banners","includes","fallback","sideNavBackgroundColor","isCollapsible","isCollapsed","startIcon","testId","variant","isLoading","_Skeleton","logoProps","rightSideMenu","topNavLeftSide","sideNavItems","appName","hasCustomFooter","sideNavFooter","footerComponent","footerItems","isObtrusive","tabIndex","MemoizedNarrowUiShellContent","displayName"],"sources":["../../../src/ui-shell/NarrowUiShellContent.tsx"],"sourcesContent":["/*!\n * Copyright (c) 2022-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nimport styled from \"@emotion/styled\";\nimport { Skeleton } from \"@mui/material\";\nimport {\n CSSProperties,\n memo,\n useCallback,\n useEffect,\n useRef,\n useState,\n} from \"react\";\nimport { ErrorBoundary } from \"react-error-boundary\";\n\nimport { Button } from \"../Buttons/Button.js\";\nimport type { HtmlProps } from \"../HtmlProps.js\";\nimport { CloseIcon } from \"../icons.generated/Close.js\";\nimport { MoreIcon } from \"../icons.generated/More.js\";\nimport {\n DesignTokens,\n useOdysseyDesignTokens,\n} from \"../OdysseyDesignTokensContext.js\";\nimport { SideNav } from \"./SideNav/SideNav.js\";\nimport { SideNavLogo } from \"./SideNav/SideNavLogo.js\";\nimport { HamburgerMenuIcon } from \"./TopNav/HamburgerMenuIcon.js\";\nimport { UiShellColors, useUiShellContext } from \"./UiShellProvider.js\";\nimport {\n UiShellNavComponentProps,\n UiShellContentProps,\n} from \"./uiShellContentTypes.js\";\nimport {\n emptySideNavItems,\n SIDE_NAV_WIDTH,\n TOP_NAV_HEIGHT,\n UI_SHELL_BASE_Z_INDEX,\n} from \"./uiShellSharedConstants.js\";\nimport { useScrollState } from \"./useScrollState.js\";\nimport { useMatchAppElementToUiShellAppArea } from \"./useMatchAppElementToUiShellAppArea.js\";\nimport { hexToRgb } from \"../hexToRgb.js\";\n\nconst StyledAppContentArea = styled(\"div\")({\n gridArea: \"app-content\",\n position: \"relative\",\n display: \"grid\",\n gridGap: 0,\n gridTemplateAreas: `\n \"left-side app-container right-side\"\n `,\n gridTemplateColumns: \"auto 1fr auto\",\n gridTemplateRows: \"1fr\",\n height: \"100%\",\n width: \"100%\",\n});\n\nconst StyledAppContainer = styled(\"div\", {\n shouldForwardProp: (prop) =>\n prop !== \"appBackgroundColor\" && prop !== \"odysseyDesignTokens\",\n})<{\n appBackgroundColor?: UiShellColors[\"appBackgroundColor\"];\n}>(({ appBackgroundColor }) => ({\n backgroundColor: appBackgroundColor,\n height: \"100%\",\n gridArea: \"app-container\",\n overflow: \"hidden\",\n width: \"100%\",\n}));\n\nconst StyledBannersContainer = styled(\"div\")({\n gridArea: \"banners\",\n zIndex: UI_SHELL_BASE_Z_INDEX,\n});\n\nconst StyledLeftSideContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"isOpen\",\n})<{\n isOpen: boolean;\n}>(({ isOpen }) => ({\n display: isOpen ? \"block\" : \"none\",\n height: \"100%\",\n gridArea: \"left-side\",\n overflowY: \"auto\",\n position: \"absolute\",\n zIndex: UI_SHELL_BASE_Z_INDEX,\n}));\n\nconst StyledRightSideContainer = styled(\"div\", {\n shouldForwardProp: (prop) =>\n prop !== \"isOpen\" && prop !== \"odysseyDesignTokens\",\n})<{\n isOpen: boolean;\n odysseyDesignTokens: DesignTokens;\n}>(({ isOpen, odysseyDesignTokens }) => ({\n backgroundColor: odysseyDesignTokens.HueNeutralWhite,\n display: isOpen ? \"block\" : \"none\",\n gridArea: \"right-side\",\n height: \"100%\",\n maxWidth: SIDE_NAV_WIDTH,\n overflowY: \"auto\",\n position: \"absolute\",\n right: 0,\n width: SIDE_NAV_WIDTH,\n zIndex: UI_SHELL_BASE_Z_INDEX,\n}));\n\nconst StyledMenuLogo = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n alignItems: \"center\",\n display: \"inline-flex\",\n gap: odysseyDesignTokens.Spacing3,\n}));\n\nconst StyledLogoContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n height: TOP_NAV_HEIGHT,\n paddingBlock: odysseyDesignTokens.Spacing4,\n\n \"svg, img\": {\n maxHeight: \"100%\",\n width: \"auto\",\n maxWidth: \"100%\",\n },\n}));\n\nconst StyledPageOverlay = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n backgroundColor: hexToRgb(\n odysseyDesignTokens.HueNeutral900,\n ).asFormattedString.replace(/rgb\\((.+)\\)$/, \"rgba($1, 0.26)\"),\n gridArea: \"app-content\",\n height: \"100vh\",\n left: 0,\n position: \"absolute\",\n top: 0,\n width: \"100vw\",\n zIndex: UI_SHELL_BASE_Z_INDEX,\n}));\n\nconst StyledSideNavContainer = styled(\"div\")({\n height: \"100%\", // Without this value, side nav won't fill up the height if the content is too short.\n});\n\nconst StyledUiShellContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n backgroundColor: odysseyDesignTokens.HueNeutral50,\n display: \"grid\",\n gridGap: 0,\n gridTemplateAreas: `\n \"banners\"\n \"top-nav\"\n \"app-content\"\n `,\n gridTemplateColumns: \"1fr\",\n gridTemplateRows: \"auto auto 1fr\",\n height: \"100vh\",\n overflow: \"hidden\",\n width: \"100vw\",\n}));\n\nconst StyledTopNav = styled(\"div\", {\n shouldForwardProp: (prop) =>\n prop !== \"odysseyDesignTokens\" &&\n prop !== \"isContentScrolled\" &&\n prop !== \"topNavBackgroundColor\",\n})<{\n isContentScrolled?: boolean;\n odysseyDesignTokens: DesignTokens;\n topNavBackgroundColor?: UiShellColors[\"topNavBackgroundColor\"];\n}>(({ odysseyDesignTokens, isContentScrolled, topNavBackgroundColor }) => ({\n alignItems: \"stretch\",\n backgroundColor: odysseyDesignTokens.HueNeutralWhite || topNavBackgroundColor, // This logic doesn't make sense, but I wanted to leave it here for when we eventually make a decision on `topNavBackgroundColor`. --Kevin Ghadyani\n boxShadow: isContentScrolled ? odysseyDesignTokens.DepthMedium : undefined,\n clipPath: \"inset(0 0 -100vh 0)\",\n display: \"flex\",\n flexDirection: \"column\",\n gridArea: \"top-nav\",\n height: \"100%\",\n justifyContent: \"center\",\n position: \"relative\",\n transition: `box-shadow ${odysseyDesignTokens.TransitionDurationMain} ${odysseyDesignTokens.TransitionTimingMain}`,\n zIndex: UI_SHELL_BASE_Z_INDEX,\n}));\n\nconst StyledTopNavMenu = styled(\"div\", {\n shouldForwardProp: (prop) =>\n prop !== \"odysseyDesignTokens\" && prop !== \"topNavBackgroundColor\",\n})<{\n odysseyDesignTokens: DesignTokens;\n topNavBackgroundColor?: UiShellColors[\"topNavBackgroundColor\"];\n}>(({ odysseyDesignTokens, topNavBackgroundColor }) => ({\n alignItems: \"center\",\n display: \"flex\",\n gap: odysseyDesignTokens.Spacing3,\n height: \"100%\",\n justifyContent: \"space-between\",\n maxHeight: TOP_NAV_HEIGHT,\n minHeight: TOP_NAV_HEIGHT,\n paddingBlock: odysseyDesignTokens.Spacing2,\n paddingInline: odysseyDesignTokens.Spacing3,\n transition: `box-shadow ${odysseyDesignTokens.TransitionDurationMain} ${odysseyDesignTokens.TransitionTimingMain}`,\n\n ...(topNavBackgroundColor === odysseyDesignTokens.HueNeutralWhite &&\n ({\n borderBottomColor: odysseyDesignTokens.HueNeutral100,\n borderBottomStyle: odysseyDesignTokens.BorderStyleMain,\n borderBottomWidth: odysseyDesignTokens.BorderWidthMain,\n } as CSSProperties)),\n}));\n\nconst StyledTopNavSearch = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n paddingBlock: odysseyDesignTokens.Spacing2,\n paddingInline: odysseyDesignTokens.Spacing3,\n}));\n\nexport type NarrowUiShellContentProps = Pick<HtmlProps, \"testId\"> &\n Pick<UiShellNavComponentProps, \"sideNavProps\" | \"topNavProps\"> &\n UiShellContentProps;\n\nconst NarrowUiShellContent = ({\n appElement,\n appElementScrollingMode,\n hasStandardAppContentPadding = true,\n initialVisibleSections = [\"TopNav\", \"SideNav\", \"AppSwitcher\"],\n onError = console.error,\n optionalComponents,\n sideNavProps,\n topNavProps,\n}: NarrowUiShellContentProps) => {\n const odysseyDesignTokens = useOdysseyDesignTokens();\n const uiShellContext = useUiShellContext();\n\n const { isContentScrolled } = useScrollState(appElement);\n\n const sideNavContainerRef = useRef<HTMLDivElement>(null);\n const topNavContainerRef = useRef<HTMLDivElement>(null);\n const uiShellAppAreaRef = useRef<HTMLDivElement>(null);\n\n const [isLeftSideMenuOpen, setIsLeftSideMenuOpen] = useState(false);\n const [isRightSideMenuOpen, setIsRightSideMenuOpen] = useState(false);\n\n const closeSideMenus = useCallback(() => {\n setIsLeftSideMenuOpen(false);\n setIsRightSideMenuOpen(false);\n }, []);\n\n useEffect(() => {\n const unsubscribeFromCloseRightSideMenu =\n uiShellContext?.subscribeToCloseRightSideMenu(() => {\n closeSideMenus();\n });\n\n const unsubscribeFromSideNavItemClicked =\n uiShellContext?.subscribeToCloseSideNavMenu(() => {\n closeSideMenus();\n });\n\n return () => {\n unsubscribeFromCloseRightSideMenu?.();\n unsubscribeFromSideNavItemClicked?.();\n };\n }, [closeSideMenus, uiShellContext]);\n\n const toggleLeftSideMenu = useCallback(() => {\n setIsRightSideMenuOpen(false);\n setIsLeftSideMenuOpen((isLeftSideMenuOpen) => !isLeftSideMenuOpen);\n }, []);\n\n const toggleRightSideMenu = useCallback(() => {\n setIsLeftSideMenuOpen(false);\n setIsRightSideMenuOpen((isRightSideMenuOpen) => !isRightSideMenuOpen);\n }, []);\n\n const { parentContainerRef } = useMatchAppElementToUiShellAppArea({\n appElement,\n appElementScrollingMode,\n paddingMode: hasStandardAppContentPadding ? \"compact\" : \"none\",\n uiShellAppAreaRef,\n uiShellResizableRefs: [\n sideNavContainerRef,\n topNavContainerRef,\n uiShellAppAreaRef,\n ],\n });\n\n return (\n <>\n {(isLeftSideMenuOpen || isRightSideMenuOpen) && (\n <StyledPageOverlay\n odysseyDesignTokens={odysseyDesignTokens}\n onClick={closeSideMenus}\n />\n )}\n\n <StyledUiShellContainer\n odysseyDesignTokens={odysseyDesignTokens}\n ref={parentContainerRef}\n >\n <StyledBannersContainer>\n {optionalComponents?.banners}\n </StyledBannersContainer>\n\n {(initialVisibleSections?.includes(\"TopNav\") || topNavProps) && (\n <ErrorBoundary fallback={null} onError={onError}>\n <StyledTopNav\n isContentScrolled={isContentScrolled}\n odysseyDesignTokens={odysseyDesignTokens}\n topNavBackgroundColor={uiShellContext?.topNavBackgroundColor}\n >\n <StyledTopNavMenu\n odysseyDesignTokens={odysseyDesignTokens}\n topNavBackgroundColor={uiShellContext?.sideNavBackgroundColor}\n >\n <StyledMenuLogo odysseyDesignTokens={odysseyDesignTokens}>\n {(sideNavProps?.isCollapsible ||\n !sideNavProps?.isCollapsed) && (\n <Button\n onClick={toggleLeftSideMenu}\n startIcon={<HamburgerMenuIcon />}\n testId=\"sidenav-menu--icon\"\n variant=\"floating\"\n />\n )}\n\n <StyledLogoContainer\n odysseyDesignTokens={odysseyDesignTokens}\n >\n {sideNavProps?.isLoading ? (\n // The skeleton takes the hardcoded dimensions of the Okta logo\n <Skeleton variant=\"rounded\" height={24} width={67} />\n ) : (\n <SideNavLogo {...sideNavProps?.logoProps} />\n )}\n </StyledLogoContainer>\n </StyledMenuLogo>\n\n {optionalComponents?.rightSideMenu && (\n <Button\n onClick={toggleRightSideMenu}\n startIcon={\n isRightSideMenuOpen ? <CloseIcon /> : <MoreIcon />\n }\n testId=\"userprofile-menu--icon\"\n variant=\"floating\"\n />\n )}\n </StyledTopNavMenu>\n\n {optionalComponents?.topNavLeftSide && (\n <StyledTopNavSearch odysseyDesignTokens={odysseyDesignTokens}>\n {optionalComponents?.topNavLeftSide}\n </StyledTopNavSearch>\n )}\n </StyledTopNav>\n </ErrorBoundary>\n )}\n\n <StyledAppContentArea>\n <StyledLeftSideContainer isOpen={isLeftSideMenuOpen}>\n {\n /* If SideNav should be initially visible and we have not yet received props, render SideNav with minimal inputs */\n initialVisibleSections?.includes(\"SideNav\") &&\n sideNavProps === undefined && (\n <ErrorBoundary fallback={null} onError={onError}>\n <SideNav isLoading sideNavItems={emptySideNavItems} />\n </ErrorBoundary>\n )\n }\n\n {sideNavProps && (\n <ErrorBoundary fallback={null} onError={onError}>\n <StyledSideNavContainer>\n <SideNav\n {...{\n ...{\n ...sideNavProps,\n // This hides the side nav logo or app name from showing up as we already have one in the narrow top nav.\n appName: undefined,\n logoProps: undefined,\n },\n ...(sideNavProps.hasCustomFooter &&\n optionalComponents?.sideNavFooter\n ? {\n footerComponent: optionalComponents.sideNavFooter,\n footerItems: undefined,\n hasCustomFooter: sideNavProps.hasCustomFooter,\n }\n : {\n footerItems: sideNavProps.footerItems,\n hasCustomFooter: false,\n }),\n }}\n isCollapsed={false}\n isCollapsible={false}\n isObtrusive\n />\n </StyledSideNavContainer>\n </ErrorBoundary>\n )}\n </StyledLeftSideContainer>\n\n <StyledRightSideContainer\n isOpen={isRightSideMenuOpen}\n odysseyDesignTokens={odysseyDesignTokens}\n >\n <StyledSideNavContainer>\n {optionalComponents?.rightSideMenu}\n </StyledSideNavContainer>\n </StyledRightSideContainer>\n\n <StyledAppContainer\n appBackgroundColor={uiShellContext?.appBackgroundColor}\n tabIndex={0}\n ref={uiShellAppAreaRef}\n />\n </StyledAppContentArea>\n </StyledUiShellContainer>\n </>\n );\n};\n\nconst MemoizedNarrowUiShellContent = memo(NarrowUiShellContent);\nMemoizedNarrowUiShellContent.displayName = \"NarrowUiShellContent\";\n\nexport { MemoizedNarrowUiShellContent as NarrowUiShellContent };\n"],"mappings":";AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAOA,MAAM,MAAM,iBAAiB;AAEpC,SAEEC,IAAI,EACJC,WAAW,EACXC,SAAS,EACTC,MAAM,EACNC,QAAQ,QACH,OAAO;AACd,SAASC,aAAa,QAAQ,sBAAsB;AAEpD,SAASC,MAAM,QAAQ,sBAAsB;AAE7C,SAASC,SAAS,QAAQ,6BAA6B;AACvD,SAASC,QAAQ,QAAQ,4BAA4B;AACrD,SAEEC,sBAAsB,QACjB,kCAAkC;AACzC,SAASC,OAAO,QAAQ,sBAAsB;AAC9C,SAASC,WAAW,QAAQ,0BAA0B;AACtD,SAASC,iBAAiB,QAAQ,+BAA+B;AACjE,SAAwBC,iBAAiB,QAAQ,sBAAsB;AAKvE,SACEC,iBAAiB,EACjBC,cAAc,EACdC,cAAc,EACdC,qBAAqB,QAChB,6BAA6B;AACpC,SAASC,cAAc,QAAQ,qBAAqB;AACpD,SAASC,kCAAkC,QAAQ,yCAAyC;AAC5F,SAASC,QAAQ,QAAQ,gBAAgB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA,EAAAC,QAAA,IAAAC,SAAA;AAE1C,MAAMC,oBAAoB,GAAG5B,MAAM,CAAC,KAAK,CAAC,CAAC;EACzC6B,QAAQ,EAAE,aAAa;EACvBC,QAAQ,EAAE,UAAU;EACpBC,OAAO,EAAE,MAAM;EACfC,OAAO,EAAE,CAAC;EACVC,iBAAiB,EAAE;AACrB;AACA,GAAG;E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B,CAAC,EAE1B3H,IAAA,CAAC0B,wBAAwB;UACvBF,MAAM,EAAEgE,mBAAoB;UAC5B7D,mBAAmB,EAAEA,mBAAoB;UAAAyE,QAAA,EAEzCpG,IAAA,CAAC6C,sBAAsB;YAAAuD,QAAA,EACpBrB,kBAAkB,EAAEoC;UAAa,CACZ;QAAC,CACD,CAAC,EAE3BnH,IAAA,CAACe,kBAAkB;UACjBG,kBAAkB,EAAEgE,cAAc,EAAEhE,kBAAmB;UACvD0G,QAAQ,EAAE,CAAE;UACZtB,GAAG,EAAEjB;QAAkB,CACxB,CAAC;MAAA,CACkB,CAAC;IAAA,CACD,CAAC;EAAA,CACzB,CAAC;AAEP,CAAC;AAED,MAAMwC,4BAA4B,GAAGnJ,IAAI,CAAC6F,oBAAoB,CAAC;AAC/DsD,4BAA4B,CAACC,WAAW,GAAG,sBAAsB;AAEjE,SAASD,4BAA4B,IAAItD,oBAAoB","ignoreList":[]}
1
+ {"version":3,"file":"NarrowUiShellContent.js","names":["styled","memo","useCallback","useEffect","useRef","useState","ErrorBoundary","Button","CloseIcon","MoreIcon","InnerAppContainer","useOdysseyDesignTokens","SideNav","SideNavLogo","HamburgerMenuIcon","useUiShellContext","emptySideNavItems","SIDE_NAV_WIDTH","TOP_NAV_HEIGHT","UI_SHELL_BASE_Z_INDEX","useScrollState","useMatchAppElementToUiShellAppArea","hexToRgb","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","StyledAppContentArea","gridArea","position","display","gridGap","gridTemplateAreas","gridTemplateColumns","gridTemplateRows","height","pointerEvents","width","StyledAppContainer","shouldForwardProp","prop","appBackgroundColor","backgroundColor","overflow","StyledBannersContainer","zIndex","StyledLeftSideContainer","isOpen","overflowY","StyledRightSideContainer","odysseyDesignTokens","HueNeutralWhite","maxWidth","right","StyledMenuLogo","alignItems","gap","Spacing3","StyledLogoContainer","paddingBlock","Spacing4","maxHeight","StyledPageOverlay","HueNeutral900","asFormattedString","replace","left","top","StyledSideNavContainer","StyledUiShellContainer","HueNeutral50","StyledTopNav","isContentScrolled","topNavBackgroundColor","boxShadow","DepthMedium","undefined","clipPath","flexDirection","justifyContent","transition","TransitionDurationMain","TransitionTimingMain","StyledTopNavMenu","minHeight","Spacing2","paddingInline","borderBottomColor","HueNeutral100","borderBottomStyle","BorderStyleMain","borderBottomWidth","BorderWidthMain","StyledTopNavSearch","NarrowUiShellContent","appElement","appElementScrollingMode","hasStandardAppContentPadding","initialVisibleSections","onError","console","error","optionalComponents","sideNavProps","topNavProps","uiShellContext","sideNavContainerRef","topNavContainerRef","uiShellAppAreaRef","isLeftSideMenuOpen","setIsLeftSideMenuOpen","isRightSideMenuOpen","setIsRightSideMenuOpen","closeSideMenus","unsubscribeFromCloseRightSideMenu","subscribeToCloseRightSideMenu","unsubscribeFromSideNavItemClicked","subscribeToCloseSideNavMenu","toggleLeftSideMenu","toggleRightSideMenu","parentContainerRef","paddingMode","uiShellResizableRefs","children","onClick","ref","banners","includes","fallback","sideNavBackgroundColor","isCollapsible","isCollapsed","startIcon","testId","variant","isLoading","_Skeleton","logoProps","rightSideMenu","topNavLeftSide","sideNavItems","appName","hasCustomFooter","sideNavFooter","footerComponent","footerItems","isObtrusive","tabIndex","MemoizedNarrowUiShellContent","displayName"],"sources":["../../../src/ui-shell/NarrowUiShellContent.tsx"],"sourcesContent":["/*!\n * Copyright (c) 2022-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nimport styled from \"@emotion/styled\";\nimport { Skeleton } from \"@mui/material\";\nimport {\n CSSProperties,\n memo,\n useCallback,\n useEffect,\n useRef,\n useState,\n} from \"react\";\nimport { ErrorBoundary } from \"react-error-boundary\";\n\nimport { Button } from \"../Buttons/Button.js\";\nimport type { HtmlProps } from \"../HtmlProps.js\";\nimport { CloseIcon } from \"../icons.generated/Close.js\";\nimport { MoreIcon } from \"../icons.generated/More.js\";\nimport { InnerAppContainer } from \"./InnerAppContainer.js\";\nimport {\n DesignTokens,\n useOdysseyDesignTokens,\n} from \"../OdysseyDesignTokensContext.js\";\nimport { SideNav } from \"./SideNav/SideNav.js\";\nimport { SideNavLogo } from \"./SideNav/SideNavLogo.js\";\nimport { HamburgerMenuIcon } from \"./TopNav/HamburgerMenuIcon.js\";\nimport { UiShellColors, useUiShellContext } from \"./UiShellProvider.js\";\nimport {\n UiShellNavComponentProps,\n UiShellContentProps,\n} from \"./uiShellContentTypes.js\";\nimport {\n emptySideNavItems,\n SIDE_NAV_WIDTH,\n TOP_NAV_HEIGHT,\n UI_SHELL_BASE_Z_INDEX,\n} from \"./uiShellSharedConstants.js\";\nimport { useScrollState } from \"./useScrollState.js\";\nimport { useMatchAppElementToUiShellAppArea } from \"./useMatchAppElementToUiShellAppArea.js\";\nimport { hexToRgb } from \"../hexToRgb.js\";\n\nconst StyledAppContentArea = styled(\"div\")({\n gridArea: \"app-content\",\n position: \"relative\",\n display: \"grid\",\n gridGap: 0,\n gridTemplateAreas: `\n \"left-side app-container right-side\"\n `,\n gridTemplateColumns: \"auto 1fr auto\",\n gridTemplateRows: \"1fr\",\n height: \"100%\",\n pointerEvents: \"none\",\n width: \"100%\",\n});\n\nconst StyledAppContainer = styled(\"div\", {\n shouldForwardProp: (prop) =>\n prop !== \"appBackgroundColor\" && prop !== \"odysseyDesignTokens\",\n})<{\n appBackgroundColor?: UiShellColors[\"appBackgroundColor\"];\n}>(({ appBackgroundColor }) => ({\n backgroundColor: appBackgroundColor,\n height: \"100%\",\n gridArea: \"app-container\",\n overflow: \"hidden\",\n width: \"100%\",\n}));\n\nconst StyledBannersContainer = styled(\"div\")({\n gridArea: \"banners\",\n zIndex: UI_SHELL_BASE_Z_INDEX,\n});\n\nconst StyledLeftSideContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"isOpen\",\n})<{\n isOpen: boolean;\n}>(({ isOpen }) => ({\n display: isOpen ? \"block\" : \"none\",\n height: \"100%\",\n gridArea: \"left-side\",\n overflowY: \"auto\",\n position: \"absolute\",\n zIndex: UI_SHELL_BASE_Z_INDEX,\n}));\n\nconst StyledRightSideContainer = styled(\"div\", {\n shouldForwardProp: (prop) =>\n prop !== \"isOpen\" && prop !== \"odysseyDesignTokens\",\n})<{\n isOpen: boolean;\n odysseyDesignTokens: DesignTokens;\n}>(({ isOpen, odysseyDesignTokens }) => ({\n backgroundColor: odysseyDesignTokens.HueNeutralWhite,\n display: isOpen ? \"block\" : \"none\",\n gridArea: \"right-side\",\n height: \"100%\",\n maxWidth: SIDE_NAV_WIDTH,\n overflowY: \"auto\",\n position: \"absolute\",\n right: 0,\n width: SIDE_NAV_WIDTH,\n zIndex: UI_SHELL_BASE_Z_INDEX,\n}));\n\nconst StyledMenuLogo = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n alignItems: \"center\",\n display: \"inline-flex\",\n gap: odysseyDesignTokens.Spacing3,\n}));\n\nconst StyledLogoContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n height: TOP_NAV_HEIGHT,\n paddingBlock: odysseyDesignTokens.Spacing4,\n\n \"svg, img\": {\n maxHeight: \"100%\",\n width: \"auto\",\n maxWidth: \"100%\",\n },\n}));\n\nconst StyledPageOverlay = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n backgroundColor: hexToRgb(\n odysseyDesignTokens.HueNeutral900,\n ).asFormattedString.replace(/rgb\\((.+)\\)$/, \"rgba($1, 0.26)\"),\n gridArea: \"app-content\",\n height: \"100vh\",\n left: 0,\n position: \"absolute\",\n top: 0,\n width: \"100vw\",\n zIndex: UI_SHELL_BASE_Z_INDEX,\n}));\n\nconst StyledSideNavContainer = styled(\"div\")({\n height: \"100%\", // Without this value, side nav won't fill up the height if the content is too short.\n});\n\nconst StyledUiShellContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n backgroundColor: odysseyDesignTokens.HueNeutral50,\n display: \"grid\",\n gridGap: 0,\n gridTemplateAreas: `\n \"banners\"\n \"top-nav\"\n \"app-content\"\n `,\n gridTemplateColumns: \"1fr\",\n gridTemplateRows: \"auto auto 1fr\",\n height: \"100vh\",\n overflow: \"hidden\",\n width: \"100vw\",\n}));\n\nconst StyledTopNav = styled(\"div\", {\n shouldForwardProp: (prop) =>\n prop !== \"odysseyDesignTokens\" &&\n prop !== \"isContentScrolled\" &&\n prop !== \"topNavBackgroundColor\",\n})<{\n isContentScrolled?: boolean;\n odysseyDesignTokens: DesignTokens;\n topNavBackgroundColor?: UiShellColors[\"topNavBackgroundColor\"];\n}>(({ odysseyDesignTokens, isContentScrolled, topNavBackgroundColor }) => ({\n alignItems: \"stretch\",\n backgroundColor: odysseyDesignTokens.HueNeutralWhite || topNavBackgroundColor, // This logic doesn't make sense, but I wanted to leave it here for when we eventually make a decision on `topNavBackgroundColor`. --Kevin Ghadyani\n boxShadow: isContentScrolled ? odysseyDesignTokens.DepthMedium : undefined,\n clipPath: \"inset(0 0 -100vh 0)\",\n display: \"flex\",\n flexDirection: \"column\",\n gridArea: \"top-nav\",\n height: \"100%\",\n justifyContent: \"center\",\n position: \"relative\",\n transition: `box-shadow ${odysseyDesignTokens.TransitionDurationMain} ${odysseyDesignTokens.TransitionTimingMain}`,\n zIndex: UI_SHELL_BASE_Z_INDEX,\n}));\n\nconst StyledTopNavMenu = styled(\"div\", {\n shouldForwardProp: (prop) =>\n prop !== \"odysseyDesignTokens\" && prop !== \"topNavBackgroundColor\",\n})<{\n odysseyDesignTokens: DesignTokens;\n topNavBackgroundColor?: UiShellColors[\"topNavBackgroundColor\"];\n}>(({ odysseyDesignTokens, topNavBackgroundColor }) => ({\n alignItems: \"center\",\n display: \"flex\",\n gap: odysseyDesignTokens.Spacing3,\n height: \"100%\",\n justifyContent: \"space-between\",\n maxHeight: TOP_NAV_HEIGHT,\n minHeight: TOP_NAV_HEIGHT,\n paddingBlock: odysseyDesignTokens.Spacing2,\n paddingInline: odysseyDesignTokens.Spacing3,\n transition: `box-shadow ${odysseyDesignTokens.TransitionDurationMain} ${odysseyDesignTokens.TransitionTimingMain}`,\n\n ...(topNavBackgroundColor === odysseyDesignTokens.HueNeutralWhite &&\n ({\n borderBottomColor: odysseyDesignTokens.HueNeutral100,\n borderBottomStyle: odysseyDesignTokens.BorderStyleMain,\n borderBottomWidth: odysseyDesignTokens.BorderWidthMain,\n } as CSSProperties)),\n}));\n\nconst StyledTopNavSearch = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n paddingBlock: odysseyDesignTokens.Spacing2,\n paddingInline: odysseyDesignTokens.Spacing3,\n}));\n\nexport type NarrowUiShellContentProps = Pick<HtmlProps, \"testId\"> &\n Pick<UiShellNavComponentProps, \"sideNavProps\" | \"topNavProps\"> &\n UiShellContentProps;\n\nconst NarrowUiShellContent = ({\n appElement,\n appElementScrollingMode,\n hasStandardAppContentPadding = true,\n initialVisibleSections = [\"TopNav\", \"SideNav\", \"AppSwitcher\"],\n onError = console.error,\n optionalComponents,\n sideNavProps,\n topNavProps,\n}: NarrowUiShellContentProps) => {\n const odysseyDesignTokens = useOdysseyDesignTokens();\n const uiShellContext = useUiShellContext();\n\n const { isContentScrolled } = useScrollState(appElement);\n\n const sideNavContainerRef = useRef<HTMLDivElement>(null);\n const topNavContainerRef = useRef<HTMLDivElement>(null);\n const uiShellAppAreaRef = useRef<HTMLDivElement>(null);\n\n const [isLeftSideMenuOpen, setIsLeftSideMenuOpen] = useState(false);\n const [isRightSideMenuOpen, setIsRightSideMenuOpen] = useState(false);\n\n const closeSideMenus = useCallback(() => {\n setIsLeftSideMenuOpen(false);\n setIsRightSideMenuOpen(false);\n }, []);\n\n useEffect(() => {\n const unsubscribeFromCloseRightSideMenu =\n uiShellContext?.subscribeToCloseRightSideMenu(() => {\n closeSideMenus();\n });\n\n const unsubscribeFromSideNavItemClicked =\n uiShellContext?.subscribeToCloseSideNavMenu(() => {\n closeSideMenus();\n });\n\n return () => {\n unsubscribeFromCloseRightSideMenu?.();\n unsubscribeFromSideNavItemClicked?.();\n };\n }, [closeSideMenus, uiShellContext]);\n\n const toggleLeftSideMenu = useCallback(() => {\n setIsRightSideMenuOpen(false);\n setIsLeftSideMenuOpen((isLeftSideMenuOpen) => !isLeftSideMenuOpen);\n }, []);\n\n const toggleRightSideMenu = useCallback(() => {\n setIsLeftSideMenuOpen(false);\n setIsRightSideMenuOpen((isRightSideMenuOpen) => !isRightSideMenuOpen);\n }, []);\n\n const { parentContainerRef } = useMatchAppElementToUiShellAppArea({\n appElement,\n appElementScrollingMode,\n paddingMode: hasStandardAppContentPadding ? \"compact\" : \"none\",\n uiShellAppAreaRef,\n uiShellResizableRefs: [\n sideNavContainerRef,\n topNavContainerRef,\n uiShellAppAreaRef,\n ],\n });\n\n return (\n <>\n {(isLeftSideMenuOpen || isRightSideMenuOpen) && (\n <StyledPageOverlay\n odysseyDesignTokens={odysseyDesignTokens}\n onClick={closeSideMenus}\n />\n )}\n\n <StyledUiShellContainer\n odysseyDesignTokens={odysseyDesignTokens}\n ref={parentContainerRef}\n >\n <StyledBannersContainer>\n {optionalComponents?.banners}\n </StyledBannersContainer>\n\n {(initialVisibleSections?.includes(\"TopNav\") || topNavProps) && (\n <ErrorBoundary fallback={null} onError={onError}>\n <StyledTopNav\n isContentScrolled={isContentScrolled}\n odysseyDesignTokens={odysseyDesignTokens}\n topNavBackgroundColor={uiShellContext?.topNavBackgroundColor}\n >\n <StyledTopNavMenu\n odysseyDesignTokens={odysseyDesignTokens}\n topNavBackgroundColor={uiShellContext?.sideNavBackgroundColor}\n >\n <StyledMenuLogo odysseyDesignTokens={odysseyDesignTokens}>\n {(sideNavProps?.isCollapsible ||\n !sideNavProps?.isCollapsed) && (\n <Button\n onClick={toggleLeftSideMenu}\n startIcon={<HamburgerMenuIcon />}\n testId=\"sidenav-menu--icon\"\n variant=\"floating\"\n />\n )}\n\n <StyledLogoContainer\n odysseyDesignTokens={odysseyDesignTokens}\n >\n {sideNavProps?.isLoading ? (\n // The skeleton takes the hardcoded dimensions of the Okta logo\n <Skeleton variant=\"rounded\" height={24} width={67} />\n ) : (\n <SideNavLogo {...sideNavProps?.logoProps} />\n )}\n </StyledLogoContainer>\n </StyledMenuLogo>\n\n {optionalComponents?.rightSideMenu && (\n <Button\n onClick={toggleRightSideMenu}\n startIcon={\n isRightSideMenuOpen ? <CloseIcon /> : <MoreIcon />\n }\n testId=\"userprofile-menu--icon\"\n variant=\"floating\"\n />\n )}\n </StyledTopNavMenu>\n\n {optionalComponents?.topNavLeftSide && (\n <StyledTopNavSearch odysseyDesignTokens={odysseyDesignTokens}>\n {optionalComponents?.topNavLeftSide}\n </StyledTopNavSearch>\n )}\n </StyledTopNav>\n </ErrorBoundary>\n )}\n\n <StyledAppContentArea>\n <StyledLeftSideContainer isOpen={isLeftSideMenuOpen}>\n {\n /* If SideNav should be initially visible and we have not yet received props, render SideNav with minimal inputs */\n initialVisibleSections?.includes(\"SideNav\") &&\n sideNavProps === undefined && (\n <ErrorBoundary fallback={null} onError={onError}>\n <SideNav isLoading sideNavItems={emptySideNavItems} />\n </ErrorBoundary>\n )\n }\n\n {sideNavProps && (\n <ErrorBoundary fallback={null} onError={onError}>\n <StyledSideNavContainer>\n <SideNav\n {...{\n ...{\n ...sideNavProps,\n // This hides the side nav logo or app name from showing up as we already have one in the narrow top nav.\n appName: undefined,\n logoProps: undefined,\n },\n ...(sideNavProps.hasCustomFooter &&\n optionalComponents?.sideNavFooter\n ? {\n footerComponent: optionalComponents.sideNavFooter,\n footerItems: undefined,\n hasCustomFooter: sideNavProps.hasCustomFooter,\n }\n : {\n footerItems: sideNavProps.footerItems,\n hasCustomFooter: false,\n }),\n }}\n isCollapsed={false}\n isCollapsible={false}\n isObtrusive\n />\n </StyledSideNavContainer>\n </ErrorBoundary>\n )}\n </StyledLeftSideContainer>\n\n <StyledRightSideContainer\n isOpen={isRightSideMenuOpen}\n odysseyDesignTokens={odysseyDesignTokens}\n >\n <StyledSideNavContainer>\n {optionalComponents?.rightSideMenu}\n </StyledSideNavContainer>\n </StyledRightSideContainer>\n\n <StyledAppContainer\n appBackgroundColor={uiShellContext?.appBackgroundColor}\n tabIndex={0}\n ref={uiShellAppAreaRef}\n >\n <InnerAppContainer isContentScrolled={isContentScrolled} />\n </StyledAppContainer>\n </StyledAppContentArea>\n </StyledUiShellContainer>\n </>\n );\n};\n\nconst MemoizedNarrowUiShellContent = memo(NarrowUiShellContent);\nMemoizedNarrowUiShellContent.displayName = \"NarrowUiShellContent\";\n\nexport { MemoizedNarrowUiShellContent as NarrowUiShellContent };\n"],"mappings":";AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAOA,MAAM,MAAM,iBAAiB;AAEpC,SAEEC,IAAI,EACJC,WAAW,EACXC,SAAS,EACTC,MAAM,EACNC,QAAQ,QACH,OAAO;AACd,SAASC,aAAa,QAAQ,sBAAsB;AAEpD,SAASC,MAAM,QAAQ,sBAAsB;AAE7C,SAASC,SAAS,QAAQ,6BAA6B;AACvD,SAASC,QAAQ,QAAQ,4BAA4B;AACrD,SAASC,iBAAiB,QAAQ,wBAAwB;AAC1D,SAEEC,sBAAsB,QACj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,CAAC;AAC/DsD,4BAA4B,CAACC,WAAW,GAAG,sBAAsB;AAEjE,SAASD,4BAA4B,IAAItD,oBAAoB","ignoreList":[]}
@@ -12,7 +12,7 @@ import _Skeleton from "@mui/material/Skeleton";
12
12
  */
13
13
 
14
14
  import styled from "@emotion/styled";
15
- import { memo, useMemo, useState, useCallback, useRef, useEffect, createElement as _createElement } from "react";
15
+ import { memo, useMemo, useState, useCallback, useRef, useEffect } from "react";
16
16
  import { useTranslation } from "react-i18next";
17
17
  import { arrayMove } from "@dnd-kit/sortable";
18
18
  import { ErrorBoundary } from "react-error-boundary";
@@ -23,12 +23,14 @@ import { SideNavHeader } from "./SideNavHeader.js";
23
23
  import { SideNavItemContent, StyledSideNavListItem } from "./SideNavItemContent.js";
24
24
  import { SideNavFooterContent } from "./SideNavFooterContent.js";
25
25
  import { SideNavItemContentContext } from "./SideNavItemContentContext.js";
26
- import { SideNavToggleButton } from "./SideNavToggleButton.js";
26
+ import { SIDE_NAV_TOGGLE_ICON_HALF_SIZE, SIDE_NAV_TOGGLE_ICON_SIZE, SideNavToggleButton } from "./SideNavToggleButton.js";
27
27
  import { SortableList } from "./SortableList/SortableList.js";
28
28
  import { Overline } from "../../Typography.js";
29
29
  import { useUiShellContext } from "../../ui-shell/UiShellProvider.js";
30
30
  import { SIDE_NAV_VISIBILITY_TOGGLE_ICON_POSITION, SIDE_NAV_WIDTH, UI_SHELL_BASE_Z_INDEX, UI_SHELL_OVERLAY_Z_INDEX } from "../uiShellSharedConstants.js";
31
31
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
32
+ export const SIDE_NAV_COLLAPSED_PADDING_HIGHLIGHTED = 12;
33
+ export const SIDE_NAV_COLLAPSED_PADDING_UNHIGHLIGHTED = 2;
32
34
  const StyledCollapsibleContent = styled("div", {
33
35
  shouldForwardProp: prop => prop !== "odysseyDesignTokens" && prop !== "isSideNavCollapsed"
34
36
  })(({
@@ -64,54 +66,62 @@ const StyledOpacityTransitionContainer = styled("div", {
64
66
  })
65
67
  }));
66
68
  const StyledSideNavContainer = styled("nav", {
67
- shouldForwardProp: prop => prop !== "backgroundColor" && prop !== "odysseyDesignTokens" && prop !== "isAppContentWhiteBackground" && prop !== "isSideNavCollapsed"
69
+ shouldForwardProp: prop => prop !== "backgroundColor" && prop !== "hasNeighboringContent" && prop !== "isAppContentWhiteBackground" && prop !== "isSideNavCollapsed" && prop !== "isSideNavToggleHighlighted" && prop !== "odysseyDesignTokens"
68
70
  })(({
69
71
  backgroundColor,
72
+ hasNeighboringContent,
70
73
  isAppContentWhiteBackground,
71
74
  isSideNavCollapsed,
75
+ isSideNavToggleHighlighted,
72
76
  odysseyDesignTokens
73
77
  }) => ({
74
78
  backgroundColor: backgroundColor || odysseyDesignTokens.HueNeutralWhite,
75
79
  height: "100%",
76
80
  position: "relative",
77
81
  width: "fit-content",
78
- ...(isAppContentWhiteBackground && {
79
- borderRightWidth: odysseyDesignTokens.BorderWidthMain,
80
- borderRightStyle: odysseyDesignTokens.BorderStyleMain,
81
- borderRightColor: odysseyDesignTokens.HueNeutral100
82
- }),
83
- "&::after": {
84
- backgroundColor: odysseyDesignTokens.HueNeutral200,
82
+ "&::before, &::after": {
85
83
  content: "''",
86
84
  height: "100%",
87
- opacity: 0,
85
+ pointerEvents: "none",
88
86
  position: "absolute",
89
- right: 0,
87
+ right: `-${odysseyDesignTokens.BorderWidthMain}`,
90
88
  top: 0,
91
- transform: `translateX(0)`,
92
- transition: `opacity ${odysseyDesignTokens.TransitionDurationMain}, transform ${odysseyDesignTokens.TransitionDurationMain}`,
93
- width: odysseyDesignTokens.Spacing2,
89
+ transition: `opacity ${odysseyDesignTokens.TransitionDurationMain}, transform ${odysseyDesignTokens.TransitionDurationMain}, width ${odysseyDesignTokens.TransitionDurationMain}`,
90
+ userSelect: "none",
94
91
  zIndex: UI_SHELL_OVERLAY_Z_INDEX
95
92
  },
96
- "&:has([data-sidenav-toggle='true']:hover), &:has([data-sidenav-toggle='true']:focus-visible)": {
97
- ...(isSideNavCollapsed && {
98
- "&::after": {
99
- opacity: 1,
100
- transform: `translateX(100%)`
101
- },
102
- "[data-sidenav-toggle='true']": {
103
- transform: `translate3d(calc(100% + ${odysseyDesignTokens.Spacing3}), 0, 0)`
104
- }
105
- })
93
+ "&::before": {
94
+ backgroundColor: isSideNavToggleHighlighted ? odysseyDesignTokens.BorderColorPrimaryControl : odysseyDesignTokens.HueNeutral100,
95
+ opacity: isAppContentWhiteBackground || !isSideNavCollapsed && isSideNavToggleHighlighted ? 1 : 0,
96
+ width: `calc(${odysseyDesignTokens.BorderWidthMain} * 2)`
106
97
  },
107
- "[data-sidenav-toggle='true']": {
108
- position: "absolute",
109
- top: SIDE_NAV_VISIBILITY_TOGGLE_ICON_POSITION,
110
- right: 0,
111
- transition: `transform ${odysseyDesignTokens.TransitionDurationMain}`,
112
- transform: `translate3d(100%, 0, 0)`
98
+ "&::after": {
99
+ backgroundColor: odysseyDesignTokens.HueNeutral200,
100
+ opacity: isSideNavCollapsed ? 1 : 0,
101
+ transform: isSideNavCollapsed && !hasNeighboringContent ? isSideNavToggleHighlighted ? `translateX(calc(100% - (${odysseyDesignTokens.BorderWidthMain} * 2)))` : `translateX(calc(100% - ${SIDE_NAV_COLLAPSED_PADDING_HIGHLIGHTED}px))` : "translateX(0)",
102
+ width: hasNeighboringContent ? 0 : `calc(${SIDE_NAV_TOGGLE_ICON_HALF_SIZE + SIDE_NAV_COLLAPSED_PADDING_HIGHLIGHTED}px + ${odysseyDesignTokens.BorderWidthMain} * 2)`,
103
+ ...(isSideNavCollapsed && isSideNavToggleHighlighted ? {
104
+ borderRightColor: odysseyDesignTokens.BorderColorPrimaryControl,
105
+ borderRightStyle: odysseyDesignTokens.BorderStyleMain,
106
+ borderRightWidth: `calc(${odysseyDesignTokens.BorderWidthMain} * 2)`
107
+ } : {})
113
108
  }
114
109
  }));
110
+ const StyledSideNavToggleButtonContainer = styled("div", {
111
+ shouldForwardProp: prop => prop !== "hasNeighboringContent" && prop !== "isSideNavCollapsed" && prop !== "isSideNavToggleHighlighted" && prop !== "odysseyDesignTokens"
112
+ })(({
113
+ hasNeighboringContent,
114
+ isSideNavCollapsed,
115
+ isSideNavToggleHighlighted,
116
+ odysseyDesignTokens
117
+ }) => ({
118
+ position: "absolute",
119
+ right: `${SIDE_NAV_TOGGLE_ICON_HALF_SIZE}px`,
120
+ top: SIDE_NAV_VISIBILITY_TOGGLE_ICON_POSITION,
121
+ transform: isSideNavCollapsed && !hasNeighboringContent ? isSideNavToggleHighlighted ? `translate3d(calc(100% + ${SIDE_NAV_TOGGLE_ICON_HALF_SIZE + SIDE_NAV_COLLAPSED_PADDING_HIGHLIGHTED}px), 0, 0)` : `translate3d(calc(100% + ${SIDE_NAV_TOGGLE_ICON_HALF_SIZE + SIDE_NAV_COLLAPSED_PADDING_UNHIGHLIGHTED}px), 0, 0)` : "translate3d(100%, 0, 0)",
122
+ transition: `transform ${odysseyDesignTokens.TransitionDurationMain}`,
123
+ zIndex: UI_SHELL_OVERLAY_Z_INDEX + 1
124
+ }));
115
125
  const StyledSideNavHeaderContainer = styled("div", {
116
126
  shouldForwardProp: prop => prop !== "borderColor" && prop !== "hasContentScrolled" && prop !== "odysseyDesignTokens"
117
127
  })(({
@@ -151,10 +161,10 @@ const StyledSectionHeaderContainer = styled("li", {
151
161
  contrastFontColor,
152
162
  odysseyDesignTokens
153
163
  }) => ({
154
- paddingBlock: odysseyDesignTokens.Spacing1,
155
- paddingInline: odysseyDesignTokens.Spacing4,
164
+ color: contrastFontColor || odysseyDesignTokens.HueNeutral600,
156
165
  marginBlock: `${odysseyDesignTokens.Spacing3}`,
157
- color: contrastFontColor || odysseyDesignTokens.HueNeutral600
166
+ paddingBlock: odysseyDesignTokens.Spacing1,
167
+ paddingInline: odysseyDesignTokens.Spacing4
158
168
  }));
159
169
  const StyledSideNavFooter = styled("div", {
160
170
  shouldForwardProp: prop => prop !== "odysseyDesignTokens" && prop !== "sideNavBackgroundColor"
@@ -162,9 +172,9 @@ const StyledSideNavFooter = styled("div", {
162
172
  odysseyDesignTokens,
163
173
  sideNavBackgroundColor
164
174
  }) => ({
175
+ backgroundColor: odysseyDesignTokens.HueNeutralWhite,
165
176
  flexShrink: 0,
166
177
  padding: odysseyDesignTokens.Spacing4,
167
- backgroundColor: odysseyDesignTokens.HueNeutralWhite,
168
178
  ...(sideNavBackgroundColor && {
169
179
  backgroundColor: sideNavBackgroundColor
170
180
  })
@@ -260,9 +270,11 @@ const SideNav = ({
260
270
  onSort,
261
271
  sideNavItems
262
272
  }) => {
263
- const [isSideNavCollapsed, setIsSideNavCollapsed] = useState(isCollapsed);
264
273
  const [hasContentScrolled, setHasContentScrolled] = useState(false);
274
+ const [hasNeighboringContent, setHasNeighboringContent] = useState(false);
265
275
  const [isContentScrollable, setIsContentScrollable] = useState(false);
276
+ const [isSideNavCollapsed, setIsSideNavCollapsed] = useState(isCollapsed);
277
+ const [isSideNavToggleHighlighted, setIsSideNavToggleHighlighted] = useState(false);
266
278
  const [sideNavItemsList, updateSideNavItemsList] = useState(sideNavItems);
267
279
  const uiShellContext = useUiShellContext();
268
280
  const odysseyDesignTokens = useOdysseyDesignTokens();
@@ -272,9 +284,15 @@ const SideNav = ({
272
284
  const scrollableContentRef = useRef(null);
273
285
  const resizeObserverRef = useRef(null);
274
286
  const intersectionObserverRef = useRef(null);
287
+ const sideNavRef = useRef(null);
275
288
  const blankElement = useMemo(() => _jsx("div", {}), []);
276
289
  useEffect(() => updateSideNavItemsList(sideNavItems), [sideNavItems]);
277
- useEffect(() => setIsSideNavCollapsed(isCollapsed), [isCollapsed]);
290
+ useEffect(() => {
291
+ setIsSideNavCollapsed(isCollapsed);
292
+ if (sideNavRef.current) {
293
+ setHasNeighboringContent(sideNavRef.current.getBoundingClientRect().x > 0);
294
+ }
295
+ }, [isCollapsed]);
278
296
  useEffect(() => {
279
297
  const updateIsContentScrollable = () => {
280
298
  if (scrollableContentRef.current && scrollableContentRef.current.parentElement) {
@@ -425,18 +443,32 @@ const SideNav = ({
425
443
  updateSideNavItemsList(sortedSideNavItems);
426
444
  onSort?.(sortedSideNavItems, parentId, activeId, activeIndex, overIndex);
427
445
  }, [onSort, sideNavItemsList]);
446
+ const onSideNavToggleButtonHighlight = useCallback(isHighlighted => {
447
+ setIsSideNavToggleHighlighted(isHighlighted);
448
+ }, []);
428
449
  return _jsxs(StyledSideNavContainer, {
429
450
  "aria-label": t("navigation.label"),
430
451
  backgroundColor: uiShellContext?.sideNavBackgroundColor,
452
+ hasNeighboringContent: hasNeighboringContent,
431
453
  id: "side-nav-expandable",
432
454
  isAppContentWhiteBackground: uiShellContext?.appBackgroundColor === odysseyDesignTokens.HueNeutralWhite,
433
455
  isSideNavCollapsed: isSideNavCollapsed,
456
+ isSideNavToggleHighlighted: isSideNavToggleHighlighted,
434
457
  odysseyDesignTokens: odysseyDesignTokens,
435
- children: [isCollapsible && _jsx(SideNavToggleButton, {
436
- ariaControls: "side-nav-expandable",
458
+ ref: sideNavRef,
459
+ children: [isCollapsible && _jsx(StyledSideNavToggleButtonContainer, {
460
+ hasNeighboringContent: hasNeighboringContent,
437
461
  isSideNavCollapsed: isSideNavCollapsed,
438
- onClick: sideNavExpandClickHandler,
439
- onKeyDown: sideNavExpandKeyHandler
462
+ isSideNavToggleHighlighted: isSideNavToggleHighlighted,
463
+ odysseyDesignTokens: odysseyDesignTokens,
464
+ children: _jsx(SideNavToggleButton, {
465
+ clickAreaPadding: isSideNavCollapsed && !hasNeighboringContent ? SIDE_NAV_TOGGLE_ICON_SIZE / 2 : 0,
466
+ ariaControls: "side-nav-expandable",
467
+ isSideNavCollapsed: isSideNavCollapsed,
468
+ onClick: sideNavExpandClickHandler,
469
+ onHighlight: onSideNavToggleButtonHighlight,
470
+ onKeyDown: sideNavExpandKeyHandler
471
+ })
440
472
  }), _jsx(OdysseyThemeProvider, {
441
473
  children: _jsx(StyledCollapsibleContent, {
442
474
  "data-se": "collapsible-region",
@@ -485,8 +517,8 @@ const SideNav = ({
485
517
  component: "h3",
486
518
  children: label
487
519
  })
488
- }, id)
489
- });
520
+ })
521
+ }, id);
490
522
  } else if (childNavItems) {
491
523
  return _jsx(ErrorBoundary, {
492
524
  fallback: blankElement,
@@ -518,22 +550,21 @@ const SideNav = ({
518
550
  }) : childNavItems.map(item => item.navItem)
519
551
  })
520
552
  })
521
- }, id)
522
- });
553
+ })
554
+ }, id);
523
555
  } else {
524
556
  return _jsx(ErrorBoundary, {
525
557
  fallback: blankElement,
526
558
  children: _jsx(SideNavItemContentContext.Provider, {
527
559
  value: sideNavItemContentProviderValue,
528
- children: _createElement(SideNavItemContent, {
560
+ children: _jsx(SideNavItemContent, {
529
561
  ...item,
530
- key: item.id,
531
562
  onItemSelected: setSelectedItem,
532
563
  scrollRef: getRefIfThisIsFirstNodeWithIsSelected(item.id),
533
564
  startIcon: item.startIcon
534
565
  })
535
- }, item.id)
536
- });
566
+ })
567
+ }, item.id);
537
568
  }
538
569
  })
539
570
  }), !isLoading && footerItems && !hasCustomFooter && _jsx(StyledSideNavFooter, {