@harpercollins/harpercollins-design-system 1.29.2 → 1.29.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.
- package/dist/cjs/components/data-display/ChipIcon/ChipIcon.cjs +2 -2
- package/dist/cjs/components/data-display/Heading/Heading.cjs +1 -1
- package/dist/cjs/components/data-display/Icon/Icon.cjs +3 -3
- package/dist/cjs/components/data-display/ReadMore/ReadMore.cjs +4 -4
- package/dist/cjs/components/data-display/StatusIcon/StatusIcon.cjs +2 -2
- package/dist/cjs/components/data-display/Table/FilterChipsSection.cjs +2 -2
- package/dist/cjs/components/data-display/Table/StickyHorizontalScrollbar.cjs +3 -3
- package/dist/cjs/components/data-display/Table/Table.cjs +1 -1
- package/dist/cjs/components/data-display/Table/Table.styles.cjs +5 -5
- package/dist/cjs/components/data-display/Table/TableToolbar.cjs +3 -3
- package/dist/cjs/components/data-display/Table/filters/FilterComponents.cjs +4 -4
- package/dist/cjs/components/data-display/TextBlock/TextBlock.cjs +7 -7
- package/dist/cjs/components/data-display/Tooltip/Tooltip.cjs +2 -2
- package/dist/cjs/components/feedback/LoadingSpinner/LoadingSpinner.cjs +3 -3
- package/dist/cjs/components/feedback/ProgressBar/ProgressBar.cjs +4 -4
- package/dist/cjs/components/feedback/ToastMessages/ToastMessages.cjs +4 -4
- package/dist/cjs/components/global/AppBar/AppBar.cjs +8 -8
- package/dist/cjs/components/global/AppBar/NavigationProgress.cjs +4 -4
- package/dist/cjs/components/global/ErrorFallback/FullPageErrorFallback.cjs +3 -3
- package/dist/cjs/components/global/Footer/Footer.cjs +3 -3
- package/dist/cjs/components/global/Layout/Layout.cjs +3 -3
- package/dist/cjs/components/global/Logo/Logo.cjs +4 -4
- package/dist/cjs/components/global/Logo/LogoMini.cjs +2 -2
- package/dist/cjs/components/inputs/Autocomplete/AutocompleteSelectMultiple/AutocompleteSelectMultiple.cjs +2 -2
- package/dist/cjs/components/inputs/DatePicker/DatePicker.cjs +2 -2
- package/dist/cjs/components/inputs/DateTimeInput/DateTimeInput.cjs +4 -4
- package/dist/cjs/components/inputs/Input/Input.cjs +2 -2
- package/dist/cjs/components/navigation/Breadcrumb/Breadcrumb.cjs +4 -4
- package/dist/cjs/components/navigation/Drawer/Drawer.cjs +18 -18
- package/dist/cjs/components/navigation/Menu/MenuHeading.cjs +1 -1
- package/dist/cjs/components/navigation/Menu/MenuItem.cjs +1 -1
- package/dist/cjs/components/navigation/PrimaryNavigation/PrimaryNavigation.cjs +3 -3
- package/dist/cjs/components/surfaces/Accordion/Accordion.cjs +1 -1
- package/dist/cjs/components/surfaces/AccordionLegacy/Accordion.cjs +5 -5
- package/dist/cjs/index.cjs +2 -1
- package/dist/cjs/node_modules/.pnpm/@mui_base@5.0.0-beta.40-1_@types_react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@mui/base/useSlider/useSlider.cjs +1 -1
- package/dist/cjs/node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/MenuItem/MenuItem.cjs +1 -1
- package/dist/cjs/node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/Modal/Modal.cjs +1 -1
- package/dist/cjs/node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/className/index.cjs +1 -1
- package/dist/esm/components/data-display/ChipIcon/ChipIcon.js +1 -1
- package/dist/esm/components/data-display/Heading/Heading.js +1 -1
- package/dist/esm/components/data-display/Icon/Icon.js +4 -4
- package/dist/esm/components/data-display/ReadMore/ReadMore.js +1 -1
- package/dist/esm/components/data-display/StatusIcon/StatusIcon.js +5 -5
- package/dist/esm/components/data-display/Table/FilterChipsSection.js +1 -1
- package/dist/esm/components/data-display/Table/StickyHorizontalScrollbar.js +1 -1
- package/dist/esm/components/data-display/Table/Table.js +4 -4
- package/dist/esm/components/data-display/Table/Table.styles.js +1 -1
- package/dist/esm/components/data-display/Table/TableBody.js +1 -1
- package/dist/esm/components/data-display/Table/TableToolbar.js +1 -1
- package/dist/esm/components/data-display/Table/filters/FilterComponents.js +10 -10
- package/dist/esm/components/data-display/TextBlock/TextBlock.js +4 -4
- package/dist/esm/components/data-display/Tooltip/Tooltip.js +3 -3
- package/dist/esm/components/feedback/LoadingSpinner/LoadingSpinner.js +5 -5
- package/dist/esm/components/feedback/ProgressBar/ProgressBar.js +3 -3
- package/dist/esm/components/feedback/ToastMessages/ToastMessages.js +1 -1
- package/dist/esm/components/global/AppBar/AppBar.js +1 -1
- package/dist/esm/components/global/AppBar/NavigationProgress.js +1 -1
- package/dist/esm/components/global/ErrorFallback/FullPageErrorFallback.js +1 -1
- package/dist/esm/components/global/Footer/Footer.js +1 -1
- package/dist/esm/components/global/Layout/Layout.js +1 -1
- package/dist/esm/components/global/Logo/Logo.js +9 -9
- package/dist/esm/components/global/Logo/LogoMini.js +7 -7
- package/dist/esm/components/inputs/Autocomplete/AutocompleteSelectMultiple/AutocompleteSelectMultiple.js +1 -1
- package/dist/esm/components/inputs/DatePicker/DatePicker.js +1 -1
- package/dist/esm/components/inputs/DateTimeInput/DateTimeInput.js +1 -1
- package/dist/esm/components/inputs/Input/Input.js +1 -1
- package/dist/esm/components/navigation/Breadcrumb/Breadcrumb.js +1 -1
- package/dist/esm/components/navigation/Drawer/Drawer.js +16 -16
- package/dist/esm/components/navigation/Menu/MenuHeading.js +1 -1
- package/dist/esm/components/navigation/Menu/MenuItem.js +1 -1
- package/dist/esm/components/navigation/PrimaryNavigation/PrimaryNavigation.js +27 -27
- package/dist/esm/components/surfaces/Accordion/Accordion.js +3 -3
- package/dist/esm/components/surfaces/AccordionLegacy/Accordion.js +1 -1
- package/dist/esm/contexts/NavigationProgressContext.js +5 -5
- package/dist/esm/index.js +196 -194
- package/dist/esm/node_modules/.pnpm/@mui_base@5.0.0-beta.40-1_@types_react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@mui/base/useSlider/useSlider.js +4 -4
- package/dist/esm/node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/Autocomplete/Autocomplete.js +1 -1
- package/dist/esm/node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/MenuItem/MenuItem.js +12 -12
- package/dist/esm/node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/Modal/Modal.js +1 -1
- package/dist/esm/node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/Switch/switchClasses.js +3 -3
- package/dist/esm/node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/className/index.js +3 -3
- package/package.json +10 -3
- package/dist/cjs/assets/harpercollins-design-system.css +0 -1
- package/dist/cjs/node_modules/.pnpm/styled-components@6.4.1_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/styled-components/dist/styled-components.browser.esm.cjs +0 -82
- package/dist/cjs/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Enum.cjs +0 -1
- package/dist/cjs/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Middleware.cjs +0 -1
- package/dist/cjs/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Parser.cjs +0 -1
- package/dist/cjs/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Prefixer.cjs +0 -1
- package/dist/cjs/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Serializer.cjs +0 -1
- package/dist/cjs/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Tokenizer.cjs +0 -1
- package/dist/cjs/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Utility.cjs +0 -1
- package/dist/esm/assets/harpercollins-design-system.css +0 -1
- package/dist/esm/node_modules/.pnpm/styled-components@6.4.1_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/styled-components/dist/styled-components.browser.esm.js +0 -721
- package/dist/esm/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Enum.js +0 -13
- package/dist/esm/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Middleware.js +0 -49
- package/dist/esm/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Parser.js +0 -136
- package/dist/esm/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Prefixer.js +0 -189
- package/dist/esm/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Serializer.js +0 -28
- package/dist/esm/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Tokenizer.js +0 -147
- package/dist/esm/node_modules/.pnpm/stylis@4.3.6/node_modules/stylis/src/Utility.js +0 -56
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as s, Fragment as g, jsx as l } from "react/jsx-runtime";
|
|
2
2
|
import h, { createElement as y } from "react";
|
|
3
|
-
import b from "
|
|
3
|
+
import b from "styled-components";
|
|
4
4
|
import { faTimes as A, faXmark as k } from "../../../../node_modules/.pnpm/@fortawesome_free-solid-svg-icons@6.7.2/node_modules/@fortawesome/free-solid-svg-icons/index.js";
|
|
5
5
|
import p from "../../../data-display/Icon/Icon.js";
|
|
6
6
|
import x from "../../../data-display/List/List.js";
|
|
@@ -2,7 +2,7 @@ import { jsx as a } from "react/jsx-runtime";
|
|
|
2
2
|
import l, { useState as p } from "react";
|
|
3
3
|
import s from "../../../node_modules/.pnpm/react-datepicker@6.9.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-datepicker/dist/es/index.js";
|
|
4
4
|
/* empty css */
|
|
5
|
-
import _ from "
|
|
5
|
+
import _ from "styled-components";
|
|
6
6
|
const g = _.div`
|
|
7
7
|
.react-datepicker-wrapper {
|
|
8
8
|
width: 100%;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsxs as a, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { faClock as M } from "../../../node_modules/.pnpm/@fortawesome_free-regular-svg-icons@6.7.2/node_modules/@fortawesome/free-regular-svg-icons/index.js";
|
|
3
3
|
import F from "react";
|
|
4
|
-
import g from "
|
|
4
|
+
import g from "styled-components";
|
|
5
5
|
import T from "../../data-display/Icon/Icon.js";
|
|
6
6
|
import Y from "../Button/Button.js";
|
|
7
7
|
import m from "../Input/Input.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import n from "
|
|
2
|
+
import n from "styled-components";
|
|
3
3
|
import p from "../../../node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/Input/Input.js";
|
|
4
4
|
const s = n(p)`
|
|
5
5
|
--Input-minHeight: 2.6rem;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import r from "
|
|
2
|
+
import r from "styled-components";
|
|
3
3
|
const t = r.div`
|
|
4
4
|
display: flex;
|
|
5
5
|
flex-flow: wrap;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as o, jsxs as s } from "react/jsx-runtime";
|
|
2
|
-
import h, { forwardRef as b, useRef as u, useEffect as
|
|
3
|
-
import r, { keyframes as e } from "
|
|
2
|
+
import h, { forwardRef as b, useRef as u, useEffect as d } from "react";
|
|
3
|
+
import r, { keyframes as e } from "styled-components";
|
|
4
4
|
import { faExclamationTriangle as z, faClose as C } from "../../../node_modules/.pnpm/@fortawesome_free-solid-svg-icons@6.7.2/node_modules/@fortawesome/free-solid-svg-icons/index.js";
|
|
5
5
|
import v from "../../data-display/Icon/Icon.js";
|
|
6
6
|
import D from "../../../node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/Drawer/Drawer.js";
|
|
@@ -14,7 +14,7 @@ const R = r.div`
|
|
|
14
14
|
font-weight: 600;
|
|
15
15
|
color: var(--color--grey-dark);
|
|
16
16
|
}
|
|
17
|
-
`,
|
|
17
|
+
`, j = e`
|
|
18
18
|
from {
|
|
19
19
|
transform: translate(-100%, 0);
|
|
20
20
|
}
|
|
@@ -22,7 +22,7 @@ const R = r.div`
|
|
|
22
22
|
to {
|
|
23
23
|
transform: none;
|
|
24
24
|
}
|
|
25
|
-
`,
|
|
25
|
+
`, M = e`
|
|
26
26
|
from {
|
|
27
27
|
transform: none;
|
|
28
28
|
}
|
|
@@ -30,7 +30,7 @@ const R = r.div`
|
|
|
30
30
|
to {
|
|
31
31
|
transform: translate(-100%, 0);
|
|
32
32
|
}
|
|
33
|
-
`,
|
|
33
|
+
`, O = e`
|
|
34
34
|
from {
|
|
35
35
|
transform: translate(100%, 0);
|
|
36
36
|
}
|
|
@@ -72,16 +72,16 @@ const R = r.div`
|
|
|
72
72
|
overflow: hidden;
|
|
73
73
|
|
|
74
74
|
&.left {
|
|
75
|
-
animation: ${
|
|
75
|
+
animation: ${j} 0.2s ease;
|
|
76
76
|
}
|
|
77
77
|
|
|
78
78
|
&.left.closing {
|
|
79
|
-
animation: ${
|
|
79
|
+
animation: ${M} 0.2s ease;
|
|
80
80
|
transform: translate(-100%, 0);
|
|
81
81
|
}
|
|
82
82
|
|
|
83
83
|
&.right {
|
|
84
|
-
animation: ${
|
|
84
|
+
animation: ${O} 0.2s ease;
|
|
85
85
|
}
|
|
86
86
|
|
|
87
87
|
&.right.closing {
|
|
@@ -177,7 +177,7 @@ let l = 1;
|
|
|
177
177
|
const ro = b(
|
|
178
178
|
({
|
|
179
179
|
children: w,
|
|
180
|
-
side:
|
|
180
|
+
side: m,
|
|
181
181
|
size: x = "md",
|
|
182
182
|
open: n = !1,
|
|
183
183
|
closeBlocked: y,
|
|
@@ -185,7 +185,7 @@ const ro = b(
|
|
|
185
185
|
},
|
|
186
186
|
onCloseCompleted: $ = () => {
|
|
187
187
|
},
|
|
188
|
-
closeRequested:
|
|
188
|
+
closeRequested: c = !1,
|
|
189
189
|
showCloseButton: B = !1,
|
|
190
190
|
...k
|
|
191
191
|
}, W) => {
|
|
@@ -201,11 +201,11 @@ const ro = b(
|
|
|
201
201
|
}
|
|
202
202
|
return () => {
|
|
203
203
|
};
|
|
204
|
-
}),
|
|
205
|
-
|
|
206
|
-
}, [
|
|
204
|
+
}), d(() => {
|
|
205
|
+
c && I(!0);
|
|
206
|
+
}, [c]), a.current || (a.current = `modal-${l}`, l += 1), d(() => {
|
|
207
207
|
document.body.style.overflow = n ? "hidden" : "auto";
|
|
208
|
-
}, [n]),
|
|
208
|
+
}, [n]), d(() => {
|
|
209
209
|
const i = (p) => {
|
|
210
210
|
p.key === "Escape" && (p.preventDefault(), f());
|
|
211
211
|
};
|
|
@@ -216,8 +216,8 @@ const ro = b(
|
|
|
216
216
|
D,
|
|
217
217
|
{
|
|
218
218
|
open: n && !g,
|
|
219
|
-
anchor:
|
|
220
|
-
className: `${
|
|
219
|
+
anchor: m,
|
|
220
|
+
className: `${m} ${n ? "open" : "closing"}`,
|
|
221
221
|
size: x,
|
|
222
222
|
...k,
|
|
223
223
|
children: /* @__PURE__ */ o(S, { children: /* @__PURE__ */ s(P, { ref: E, children: [
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import t from "
|
|
1
|
+
import t from "styled-components";
|
|
2
2
|
import e from "../../../node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/ListItem/ListItem.js";
|
|
3
3
|
const a = t(e)`
|
|
4
4
|
text-transform: uppercase;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import t from "
|
|
1
|
+
import t from "styled-components";
|
|
2
2
|
import e from "../../../node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/MenuItem/MenuItem.js";
|
|
3
3
|
const o = t(e)`
|
|
4
4
|
a,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as i, jsxs as g } from "react/jsx-runtime";
|
|
2
2
|
import { faChevronUp as A } from "../../../node_modules/.pnpm/@fortawesome_free-solid-svg-icons@6.7.2/node_modules/@fortawesome/free-solid-svg-icons/index.js";
|
|
3
3
|
import { useState as w } from "react";
|
|
4
|
-
import y from "
|
|
4
|
+
import y from "styled-components";
|
|
5
5
|
import L from "../../data-display/Icon/Icon.js";
|
|
6
6
|
import I from "../../../node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/List/List.js";
|
|
7
7
|
import S from "../../../node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/ListItem/ListItem.js";
|
|
@@ -9,60 +9,60 @@ import $ from "../../../node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react
|
|
|
9
9
|
import P from "../../../node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/ListItemDecorator/ListItemDecorator.js";
|
|
10
10
|
import z from "../../../node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/ListItemContent/ListItemContent.js";
|
|
11
11
|
const E = y(L)`
|
|
12
|
-
color: ${({ $active:
|
|
12
|
+
color: ${({ $active: o }) => o ? "var(--palette-primary-500)" : "inherit"};
|
|
13
13
|
`, N = y(L)`
|
|
14
14
|
transition: transform 0.2s ease;
|
|
15
|
-
transform: ${({ $expanded:
|
|
15
|
+
transform: ${({ $expanded: o }) => o ? "rotate(0deg)" : "rotate(180deg)"};
|
|
16
16
|
font-size: 0.75rem;
|
|
17
17
|
flex-shrink: 0;
|
|
18
18
|
margin-left: auto;
|
|
19
19
|
opacity: 0.6;
|
|
20
20
|
`;
|
|
21
|
-
function u(
|
|
22
|
-
return
|
|
21
|
+
function u(o) {
|
|
22
|
+
return o.isActive ? !0 : o.children?.some((t) => u(t)) ?? !1;
|
|
23
23
|
}
|
|
24
|
-
function D(
|
|
24
|
+
function D(o) {
|
|
25
25
|
const t = /* @__PURE__ */ new Set(), c = (l, s) => {
|
|
26
26
|
l.forEach((r) => {
|
|
27
27
|
u(r) && s.length > 0 && s.forEach((d) => t.add(d)), r.children && c(r.children, [...s, r.id]);
|
|
28
28
|
});
|
|
29
29
|
};
|
|
30
|
-
return c(
|
|
30
|
+
return c(o, []), t;
|
|
31
31
|
}
|
|
32
32
|
function J({
|
|
33
|
-
items:
|
|
33
|
+
items: o,
|
|
34
34
|
sidebarOpen: t = !0,
|
|
35
35
|
onSidebarToggle: c,
|
|
36
36
|
linkComponent: l = "a"
|
|
37
37
|
}) {
|
|
38
38
|
const [s, r] = w(
|
|
39
|
-
() => D(
|
|
40
|
-
), d = (
|
|
39
|
+
() => D(o)
|
|
40
|
+
), d = (e) => {
|
|
41
41
|
r((a) => {
|
|
42
42
|
const n = new Set(a);
|
|
43
|
-
return n.has(
|
|
43
|
+
return n.has(e) ? n.delete(e) : n.add(e), n;
|
|
44
44
|
});
|
|
45
|
-
}, x = (
|
|
46
|
-
if (!
|
|
47
|
-
const n = !!
|
|
48
|
-
n && (m.preventDefault(), t ? d(
|
|
49
|
-
}, C = !n &&
|
|
45
|
+
}, x = (e, a = 0) => {
|
|
46
|
+
if (!e.show) return null;
|
|
47
|
+
const n = !!e.children?.length, p = s.has(e.id), f = u(e), v = `nav-children-${e.id}`, h = a > 0, b = (m) => {
|
|
48
|
+
n && (m.preventDefault(), t ? d(e.id) : (c?.(), r((k) => /* @__PURE__ */ new Set([...k, e.id]))));
|
|
49
|
+
}, C = !n && e.href ? { component: l, href: e.href, onClick: e.onClick } : { component: "button", onClick: b };
|
|
50
50
|
return /* @__PURE__ */ g(S, { nested: n, children: [
|
|
51
51
|
/* @__PURE__ */ g(
|
|
52
52
|
$,
|
|
53
53
|
{
|
|
54
54
|
...C,
|
|
55
55
|
...n ? { "aria-expanded": p, "aria-controls": v } : {},
|
|
56
|
-
"aria-current":
|
|
57
|
-
"aria-label": t ? void 0 :
|
|
56
|
+
"aria-current": e.isActive ? "page" : void 0,
|
|
57
|
+
"aria-label": t ? void 0 : e.label,
|
|
58
58
|
sx: {
|
|
59
59
|
gap: 1,
|
|
60
60
|
fontSize: h ? `${Math.max(0.75, 0.875 - (a - 1) * 0.0625)}rem` : void 0,
|
|
61
61
|
color: f ? "var(--palette-primary-500)" : "inherit",
|
|
62
|
-
backgroundColor:
|
|
63
|
-
borderLeft:
|
|
62
|
+
backgroundColor: e.isActive ? "background.body" : "inherit",
|
|
63
|
+
borderLeft: e.isActive ? "2px solid var(--palette-primary-500)" : "2px solid transparent",
|
|
64
64
|
// eslint-disable-next-line no-nested-ternary
|
|
65
|
-
fontWeight:
|
|
65
|
+
fontWeight: e.isActive ? 600 : h ? 400 : 500,
|
|
66
66
|
opacity: h && !f ? 0.85 : 1,
|
|
67
67
|
"&:hover": {
|
|
68
68
|
textDecoration: "none",
|
|
@@ -74,7 +74,7 @@ function J({
|
|
|
74
74
|
transition: "color 0.15s ease, background-color 0.15s ease, opacity 0.15s ease, border-width 0.15s ease"
|
|
75
75
|
},
|
|
76
76
|
children: [
|
|
77
|
-
|
|
77
|
+
e.icon && /* @__PURE__ */ i(P, { sx: { minInlineSize: "auto", minWidth: 24 }, children: /* @__PURE__ */ i(E, { icon: e.icon, $active: f }) }),
|
|
78
78
|
/* @__PURE__ */ i(
|
|
79
79
|
z,
|
|
80
80
|
{
|
|
@@ -84,7 +84,7 @@ function J({
|
|
|
84
84
|
transition: "opacity 0.15s ease",
|
|
85
85
|
whiteSpace: "nowrap"
|
|
86
86
|
},
|
|
87
|
-
children:
|
|
87
|
+
children: e.label
|
|
88
88
|
}
|
|
89
89
|
),
|
|
90
90
|
n && t && /* @__PURE__ */ i(N, { icon: A, $expanded: p, size: "sm" })
|
|
@@ -95,7 +95,7 @@ function J({
|
|
|
95
95
|
I,
|
|
96
96
|
{
|
|
97
97
|
id: v,
|
|
98
|
-
"aria-label": `${
|
|
98
|
+
"aria-label": `${e.label} submenu`,
|
|
99
99
|
sx: {
|
|
100
100
|
pl: 2,
|
|
101
101
|
display: t && p ? "flex" : "none",
|
|
@@ -103,17 +103,17 @@ function J({
|
|
|
103
103
|
"--List-gap": "2px",
|
|
104
104
|
"--ListItem-radius": "8px"
|
|
105
105
|
},
|
|
106
|
-
children:
|
|
106
|
+
children: e.children?.map((m) => x(m, a + 1))
|
|
107
107
|
}
|
|
108
108
|
)
|
|
109
|
-
] },
|
|
109
|
+
] }, e.id);
|
|
110
110
|
};
|
|
111
111
|
return /* @__PURE__ */ i("nav", { "aria-label": "Primary Navigation", children: /* @__PURE__ */ i(
|
|
112
112
|
I,
|
|
113
113
|
{
|
|
114
114
|
size: "sm",
|
|
115
115
|
sx: { "--ListItem-radius": "8px", "--List-gap": "4px", p: 1 },
|
|
116
|
-
children:
|
|
116
|
+
children: o.map((e) => x(e))
|
|
117
117
|
}
|
|
118
118
|
) });
|
|
119
119
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import t from "
|
|
2
|
+
import t from "styled-components";
|
|
3
3
|
import c from "../../../node_modules/.pnpm/@mui_joy@5.0.0-beta.52_@emotion_react@11.14.0_@types_react@18.3.28_react@18.3.1__@emoti_58201694b486b0db36cbf79098c4edaa/node_modules/@mui/joy/Accordion/Accordion.js";
|
|
4
4
|
const i = t(c)``;
|
|
5
|
-
function
|
|
5
|
+
function e(o) {
|
|
6
6
|
return /* @__PURE__ */ r(i, { sx: {}, ...o });
|
|
7
7
|
}
|
|
8
8
|
export {
|
|
9
|
-
|
|
9
|
+
e as default
|
|
10
10
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsxs as a, jsx as t } from "react/jsx-runtime";
|
|
2
2
|
import { faChevronUp as l } from "../../../node_modules/.pnpm/@fortawesome_free-solid-svg-icons@6.7.2/node_modules/@fortawesome/free-solid-svg-icons/index.js";
|
|
3
3
|
import { useState as m, useRef as u, useEffect as p } from "react";
|
|
4
|
-
import n from "
|
|
4
|
+
import n from "styled-components";
|
|
5
5
|
import f from "../../data-display/Heading/Heading.js";
|
|
6
6
|
import g from "../../data-display/Icon/Icon.js";
|
|
7
7
|
const h = n.div`
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { jsx as p } from "react/jsx-runtime";
|
|
2
|
-
import x, {
|
|
2
|
+
import x, { useState as N, useRef as f, useCallback as s, useEffect as T, useContext as S, createContext as C } from "react";
|
|
3
3
|
const d = {
|
|
4
4
|
showProgress: !1,
|
|
5
5
|
completing: !1,
|
|
6
6
|
width: 0
|
|
7
|
-
}, h =
|
|
7
|
+
}, h = C(void 0);
|
|
8
8
|
function M({
|
|
9
9
|
children: i
|
|
10
10
|
}) {
|
|
11
|
-
const [r, c] =
|
|
11
|
+
const [r, c] = N(d), t = f({}), a = f(!1), o = s(() => {
|
|
12
12
|
Object.values(t.current).forEach((e) => {
|
|
13
13
|
e && clearTimeout(e);
|
|
14
14
|
}), t.current = {};
|
|
@@ -43,7 +43,7 @@ function M({
|
|
|
43
43
|
l
|
|
44
44
|
]
|
|
45
45
|
);
|
|
46
|
-
|
|
46
|
+
T(() => o, [o]);
|
|
47
47
|
const w = x.useMemo(
|
|
48
48
|
() => ({ progressState: r, setNavigating: m }),
|
|
49
49
|
[r, m]
|
|
@@ -51,7 +51,7 @@ function M({
|
|
|
51
51
|
return /* @__PURE__ */ p(h.Provider, { value: w, children: i });
|
|
52
52
|
}
|
|
53
53
|
const j = () => {
|
|
54
|
-
const i =
|
|
54
|
+
const i = S(h);
|
|
55
55
|
if (!i)
|
|
56
56
|
throw new Error(
|
|
57
57
|
"useNavigationProgress must be used within a NavigationProgressProvider"
|