@caseparts-org/caseblocks 0.0.297 → 0.0.299
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/Cart.module-DTLrsJdk.js +40 -0
- package/dist/assets/AddToCartPart.css +1 -1
- package/dist/assets/Cart.css +1 -1
- package/dist/assets/MainNav.css +1 -1
- package/dist/molecules/AddToCartPart/AddToCartPart.d.ts +5 -2
- package/dist/molecules/AddToCartPart/AddToCartPart.js +90 -86
- package/dist/molecules/AddToCartPart/AddToCartPart.stories.d.ts +2 -2
- package/dist/molecules/AddToCartPart/AddToCartPart.stories.js +5 -2
- package/dist/molecules/Cart/Cart.d.ts +1 -0
- package/dist/molecules/Cart/Cart.js +35 -29
- package/dist/molecules/Cart/CartPart.js +1 -1
- package/dist/molecules/Cart/CartSlideInPanel.js +1 -1
- package/dist/organisms/MainNav/MainNav.d.ts +4 -0
- package/dist/organisms/MainNav/MainNav.js +212 -189
- package/dist/organisms/MainNav/MainNav.stories.js +140 -87
- package/package.json +1 -1
- package/dist/Cart.module-CG06lLyg.js +0 -38
|
@@ -1,153 +1,162 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as m, Fragment as O, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import s from "react";
|
|
3
|
-
import { r as
|
|
3
|
+
import { r as kt } from "../../index-BkF-BQ3Q.js";
|
|
4
4
|
import { Text as U } from "../../atoms/Text/Text.js";
|
|
5
|
-
import { Link as
|
|
5
|
+
import { Link as j } from "../../atoms/Link/Link.js";
|
|
6
6
|
import { Icon as u } from "../../atoms/Icon/Icon.js";
|
|
7
|
-
import { Flex as
|
|
8
|
-
import { Grid as
|
|
9
|
-
import { Input as
|
|
7
|
+
import { Flex as H } from "../../atoms/Flex/Flex.js";
|
|
8
|
+
import { Grid as yt, Column as vt } from "../../atoms/Grid/Grid.js";
|
|
9
|
+
import { Input as C } from "../../atoms/Input/Input.js";
|
|
10
10
|
import { InputEndAdornmentButton as $ } from "../../atoms/InputEndAdornmentButton/InputEndAdornmentButton.js";
|
|
11
|
-
import { Logo as
|
|
12
|
-
import { HamburgerMenu as
|
|
13
|
-
import { ShoppingCart as
|
|
14
|
-
import { Account as
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
11
|
+
import { Logo as ut } from "../../molecules/Logo/Logo.js";
|
|
12
|
+
import { HamburgerMenu as Nt } from "../../molecules/HamburgerMenu/HamburgerMenu.js";
|
|
13
|
+
import { ShoppingCart as pt } from "../../molecules/Cart/Cart.js";
|
|
14
|
+
import { Account as wt } from "../../molecules/Account/Account.js";
|
|
15
|
+
import { Popover as At } from "../../atoms/Popover/Popover.js";
|
|
16
|
+
import { CategoryNav as bt } from "../../molecules/CategoryNav/CategoryNav.js";
|
|
17
|
+
import { SuggestionDropdown as g } from "../SuggestionDropdown/SuggestionDropdown.js";
|
|
18
|
+
import { getHideAtStyles as V } from "../../atoms/HideAt.js";
|
|
19
|
+
import { c as _ } from "../../clsx-OuTLNxxd.js";
|
|
20
|
+
import '../../assets/MainNav.css';const Lt = "_main_1sd1k_1", xt = "_column_1sd1k_8", Kt = "_topNav_1sd1k_13", Dt = "_logo_1sd1k_21", zt = "_operations_1sd1k_24", Bt = "_search_1sd1k_31", Et = "_mobileSearch_1sd1k_37", Ht = "_typeAheadPortal_1sd1k_40", $t = "_siteLink_1sd1k_47", Ft = "_accountArea_1sd1k_74", Rt = "_cartArea_1sd1k_88", Mt = "_cartPopover_1sd1k_94", Ot = "_cartPopoverHidden_1sd1k_105", Ut = "_cartPopoverContent_1sd1k_109", jt = "_category_1sd1k_114", It = "_categoryLink_1sd1k_122", Tt = "_menuList_1sd1k_138", Pt = "_menuItemAction_1sd1k_161", qt = "_shortcutIcon_1sd1k_170", i = {
|
|
21
|
+
main: Lt,
|
|
22
|
+
column: xt,
|
|
23
|
+
topNav: Kt,
|
|
24
|
+
logo: Dt,
|
|
25
|
+
operations: zt,
|
|
26
|
+
search: Bt,
|
|
27
|
+
mobileSearch: Et,
|
|
28
|
+
typeAheadPortal: Ht,
|
|
29
|
+
siteLink: $t,
|
|
30
|
+
accountArea: Ft,
|
|
31
|
+
cartArea: Rt,
|
|
32
|
+
cartPopover: Mt,
|
|
33
|
+
cartPopoverHidden: Ot,
|
|
34
|
+
cartPopoverContent: Ut,
|
|
35
|
+
category: jt,
|
|
36
|
+
categoryLink: It,
|
|
37
|
+
menuList: Tt,
|
|
38
|
+
menuItemAction: Pt,
|
|
39
|
+
shortcutIcon: qt
|
|
40
|
+
}, de = s.forwardRef(function({
|
|
36
41
|
account: F,
|
|
37
|
-
categories:
|
|
38
|
-
homeRoute:
|
|
39
|
-
faqRoute:
|
|
40
|
-
customPartsRoute:
|
|
41
|
-
aboutUsRoute:
|
|
42
|
-
contactRoute:
|
|
43
|
-
cart:
|
|
44
|
-
open:
|
|
42
|
+
categories: b,
|
|
43
|
+
homeRoute: h,
|
|
44
|
+
faqRoute: S,
|
|
45
|
+
customPartsRoute: T,
|
|
46
|
+
aboutUsRoute: tt,
|
|
47
|
+
contactRoute: P,
|
|
48
|
+
cart: et,
|
|
49
|
+
open: it,
|
|
45
50
|
// consume external panel control props from CartPropsBase
|
|
46
|
-
className:
|
|
47
|
-
onLoginClick:
|
|
48
|
-
searchInputProps:
|
|
49
|
-
searchValue:
|
|
51
|
+
className: ot,
|
|
52
|
+
onLoginClick: nt,
|
|
53
|
+
searchInputProps: l,
|
|
54
|
+
searchValue: c,
|
|
50
55
|
onSearchValueChange: d,
|
|
51
|
-
onClearSearch:
|
|
52
|
-
onSearch:
|
|
56
|
+
onClearSearch: N,
|
|
57
|
+
onSearch: f,
|
|
53
58
|
searchSuggestions: o,
|
|
54
|
-
recentSearches:
|
|
55
|
-
onClearRecentSearch:
|
|
56
|
-
onCategoryClick:
|
|
59
|
+
recentSearches: k,
|
|
60
|
+
onClearRecentSearch: lt,
|
|
61
|
+
onCategoryClick: D,
|
|
57
62
|
onClickModelSerial: q,
|
|
58
63
|
onCartClick: mt,
|
|
59
|
-
accountPopoverContent:
|
|
60
|
-
isAccountLoading:
|
|
61
|
-
isCategoriesLoading:
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
64
|
+
accountPopoverContent: dt,
|
|
65
|
+
isAccountLoading: rt,
|
|
66
|
+
isCategoriesLoading: ct,
|
|
67
|
+
cartConfirmation: G,
|
|
68
|
+
cartConfirmationVisible: at,
|
|
69
|
+
onCartConfirmationDismiss: R,
|
|
70
|
+
cartConfirmationKey: ft,
|
|
71
|
+
...st
|
|
72
|
+
}, _t) {
|
|
73
|
+
var Z;
|
|
74
|
+
const [Q, M] = s.useState(!1), [r, y] = s.useState(-1), [W, J] = s.useState(), p = s.useRef(null), z = s.useRef(null), v = s.useId(), B = () => {
|
|
66
75
|
var t;
|
|
67
|
-
return (t =
|
|
68
|
-
},
|
|
76
|
+
return (t = p.current) != null && t.offsetParent ? p.current : z.current;
|
|
77
|
+
}, w = Q && !!c && !!o, E = Q && !w && !!(k != null && k.length), L = w ? ((o == null ? void 0 : o.terms.length) ?? 0) + ((o == null ? void 0 : o.categories.length) ?? 0) + (((Z = o == null ? void 0 : o.customParts) == null ? void 0 : Z.length) ?? 0) + ((o == null ? void 0 : o.items.length) ?? 0) : E ? (k == null ? void 0 : k.length) ?? 0 : 0;
|
|
69
78
|
s.useLayoutEffect(() => {
|
|
70
|
-
if (!
|
|
71
|
-
|
|
79
|
+
if (!w && !E) {
|
|
80
|
+
J(void 0);
|
|
72
81
|
return;
|
|
73
82
|
}
|
|
74
83
|
function t() {
|
|
75
84
|
var x;
|
|
76
|
-
const
|
|
77
|
-
if (!
|
|
78
|
-
const
|
|
79
|
-
|
|
80
|
-
top:
|
|
81
|
-
left:
|
|
82
|
-
width:
|
|
83
|
-
maxHeight: Math.max(0, window.innerHeight -
|
|
85
|
+
const n = (x = p.current) != null && x.offsetParent ? p.current : z.current;
|
|
86
|
+
if (!n) return;
|
|
87
|
+
const a = n.getBoundingClientRect();
|
|
88
|
+
J({
|
|
89
|
+
top: a.bottom + 4,
|
|
90
|
+
left: a.left,
|
|
91
|
+
width: a.width,
|
|
92
|
+
maxHeight: Math.max(0, window.innerHeight - a.bottom - 12)
|
|
84
93
|
});
|
|
85
94
|
}
|
|
86
95
|
return t(), window.addEventListener("resize", t), window.addEventListener("scroll", t, !0), () => {
|
|
87
96
|
window.removeEventListener("resize", t), window.removeEventListener("scroll", t, !0);
|
|
88
97
|
};
|
|
89
|
-
}, [
|
|
90
|
-
const
|
|
91
|
-
...
|
|
98
|
+
}, [w, E]);
|
|
99
|
+
const X = {
|
|
100
|
+
...l,
|
|
92
101
|
onChange: (t) => {
|
|
93
|
-
var
|
|
94
|
-
|
|
102
|
+
var n;
|
|
103
|
+
y(-1), (n = l == null ? void 0 : l.onChange) == null || n.call(l, t);
|
|
95
104
|
},
|
|
96
105
|
onFocus: (t) => {
|
|
97
|
-
var
|
|
98
|
-
(
|
|
106
|
+
var n;
|
|
107
|
+
(n = l == null ? void 0 : l.onFocus) == null || n.call(l, t), M(!0);
|
|
99
108
|
},
|
|
100
109
|
onBlur: (t) => {
|
|
101
|
-
var
|
|
102
|
-
(
|
|
110
|
+
var n;
|
|
111
|
+
(n = l == null ? void 0 : l.onBlur) == null || n.call(l, t), M(!1);
|
|
103
112
|
},
|
|
104
113
|
onKeyDown: (t) => {
|
|
105
|
-
var
|
|
106
|
-
if ((
|
|
107
|
-
if (t.key === "ArrowDown" &&
|
|
108
|
-
t.preventDefault(),
|
|
114
|
+
var n, a, x;
|
|
115
|
+
if ((n = l == null ? void 0 : l.onKeyDown) == null || n.call(l, t), !t.defaultPrevented) {
|
|
116
|
+
if (t.key === "ArrowDown" && L > 0) {
|
|
117
|
+
t.preventDefault(), y((K) => K >= L - 1 ? 0 : K + 1);
|
|
109
118
|
return;
|
|
110
119
|
}
|
|
111
|
-
if (t.key === "ArrowUp" &&
|
|
112
|
-
t.preventDefault(),
|
|
120
|
+
if (t.key === "ArrowUp" && L > 0) {
|
|
121
|
+
t.preventDefault(), y((K) => K <= 0 ? L - 1 : K - 1);
|
|
113
122
|
return;
|
|
114
123
|
}
|
|
115
|
-
if (t.key === "Tab" &&
|
|
116
|
-
t.preventDefault(), d == null || d((o == null ? void 0 : o.terms[r].name) ?? ""),
|
|
124
|
+
if (t.key === "Tab" && w && r >= 0 && r < ((o == null ? void 0 : o.terms.length) ?? 0)) {
|
|
125
|
+
t.preventDefault(), d == null || d((o == null ? void 0 : o.terms[r].name) ?? ""), y(-1);
|
|
117
126
|
return;
|
|
118
127
|
}
|
|
119
|
-
if (t.key === "Enter" && r >= 0 && r <
|
|
120
|
-
t.preventDefault(), (
|
|
128
|
+
if (t.key === "Enter" && r >= 0 && r < L) {
|
|
129
|
+
t.preventDefault(), (a = document.getElementById(`${v}-${r}`)) == null || a.click();
|
|
121
130
|
return;
|
|
122
131
|
}
|
|
123
|
-
t.key === "Enter" && (t.preventDefault(),
|
|
132
|
+
t.key === "Enter" && (t.preventDefault(), M(!1), (x = B()) == null || x.blur(), f == null || f(c ?? ""));
|
|
124
133
|
}
|
|
125
134
|
}
|
|
126
|
-
},
|
|
127
|
-
var
|
|
128
|
-
t.key.length !== 1 || t.altKey || t.ctrlKey || t.metaKey || (t.preventDefault(),
|
|
135
|
+
}, Y = (t) => {
|
|
136
|
+
var n;
|
|
137
|
+
t.key.length !== 1 || t.altKey || t.ctrlKey || t.metaKey || (t.preventDefault(), y(-1), d == null || d(`${c ?? ""}${t.key}`), (n = B()) == null || n.focus());
|
|
129
138
|
};
|
|
130
|
-
return /* @__PURE__ */
|
|
131
|
-
/* @__PURE__ */
|
|
132
|
-
/* @__PURE__ */
|
|
133
|
-
|
|
139
|
+
return /* @__PURE__ */ m(O, { children: [
|
|
140
|
+
/* @__PURE__ */ e(yt, { ...st, gridWrapperClassName: _(i.main, ot), children: /* @__PURE__ */ m(vt, { span: 12, className: i.column, children: [
|
|
141
|
+
/* @__PURE__ */ m(
|
|
142
|
+
H,
|
|
134
143
|
{
|
|
135
144
|
flexDirection: "row",
|
|
136
145
|
alignItems: "center",
|
|
137
146
|
justifyContent: "space-between",
|
|
138
|
-
className:
|
|
147
|
+
className: i.topNav,
|
|
139
148
|
children: [
|
|
140
|
-
/* @__PURE__ */
|
|
141
|
-
/* @__PURE__ */
|
|
142
|
-
|
|
149
|
+
/* @__PURE__ */ e("div", { className: i.logo, children: /* @__PURE__ */ e(j, { href: h, children: /* @__PURE__ */ e(ut, {}) }) }),
|
|
150
|
+
/* @__PURE__ */ m(
|
|
151
|
+
H,
|
|
143
152
|
{
|
|
144
153
|
flexDirection: "row",
|
|
145
154
|
alignItems: "center",
|
|
146
155
|
justifyContent: "flex-end",
|
|
147
|
-
className:
|
|
156
|
+
className: i.operations,
|
|
148
157
|
children: [
|
|
149
|
-
/* @__PURE__ */
|
|
150
|
-
|
|
158
|
+
/* @__PURE__ */ e(H, { flexDirection: "row", hideAt: ["sm"], className: i.search, children: /* @__PURE__ */ e(
|
|
159
|
+
C,
|
|
151
160
|
{
|
|
152
161
|
variant: "search",
|
|
153
162
|
label: "Search",
|
|
@@ -155,105 +164,119 @@ import '../../assets/MainNav.css';const kt = "_main_1w2jy_1", At = "_column_1w2j
|
|
|
155
164
|
name: "cpc-search",
|
|
156
165
|
autoComplete: "off",
|
|
157
166
|
"aria-autocomplete": "list",
|
|
158
|
-
"aria-controls":
|
|
159
|
-
"aria-activedescendant": r >= 0 ? `${
|
|
160
|
-
...
|
|
161
|
-
ref:
|
|
162
|
-
value:
|
|
163
|
-
endAdornment: /* @__PURE__ */
|
|
164
|
-
!!
|
|
167
|
+
"aria-controls": v,
|
|
168
|
+
"aria-activedescendant": r >= 0 ? `${v}-${r}` : void 0,
|
|
169
|
+
...X,
|
|
170
|
+
ref: p,
|
|
171
|
+
value: c,
|
|
172
|
+
endAdornment: /* @__PURE__ */ m(O, { children: [
|
|
173
|
+
!!c && /* @__PURE__ */ e(
|
|
165
174
|
$,
|
|
166
175
|
{
|
|
167
176
|
"aria-label": "Clear search",
|
|
168
177
|
onMouseDown: (t) => t.preventDefault(),
|
|
169
178
|
onClick: () => {
|
|
170
179
|
var t;
|
|
171
|
-
|
|
180
|
+
y(-1), N == null || N(), (t = p.current) == null || t.focus();
|
|
172
181
|
},
|
|
173
182
|
iconProps: { iconKey: "fa-regular fa-xmark", size: "sm" }
|
|
174
183
|
}
|
|
175
184
|
),
|
|
176
|
-
/* @__PURE__ */
|
|
185
|
+
/* @__PURE__ */ e(
|
|
177
186
|
$,
|
|
178
187
|
{
|
|
179
188
|
"aria-label": "Submit search",
|
|
180
|
-
onClick: () =>
|
|
189
|
+
onClick: () => f == null ? void 0 : f(c ?? ""),
|
|
181
190
|
iconProps: { iconKey: "fa-regular fa-magnifying-glass", size: "sm" }
|
|
182
191
|
}
|
|
183
192
|
)
|
|
184
193
|
] })
|
|
185
194
|
}
|
|
186
195
|
) }),
|
|
187
|
-
/* @__PURE__ */
|
|
188
|
-
/* @__PURE__ */
|
|
196
|
+
/* @__PURE__ */ m("button", { onClick: q, className: _(i.siteLink, V(["sm", "md"])), children: [
|
|
197
|
+
/* @__PURE__ */ e(u, { iconKey: "fa-regular fa-sparkles", size: "sm" }),
|
|
189
198
|
"Identify a Part"
|
|
190
199
|
] }),
|
|
191
|
-
/* @__PURE__ */
|
|
192
|
-
/* @__PURE__ */
|
|
193
|
-
/* @__PURE__ */
|
|
194
|
-
|
|
200
|
+
/* @__PURE__ */ e(A, { href: T, hideAt: ["sm", "md"], children: "Custom Parts" }),
|
|
201
|
+
/* @__PURE__ */ e(A, { href: P, hideAt: ["sm", "md"], children: "Contact Us" }),
|
|
202
|
+
/* @__PURE__ */ e("div", { className: i.accountArea, children: /* @__PURE__ */ e(
|
|
203
|
+
wt,
|
|
195
204
|
{
|
|
196
205
|
account: F,
|
|
197
|
-
onLoginClick:
|
|
198
|
-
className:
|
|
199
|
-
popoverContent:
|
|
200
|
-
isAccountLoading:
|
|
206
|
+
onLoginClick: nt,
|
|
207
|
+
className: i.avatar,
|
|
208
|
+
popoverContent: dt,
|
|
209
|
+
isAccountLoading: rt
|
|
201
210
|
}
|
|
202
211
|
) }),
|
|
203
|
-
/* @__PURE__ */
|
|
204
|
-
|
|
212
|
+
/* @__PURE__ */ e(
|
|
213
|
+
At,
|
|
205
214
|
{
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
215
|
+
trigger: /* @__PURE__ */ e("div", { className: i.cartArea, children: /* @__PURE__ */ e(
|
|
216
|
+
pt,
|
|
217
|
+
{
|
|
218
|
+
ref: _t,
|
|
219
|
+
cart: et,
|
|
220
|
+
open: it,
|
|
221
|
+
onCartClick: mt,
|
|
222
|
+
splashKey: ft
|
|
223
|
+
}
|
|
224
|
+
) }),
|
|
225
|
+
position: "bottom right",
|
|
226
|
+
open: !!G,
|
|
227
|
+
onOpenChange: (t) => {
|
|
228
|
+
t || R == null || R();
|
|
229
|
+
},
|
|
230
|
+
popoverClassName: _(i.cartPopover, !at && i.cartPopoverHidden),
|
|
231
|
+
contentClassName: i.cartPopoverContent,
|
|
232
|
+
children: G
|
|
210
233
|
}
|
|
211
234
|
),
|
|
212
|
-
/* @__PURE__ */
|
|
213
|
-
/* @__PURE__ */
|
|
214
|
-
/* @__PURE__ */
|
|
215
|
-
/* @__PURE__ */
|
|
216
|
-
/* @__PURE__ */
|
|
235
|
+
/* @__PURE__ */ m(Nt, { hideAt: ["lg"], children: [
|
|
236
|
+
/* @__PURE__ */ m("section", { children: [
|
|
237
|
+
/* @__PURE__ */ e(U, { size: "md", weight: "semibold", children: "Useful shortcuts" }),
|
|
238
|
+
/* @__PURE__ */ m("ul", { className: i.menuList, children: [
|
|
239
|
+
/* @__PURE__ */ e("li", { className: i.menuItem, children: /* @__PURE__ */ m(
|
|
217
240
|
"button",
|
|
218
241
|
{
|
|
219
242
|
onClick: q,
|
|
220
243
|
"data-hamburger-close": "true",
|
|
221
|
-
className:
|
|
244
|
+
className: _(i.siteLink, i.menuItemAction, V(["lg"])),
|
|
222
245
|
children: [
|
|
223
|
-
/* @__PURE__ */
|
|
246
|
+
/* @__PURE__ */ e(u, { iconKey: "fa-regular fa-sparkles", size: "sm", className: i.shortcutIcon }),
|
|
224
247
|
"Identify a Part"
|
|
225
248
|
]
|
|
226
249
|
}
|
|
227
250
|
) }),
|
|
228
|
-
/* @__PURE__ */
|
|
229
|
-
/* @__PURE__ */
|
|
251
|
+
/* @__PURE__ */ e("li", { className: i.menuItem, children: /* @__PURE__ */ m(A, { href: T, className: _(i.siteLink, i.menuItemAction), children: [
|
|
252
|
+
/* @__PURE__ */ e(u, { iconKey: "fa-regular fa-screwdriver-wrench", size: "sm", className: i.shortcutIcon }),
|
|
230
253
|
"Custom Parts"
|
|
231
254
|
] }) }),
|
|
232
|
-
/* @__PURE__ */
|
|
233
|
-
/* @__PURE__ */
|
|
255
|
+
/* @__PURE__ */ e("li", { className: i.menuItem, children: /* @__PURE__ */ m(A, { href: P, className: _(i.siteLink, i.menuItemAction), children: [
|
|
256
|
+
/* @__PURE__ */ e(u, { iconKey: "fa-regular fa-envelope", size: "sm", className: i.shortcutIcon }),
|
|
234
257
|
"Contact Us"
|
|
235
258
|
] }) }),
|
|
236
|
-
/* @__PURE__ */
|
|
237
|
-
/* @__PURE__ */
|
|
259
|
+
/* @__PURE__ */ e("li", { className: i.menuItem, children: /* @__PURE__ */ m(A, { href: S, className: _(i.siteLink, i.menuItemAction), children: [
|
|
260
|
+
/* @__PURE__ */ e(u, { iconKey: "fa-solid fa-question", size: "sm", className: i.shortcutIcon }),
|
|
238
261
|
"FAQ"
|
|
239
262
|
] }) }),
|
|
240
|
-
/* @__PURE__ */
|
|
241
|
-
/* @__PURE__ */
|
|
263
|
+
/* @__PURE__ */ e("li", { className: i.menuItem, children: /* @__PURE__ */ m(A, { href: tt, className: _(i.siteLink, i.menuItemAction), children: [
|
|
264
|
+
/* @__PURE__ */ e(u, { iconKey: "fa-regular fa-people-group", size: "sm", className: i.shortcutIcon }),
|
|
242
265
|
"About Us"
|
|
243
266
|
] }) })
|
|
244
267
|
] })
|
|
245
268
|
] }),
|
|
246
|
-
/* @__PURE__ */
|
|
247
|
-
/* @__PURE__ */
|
|
248
|
-
/* @__PURE__ */
|
|
249
|
-
|
|
269
|
+
/* @__PURE__ */ m("section", { children: [
|
|
270
|
+
/* @__PURE__ */ e(U, { size: "md", weight: "semibold", children: "Shop by category" }),
|
|
271
|
+
/* @__PURE__ */ e("ul", { className: i.menuList, children: b && b.map((t) => /* @__PURE__ */ e("li", { className: i.category, children: /* @__PURE__ */ m(
|
|
272
|
+
j,
|
|
250
273
|
{
|
|
251
274
|
href: t.route,
|
|
252
|
-
className:
|
|
253
|
-
onClick: () =>
|
|
275
|
+
className: i.categoryLink,
|
|
276
|
+
onClick: () => D == null ? void 0 : D(t),
|
|
254
277
|
children: [
|
|
255
|
-
/* @__PURE__ */
|
|
256
|
-
/* @__PURE__ */
|
|
278
|
+
/* @__PURE__ */ e(U, { size: "sm", children: t.label }),
|
|
279
|
+
/* @__PURE__ */ e(
|
|
257
280
|
u,
|
|
258
281
|
{
|
|
259
282
|
iconKey: "fa-solid fa-chevron-right",
|
|
@@ -272,8 +295,8 @@ import '../../assets/MainNav.css';const kt = "_main_1w2jy_1", At = "_column_1w2j
|
|
|
272
295
|
]
|
|
273
296
|
}
|
|
274
297
|
),
|
|
275
|
-
/* @__PURE__ */
|
|
276
|
-
|
|
298
|
+
/* @__PURE__ */ e(H, { flexDirection: "row", hideAt: ["md", "lg"], className: i.mobileSearch, children: /* @__PURE__ */ e("div", { className: i.search, children: /* @__PURE__ */ e(
|
|
299
|
+
C,
|
|
277
300
|
{
|
|
278
301
|
variant: "search",
|
|
279
302
|
label: "Search",
|
|
@@ -281,79 +304,79 @@ import '../../assets/MainNav.css';const kt = "_main_1w2jy_1", At = "_column_1w2j
|
|
|
281
304
|
name: "cpc-search",
|
|
282
305
|
autoComplete: "off",
|
|
283
306
|
"aria-autocomplete": "list",
|
|
284
|
-
"aria-controls":
|
|
285
|
-
"aria-activedescendant": r >= 0 ? `${
|
|
286
|
-
...
|
|
287
|
-
ref:
|
|
288
|
-
value:
|
|
289
|
-
endAdornment: /* @__PURE__ */
|
|
290
|
-
!!
|
|
307
|
+
"aria-controls": v,
|
|
308
|
+
"aria-activedescendant": r >= 0 ? `${v}-${r}` : void 0,
|
|
309
|
+
...X,
|
|
310
|
+
ref: z,
|
|
311
|
+
value: c,
|
|
312
|
+
endAdornment: /* @__PURE__ */ m(O, { children: [
|
|
313
|
+
!!c && /* @__PURE__ */ e(
|
|
291
314
|
$,
|
|
292
315
|
{
|
|
293
316
|
"aria-label": "Clear search",
|
|
294
317
|
onMouseDown: (t) => t.preventDefault(),
|
|
295
318
|
onClick: () => {
|
|
296
319
|
var t;
|
|
297
|
-
|
|
320
|
+
y(-1), N == null || N(), (t = z.current) == null || t.focus();
|
|
298
321
|
},
|
|
299
322
|
iconProps: { iconKey: "fa-regular fa-xmark", size: "sm" }
|
|
300
323
|
}
|
|
301
324
|
),
|
|
302
|
-
/* @__PURE__ */
|
|
325
|
+
/* @__PURE__ */ e(
|
|
303
326
|
$,
|
|
304
327
|
{
|
|
305
328
|
"aria-label": "Submit search",
|
|
306
|
-
onClick: () =>
|
|
329
|
+
onClick: () => f == null ? void 0 : f(c ?? ""),
|
|
307
330
|
iconProps: { iconKey: "fa-regular fa-magnifying-glass", size: "sm" }
|
|
308
331
|
}
|
|
309
332
|
)
|
|
310
333
|
] })
|
|
311
334
|
}
|
|
312
335
|
) }) }),
|
|
313
|
-
/* @__PURE__ */
|
|
314
|
-
|
|
336
|
+
/* @__PURE__ */ e(
|
|
337
|
+
bt,
|
|
315
338
|
{
|
|
316
|
-
categories:
|
|
317
|
-
isCategoriesLoading:
|
|
318
|
-
onCategoryClick:
|
|
339
|
+
categories: b,
|
|
340
|
+
isCategoriesLoading: ct,
|
|
341
|
+
onCategoryClick: D
|
|
319
342
|
}
|
|
320
343
|
)
|
|
321
344
|
] }) }),
|
|
322
|
-
|
|
323
|
-
/* @__PURE__ */
|
|
345
|
+
W && typeof document < "u" && kt.createPortal(
|
|
346
|
+
/* @__PURE__ */ m(
|
|
324
347
|
"div",
|
|
325
348
|
{
|
|
326
|
-
className:
|
|
327
|
-
style:
|
|
349
|
+
className: i.typeAheadPortal,
|
|
350
|
+
style: W,
|
|
328
351
|
children: [
|
|
329
|
-
|
|
330
|
-
|
|
352
|
+
w && o && /* @__PURE__ */ e(
|
|
353
|
+
g,
|
|
331
354
|
{
|
|
332
355
|
...o,
|
|
333
356
|
activeOptionIndex: r,
|
|
334
|
-
optionIdPrefix:
|
|
335
|
-
onKeyDown:
|
|
357
|
+
optionIdPrefix: v,
|
|
358
|
+
onKeyDown: Y,
|
|
336
359
|
onSuggestionClick: (t) => {
|
|
337
|
-
var
|
|
338
|
-
(
|
|
360
|
+
var n, a;
|
|
361
|
+
(n = o.onSuggestionClick) == null || n.call(o, t), d == null || d((t == null ? void 0 : t.name) ?? c ?? ""), (a = B()) == null || a.blur();
|
|
339
362
|
}
|
|
340
363
|
}
|
|
341
364
|
),
|
|
342
|
-
|
|
343
|
-
|
|
365
|
+
E && /* @__PURE__ */ e(
|
|
366
|
+
g,
|
|
344
367
|
{
|
|
345
368
|
terms: [],
|
|
346
369
|
categories: [],
|
|
347
370
|
items: [],
|
|
348
371
|
view: "recent-searches",
|
|
349
|
-
recentSearches:
|
|
350
|
-
onClearRecentSearch:
|
|
372
|
+
recentSearches: k,
|
|
373
|
+
onClearRecentSearch: lt,
|
|
351
374
|
activeOptionIndex: r,
|
|
352
|
-
optionIdPrefix:
|
|
353
|
-
onKeyDown:
|
|
375
|
+
optionIdPrefix: v,
|
|
376
|
+
onKeyDown: Y,
|
|
354
377
|
onSuggestionClick: (t) => {
|
|
355
|
-
var
|
|
356
|
-
d == null || d((t == null ? void 0 : t.term) ??
|
|
378
|
+
var n;
|
|
379
|
+
d == null || d((t == null ? void 0 : t.term) ?? c ?? ""), (n = B()) == null || n.blur();
|
|
357
380
|
}
|
|
358
381
|
}
|
|
359
382
|
)
|
|
@@ -364,13 +387,13 @@ import '../../assets/MainNav.css';const kt = "_main_1w2jy_1", At = "_column_1w2j
|
|
|
364
387
|
)
|
|
365
388
|
] });
|
|
366
389
|
});
|
|
367
|
-
function
|
|
390
|
+
function A({
|
|
368
391
|
href: I,
|
|
369
392
|
children: F,
|
|
370
|
-
...
|
|
393
|
+
...b
|
|
371
394
|
}) {
|
|
372
|
-
return /* @__PURE__ */
|
|
395
|
+
return /* @__PURE__ */ e(j, { href: I, className: i.siteLink, ...b, children: F });
|
|
373
396
|
}
|
|
374
397
|
export {
|
|
375
|
-
|
|
398
|
+
de as MainNav
|
|
376
399
|
};
|