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