@shopito/design-system-fe 0.1.19 → 0.1.20
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/common/Carousel/Carousel.d.ts +16 -8
- package/dist/common/Carousel/Carousel.d.ts.map +1 -1
- package/dist/common/Carousel/index.d.ts +1 -0
- package/dist/common/Carousel/index.d.ts.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +678 -561
- package/dist/index.js.map +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Fragment as
|
|
3
|
-
import { createPortal as
|
|
1
|
+
import { Children as e, forwardRef as t, useCallback as n, useEffect as r, useId as i, useLayoutEffect as a, useRef as o, useState as s } from "react";
|
|
2
|
+
import { Fragment as c, jsx as l, jsxs as u } from "react/jsx-runtime";
|
|
3
|
+
import { createPortal as d } from "react-dom";
|
|
4
4
|
//#region \0rolldown/runtime.js
|
|
5
|
-
var
|
|
6
|
-
if (t && typeof t == "object" || typeof t == "function") for (var i =
|
|
5
|
+
var f = Object.create, p = Object.defineProperty, m = Object.getOwnPropertyDescriptor, h = Object.getOwnPropertyNames, g = Object.getPrototypeOf, _ = Object.prototype.hasOwnProperty, v = (e, t) => () => (t || (e((t = { exports: {} }).exports, t), e = null), t.exports), y = (e, t, n, r) => {
|
|
6
|
+
if (t && typeof t == "object" || typeof t == "function") for (var i = h(t), a = 0, o = i.length, s; a < o; a++) s = i[a], !_.call(e, s) && s !== n && p(e, s, {
|
|
7
7
|
get: ((e) => t[e]).bind(null, s),
|
|
8
|
-
enumerable: !(r =
|
|
8
|
+
enumerable: !(r = m(t, s)) || r.enumerable
|
|
9
9
|
});
|
|
10
10
|
return e;
|
|
11
|
-
},
|
|
11
|
+
}, b = (e, t, n) => (n = e == null ? {} : f(g(e)), y(t || !e || !e.__esModule ? p(n, "default", {
|
|
12
12
|
value: e,
|
|
13
13
|
enumerable: !0
|
|
14
|
-
}) : n, e)),
|
|
14
|
+
}) : n, e)), x = ({ children: e }) => /* @__PURE__ */ l("div", {
|
|
15
15
|
className: "container",
|
|
16
16
|
children: e
|
|
17
|
-
}),
|
|
17
|
+
}), S = ({ children: e }) => /* @__PURE__ */ l("main", {
|
|
18
18
|
className: "main",
|
|
19
|
-
children: /* @__PURE__ */
|
|
20
|
-
}),
|
|
19
|
+
children: /* @__PURE__ */ l(x, { children: e })
|
|
20
|
+
}), C = /* @__PURE__ */ b((/* @__PURE__ */ v(((e, t) => {
|
|
21
21
|
(function() {
|
|
22
22
|
var e = {}.hasOwnProperty;
|
|
23
23
|
function n() {
|
|
@@ -43,137 +43,137 @@ var u = Object.create, d = Object.defineProperty, f = Object.getOwnPropertyDescr
|
|
|
43
43
|
return n;
|
|
44
44
|
}) : window.classNames = n;
|
|
45
45
|
})();
|
|
46
|
-
})))(), 1),
|
|
47
|
-
ref:
|
|
46
|
+
})))(), 1), w = t(({ variant: e = "primary", size: t = "md", loading: n = !1, fullWidth: r = !1, disabled: i, children: a, className: o = "", ...s }, c) => /* @__PURE__ */ u("button", {
|
|
47
|
+
ref: c,
|
|
48
48
|
disabled: i || n,
|
|
49
|
-
className: (0,
|
|
50
|
-
...
|
|
51
|
-
children: [n && /* @__PURE__ */
|
|
49
|
+
className: (0, C.default)("btn", e && `btn-${e}`, t && `btn-${t}`, r && "w-full", o),
|
|
50
|
+
...s,
|
|
51
|
+
children: [n && /* @__PURE__ */ u("svg", {
|
|
52
52
|
className: "animate-spin h-4 w-4 shrink-0",
|
|
53
53
|
xmlns: "http://www.w3.org/2000/svg",
|
|
54
54
|
fill: "none",
|
|
55
55
|
viewBox: "0 0 24 24",
|
|
56
|
-
children: [/* @__PURE__ */
|
|
56
|
+
children: [/* @__PURE__ */ l("circle", {
|
|
57
57
|
className: "opacity-25",
|
|
58
58
|
cx: "12",
|
|
59
59
|
cy: "12",
|
|
60
60
|
r: "10",
|
|
61
61
|
stroke: "currentColor",
|
|
62
62
|
strokeWidth: "4"
|
|
63
|
-
}), /* @__PURE__ */
|
|
63
|
+
}), /* @__PURE__ */ l("path", {
|
|
64
64
|
className: "opacity-75",
|
|
65
65
|
fill: "currentColor",
|
|
66
66
|
d: "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4z"
|
|
67
67
|
})]
|
|
68
68
|
}), a]
|
|
69
69
|
}));
|
|
70
|
-
|
|
70
|
+
w.displayName = "Button";
|
|
71
71
|
//#endregion
|
|
72
72
|
//#region src/components/common/LoadingSpin/LoadingSpin.tsx
|
|
73
|
-
var
|
|
74
|
-
className: (0,
|
|
73
|
+
var T = ({ size: e = "md" }) => /* @__PURE__ */ u("svg", {
|
|
74
|
+
className: (0, C.default)("loading-spin", `loading-spin-${e}`),
|
|
75
75
|
xmlns: "http://www.w3.org/2000/svg",
|
|
76
76
|
fill: "none",
|
|
77
77
|
viewBox: "0 0 24 24",
|
|
78
|
-
children: [/* @__PURE__ */
|
|
78
|
+
children: [/* @__PURE__ */ l("circle", {
|
|
79
79
|
className: "opacity-25",
|
|
80
80
|
cx: "12",
|
|
81
81
|
cy: "12",
|
|
82
82
|
r: "10",
|
|
83
83
|
stroke: "currentColor",
|
|
84
84
|
strokeWidth: "4"
|
|
85
|
-
}), /* @__PURE__ */
|
|
85
|
+
}), /* @__PURE__ */ l("path", {
|
|
86
86
|
className: "opacity-75",
|
|
87
87
|
fill: "currentColor",
|
|
88
88
|
d: "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4z"
|
|
89
89
|
})]
|
|
90
|
-
}),
|
|
91
|
-
ref:
|
|
90
|
+
}), E = t(({ icon: e, label: t, variant: n = "ghost", size: r = "md", loading: i = !1, disabled: a, className: o = "", ...s }, c) => /* @__PURE__ */ l("button", {
|
|
91
|
+
ref: c,
|
|
92
92
|
disabled: a || i,
|
|
93
93
|
"aria-label": t,
|
|
94
94
|
title: t,
|
|
95
|
-
className: (0,
|
|
96
|
-
...
|
|
97
|
-
children: i ? /* @__PURE__ */
|
|
95
|
+
className: (0, C.default)("icon-button", `icon-button-${n}`, `icon-button-${r}`, o),
|
|
96
|
+
...s,
|
|
97
|
+
children: i ? /* @__PURE__ */ l(T, { size: r }) : e
|
|
98
98
|
}));
|
|
99
|
-
|
|
99
|
+
E.displayName = "IconButton";
|
|
100
100
|
//#endregion
|
|
101
101
|
//#region src/components/common/Input/Input.tsx
|
|
102
|
-
var
|
|
102
|
+
var D = t(({ label: e, error: t, hint: n, leftIcon: r, rightIcon: i, className: a = "", id: o, ...s }, c) => {
|
|
103
103
|
let d = o ?? e?.toLowerCase().replace(/\s+/g, "-");
|
|
104
|
-
return /* @__PURE__ */
|
|
104
|
+
return /* @__PURE__ */ u("div", {
|
|
105
105
|
className: "w-full",
|
|
106
106
|
children: [
|
|
107
|
-
e && /* @__PURE__ */
|
|
107
|
+
e && /* @__PURE__ */ l("label", {
|
|
108
108
|
htmlFor: d,
|
|
109
109
|
className: "input-label",
|
|
110
110
|
children: e
|
|
111
111
|
}),
|
|
112
|
-
/* @__PURE__ */
|
|
112
|
+
/* @__PURE__ */ u("div", {
|
|
113
113
|
className: "relative",
|
|
114
114
|
children: [
|
|
115
|
-
r && /* @__PURE__ */
|
|
115
|
+
r && /* @__PURE__ */ l("span", {
|
|
116
116
|
className: "left-icon",
|
|
117
117
|
children: r
|
|
118
118
|
}),
|
|
119
|
-
/* @__PURE__ */
|
|
120
|
-
ref:
|
|
119
|
+
/* @__PURE__ */ l("input", {
|
|
120
|
+
ref: c,
|
|
121
121
|
id: d,
|
|
122
|
-
className: (0,
|
|
123
|
-
...
|
|
122
|
+
className: (0, C.default)("input", t && "has-error", !!r && "with-left-icon", !!i && "with-right-icon", "w-full", a),
|
|
123
|
+
...s
|
|
124
124
|
}),
|
|
125
|
-
i && /* @__PURE__ */
|
|
125
|
+
i && /* @__PURE__ */ l("span", {
|
|
126
126
|
className: "right-icon",
|
|
127
127
|
children: i
|
|
128
128
|
})
|
|
129
129
|
]
|
|
130
130
|
}),
|
|
131
|
-
(t || n) && /* @__PURE__ */
|
|
132
|
-
className: (0,
|
|
131
|
+
(t || n) && /* @__PURE__ */ l("p", {
|
|
132
|
+
className: (0, C.default)("helper-text", t && "has-error"),
|
|
133
133
|
children: t ?? n
|
|
134
134
|
})
|
|
135
135
|
]
|
|
136
136
|
});
|
|
137
137
|
});
|
|
138
|
-
|
|
138
|
+
D.displayName = "Input";
|
|
139
139
|
//#endregion
|
|
140
140
|
//#region src/components/common/Select/Select.tsx
|
|
141
|
-
var
|
|
141
|
+
var O = t(({ label: e, error: t, hint: n, options: r, placeholder: i, className: a = "", id: o, ...s }, c) => {
|
|
142
142
|
let d = o ?? e?.toLowerCase().replace(/\s+/g, "-");
|
|
143
|
-
return /* @__PURE__ */
|
|
144
|
-
className: (0,
|
|
143
|
+
return /* @__PURE__ */ u("div", {
|
|
144
|
+
className: (0, C.default)("select-wrapper", "w-full"),
|
|
145
145
|
children: [
|
|
146
|
-
e && /* @__PURE__ */
|
|
146
|
+
e && /* @__PURE__ */ l("label", {
|
|
147
147
|
htmlFor: d,
|
|
148
148
|
className: "select-label",
|
|
149
149
|
children: e
|
|
150
150
|
}),
|
|
151
|
-
/* @__PURE__ */
|
|
151
|
+
/* @__PURE__ */ u("div", {
|
|
152
152
|
className: "relative",
|
|
153
|
-
children: [/* @__PURE__ */
|
|
154
|
-
ref:
|
|
153
|
+
children: [/* @__PURE__ */ u("select", {
|
|
154
|
+
ref: c,
|
|
155
155
|
id: d,
|
|
156
|
-
className: (0,
|
|
157
|
-
...
|
|
158
|
-
children: [i && /* @__PURE__ */
|
|
156
|
+
className: (0, C.default)("select", "w-full", t && "has-error", a),
|
|
157
|
+
...s,
|
|
158
|
+
children: [i && /* @__PURE__ */ l("option", {
|
|
159
159
|
value: "",
|
|
160
160
|
disabled: !0,
|
|
161
161
|
children: i
|
|
162
|
-
}), r.map((e) => /* @__PURE__ */
|
|
162
|
+
}), r.map((e) => /* @__PURE__ */ l("option", {
|
|
163
163
|
value: e.value,
|
|
164
164
|
disabled: e.disabled,
|
|
165
165
|
children: e.label
|
|
166
166
|
}, e.value))]
|
|
167
|
-
}), /* @__PURE__ */
|
|
167
|
+
}), /* @__PURE__ */ l("span", {
|
|
168
168
|
className: "select-chevron-icon",
|
|
169
|
-
children: /* @__PURE__ */
|
|
169
|
+
children: /* @__PURE__ */ l("svg", {
|
|
170
170
|
xmlns: "http://www.w3.org/2000/svg",
|
|
171
171
|
fill: "none",
|
|
172
172
|
viewBox: "0 0 24 24",
|
|
173
173
|
strokeWidth: 2,
|
|
174
174
|
stroke: "currentColor",
|
|
175
175
|
className: "w-4 h-4",
|
|
176
|
-
children: /* @__PURE__ */
|
|
176
|
+
children: /* @__PURE__ */ l("path", {
|
|
177
177
|
strokeLinecap: "round",
|
|
178
178
|
strokeLinejoin: "round",
|
|
179
179
|
d: "M19.5 8.25l-7.5 7.5-7.5-7.5"
|
|
@@ -181,71 +181,71 @@ var E = e(({ label: e, error: t, hint: n, options: r, placeholder: i, className:
|
|
|
181
181
|
})
|
|
182
182
|
})]
|
|
183
183
|
}),
|
|
184
|
-
(t || n) && /* @__PURE__ */
|
|
185
|
-
className: (0,
|
|
184
|
+
(t || n) && /* @__PURE__ */ l("p", {
|
|
185
|
+
className: (0, C.default)("select-helper", t && "has-error"),
|
|
186
186
|
children: t ?? n
|
|
187
187
|
})
|
|
188
188
|
]
|
|
189
189
|
});
|
|
190
190
|
});
|
|
191
|
-
|
|
191
|
+
O.displayName = "Select";
|
|
192
192
|
//#endregion
|
|
193
193
|
//#region src/components/common/Typography/Heading.tsx
|
|
194
|
-
var
|
|
195
|
-
className: (0,
|
|
194
|
+
var k = ({ as: e, level: t = 1, color: n = "default", className: r = "", children: i, ...a }) => /* @__PURE__ */ l(e ?? `h${t}`, {
|
|
195
|
+
className: (0, C.default)(`text-color-${n}`, `heading-size-${t}`, r),
|
|
196
196
|
...a,
|
|
197
197
|
children: i
|
|
198
|
-
}),
|
|
199
|
-
className: (0,
|
|
198
|
+
}), A = ({ variant: e = "body", color: t = "default", as: n = "p", className: r = "", children: i, ...a }) => /* @__PURE__ */ l(n, {
|
|
199
|
+
className: (0, C.default)(`text-color-${t}`, `text-variant-${e}`, r),
|
|
200
200
|
...a,
|
|
201
201
|
children: i
|
|
202
202
|
});
|
|
203
203
|
//#endregion
|
|
204
204
|
//#region src/components/common/Badge/Badge.tsx
|
|
205
|
-
function
|
|
206
|
-
return /* @__PURE__ */
|
|
207
|
-
className: (0,
|
|
205
|
+
function j({ variant: e = "default", size: t = "md", dot: n = !1, className: r, children: i, ...a }) {
|
|
206
|
+
return /* @__PURE__ */ u("span", {
|
|
207
|
+
className: (0, C.default)("badge", `badge-${e}`, `badge-${t}`, r),
|
|
208
208
|
...a,
|
|
209
|
-
children: [n && /* @__PURE__ */
|
|
209
|
+
children: [n && /* @__PURE__ */ l("span", { className: (0, C.default)("badge-dot", `badge-dot-${e}`) }), i]
|
|
210
210
|
});
|
|
211
211
|
}
|
|
212
212
|
//#endregion
|
|
213
213
|
//#region src/components/common/Card/Card.tsx
|
|
214
|
-
var
|
|
214
|
+
var M = {
|
|
215
215
|
none: "",
|
|
216
216
|
sm: "p-4",
|
|
217
217
|
md: "p-6",
|
|
218
218
|
lg: "p-8"
|
|
219
219
|
};
|
|
220
|
-
function
|
|
221
|
-
return /* @__PURE__ */
|
|
220
|
+
function N({ children: e, padding: t = "md", shadow: n = !0, border: r = !0, className: i = "", ...a }) {
|
|
221
|
+
return /* @__PURE__ */ l("div", {
|
|
222
222
|
className: [
|
|
223
223
|
"bg-white rounded-xl overflow-hidden",
|
|
224
224
|
r ? "border border-gray-200" : "",
|
|
225
225
|
n ? "shadow-sm" : "",
|
|
226
|
-
|
|
226
|
+
M[t],
|
|
227
227
|
i
|
|
228
228
|
].filter(Boolean).join(" "),
|
|
229
229
|
...a,
|
|
230
230
|
children: e
|
|
231
231
|
});
|
|
232
232
|
}
|
|
233
|
-
function
|
|
234
|
-
return /* @__PURE__ */
|
|
233
|
+
function P({ children: e, className: t = "", ...n }) {
|
|
234
|
+
return /* @__PURE__ */ l("div", {
|
|
235
235
|
className: ["px-6 py-4 border-b border-gray-100", t].filter(Boolean).join(" "),
|
|
236
236
|
...n,
|
|
237
237
|
children: e
|
|
238
238
|
});
|
|
239
239
|
}
|
|
240
|
-
function
|
|
241
|
-
return /* @__PURE__ */
|
|
240
|
+
function F({ children: e, className: t = "", ...n }) {
|
|
241
|
+
return /* @__PURE__ */ l("div", {
|
|
242
242
|
className: ["p-6", t].filter(Boolean).join(" "),
|
|
243
243
|
...n,
|
|
244
244
|
children: e
|
|
245
245
|
});
|
|
246
246
|
}
|
|
247
|
-
function
|
|
248
|
-
return /* @__PURE__ */
|
|
247
|
+
function I({ children: e, className: t = "", ...n }) {
|
|
248
|
+
return /* @__PURE__ */ l("div", {
|
|
249
249
|
className: ["px-6 py-4 border-t border-gray-100 bg-gray-50", t].filter(Boolean).join(" "),
|
|
250
250
|
...n,
|
|
251
251
|
children: e
|
|
@@ -253,13 +253,13 @@ function ne({ children: e, className: t = "", ...n }) {
|
|
|
253
253
|
}
|
|
254
254
|
//#endregion
|
|
255
255
|
//#region src/components/common/Spinner/Spinner.tsx
|
|
256
|
-
function
|
|
257
|
-
return /* @__PURE__ */
|
|
256
|
+
function L({ size: e = "md", color: t = "primary", label: n = "Loading…", className: r = "", ...i }) {
|
|
257
|
+
return /* @__PURE__ */ u("span", {
|
|
258
258
|
role: "status",
|
|
259
259
|
"aria-label": n,
|
|
260
|
-
className: (0,
|
|
260
|
+
className: (0, C.default)("spinner-wrapper", r),
|
|
261
261
|
...i,
|
|
262
|
-
children: [/* @__PURE__ */
|
|
262
|
+
children: [/* @__PURE__ */ l("span", { className: (0, C.default)("spinner", `spinner-${e}`, `spinner-${t}`) }), /* @__PURE__ */ l("span", {
|
|
263
263
|
className: "sr-only",
|
|
264
264
|
children: n
|
|
265
265
|
})]
|
|
@@ -267,65 +267,65 @@ function re({ size: e = "md", color: t = "primary", label: n = "Loading…", cla
|
|
|
267
267
|
}
|
|
268
268
|
//#endregion
|
|
269
269
|
//#region src/components/common/Alert/Alert.tsx
|
|
270
|
-
var
|
|
271
|
-
info: /* @__PURE__ */
|
|
270
|
+
var R = {
|
|
271
|
+
info: /* @__PURE__ */ l("path", {
|
|
272
272
|
strokeLinecap: "round",
|
|
273
273
|
strokeLinejoin: "round",
|
|
274
274
|
d: "M11.25 11.25l.041-.02a.75.75 0 011.063.852l-.708 2.836a.75.75 0 001.063.853l.041-.021M21 12a9 9 0 11-18 0 9 9 0 0118 0zm-9-3.75h.008v.008H12V8.25z"
|
|
275
275
|
}),
|
|
276
|
-
success: /* @__PURE__ */
|
|
276
|
+
success: /* @__PURE__ */ l("path", {
|
|
277
277
|
strokeLinecap: "round",
|
|
278
278
|
strokeLinejoin: "round",
|
|
279
279
|
d: "M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z"
|
|
280
280
|
}),
|
|
281
|
-
warning: /* @__PURE__ */
|
|
281
|
+
warning: /* @__PURE__ */ l("path", {
|
|
282
282
|
strokeLinecap: "round",
|
|
283
283
|
strokeLinejoin: "round",
|
|
284
284
|
d: "M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126zM12 15.75h.007v.008H12v-.008z"
|
|
285
285
|
}),
|
|
286
|
-
danger: /* @__PURE__ */
|
|
286
|
+
danger: /* @__PURE__ */ l("path", {
|
|
287
287
|
strokeLinecap: "round",
|
|
288
288
|
strokeLinejoin: "round",
|
|
289
289
|
d: "M12 9v3.75m9-.75a9 9 0 11-18 0 9 9 0 0118 0zm-9 3.75h.008v.008H12v-.008z"
|
|
290
290
|
})
|
|
291
291
|
};
|
|
292
|
-
function
|
|
293
|
-
return /* @__PURE__ */
|
|
292
|
+
function z({ variant: e = "info", title: t, children: n, onClose: r, className: i = "", ...a }) {
|
|
293
|
+
return /* @__PURE__ */ u("div", {
|
|
294
294
|
role: "alert",
|
|
295
|
-
className: (0,
|
|
295
|
+
className: (0, C.default)("alert", `alert-${e}`, "w-full", i),
|
|
296
296
|
...a,
|
|
297
297
|
children: [
|
|
298
|
-
/* @__PURE__ */
|
|
298
|
+
/* @__PURE__ */ l("svg", {
|
|
299
299
|
xmlns: "http://www.w3.org/2000/svg",
|
|
300
300
|
fill: "none",
|
|
301
301
|
viewBox: "0 0 24 24",
|
|
302
302
|
strokeWidth: 1.5,
|
|
303
303
|
stroke: "currentColor",
|
|
304
|
-
className: (0,
|
|
305
|
-
children:
|
|
304
|
+
className: (0, C.default)("alert-icon", `alert-icon-${e}`),
|
|
305
|
+
children: R[e]
|
|
306
306
|
}),
|
|
307
|
-
/* @__PURE__ */
|
|
307
|
+
/* @__PURE__ */ u("div", {
|
|
308
308
|
className: "flex-1 min-w-0",
|
|
309
|
-
children: [t && /* @__PURE__ */
|
|
309
|
+
children: [t && /* @__PURE__ */ l("p", {
|
|
310
310
|
className: "alert-title",
|
|
311
311
|
children: t
|
|
312
|
-
}), /* @__PURE__ */
|
|
312
|
+
}), /* @__PURE__ */ l("div", {
|
|
313
313
|
className: "alert-text",
|
|
314
314
|
children: n
|
|
315
315
|
})]
|
|
316
316
|
}),
|
|
317
|
-
r && /* @__PURE__ */
|
|
317
|
+
r && /* @__PURE__ */ l("button", {
|
|
318
318
|
onClick: r,
|
|
319
319
|
className: "alert-close-btn",
|
|
320
320
|
"aria-label": "Close",
|
|
321
|
-
children: /* @__PURE__ */
|
|
321
|
+
children: /* @__PURE__ */ l("svg", {
|
|
322
322
|
xmlns: "http://www.w3.org/2000/svg",
|
|
323
323
|
fill: "none",
|
|
324
324
|
viewBox: "0 0 24 24",
|
|
325
325
|
strokeWidth: 1.5,
|
|
326
326
|
stroke: "currentColor",
|
|
327
327
|
className: "w-4 h-4",
|
|
328
|
-
children: /* @__PURE__ */
|
|
328
|
+
children: /* @__PURE__ */ l("path", {
|
|
329
329
|
strokeLinecap: "round",
|
|
330
330
|
strokeLinejoin: "round",
|
|
331
331
|
d: "M6 18L18 6M6 6l12 12"
|
|
@@ -337,57 +337,57 @@ function ae({ variant: e = "info", title: t, children: n, onClose: r, className:
|
|
|
337
337
|
}
|
|
338
338
|
//#endregion
|
|
339
339
|
//#region src/components/common/Modal/Modal.tsx
|
|
340
|
-
var
|
|
340
|
+
var ee = {
|
|
341
341
|
sm: "max-w-sm",
|
|
342
342
|
md: "max-w-md",
|
|
343
343
|
lg: "max-w-lg",
|
|
344
344
|
xl: "max-w-xl",
|
|
345
345
|
full: "max-w-full mx-4"
|
|
346
346
|
};
|
|
347
|
-
function
|
|
348
|
-
let f =
|
|
349
|
-
return
|
|
347
|
+
function te({ open: e, onClose: t, title: n, children: i, footer: a, size: s = "md", closeOnBackdrop: c = !0 }) {
|
|
348
|
+
let f = o(null);
|
|
349
|
+
return r(() => {
|
|
350
350
|
if (!e) return;
|
|
351
351
|
let t = document.body.style.overflow;
|
|
352
352
|
return document.body.style.overflow = "hidden", () => {
|
|
353
353
|
document.body.style.overflow = t;
|
|
354
354
|
};
|
|
355
|
-
}, [e]),
|
|
355
|
+
}, [e]), r(() => {
|
|
356
356
|
if (!e) return;
|
|
357
357
|
let n = (e) => {
|
|
358
358
|
e.key === "Escape" && t();
|
|
359
359
|
};
|
|
360
360
|
return document.addEventListener("keydown", n), () => document.removeEventListener("keydown", n);
|
|
361
|
-
}, [e, t]), e ?
|
|
361
|
+
}, [e, t]), e ? d(/* @__PURE__ */ l("div", {
|
|
362
362
|
ref: f,
|
|
363
363
|
className: "fixed inset-0 z-50 flex items-center justify-center p-4 bg-black/50 backdrop-blur-sm",
|
|
364
364
|
onClick: (e) => {
|
|
365
|
-
|
|
365
|
+
c && e.target === f.current && t();
|
|
366
366
|
},
|
|
367
|
-
children: /* @__PURE__ */
|
|
367
|
+
children: /* @__PURE__ */ u("div", {
|
|
368
368
|
role: "dialog",
|
|
369
369
|
"aria-modal": "true",
|
|
370
|
-
"aria-labelledby":
|
|
371
|
-
className: ["relative w-full bg-white rounded-xl shadow-xl flex flex-col max-h-[90vh]",
|
|
370
|
+
"aria-labelledby": n ? "modal-title" : void 0,
|
|
371
|
+
className: ["relative w-full bg-white rounded-xl shadow-xl flex flex-col max-h-[90vh]", ee[s]].join(" "),
|
|
372
372
|
children: [
|
|
373
|
-
|
|
373
|
+
n && /* @__PURE__ */ u("div", {
|
|
374
374
|
className: "flex items-center justify-between px-6 py-4 border-b border-gray-100 shrink-0",
|
|
375
|
-
children: [/* @__PURE__ */
|
|
375
|
+
children: [/* @__PURE__ */ l("h2", {
|
|
376
376
|
id: "modal-title",
|
|
377
377
|
className: "text-lg font-semibold text-gray-900",
|
|
378
|
-
children:
|
|
379
|
-
}), /* @__PURE__ */
|
|
378
|
+
children: n
|
|
379
|
+
}), /* @__PURE__ */ l("button", {
|
|
380
380
|
onClick: t,
|
|
381
381
|
className: "text-gray-400 hover:text-gray-600 transition-colors",
|
|
382
382
|
"aria-label": "Close modal",
|
|
383
|
-
children: /* @__PURE__ */
|
|
383
|
+
children: /* @__PURE__ */ l("svg", {
|
|
384
384
|
xmlns: "http://www.w3.org/2000/svg",
|
|
385
385
|
fill: "none",
|
|
386
386
|
viewBox: "0 0 24 24",
|
|
387
387
|
strokeWidth: 1.5,
|
|
388
388
|
stroke: "currentColor",
|
|
389
389
|
className: "w-5 h-5",
|
|
390
|
-
children: /* @__PURE__ */
|
|
390
|
+
children: /* @__PURE__ */ l("path", {
|
|
391
391
|
strokeLinecap: "round",
|
|
392
392
|
strokeLinejoin: "round",
|
|
393
393
|
d: "M6 18L18 6M6 6l12 12"
|
|
@@ -395,13 +395,13 @@ function se({ open: e, onClose: t, title: r, children: a, footer: o, size: u = "
|
|
|
395
395
|
})
|
|
396
396
|
})]
|
|
397
397
|
}),
|
|
398
|
-
/* @__PURE__ */
|
|
398
|
+
/* @__PURE__ */ l("div", {
|
|
399
399
|
className: "flex-1 overflow-y-auto px-6 py-4",
|
|
400
|
-
children:
|
|
400
|
+
children: i
|
|
401
401
|
}),
|
|
402
|
-
|
|
402
|
+
a && /* @__PURE__ */ l("div", {
|
|
403
403
|
className: "px-6 py-4 border-t border-gray-100 shrink-0 bg-gray-50 rounded-b-xl",
|
|
404
|
-
children:
|
|
404
|
+
children: a
|
|
405
405
|
})
|
|
406
406
|
]
|
|
407
407
|
})
|
|
@@ -409,73 +409,73 @@ function se({ open: e, onClose: t, title: r, children: a, footer: o, size: u = "
|
|
|
409
409
|
}
|
|
410
410
|
//#endregion
|
|
411
411
|
//#region src/components/common/Checkbox/Checkbox.tsx
|
|
412
|
-
var
|
|
413
|
-
let
|
|
414
|
-
return /* @__PURE__ */
|
|
415
|
-
className: (0,
|
|
416
|
-
children: [/* @__PURE__ */
|
|
412
|
+
var B = t(({ label: e, description: t, error: n, indeterminate: r, className: i = "", id: a, ...o }, s) => {
|
|
413
|
+
let c = a ?? e?.toLowerCase().replace(/\s+/g, "-");
|
|
414
|
+
return /* @__PURE__ */ u("div", {
|
|
415
|
+
className: (0, C.default)("checkbox-wrapper", i),
|
|
416
|
+
children: [/* @__PURE__ */ l("div", {
|
|
417
417
|
className: "checkbox-wrapper-inner",
|
|
418
|
-
children: /* @__PURE__ */
|
|
418
|
+
children: /* @__PURE__ */ l("input", {
|
|
419
419
|
ref: (e) => {
|
|
420
|
-
e && (e.indeterminate = r ?? !1), typeof
|
|
420
|
+
e && (e.indeterminate = r ?? !1), typeof s == "function" ? s(e) : s && (s.current = e);
|
|
421
421
|
},
|
|
422
|
-
id:
|
|
422
|
+
id: c,
|
|
423
423
|
type: "checkbox",
|
|
424
|
-
className: (0,
|
|
424
|
+
className: (0, C.default)("checkbox", n && "has-error"),
|
|
425
425
|
...o
|
|
426
426
|
})
|
|
427
|
-
}), (e || t) && /* @__PURE__ */
|
|
428
|
-
e && /* @__PURE__ */
|
|
429
|
-
htmlFor:
|
|
427
|
+
}), (e || t) && /* @__PURE__ */ u("div", { children: [
|
|
428
|
+
e && /* @__PURE__ */ l("label", {
|
|
429
|
+
htmlFor: c,
|
|
430
430
|
className: "checkbox-label",
|
|
431
431
|
children: e
|
|
432
432
|
}),
|
|
433
|
-
t && /* @__PURE__ */
|
|
433
|
+
t && /* @__PURE__ */ l("p", {
|
|
434
434
|
className: "checkbox-description",
|
|
435
435
|
children: t
|
|
436
436
|
}),
|
|
437
|
-
n && /* @__PURE__ */
|
|
437
|
+
n && /* @__PURE__ */ l("p", {
|
|
438
438
|
className: "checkbox-error",
|
|
439
439
|
children: n
|
|
440
440
|
})
|
|
441
441
|
] })]
|
|
442
442
|
});
|
|
443
443
|
});
|
|
444
|
-
|
|
444
|
+
B.displayName = "Checkbox";
|
|
445
445
|
//#endregion
|
|
446
446
|
//#region src/components/common/Toggle/Toggle.tsx
|
|
447
|
-
var
|
|
448
|
-
let
|
|
449
|
-
return /* @__PURE__ */
|
|
450
|
-
htmlFor:
|
|
451
|
-
className: (0,
|
|
452
|
-
children: [/* @__PURE__ */
|
|
453
|
-
className: (0,
|
|
447
|
+
var V = t(({ label: e, description: t, size: n = "md", className: r = "", id: i, ...a }, o) => {
|
|
448
|
+
let s = i ?? e?.toLowerCase().replace(/\s+/g, "-");
|
|
449
|
+
return /* @__PURE__ */ u("label", {
|
|
450
|
+
htmlFor: s,
|
|
451
|
+
className: (0, C.default)("toggle", a.disabled && "toggle-disabled", r),
|
|
452
|
+
children: [/* @__PURE__ */ u("div", {
|
|
453
|
+
className: (0, C.default)("toggle-wrapper", `toggle-wrapper-${n}`),
|
|
454
454
|
children: [
|
|
455
|
-
/* @__PURE__ */
|
|
455
|
+
/* @__PURE__ */ l("input", {
|
|
456
456
|
ref: o,
|
|
457
|
-
id:
|
|
457
|
+
id: s,
|
|
458
458
|
type: "checkbox",
|
|
459
459
|
role: "switch",
|
|
460
460
|
className: "sr-only peer",
|
|
461
461
|
...a
|
|
462
462
|
}),
|
|
463
|
-
/* @__PURE__ */
|
|
464
|
-
/* @__PURE__ */
|
|
463
|
+
/* @__PURE__ */ l("div", { className: "toggle-track" }),
|
|
464
|
+
/* @__PURE__ */ l("div", { className: (0, C.default)("toggle-thumb", `toggle-thumb-${n}`) })
|
|
465
465
|
]
|
|
466
|
-
}), (e || t) && /* @__PURE__ */
|
|
466
|
+
}), (e || t) && /* @__PURE__ */ u("div", { children: [e && /* @__PURE__ */ l("span", {
|
|
467
467
|
className: "toggle-label",
|
|
468
468
|
children: e
|
|
469
|
-
}), t && /* @__PURE__ */
|
|
469
|
+
}), t && /* @__PURE__ */ l("span", {
|
|
470
470
|
className: "toggle-description",
|
|
471
471
|
children: t
|
|
472
472
|
})] })]
|
|
473
473
|
});
|
|
474
474
|
});
|
|
475
|
-
|
|
475
|
+
V.displayName = "Toggle";
|
|
476
476
|
//#endregion
|
|
477
477
|
//#region src/components/common/Avatar/Avatar.tsx
|
|
478
|
-
var
|
|
478
|
+
var H = [
|
|
479
479
|
"bg-red-500",
|
|
480
480
|
"bg-orange-500",
|
|
481
481
|
"bg-amber-500",
|
|
@@ -486,38 +486,38 @@ var P = [
|
|
|
486
486
|
"bg-violet-500",
|
|
487
487
|
"bg-pink-500"
|
|
488
488
|
];
|
|
489
|
-
function
|
|
489
|
+
function ne({ src: e, alt: t, name: n, size: r = "md", className: i, ...a }) {
|
|
490
490
|
let o = [
|
|
491
491
|
"avatar",
|
|
492
492
|
`avatar-${r}`,
|
|
493
493
|
i
|
|
494
|
-
],
|
|
494
|
+
], s = (e) => {
|
|
495
495
|
let t = 0;
|
|
496
496
|
for (let n = 0; n < e.length; n++) t += e.charCodeAt(n);
|
|
497
|
-
return
|
|
498
|
-
},
|
|
499
|
-
return e ? /* @__PURE__ */
|
|
500
|
-
className: (0,
|
|
497
|
+
return H[t % H.length];
|
|
498
|
+
}, c = (e) => e.split(" ").slice(0, 2).map((e) => e[0]).join("").toUpperCase();
|
|
499
|
+
return e ? /* @__PURE__ */ l("span", {
|
|
500
|
+
className: (0, C.default)(o),
|
|
501
501
|
...a,
|
|
502
|
-
children: /* @__PURE__ */
|
|
502
|
+
children: /* @__PURE__ */ l("img", {
|
|
503
503
|
src: e,
|
|
504
504
|
alt: t ?? n ?? "",
|
|
505
505
|
className: "w-full h-full object-cover"
|
|
506
506
|
})
|
|
507
|
-
}) : n ? /* @__PURE__ */
|
|
508
|
-
className: (0,
|
|
507
|
+
}) : n ? /* @__PURE__ */ l("span", {
|
|
508
|
+
className: (0, C.default)(o, s(n)),
|
|
509
509
|
"aria-label": n,
|
|
510
510
|
...a,
|
|
511
|
-
children:
|
|
512
|
-
}) : /* @__PURE__ */
|
|
513
|
-
className: (0,
|
|
511
|
+
children: c(n)
|
|
512
|
+
}) : /* @__PURE__ */ l("span", {
|
|
513
|
+
className: (0, C.default)(o, "avatar-fallback"),
|
|
514
514
|
...a,
|
|
515
|
-
children: /* @__PURE__ */
|
|
515
|
+
children: /* @__PURE__ */ l("svg", {
|
|
516
516
|
xmlns: "http://www.w3.org/2000/svg",
|
|
517
517
|
fill: "currentColor",
|
|
518
518
|
viewBox: "0 0 24 24",
|
|
519
519
|
className: "w-3/5 h-3/5",
|
|
520
|
-
children: /* @__PURE__ */
|
|
520
|
+
children: /* @__PURE__ */ l("path", {
|
|
521
521
|
fillRule: "evenodd",
|
|
522
522
|
d: "M7.5 6a4.5 4.5 0 119 0 4.5 4.5 0 01-9 0zM3.751 20.105a8.25 8.25 0 0116.498 0 .75.75 0 01-.437.695A18.683 18.683 0 0112 22.5c-2.786 0-5.433-.608-7.812-1.7a.75.75 0 01-.437-.695z",
|
|
523
523
|
clipRule: "evenodd"
|
|
@@ -527,8 +527,8 @@ function ce({ src: e, alt: t, name: n, size: r = "md", className: i, ...a }) {
|
|
|
527
527
|
}
|
|
528
528
|
//#endregion
|
|
529
529
|
//#region src/components/common/Stack/Stack.tsx
|
|
530
|
-
var
|
|
531
|
-
className: (0,
|
|
530
|
+
var re = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems: r = "start", justifyContent: i = "normal", className: a, children: o }) => /* @__PURE__ */ l("div", {
|
|
531
|
+
className: (0, C.default)("stack", `stack-${e}`, t && `gap-${t}`, {
|
|
532
532
|
start: "items-start",
|
|
533
533
|
end: "items-end",
|
|
534
534
|
center: "items-center",
|
|
@@ -550,14 +550,14 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
550
550
|
stretch: "justify-stretch"
|
|
551
551
|
}[i], a),
|
|
552
552
|
children: o
|
|
553
|
-
}),
|
|
553
|
+
}), ie = {
|
|
554
554
|
1: "grid-cols-1",
|
|
555
555
|
2: "grid-cols-2",
|
|
556
556
|
3: "grid-cols-3",
|
|
557
557
|
4: "grid-cols-4",
|
|
558
558
|
6: "grid-cols-6",
|
|
559
559
|
12: "grid-cols-12"
|
|
560
|
-
},
|
|
560
|
+
}, ae = {
|
|
561
561
|
0: "gap-0",
|
|
562
562
|
1: "gap-1",
|
|
563
563
|
2: "gap-2",
|
|
@@ -569,7 +569,7 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
569
569
|
10: "gap-10",
|
|
570
570
|
12: "gap-12",
|
|
571
571
|
16: "gap-16"
|
|
572
|
-
},
|
|
572
|
+
}, oe = {
|
|
573
573
|
0: "gap-y-0",
|
|
574
574
|
1: "gap-y-1",
|
|
575
575
|
2: "gap-y-2",
|
|
@@ -581,7 +581,7 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
581
581
|
10: "gap-y-10",
|
|
582
582
|
12: "gap-y-12",
|
|
583
583
|
16: "gap-y-16"
|
|
584
|
-
},
|
|
584
|
+
}, se = {
|
|
585
585
|
0: "gap-x-0",
|
|
586
586
|
1: "gap-x-1",
|
|
587
587
|
2: "gap-x-2",
|
|
@@ -593,7 +593,7 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
593
593
|
10: "gap-x-10",
|
|
594
594
|
12: "gap-x-12",
|
|
595
595
|
16: "gap-x-16"
|
|
596
|
-
},
|
|
596
|
+
}, ce = {
|
|
597
597
|
1: "col-span-1",
|
|
598
598
|
2: "col-span-2",
|
|
599
599
|
3: "col-span-3",
|
|
@@ -606,7 +606,7 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
606
606
|
10: "col-span-10",
|
|
607
607
|
11: "col-span-11",
|
|
608
608
|
12: "col-span-12"
|
|
609
|
-
},
|
|
609
|
+
}, le = {
|
|
610
610
|
1: "sm:col-span-1",
|
|
611
611
|
2: "sm:col-span-2",
|
|
612
612
|
3: "sm:col-span-3",
|
|
@@ -619,7 +619,7 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
619
619
|
10: "sm:col-span-10",
|
|
620
620
|
11: "sm:col-span-11",
|
|
621
621
|
12: "sm:col-span-12"
|
|
622
|
-
},
|
|
622
|
+
}, ue = {
|
|
623
623
|
1: "md:col-span-1",
|
|
624
624
|
2: "md:col-span-2",
|
|
625
625
|
3: "md:col-span-3",
|
|
@@ -632,7 +632,7 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
632
632
|
10: "md:col-span-10",
|
|
633
633
|
11: "md:col-span-11",
|
|
634
634
|
12: "md:col-span-12"
|
|
635
|
-
},
|
|
635
|
+
}, de = {
|
|
636
636
|
1: "lg:col-span-1",
|
|
637
637
|
2: "lg:col-span-2",
|
|
638
638
|
3: "lg:col-span-3",
|
|
@@ -645,7 +645,7 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
645
645
|
10: "lg:col-span-10",
|
|
646
646
|
11: "lg:col-span-11",
|
|
647
647
|
12: "lg:col-span-12"
|
|
648
|
-
},
|
|
648
|
+
}, fe = {
|
|
649
649
|
1: "xl:col-span-1",
|
|
650
650
|
2: "xl:col-span-2",
|
|
651
651
|
3: "xl:col-span-3",
|
|
@@ -658,7 +658,7 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
658
658
|
10: "xl:col-span-10",
|
|
659
659
|
11: "xl:col-span-11",
|
|
660
660
|
12: "xl:col-span-12"
|
|
661
|
-
},
|
|
661
|
+
}, pe = {
|
|
662
662
|
1: "col-start-2",
|
|
663
663
|
2: "col-start-3",
|
|
664
664
|
3: "col-start-4",
|
|
@@ -670,7 +670,7 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
670
670
|
9: "col-start-10",
|
|
671
671
|
10: "col-start-11",
|
|
672
672
|
11: "col-start-12"
|
|
673
|
-
},
|
|
673
|
+
}, me = {
|
|
674
674
|
1: "sm:col-start-2",
|
|
675
675
|
2: "sm:col-start-3",
|
|
676
676
|
3: "sm:col-start-4",
|
|
@@ -682,7 +682,7 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
682
682
|
9: "sm:col-start-10",
|
|
683
683
|
10: "sm:col-start-11",
|
|
684
684
|
11: "sm:col-start-12"
|
|
685
|
-
},
|
|
685
|
+
}, he = {
|
|
686
686
|
1: "md:col-start-2",
|
|
687
687
|
2: "md:col-start-3",
|
|
688
688
|
3: "md:col-start-4",
|
|
@@ -694,7 +694,7 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
694
694
|
9: "md:col-start-10",
|
|
695
695
|
10: "md:col-start-11",
|
|
696
696
|
11: "md:col-start-12"
|
|
697
|
-
},
|
|
697
|
+
}, ge = {
|
|
698
698
|
1: "lg:col-start-2",
|
|
699
699
|
2: "lg:col-start-3",
|
|
700
700
|
3: "lg:col-start-4",
|
|
@@ -706,7 +706,7 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
706
706
|
9: "lg:col-start-10",
|
|
707
707
|
10: "lg:col-start-11",
|
|
708
708
|
11: "lg:col-start-12"
|
|
709
|
-
},
|
|
709
|
+
}, _e = {
|
|
710
710
|
1: "xl:col-start-2",
|
|
711
711
|
2: "xl:col-start-3",
|
|
712
712
|
3: "xl:col-start-4",
|
|
@@ -718,32 +718,32 @@ var le = ({ direction: e = "row", gap: t, alignItems: n = "start", justifyItems:
|
|
|
718
718
|
9: "xl:col-start-10",
|
|
719
719
|
10: "xl:col-start-11",
|
|
720
720
|
11: "xl:col-start-12"
|
|
721
|
-
},
|
|
722
|
-
className: (0,
|
|
721
|
+
}, U = ({ children: e, cols: t = 12, gap: n, rowGap: r, colGap: i, as: a = "div", className: o }) => /* @__PURE__ */ l(a, {
|
|
722
|
+
className: (0, C.default)("grid", "w-full", ie[t], n !== void 0 && ae[n], r !== void 0 && oe[r], i !== void 0 && se[i], o),
|
|
723
723
|
children: e
|
|
724
724
|
});
|
|
725
|
-
|
|
726
|
-
var
|
|
727
|
-
className: (0,
|
|
725
|
+
U.displayName = "Grid";
|
|
726
|
+
var W = ({ children: e, span: t, sm: n, md: r, lg: i, xl: a, offset: o, smOffset: s, mdOffset: c, lgOffset: u, xlOffset: d, className: f, ...p }) => /* @__PURE__ */ l("div", {
|
|
727
|
+
className: (0, C.default)(t && ce[t], n && le[n], r && ue[r], i && de[i], a && fe[a], o && pe[o], s && me[s], c && he[c], u && ge[u], d && _e[d], f),
|
|
728
728
|
...p,
|
|
729
729
|
children: e
|
|
730
730
|
});
|
|
731
|
-
|
|
731
|
+
W.displayName = "Col";
|
|
732
732
|
//#endregion
|
|
733
733
|
//#region src/components/common/QuantityInput/QuantityInput.tsx
|
|
734
|
-
var
|
|
735
|
-
let _ =
|
|
736
|
-
|
|
737
|
-
document.activeElement !== y.current &&
|
|
734
|
+
var G = ({ value: e, onChange: t, min: n = 1, max: a = 999, step: c = 1, disabled: d = !1, label: f, error: p, hint: m, id: h, className: g }) => {
|
|
735
|
+
let _ = i(), v = h ?? _, y = o(null), [b, x] = s(String(e));
|
|
736
|
+
r(() => {
|
|
737
|
+
document.activeElement !== y.current && x(String(e));
|
|
738
738
|
}, [e]);
|
|
739
|
-
let
|
|
740
|
-
let r = parseInt(n, 10), i = isNaN(r) ? e :
|
|
741
|
-
|
|
739
|
+
let S = (e) => Math.min(a, Math.max(n, e)), w = (n) => {
|
|
740
|
+
let r = parseInt(n, 10), i = isNaN(r) ? e : S(r);
|
|
741
|
+
x(String(i)), i !== e && t(i);
|
|
742
742
|
}, T = (e) => {
|
|
743
743
|
let n = e.target.value.replace(/[^0-9]/g, "");
|
|
744
|
-
|
|
744
|
+
x(n);
|
|
745
745
|
let r = parseInt(n, 10);
|
|
746
|
-
isNaN(r) || t(
|
|
746
|
+
isNaN(r) || t(S(r));
|
|
747
747
|
}, E = () => w(b), D = (e) => {
|
|
748
748
|
if (e.key === "Enter") {
|
|
749
749
|
w(b), y.current?.blur();
|
|
@@ -759,28 +759,28 @@ var H = ({ value: e, onChange: t, min: o = 1, max: l = 999, step: u = 1, disable
|
|
|
759
759
|
"Home",
|
|
760
760
|
"End"
|
|
761
761
|
].includes(e.key) && !/^[0-9]$/.test(e.key) && !e.metaKey && !e.ctrlKey && e.preventDefault();
|
|
762
|
-
}, O = () => t(
|
|
763
|
-
return /* @__PURE__ */
|
|
764
|
-
className: (0,
|
|
762
|
+
}, O = () => t(S(e - c)), k = () => t(S(e + c)), A = e - c >= n, j = e + c <= a;
|
|
763
|
+
return /* @__PURE__ */ u("div", {
|
|
764
|
+
className: (0, C.default)("quantity-input-wrapper", g),
|
|
765
765
|
children: [
|
|
766
|
-
f && /* @__PURE__ */
|
|
766
|
+
f && /* @__PURE__ */ l("label", {
|
|
767
767
|
htmlFor: v,
|
|
768
768
|
className: "input-label",
|
|
769
769
|
children: f
|
|
770
770
|
}),
|
|
771
|
-
/* @__PURE__ */
|
|
772
|
-
className: (0,
|
|
771
|
+
/* @__PURE__ */ u("div", {
|
|
772
|
+
className: (0, C.default)("quantity-input", p && "has-error", d && "is-disabled"),
|
|
773
773
|
children: [
|
|
774
|
-
/* @__PURE__ */
|
|
774
|
+
/* @__PURE__ */ l("button", {
|
|
775
775
|
type: "button",
|
|
776
776
|
className: "quantity-btn",
|
|
777
777
|
onClick: O,
|
|
778
778
|
disabled: d || !A,
|
|
779
779
|
"aria-label": "Snížit množství",
|
|
780
780
|
tabIndex: -1,
|
|
781
|
-
children: /* @__PURE__ */
|
|
781
|
+
children: /* @__PURE__ */ l(ve, {})
|
|
782
782
|
}),
|
|
783
|
-
/* @__PURE__ */
|
|
783
|
+
/* @__PURE__ */ l("input", {
|
|
784
784
|
ref: y,
|
|
785
785
|
id: v,
|
|
786
786
|
type: "text",
|
|
@@ -792,122 +792,122 @@ var H = ({ value: e, onChange: t, min: o = 1, max: l = 999, step: u = 1, disable
|
|
|
792
792
|
onKeyDown: D,
|
|
793
793
|
disabled: d,
|
|
794
794
|
"aria-label": f ?? "Množství",
|
|
795
|
-
"aria-valuemin":
|
|
796
|
-
"aria-valuemax":
|
|
795
|
+
"aria-valuemin": n,
|
|
796
|
+
"aria-valuemax": a,
|
|
797
797
|
"aria-valuenow": e
|
|
798
798
|
}),
|
|
799
|
-
/* @__PURE__ */
|
|
799
|
+
/* @__PURE__ */ l("button", {
|
|
800
800
|
type: "button",
|
|
801
801
|
className: "quantity-btn",
|
|
802
802
|
onClick: k,
|
|
803
803
|
disabled: d || !j,
|
|
804
804
|
"aria-label": "Zvýšit množství",
|
|
805
805
|
tabIndex: -1,
|
|
806
|
-
children: /* @__PURE__ */
|
|
806
|
+
children: /* @__PURE__ */ l(ye, {})
|
|
807
807
|
})
|
|
808
808
|
]
|
|
809
809
|
}),
|
|
810
|
-
(p || m) && /* @__PURE__ */
|
|
811
|
-
className: (0,
|
|
810
|
+
(p || m) && /* @__PURE__ */ l("p", {
|
|
811
|
+
className: (0, C.default)("helper-text", p && "has-error"),
|
|
812
812
|
children: p ?? m
|
|
813
813
|
})
|
|
814
814
|
]
|
|
815
815
|
});
|
|
816
816
|
};
|
|
817
|
-
|
|
818
|
-
var
|
|
817
|
+
G.displayName = "QuantityInput";
|
|
818
|
+
var ve = () => /* @__PURE__ */ l("svg", {
|
|
819
819
|
width: "12",
|
|
820
820
|
height: "2",
|
|
821
821
|
viewBox: "0 0 12 2",
|
|
822
822
|
fill: "none",
|
|
823
823
|
"aria-hidden": "true",
|
|
824
|
-
children: /* @__PURE__ */
|
|
824
|
+
children: /* @__PURE__ */ l("path", {
|
|
825
825
|
d: "M1 1H11",
|
|
826
826
|
stroke: "currentColor",
|
|
827
827
|
strokeWidth: "1.5",
|
|
828
828
|
strokeLinecap: "round"
|
|
829
829
|
})
|
|
830
|
-
}),
|
|
830
|
+
}), ye = () => /* @__PURE__ */ l("svg", {
|
|
831
831
|
width: "12",
|
|
832
832
|
height: "12",
|
|
833
833
|
viewBox: "0 0 12 12",
|
|
834
834
|
fill: "none",
|
|
835
835
|
"aria-hidden": "true",
|
|
836
|
-
children: /* @__PURE__ */
|
|
836
|
+
children: /* @__PURE__ */ l("path", {
|
|
837
837
|
d: "M6 1V11M1 6H11",
|
|
838
838
|
stroke: "currentColor",
|
|
839
839
|
strokeWidth: "1.5",
|
|
840
840
|
strokeLinecap: "round"
|
|
841
841
|
})
|
|
842
|
-
}),
|
|
843
|
-
if (t <= n * 2 + 5) return
|
|
842
|
+
}), K = (e, t) => Array.from({ length: t - e + 1 }, (t, n) => e + n), be = (e, t, n) => {
|
|
843
|
+
if (t <= n * 2 + 5) return K(1, t);
|
|
844
844
|
let r = Math.max(e - n, 1), i = Math.min(e + n, t), a = r > 2, o = i < t - 1;
|
|
845
845
|
return !a && o ? [
|
|
846
|
-
...
|
|
846
|
+
...K(1, 3 + n * 2),
|
|
847
847
|
"…",
|
|
848
848
|
t
|
|
849
849
|
] : a && !o ? [
|
|
850
850
|
1,
|
|
851
851
|
"…",
|
|
852
|
-
...
|
|
852
|
+
...K(t - (2 + n * 2), t)
|
|
853
853
|
] : [
|
|
854
854
|
1,
|
|
855
855
|
"…",
|
|
856
|
-
...
|
|
856
|
+
...K(r, i),
|
|
857
857
|
"…",
|
|
858
858
|
t
|
|
859
859
|
];
|
|
860
|
-
},
|
|
860
|
+
}, q = ({ active: e, disabled: t, children: n, ...r }) => /* @__PURE__ */ l("button", {
|
|
861
861
|
disabled: t,
|
|
862
|
-
className: (0,
|
|
862
|
+
className: (0, C.default)("pagination-button", `pagination-button-${e ? "active" : "inactive"}`),
|
|
863
863
|
...r,
|
|
864
864
|
children: n
|
|
865
|
-
}),
|
|
866
|
-
let i =
|
|
867
|
-
return /* @__PURE__ */
|
|
865
|
+
}), J = ({ page: e, totalPages: t, onPageChange: n, siblingsCount: r = 1 }) => {
|
|
866
|
+
let i = be(e, t, r);
|
|
867
|
+
return /* @__PURE__ */ u("nav", {
|
|
868
868
|
"aria-label": "Pagination",
|
|
869
869
|
className: "pagination",
|
|
870
870
|
children: [
|
|
871
|
-
/* @__PURE__ */
|
|
871
|
+
/* @__PURE__ */ l(q, {
|
|
872
872
|
disabled: e <= 1,
|
|
873
873
|
onClick: () => n(e - 1),
|
|
874
874
|
"aria-label": "Previous page",
|
|
875
|
-
children: /* @__PURE__ */
|
|
875
|
+
children: /* @__PURE__ */ l("svg", {
|
|
876
876
|
xmlns: "http://www.w3.org/2000/svg",
|
|
877
877
|
fill: "none",
|
|
878
878
|
viewBox: "0 0 24 24",
|
|
879
879
|
strokeWidth: 2,
|
|
880
880
|
stroke: "currentColor",
|
|
881
881
|
className: "w-4 h-4",
|
|
882
|
-
children: /* @__PURE__ */
|
|
882
|
+
children: /* @__PURE__ */ l("path", {
|
|
883
883
|
strokeLinecap: "round",
|
|
884
884
|
strokeLinejoin: "round",
|
|
885
885
|
d: "M15.75 19.5L8.25 12l7.5-7.5"
|
|
886
886
|
})
|
|
887
887
|
})
|
|
888
888
|
}),
|
|
889
|
-
i.map((t, r) => t === "…" ? /* @__PURE__ */
|
|
889
|
+
i.map((t, r) => t === "…" ? /* @__PURE__ */ l("span", {
|
|
890
890
|
className: "pagination-dots",
|
|
891
891
|
children: "…"
|
|
892
|
-
}, `dots-${r}`) : /* @__PURE__ */
|
|
892
|
+
}, `dots-${r}`) : /* @__PURE__ */ l(q, {
|
|
893
893
|
active: t === e,
|
|
894
894
|
onClick: () => n(t),
|
|
895
895
|
"aria-label": `Page ${t}`,
|
|
896
896
|
"aria-current": t === e ? "page" : void 0,
|
|
897
897
|
children: t
|
|
898
898
|
}, t)),
|
|
899
|
-
/* @__PURE__ */
|
|
899
|
+
/* @__PURE__ */ l(q, {
|
|
900
900
|
disabled: e >= t,
|
|
901
901
|
onClick: () => n(e + 1),
|
|
902
902
|
"aria-label": "Next page",
|
|
903
|
-
children: /* @__PURE__ */
|
|
903
|
+
children: /* @__PURE__ */ l("svg", {
|
|
904
904
|
xmlns: "http://www.w3.org/2000/svg",
|
|
905
905
|
fill: "none",
|
|
906
906
|
viewBox: "0 0 24 24",
|
|
907
907
|
strokeWidth: 2,
|
|
908
908
|
stroke: "currentColor",
|
|
909
909
|
className: "w-4 h-4",
|
|
910
|
-
children: /* @__PURE__ */
|
|
910
|
+
children: /* @__PURE__ */ l("path", {
|
|
911
911
|
strokeLinecap: "round",
|
|
912
912
|
strokeLinejoin: "round",
|
|
913
913
|
d: "M8.25 4.5l7.5 7.5-7.5 7.5"
|
|
@@ -918,10 +918,127 @@ var ye = () => /* @__PURE__ */ s("svg", {
|
|
|
918
918
|
});
|
|
919
919
|
};
|
|
920
920
|
//#endregion
|
|
921
|
+
//#region src/components/common/Carousel/Carousel.tsx
|
|
922
|
+
function xe({ children: t, slidesPerView: i = 1, gap: d = 16, arrows: f = !0, dots: p = !0, autoPlay: m = !1, autoPlayInterval: h = 4e3, loop: g = !1, className: _, ...v }) {
|
|
923
|
+
let y = e.toArray(t), b = y.length, x = g ? b - 1 : Math.max(0, b - i), S = b > i, [w, T] = s(0), [E, D] = s(!1), O = o(null), k = o(null), A = o(null), j = o(null), M = n((e, t = !0) => {
|
|
924
|
+
let n = O.current;
|
|
925
|
+
if (!n) return;
|
|
926
|
+
let r = n.children[e];
|
|
927
|
+
r && (t || (n.style.transition = "none", n.getBoundingClientRect()), n.style.transform = `translateX(${-r.offsetLeft}px)`, t || (n.getBoundingClientRect(), n.style.transition = ""));
|
|
928
|
+
}, []), N = n((e) => {
|
|
929
|
+
T(g ? (e % b + b) % b : Math.max(0, Math.min(e, x)));
|
|
930
|
+
}, [
|
|
931
|
+
b,
|
|
932
|
+
g,
|
|
933
|
+
x
|
|
934
|
+
]), P = n(() => N(w - 1), [w, N]), F = n(() => N(w + 1), [w, N]);
|
|
935
|
+
a(() => {
|
|
936
|
+
M(w);
|
|
937
|
+
}, [w, M]), r(() => {
|
|
938
|
+
let e = k.current;
|
|
939
|
+
if (!e) return;
|
|
940
|
+
let t = new ResizeObserver(() => M(w, !1));
|
|
941
|
+
return t.observe(e), () => t.disconnect();
|
|
942
|
+
}, [w, M]), r(() => {
|
|
943
|
+
if (!(!m || E || !S)) return A.current = setInterval(F, h), () => {
|
|
944
|
+
A.current && clearInterval(A.current);
|
|
945
|
+
};
|
|
946
|
+
}, [
|
|
947
|
+
m,
|
|
948
|
+
E,
|
|
949
|
+
h,
|
|
950
|
+
F,
|
|
951
|
+
S
|
|
952
|
+
]);
|
|
953
|
+
let I = (e) => {
|
|
954
|
+
j.current = e.touches[0].clientX;
|
|
955
|
+
}, L = (e) => {
|
|
956
|
+
if (j.current === null) return;
|
|
957
|
+
let t = e.changedTouches[0].clientX - j.current;
|
|
958
|
+
Math.abs(t) > 50 && (t < 0 ? F() : P()), j.current = null;
|
|
959
|
+
};
|
|
960
|
+
if (b === 0) return null;
|
|
961
|
+
let R = g || w > 0, z = g || w < x;
|
|
962
|
+
return /* @__PURE__ */ u("div", {
|
|
963
|
+
className: (0, C.default)("carousel", _),
|
|
964
|
+
onMouseEnter: () => D(!0),
|
|
965
|
+
onMouseLeave: () => D(!1),
|
|
966
|
+
onTouchStart: I,
|
|
967
|
+
onTouchEnd: L,
|
|
968
|
+
...v,
|
|
969
|
+
children: [
|
|
970
|
+
/* @__PURE__ */ l("div", {
|
|
971
|
+
ref: k,
|
|
972
|
+
className: "carousel-viewport",
|
|
973
|
+
children: /* @__PURE__ */ l("div", {
|
|
974
|
+
ref: O,
|
|
975
|
+
className: "carousel-track",
|
|
976
|
+
style: { gap: `${d}px` },
|
|
977
|
+
children: y.map((e, t) => /* @__PURE__ */ l("div", {
|
|
978
|
+
className: "carousel-slide",
|
|
979
|
+
style: {
|
|
980
|
+
minWidth: `calc((100% - ${d}px * ${i - 1}) / ${i})`,
|
|
981
|
+
maxWidth: `calc((100% - ${d}px * ${i - 1}) / ${i})`
|
|
982
|
+
},
|
|
983
|
+
"aria-hidden": t < w || t >= w + i,
|
|
984
|
+
children: e
|
|
985
|
+
}, t))
|
|
986
|
+
})
|
|
987
|
+
}),
|
|
988
|
+
f && S && /* @__PURE__ */ u(c, { children: [/* @__PURE__ */ l("button", {
|
|
989
|
+
onClick: P,
|
|
990
|
+
disabled: !R,
|
|
991
|
+
className: "carousel-btn carousel-btn-prev",
|
|
992
|
+
"aria-label": "Previous slide",
|
|
993
|
+
children: /* @__PURE__ */ l("svg", {
|
|
994
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
995
|
+
fill: "none",
|
|
996
|
+
viewBox: "0 0 24 24",
|
|
997
|
+
strokeWidth: 2,
|
|
998
|
+
stroke: "currentColor",
|
|
999
|
+
className: "w-5 h-5",
|
|
1000
|
+
children: /* @__PURE__ */ l("path", {
|
|
1001
|
+
strokeLinecap: "round",
|
|
1002
|
+
strokeLinejoin: "round",
|
|
1003
|
+
d: "M15.75 19.5L8.25 12l7.5-7.5"
|
|
1004
|
+
})
|
|
1005
|
+
})
|
|
1006
|
+
}), /* @__PURE__ */ l("button", {
|
|
1007
|
+
onClick: F,
|
|
1008
|
+
disabled: !z,
|
|
1009
|
+
className: "carousel-btn carousel-btn-next",
|
|
1010
|
+
"aria-label": "Next slide",
|
|
1011
|
+
children: /* @__PURE__ */ l("svg", {
|
|
1012
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1013
|
+
fill: "none",
|
|
1014
|
+
viewBox: "0 0 24 24",
|
|
1015
|
+
strokeWidth: 2,
|
|
1016
|
+
stroke: "currentColor",
|
|
1017
|
+
className: "w-5 h-5",
|
|
1018
|
+
children: /* @__PURE__ */ l("path", {
|
|
1019
|
+
strokeLinecap: "round",
|
|
1020
|
+
strokeLinejoin: "round",
|
|
1021
|
+
d: "M8.25 4.5l7.5 7.5-7.5 7.5"
|
|
1022
|
+
})
|
|
1023
|
+
})
|
|
1024
|
+
})] }),
|
|
1025
|
+
p && S && /* @__PURE__ */ l("div", {
|
|
1026
|
+
className: "carousel-dots",
|
|
1027
|
+
children: Array.from({ length: x + 1 }).map((e, t) => /* @__PURE__ */ l("button", {
|
|
1028
|
+
onClick: () => N(t),
|
|
1029
|
+
className: (0, C.default)("carousel-dot", t === w && "carousel-dot-active"),
|
|
1030
|
+
"aria-label": `Go to slide ${t + 1}`,
|
|
1031
|
+
"aria-current": t === w ? "true" : void 0
|
|
1032
|
+
}, t))
|
|
1033
|
+
})
|
|
1034
|
+
]
|
|
1035
|
+
});
|
|
1036
|
+
}
|
|
1037
|
+
//#endregion
|
|
921
1038
|
//#region src/components/Header/Header.tsx
|
|
922
|
-
function
|
|
923
|
-
let [
|
|
924
|
-
return /* @__PURE__ */
|
|
1039
|
+
function Y({ trigger: e, items: t, onSelect: n, getKey: r, renderItem: i }) {
|
|
1040
|
+
let [a, c] = s(!1), d = o(null), f = () => c(!1);
|
|
1041
|
+
return /* @__PURE__ */ u("div", {
|
|
925
1042
|
ref: d,
|
|
926
1043
|
className: "relative",
|
|
927
1044
|
onBlur: (e) => {
|
|
@@ -930,83 +1047,83 @@ function K({ trigger: e, items: t, onSelect: n, getKey: r, renderItem: o }) {
|
|
|
930
1047
|
onKeyDown: (e) => {
|
|
931
1048
|
e.key === "Escape" && f();
|
|
932
1049
|
},
|
|
933
|
-
children: [/* @__PURE__ */
|
|
1050
|
+
children: [/* @__PURE__ */ l("div", {
|
|
934
1051
|
role: "button",
|
|
935
1052
|
tabIndex: 0,
|
|
936
|
-
onClick: () =>
|
|
937
|
-
onKeyDown: (e) => e.key === "Enter" &&
|
|
1053
|
+
onClick: () => c((e) => !e),
|
|
1054
|
+
onKeyDown: (e) => e.key === "Enter" && c((e) => !e),
|
|
938
1055
|
className: "cursor-pointer",
|
|
939
1056
|
children: e
|
|
940
|
-
}),
|
|
1057
|
+
}), a && /* @__PURE__ */ l("ul", {
|
|
941
1058
|
role: "menu",
|
|
942
1059
|
className: "absolute right-0 top-full mt-1 z-50 min-w-28 bg-white rounded-lg shadow-lg border border-gray-100 py-1 text-sm",
|
|
943
|
-
children: t.map((e) => /* @__PURE__ */
|
|
1060
|
+
children: t.map((e) => /* @__PURE__ */ l("li", {
|
|
944
1061
|
role: "none",
|
|
945
|
-
children: /* @__PURE__ */
|
|
1062
|
+
children: /* @__PURE__ */ l("button", {
|
|
946
1063
|
role: "menuitem",
|
|
947
1064
|
className: "w-full px-3 py-1.5 text-left hover:bg-gray-50 text-gray-700 whitespace-nowrap",
|
|
948
1065
|
onClick: () => {
|
|
949
1066
|
n(e), f();
|
|
950
1067
|
},
|
|
951
|
-
children:
|
|
1068
|
+
children: i ? i(e) : e.label
|
|
952
1069
|
})
|
|
953
1070
|
}, r(e)))
|
|
954
1071
|
})]
|
|
955
1072
|
});
|
|
956
1073
|
}
|
|
957
1074
|
function Se() {
|
|
958
|
-
return /* @__PURE__ */
|
|
1075
|
+
return /* @__PURE__ */ l("svg", {
|
|
959
1076
|
xmlns: "http://www.w3.org/2000/svg",
|
|
960
1077
|
fill: "none",
|
|
961
1078
|
viewBox: "0 0 24 24",
|
|
962
1079
|
strokeWidth: 1.5,
|
|
963
1080
|
stroke: "currentColor",
|
|
964
1081
|
className: "w-4 h-4",
|
|
965
|
-
children: /* @__PURE__ */
|
|
1082
|
+
children: /* @__PURE__ */ l("path", {
|
|
966
1083
|
strokeLinecap: "round",
|
|
967
1084
|
strokeLinejoin: "round",
|
|
968
1085
|
d: "M21 21l-5.197-5.197m0 0A7.5 7.5 0 105.196 15.803a7.5 7.5 0 0010.607 10.607z"
|
|
969
1086
|
})
|
|
970
1087
|
});
|
|
971
1088
|
}
|
|
972
|
-
function Ce({ logo: e, searchPlaceholder: t = "Hledat produkty…", onSearch: n, cartItemCount: r = 0, onCartClick: i, isLoggedIn:
|
|
973
|
-
let [y, b] =
|
|
974
|
-
return /* @__PURE__ */
|
|
1089
|
+
function Ce({ logo: e, searchPlaceholder: t = "Hledat produkty…", onSearch: n, cartItemCount: r = 0, onCartClick: i, isLoggedIn: a = !1, customerName: o, onCustomerClick: d, currencies: f = [], selectedCurrency: p, onCurrencyChange: m, locales: h = [], selectedLocale: g, onLocaleChange: _, rightSlot: v }) {
|
|
1090
|
+
let [y, b] = s(""), x = f.find((e) => e.code === p), S = h.find((e) => e.code === g);
|
|
1091
|
+
return /* @__PURE__ */ l("header", {
|
|
975
1092
|
className: "bg-white border-b border-gray-200 sticky top-0 z-40",
|
|
976
|
-
children: /* @__PURE__ */
|
|
1093
|
+
children: /* @__PURE__ */ u("div", {
|
|
977
1094
|
className: "max-w-7xl mx-auto px-4 h-16 flex items-center gap-4",
|
|
978
1095
|
children: [
|
|
979
|
-
/* @__PURE__ */
|
|
1096
|
+
/* @__PURE__ */ l("div", {
|
|
980
1097
|
className: "shrink-0",
|
|
981
|
-
children: e ?? /* @__PURE__ */
|
|
1098
|
+
children: e ?? /* @__PURE__ */ l("span", {
|
|
982
1099
|
className: "text-xl font-bold text-primary-600 tracking-tight",
|
|
983
1100
|
children: "shopito"
|
|
984
1101
|
})
|
|
985
1102
|
}),
|
|
986
|
-
/* @__PURE__ */
|
|
1103
|
+
/* @__PURE__ */ l("div", {
|
|
987
1104
|
className: "flex-1 max-w-xl",
|
|
988
|
-
children: /* @__PURE__ */
|
|
1105
|
+
children: /* @__PURE__ */ l(D, {
|
|
989
1106
|
placeholder: t,
|
|
990
1107
|
value: y,
|
|
991
1108
|
onChange: (e) => b(e.target.value),
|
|
992
1109
|
onKeyDown: (e) => {
|
|
993
1110
|
e.key === "Enter" && n?.(y);
|
|
994
1111
|
},
|
|
995
|
-
leftIcon: /* @__PURE__ */
|
|
996
|
-
rightIcon: y ? /* @__PURE__ */
|
|
1112
|
+
leftIcon: /* @__PURE__ */ l(Se, {}),
|
|
1113
|
+
rightIcon: y ? /* @__PURE__ */ l("button", {
|
|
997
1114
|
onClick: () => {
|
|
998
1115
|
b(""), n?.("");
|
|
999
1116
|
},
|
|
1000
1117
|
className: "hover:text-gray-600 transition-colors",
|
|
1001
1118
|
"aria-label": "Clear search",
|
|
1002
|
-
children: /* @__PURE__ */
|
|
1119
|
+
children: /* @__PURE__ */ l("svg", {
|
|
1003
1120
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1004
1121
|
fill: "none",
|
|
1005
1122
|
viewBox: "0 0 24 24",
|
|
1006
1123
|
strokeWidth: 2,
|
|
1007
1124
|
stroke: "currentColor",
|
|
1008
1125
|
className: "w-3.5 h-3.5",
|
|
1009
|
-
children: /* @__PURE__ */
|
|
1126
|
+
children: /* @__PURE__ */ l("path", {
|
|
1010
1127
|
strokeLinecap: "round",
|
|
1011
1128
|
strokeLinejoin: "round",
|
|
1012
1129
|
d: "M6 18L18 6M6 6l12 12"
|
|
@@ -1015,85 +1132,85 @@ function Ce({ logo: e, searchPlaceholder: t = "Hledat produkty…", onSearch: n,
|
|
|
1015
1132
|
}) : void 0
|
|
1016
1133
|
})
|
|
1017
1134
|
}),
|
|
1018
|
-
/* @__PURE__ */
|
|
1135
|
+
/* @__PURE__ */ u("div", {
|
|
1019
1136
|
className: "flex items-center gap-1 shrink-0 ml-auto",
|
|
1020
1137
|
children: [
|
|
1021
|
-
f.length > 0 && /* @__PURE__ */
|
|
1022
|
-
trigger: /* @__PURE__ */
|
|
1138
|
+
f.length > 0 && /* @__PURE__ */ l(Y, {
|
|
1139
|
+
trigger: /* @__PURE__ */ u("button", {
|
|
1023
1140
|
className: "flex items-center gap-1 px-2 py-1.5 rounded-md text-sm text-gray-600 hover:bg-gray-50 transition-colors font-medium",
|
|
1024
1141
|
children: [
|
|
1025
|
-
/* @__PURE__ */
|
|
1026
|
-
/* @__PURE__ */
|
|
1142
|
+
/* @__PURE__ */ l("span", { children: x?.symbol ?? p }),
|
|
1143
|
+
/* @__PURE__ */ l("span", {
|
|
1027
1144
|
className: "text-xs text-gray-400",
|
|
1028
1145
|
children: x?.code ?? p
|
|
1029
1146
|
}),
|
|
1030
|
-
/* @__PURE__ */
|
|
1147
|
+
/* @__PURE__ */ l(X, { className: "w-3 h-3 text-gray-400" })
|
|
1031
1148
|
]
|
|
1032
1149
|
}),
|
|
1033
1150
|
items: f,
|
|
1034
1151
|
getKey: (e) => e.code,
|
|
1035
1152
|
onSelect: (e) => m?.(e.code),
|
|
1036
|
-
renderItem: (e) => /* @__PURE__ */
|
|
1153
|
+
renderItem: (e) => /* @__PURE__ */ u("span", {
|
|
1037
1154
|
className: "flex items-center gap-2",
|
|
1038
|
-
children: [/* @__PURE__ */
|
|
1155
|
+
children: [/* @__PURE__ */ l("span", {
|
|
1039
1156
|
className: "w-6 text-center font-medium text-gray-500",
|
|
1040
1157
|
children: e.symbol
|
|
1041
|
-
}), /* @__PURE__ */
|
|
1158
|
+
}), /* @__PURE__ */ l("span", { children: e.label })]
|
|
1042
1159
|
})
|
|
1043
1160
|
}),
|
|
1044
|
-
h.length > 0 && /* @__PURE__ */
|
|
1045
|
-
trigger: /* @__PURE__ */
|
|
1161
|
+
h.length > 0 && /* @__PURE__ */ l(Y, {
|
|
1162
|
+
trigger: /* @__PURE__ */ u("button", {
|
|
1046
1163
|
className: "flex items-center gap-1 px-2 py-1.5 rounded-md text-sm text-gray-600 hover:bg-gray-50 transition-colors",
|
|
1047
1164
|
children: [
|
|
1048
|
-
S?.flag && /* @__PURE__ */
|
|
1165
|
+
S?.flag && /* @__PURE__ */ l("span", {
|
|
1049
1166
|
className: "text-base leading-none",
|
|
1050
1167
|
children: S.flag
|
|
1051
1168
|
}),
|
|
1052
|
-
/* @__PURE__ */
|
|
1169
|
+
/* @__PURE__ */ l("span", {
|
|
1053
1170
|
className: "font-medium uppercase",
|
|
1054
1171
|
children: S?.code ?? g
|
|
1055
1172
|
}),
|
|
1056
|
-
/* @__PURE__ */
|
|
1173
|
+
/* @__PURE__ */ l(X, { className: "w-3 h-3 text-gray-400" })
|
|
1057
1174
|
]
|
|
1058
1175
|
}),
|
|
1059
1176
|
items: h,
|
|
1060
1177
|
getKey: (e) => e.code,
|
|
1061
1178
|
onSelect: (e) => _?.(e.code),
|
|
1062
|
-
renderItem: (e) => /* @__PURE__ */
|
|
1179
|
+
renderItem: (e) => /* @__PURE__ */ u("span", {
|
|
1063
1180
|
className: "flex items-center gap-2",
|
|
1064
|
-
children: [e.flag && /* @__PURE__ */
|
|
1181
|
+
children: [e.flag && /* @__PURE__ */ l("span", {
|
|
1065
1182
|
className: "text-base",
|
|
1066
1183
|
children: e.flag
|
|
1067
|
-
}), /* @__PURE__ */
|
|
1184
|
+
}), /* @__PURE__ */ l("span", { children: e.label })]
|
|
1068
1185
|
})
|
|
1069
1186
|
}),
|
|
1070
|
-
(f.length > 0 || h.length > 0) && /* @__PURE__ */
|
|
1071
|
-
/* @__PURE__ */
|
|
1187
|
+
(f.length > 0 || h.length > 0) && /* @__PURE__ */ l("div", { className: "w-px h-5 bg-gray-200 mx-1" }),
|
|
1188
|
+
/* @__PURE__ */ l("button", {
|
|
1072
1189
|
onClick: d,
|
|
1073
1190
|
className: "flex items-center gap-1.5 px-2.5 py-1.5 rounded-md text-sm text-gray-600 hover:bg-gray-50 transition-colors",
|
|
1074
|
-
"aria-label":
|
|
1075
|
-
children:
|
|
1191
|
+
"aria-label": a ? "My account" : "Sign in",
|
|
1192
|
+
children: a ? /* @__PURE__ */ u(c, { children: [/* @__PURE__ */ l("div", {
|
|
1076
1193
|
className: "w-6 h-6 rounded-full bg-primary-600 text-white flex items-center justify-center text-xs font-bold",
|
|
1077
|
-
children: (
|
|
1078
|
-
}),
|
|
1194
|
+
children: (o ?? "U")[0].toUpperCase()
|
|
1195
|
+
}), o && /* @__PURE__ */ l("span", {
|
|
1079
1196
|
className: "hidden sm:block font-medium max-w-32 truncate",
|
|
1080
|
-
children:
|
|
1081
|
-
})] }) : /* @__PURE__ */ c
|
|
1197
|
+
children: o
|
|
1198
|
+
})] }) : /* @__PURE__ */ u(c, { children: [/* @__PURE__ */ l(we, { className: "w-5 h-5" }), /* @__PURE__ */ l("span", {
|
|
1082
1199
|
className: "hidden sm:block font-medium",
|
|
1083
1200
|
children: "Přihlásit se"
|
|
1084
1201
|
})] })
|
|
1085
1202
|
}),
|
|
1086
|
-
/* @__PURE__ */
|
|
1203
|
+
/* @__PURE__ */ u("button", {
|
|
1087
1204
|
onClick: i,
|
|
1088
1205
|
className: "relative flex items-center gap-1.5 px-2.5 py-1.5 rounded-md text-sm text-gray-600 hover:bg-gray-50 transition-colors",
|
|
1089
1206
|
"aria-label": `Cart, ${r} items`,
|
|
1090
1207
|
children: [
|
|
1091
|
-
/* @__PURE__ */
|
|
1092
|
-
/* @__PURE__ */
|
|
1208
|
+
/* @__PURE__ */ l(Te, { className: "w-5 h-5" }),
|
|
1209
|
+
/* @__PURE__ */ l("span", {
|
|
1093
1210
|
className: "hidden sm:block font-medium",
|
|
1094
1211
|
children: "Košík"
|
|
1095
1212
|
}),
|
|
1096
|
-
r > 0 && /* @__PURE__ */
|
|
1213
|
+
r > 0 && /* @__PURE__ */ l("span", {
|
|
1097
1214
|
className: "absolute -top-0.5 -right-0.5 min-w-4.5 h-4.5 flex items-center justify-center rounded-full bg-primary-600 text-white text-[10px] font-bold leading-none px-1",
|
|
1098
1215
|
children: r > 99 ? "99+" : r
|
|
1099
1216
|
})
|
|
@@ -1106,15 +1223,15 @@ function Ce({ logo: e, searchPlaceholder: t = "Hledat produkty…", onSearch: n,
|
|
|
1106
1223
|
})
|
|
1107
1224
|
});
|
|
1108
1225
|
}
|
|
1109
|
-
function
|
|
1110
|
-
return /* @__PURE__ */
|
|
1226
|
+
function X({ className: e }) {
|
|
1227
|
+
return /* @__PURE__ */ l("svg", {
|
|
1111
1228
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1112
1229
|
fill: "none",
|
|
1113
1230
|
viewBox: "0 0 24 24",
|
|
1114
1231
|
strokeWidth: 2,
|
|
1115
1232
|
stroke: "currentColor",
|
|
1116
1233
|
className: e,
|
|
1117
|
-
children: /* @__PURE__ */
|
|
1234
|
+
children: /* @__PURE__ */ l("path", {
|
|
1118
1235
|
strokeLinecap: "round",
|
|
1119
1236
|
strokeLinejoin: "round",
|
|
1120
1237
|
d: "M19.5 8.25l-7.5 7.5-7.5-7.5"
|
|
@@ -1122,14 +1239,14 @@ function q({ className: e }) {
|
|
|
1122
1239
|
});
|
|
1123
1240
|
}
|
|
1124
1241
|
function we({ className: e }) {
|
|
1125
|
-
return /* @__PURE__ */
|
|
1242
|
+
return /* @__PURE__ */ l("svg", {
|
|
1126
1243
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1127
1244
|
fill: "none",
|
|
1128
1245
|
viewBox: "0 0 24 24",
|
|
1129
1246
|
strokeWidth: 1.5,
|
|
1130
1247
|
stroke: "currentColor",
|
|
1131
1248
|
className: e,
|
|
1132
|
-
children: /* @__PURE__ */
|
|
1249
|
+
children: /* @__PURE__ */ l("path", {
|
|
1133
1250
|
strokeLinecap: "round",
|
|
1134
1251
|
strokeLinejoin: "round",
|
|
1135
1252
|
d: "M15.75 6a3.75 3.75 0 11-7.5 0 3.75 3.75 0 017.5 0zM4.501 20.118a7.5 7.5 0 0114.998 0A17.933 17.933 0 0112 21.75c-2.676 0-5.216-.584-7.499-1.632z"
|
|
@@ -1137,14 +1254,14 @@ function we({ className: e }) {
|
|
|
1137
1254
|
});
|
|
1138
1255
|
}
|
|
1139
1256
|
function Te({ className: e }) {
|
|
1140
|
-
return /* @__PURE__ */
|
|
1257
|
+
return /* @__PURE__ */ l("svg", {
|
|
1141
1258
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1142
1259
|
fill: "none",
|
|
1143
1260
|
viewBox: "0 0 24 24",
|
|
1144
1261
|
strokeWidth: 1.5,
|
|
1145
1262
|
stroke: "currentColor",
|
|
1146
1263
|
className: e,
|
|
1147
|
-
children: /* @__PURE__ */
|
|
1264
|
+
children: /* @__PURE__ */ l("path", {
|
|
1148
1265
|
strokeLinecap: "round",
|
|
1149
1266
|
strokeLinejoin: "round",
|
|
1150
1267
|
d: "M2.25 3h1.386c.51 0 .955.343 1.087.835l.383 1.437M7.5 14.25a3 3 0 00-3 3h15.75m-12.75-3h11.218c1.121-2.3 2.1-4.684 2.924-7.138a60.114 60.114 0 00-16.536-1.84M7.5 14.25L5.106 5.272M6 20.25a.75.75 0 11-1.5 0 .75.75 0 011.5 0zm12.75 0a.75.75 0 11-1.5 0 .75.75 0 011.5 0z"
|
|
@@ -1153,9 +1270,9 @@ function Te({ className: e }) {
|
|
|
1153
1270
|
}
|
|
1154
1271
|
//#endregion
|
|
1155
1272
|
//#region src/components/CategoryTree/CategoryTree.tsx
|
|
1156
|
-
function
|
|
1157
|
-
let
|
|
1158
|
-
return /* @__PURE__ */
|
|
1273
|
+
function Z({ node: e, activeId: t, onSelect: n, showCounts: r, depth: i, defaultExpandAll: a }) {
|
|
1274
|
+
let o = e.children && e.children.length > 0, [c, d] = s(a || Q(e, t)), f = e.id === t;
|
|
1275
|
+
return /* @__PURE__ */ u("li", { children: [/* @__PURE__ */ u("div", {
|
|
1159
1276
|
className: [
|
|
1160
1277
|
"group flex items-center gap-1.5 rounded-lg px-2 py-1.5 cursor-pointer select-none",
|
|
1161
1278
|
"transition-colors text-sm",
|
|
@@ -1164,72 +1281,72 @@ function J({ node: e, activeId: t, onSelect: n, showCounts: r, depth: i, default
|
|
|
1164
1281
|
].filter(Boolean).join(" "),
|
|
1165
1282
|
style: i > 0 ? { marginLeft: i * 16 } : void 0,
|
|
1166
1283
|
onClick: () => {
|
|
1167
|
-
n(e),
|
|
1284
|
+
n(e), o && d((e) => !e);
|
|
1168
1285
|
},
|
|
1169
1286
|
role: "button",
|
|
1170
1287
|
tabIndex: 0,
|
|
1171
1288
|
onKeyDown: (t) => {
|
|
1172
|
-
(t.key === "Enter" || t.key === " ") && (t.preventDefault(), n(e),
|
|
1289
|
+
(t.key === "Enter" || t.key === " ") && (t.preventDefault(), n(e), o && d((e) => !e));
|
|
1173
1290
|
},
|
|
1174
|
-
"aria-expanded":
|
|
1291
|
+
"aria-expanded": o ? c : void 0,
|
|
1175
1292
|
children: [
|
|
1176
|
-
|
|
1177
|
-
className: `shrink-0 text-gray-400 transition-transform duration-150 ${
|
|
1178
|
-
children: /* @__PURE__ */
|
|
1293
|
+
o ? /* @__PURE__ */ l("span", {
|
|
1294
|
+
className: `shrink-0 text-gray-400 transition-transform duration-150 ${c ? "rotate-90" : ""}`,
|
|
1295
|
+
children: /* @__PURE__ */ l("svg", {
|
|
1179
1296
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1180
1297
|
fill: "none",
|
|
1181
1298
|
viewBox: "0 0 24 24",
|
|
1182
1299
|
strokeWidth: 2,
|
|
1183
1300
|
stroke: "currentColor",
|
|
1184
1301
|
className: "w-3.5 h-3.5",
|
|
1185
|
-
children: /* @__PURE__ */
|
|
1302
|
+
children: /* @__PURE__ */ l("path", {
|
|
1186
1303
|
strokeLinecap: "round",
|
|
1187
1304
|
strokeLinejoin: "round",
|
|
1188
1305
|
d: "M8.25 4.5l7.5 7.5-7.5 7.5"
|
|
1189
1306
|
})
|
|
1190
1307
|
})
|
|
1191
|
-
}) : /* @__PURE__ */
|
|
1192
|
-
e.icon && /* @__PURE__ */
|
|
1308
|
+
}) : /* @__PURE__ */ l("span", { className: "w-3.5 shrink-0" }),
|
|
1309
|
+
e.icon && /* @__PURE__ */ l("span", {
|
|
1193
1310
|
className: "text-base leading-none",
|
|
1194
1311
|
children: e.icon
|
|
1195
1312
|
}),
|
|
1196
|
-
/* @__PURE__ */
|
|
1313
|
+
/* @__PURE__ */ l("span", {
|
|
1197
1314
|
className: "flex-1 truncate",
|
|
1198
1315
|
children: e.label
|
|
1199
1316
|
}),
|
|
1200
|
-
r && e.count !== void 0 && /* @__PURE__ */
|
|
1317
|
+
r && e.count !== void 0 && /* @__PURE__ */ l("span", {
|
|
1201
1318
|
className: `text-xs rounded-full px-1.5 py-0.5 font-medium ${f ? "bg-primary-100 text-primary-600" : "bg-gray-100 text-gray-500"}`,
|
|
1202
1319
|
children: e.count
|
|
1203
1320
|
})
|
|
1204
1321
|
]
|
|
1205
|
-
}),
|
|
1322
|
+
}), o && c && /* @__PURE__ */ l("ul", {
|
|
1206
1323
|
role: "group",
|
|
1207
|
-
children: e.children.map((e) => /* @__PURE__ */
|
|
1324
|
+
children: e.children.map((e) => /* @__PURE__ */ l(Z, {
|
|
1208
1325
|
node: e,
|
|
1209
1326
|
activeId: t,
|
|
1210
1327
|
onSelect: n,
|
|
1211
1328
|
showCounts: r,
|
|
1212
1329
|
depth: i + 1,
|
|
1213
|
-
defaultExpandAll:
|
|
1330
|
+
defaultExpandAll: a
|
|
1214
1331
|
}, e.id))
|
|
1215
1332
|
})] });
|
|
1216
1333
|
}
|
|
1217
|
-
function
|
|
1218
|
-
return !t || !e.children ? !1 : e.children.some((e) => e.id === t ||
|
|
1334
|
+
function Q(e, t) {
|
|
1335
|
+
return !t || !e.children ? !1 : e.children.some((e) => e.id === t || Q(e, t));
|
|
1219
1336
|
}
|
|
1220
1337
|
function Ee({ categories: e, activeId: t, onSelect: n, showCounts: r = !0, defaultExpandAll: i = !1, className: a = "", ...o }) {
|
|
1221
|
-
let
|
|
1222
|
-
return /* @__PURE__ */
|
|
1338
|
+
let s = (e) => n?.(e);
|
|
1339
|
+
return /* @__PURE__ */ l("nav", {
|
|
1223
1340
|
"aria-label": "Category navigation",
|
|
1224
1341
|
className: ["w-full", a].filter(Boolean).join(" "),
|
|
1225
1342
|
...o,
|
|
1226
|
-
children: /* @__PURE__ */
|
|
1343
|
+
children: /* @__PURE__ */ l("ul", {
|
|
1227
1344
|
role: "tree",
|
|
1228
1345
|
className: "space-y-0.5",
|
|
1229
|
-
children: e.map((e) => /* @__PURE__ */
|
|
1346
|
+
children: e.map((e) => /* @__PURE__ */ l(Z, {
|
|
1230
1347
|
node: e,
|
|
1231
1348
|
activeId: t,
|
|
1232
|
-
onSelect:
|
|
1349
|
+
onSelect: s,
|
|
1233
1350
|
showCounts: r,
|
|
1234
1351
|
depth: 0,
|
|
1235
1352
|
defaultExpandAll: i
|
|
@@ -1240,58 +1357,58 @@ function Ee({ categories: e, activeId: t, onSelect: n, showCounts: r = !0, defau
|
|
|
1240
1357
|
//#endregion
|
|
1241
1358
|
//#region src/components/MegaMenu/MegaMenu.tsx
|
|
1242
1359
|
function De({ item: e, onNavigate: t, onClose: n }) {
|
|
1243
|
-
return e.columns?.length ? /* @__PURE__ */
|
|
1360
|
+
return e.columns?.length ? /* @__PURE__ */ l("div", {
|
|
1244
1361
|
className: "absolute left-0 right-0 top-full z-50 bg-white border-b border-gray-200 shadow-lg",
|
|
1245
|
-
children: /* @__PURE__ */
|
|
1362
|
+
children: /* @__PURE__ */ u("div", {
|
|
1246
1363
|
className: "max-w-7xl mx-auto px-4 py-6 flex gap-8",
|
|
1247
|
-
children: [/* @__PURE__ */
|
|
1364
|
+
children: [/* @__PURE__ */ l("div", {
|
|
1248
1365
|
className: "flex-1 grid grid-cols-2 md:grid-cols-3 lg:grid-cols-4 gap-6",
|
|
1249
|
-
children: e.columns.map((e, r) => /* @__PURE__ */
|
|
1366
|
+
children: e.columns.map((e, r) => /* @__PURE__ */ u("div", { children: [e.heading && /* @__PURE__ */ l("p", {
|
|
1250
1367
|
className: "text-xs font-semibold uppercase tracking-wider text-gray-400 mb-2",
|
|
1251
1368
|
children: e.heading
|
|
1252
|
-
}), /* @__PURE__ */
|
|
1369
|
+
}), /* @__PURE__ */ l("ul", {
|
|
1253
1370
|
className: "space-y-1",
|
|
1254
|
-
children: e.items.map((e) => /* @__PURE__ */
|
|
1371
|
+
children: e.items.map((e) => /* @__PURE__ */ l("li", { children: /* @__PURE__ */ u("button", {
|
|
1255
1372
|
className: "flex items-center gap-1.5 text-sm text-gray-700 hover:text-primary-600 transition-colors py-0.5",
|
|
1256
1373
|
onClick: () => {
|
|
1257
1374
|
t(e), n();
|
|
1258
1375
|
},
|
|
1259
|
-
children: [e.label, e.badge && /* @__PURE__ */
|
|
1376
|
+
children: [e.label, e.badge && /* @__PURE__ */ l("span", {
|
|
1260
1377
|
className: "text-[10px] font-semibold px-1.5 py-0.5 rounded-full bg-danger-50 text-danger-600 leading-none",
|
|
1261
1378
|
children: e.badge
|
|
1262
1379
|
})]
|
|
1263
1380
|
}) }, e.id))
|
|
1264
1381
|
})] }, r))
|
|
1265
|
-
}), e.featured && /* @__PURE__ */
|
|
1382
|
+
}), e.featured && /* @__PURE__ */ l("div", {
|
|
1266
1383
|
className: "w-52 shrink-0",
|
|
1267
|
-
children: /* @__PURE__ */
|
|
1384
|
+
children: /* @__PURE__ */ u("button", {
|
|
1268
1385
|
className: "group block w-full rounded-xl overflow-hidden border border-gray-100 text-left hover:shadow-md transition-shadow",
|
|
1269
1386
|
onClick: () => {
|
|
1270
1387
|
t(e), n();
|
|
1271
1388
|
},
|
|
1272
|
-
children: [e.featured.image ? /* @__PURE__ */
|
|
1389
|
+
children: [e.featured.image ? /* @__PURE__ */ l("img", {
|
|
1273
1390
|
src: e.featured.image,
|
|
1274
1391
|
alt: e.featured.title,
|
|
1275
1392
|
className: "w-full h-28 object-cover"
|
|
1276
|
-
}) : /* @__PURE__ */
|
|
1393
|
+
}) : /* @__PURE__ */ l("div", {
|
|
1277
1394
|
className: "w-full h-28 bg-linear-to-br from-primary-100 to-primary-200 flex items-center justify-center text-4xl",
|
|
1278
1395
|
children: e.icon ?? "🛍️"
|
|
1279
|
-
}), /* @__PURE__ */
|
|
1396
|
+
}), /* @__PURE__ */ u("div", {
|
|
1280
1397
|
className: "p-3",
|
|
1281
1398
|
children: [
|
|
1282
|
-
e.featured.eyebrow && /* @__PURE__ */
|
|
1399
|
+
e.featured.eyebrow && /* @__PURE__ */ l("p", {
|
|
1283
1400
|
className: "text-[10px] font-semibold uppercase tracking-wider text-primary-500 mb-0.5",
|
|
1284
1401
|
children: e.featured.eyebrow
|
|
1285
1402
|
}),
|
|
1286
|
-
/* @__PURE__ */
|
|
1403
|
+
/* @__PURE__ */ l("p", {
|
|
1287
1404
|
className: "text-sm font-semibold text-gray-900 group-hover:text-primary-600 transition-colors",
|
|
1288
1405
|
children: e.featured.title
|
|
1289
1406
|
}),
|
|
1290
|
-
e.featured.description && /* @__PURE__ */
|
|
1407
|
+
e.featured.description && /* @__PURE__ */ l("p", {
|
|
1291
1408
|
className: "text-xs text-gray-500 mt-0.5 line-clamp-2",
|
|
1292
1409
|
children: e.featured.description
|
|
1293
1410
|
}),
|
|
1294
|
-
e.featured.cta && /* @__PURE__ */
|
|
1411
|
+
e.featured.cta && /* @__PURE__ */ u("span", {
|
|
1295
1412
|
className: "inline-block mt-2 text-xs font-medium text-primary-600",
|
|
1296
1413
|
children: [e.featured.cta, " →"]
|
|
1297
1414
|
})
|
|
@@ -1303,55 +1420,55 @@ function De({ item: e, onNavigate: t, onClose: n }) {
|
|
|
1303
1420
|
}) : null;
|
|
1304
1421
|
}
|
|
1305
1422
|
function Oe({ items: e, activeId: t, onNavigate: n }) {
|
|
1306
|
-
let [r,
|
|
1307
|
-
|
|
1423
|
+
let [r, i] = s(null), a = o(null), c = (e) => {
|
|
1424
|
+
a.current && clearTimeout(a.current), i(e);
|
|
1308
1425
|
}, d = () => {
|
|
1309
|
-
|
|
1426
|
+
a.current = setTimeout(() => i(null), 120);
|
|
1310
1427
|
}, f = () => {
|
|
1311
|
-
|
|
1428
|
+
a.current && clearTimeout(a.current);
|
|
1312
1429
|
}, p = e.find((e) => e.id === r);
|
|
1313
|
-
return /* @__PURE__ */
|
|
1430
|
+
return /* @__PURE__ */ u("nav", {
|
|
1314
1431
|
"aria-label": "Main navigation",
|
|
1315
1432
|
className: "relative bg-white border-b border-gray-100",
|
|
1316
1433
|
onMouseLeave: d,
|
|
1317
|
-
children: [/* @__PURE__ */
|
|
1434
|
+
children: [/* @__PURE__ */ l("div", {
|
|
1318
1435
|
className: "max-w-7xl mx-auto px-4",
|
|
1319
|
-
children: /* @__PURE__ */
|
|
1436
|
+
children: /* @__PURE__ */ l("ul", {
|
|
1320
1437
|
className: "flex items-center gap-0",
|
|
1321
1438
|
role: "menubar",
|
|
1322
1439
|
children: e.map((e) => {
|
|
1323
|
-
let
|
|
1324
|
-
return /* @__PURE__ */
|
|
1440
|
+
let a = !!e.columns?.length, o = r === e.id, s = t === e.id;
|
|
1441
|
+
return /* @__PURE__ */ l("li", {
|
|
1325
1442
|
role: "none",
|
|
1326
|
-
children: /* @__PURE__ */
|
|
1443
|
+
children: /* @__PURE__ */ u("button", {
|
|
1327
1444
|
role: "menuitem",
|
|
1328
|
-
"aria-haspopup":
|
|
1329
|
-
"aria-expanded":
|
|
1445
|
+
"aria-haspopup": a ? "true" : void 0,
|
|
1446
|
+
"aria-expanded": a ? o : void 0,
|
|
1330
1447
|
className: [
|
|
1331
1448
|
"flex items-center gap-1.5 px-4 py-3.5 text-sm font-medium transition-colors relative",
|
|
1332
1449
|
"outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-primary-500",
|
|
1333
|
-
|
|
1334
|
-
|
|
1450
|
+
s || o ? "text-primary-600" : "text-gray-700 hover:text-gray-900",
|
|
1451
|
+
o ? "after:absolute after:bottom-0 after:left-0 after:right-0 after:h-0.5 after:bg-primary-600" : ""
|
|
1335
1452
|
].filter(Boolean).join(" "),
|
|
1336
|
-
onMouseEnter: () =>
|
|
1337
|
-
onFocus: () =>
|
|
1453
|
+
onMouseEnter: () => a ? c(e.id) : i(null),
|
|
1454
|
+
onFocus: () => a && c(e.id),
|
|
1338
1455
|
onClick: () => {
|
|
1339
|
-
|
|
1456
|
+
a || (n?.(e), i(null));
|
|
1340
1457
|
},
|
|
1341
1458
|
children: [
|
|
1342
|
-
e.icon && /* @__PURE__ */
|
|
1459
|
+
e.icon && /* @__PURE__ */ l("span", {
|
|
1343
1460
|
className: "text-base leading-none",
|
|
1344
1461
|
children: e.icon
|
|
1345
1462
|
}),
|
|
1346
1463
|
e.label,
|
|
1347
|
-
|
|
1464
|
+
a && /* @__PURE__ */ l("svg", {
|
|
1348
1465
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1349
1466
|
fill: "none",
|
|
1350
1467
|
viewBox: "0 0 24 24",
|
|
1351
1468
|
strokeWidth: 2,
|
|
1352
1469
|
stroke: "currentColor",
|
|
1353
|
-
className: `w-3.5 h-3.5 transition-transform duration-150 ${
|
|
1354
|
-
children: /* @__PURE__ */
|
|
1470
|
+
className: `w-3.5 h-3.5 transition-transform duration-150 ${o ? "rotate-180" : ""}`,
|
|
1471
|
+
children: /* @__PURE__ */ l("path", {
|
|
1355
1472
|
strokeLinecap: "round",
|
|
1356
1473
|
strokeLinejoin: "round",
|
|
1357
1474
|
d: "M19.5 8.25l-7.5 7.5-7.5-7.5"
|
|
@@ -1362,35 +1479,35 @@ function Oe({ items: e, activeId: t, onNavigate: n }) {
|
|
|
1362
1479
|
}, e.id);
|
|
1363
1480
|
})
|
|
1364
1481
|
})
|
|
1365
|
-
}), p?.columns?.length && /* @__PURE__ */
|
|
1482
|
+
}), p?.columns?.length && /* @__PURE__ */ l("div", {
|
|
1366
1483
|
onMouseEnter: f,
|
|
1367
1484
|
onMouseLeave: d,
|
|
1368
|
-
children: /* @__PURE__ */
|
|
1485
|
+
children: /* @__PURE__ */ l(De, {
|
|
1369
1486
|
item: p,
|
|
1370
1487
|
onNavigate: (e) => n?.(e),
|
|
1371
|
-
onClose: () =>
|
|
1488
|
+
onClose: () => i(null)
|
|
1372
1489
|
})
|
|
1373
1490
|
})]
|
|
1374
1491
|
});
|
|
1375
1492
|
}
|
|
1376
1493
|
//#endregion
|
|
1377
1494
|
//#region src/components/BannerCarousel/BannerCarousel.tsx
|
|
1378
|
-
function ke({ banners: e, autoPlay:
|
|
1379
|
-
let [m, h] =
|
|
1495
|
+
function ke({ banners: e, autoPlay: t = !0, autoPlayInterval: i = 5e3, arrows: a = !0, dots: d = !0, className: f = "", aspectRatio: p = "3 / 1" }) {
|
|
1496
|
+
let [m, h] = s(0), [g, _] = s(!1), v = o(null), y = o(null), b = e.length, x = n((e) => {
|
|
1380
1497
|
h((e % b + b) % b);
|
|
1381
|
-
}, [b]), S = () => x(m - 1), C =
|
|
1382
|
-
|
|
1383
|
-
if (!(!
|
|
1498
|
+
}, [b]), S = () => x(m - 1), C = n(() => x(m + 1), [m, x]);
|
|
1499
|
+
r(() => {
|
|
1500
|
+
if (!(!t || g || b <= 1)) return v.current = setInterval(C, i), () => {
|
|
1384
1501
|
v.current && clearInterval(v.current);
|
|
1385
1502
|
};
|
|
1386
1503
|
}, [
|
|
1387
|
-
|
|
1504
|
+
t,
|
|
1388
1505
|
g,
|
|
1389
|
-
|
|
1506
|
+
i,
|
|
1390
1507
|
C,
|
|
1391
1508
|
b
|
|
1392
1509
|
]);
|
|
1393
|
-
let w =
|
|
1510
|
+
let w = o(null), T = (e) => {
|
|
1394
1511
|
w.current = e.touches[0].clientX;
|
|
1395
1512
|
}, E = (e) => {
|
|
1396
1513
|
if (w.current === null) return;
|
|
@@ -1399,7 +1516,7 @@ function ke({ banners: e, autoPlay: r = !0, autoPlayInterval: l = 5e3, arrows: u
|
|
|
1399
1516
|
};
|
|
1400
1517
|
if (b === 0) return null;
|
|
1401
1518
|
let D = e[m], O = D.textColor === "light" || !D.textColor;
|
|
1402
|
-
return /* @__PURE__ */
|
|
1519
|
+
return /* @__PURE__ */ u("div", {
|
|
1403
1520
|
className: ["relative overflow-hidden rounded-xl", f].filter(Boolean).join(" "),
|
|
1404
1521
|
style: { aspectRatio: p },
|
|
1405
1522
|
onMouseEnter: () => _(!0),
|
|
@@ -1407,41 +1524,41 @@ function ke({ banners: e, autoPlay: r = !0, autoPlayInterval: l = 5e3, arrows: u
|
|
|
1407
1524
|
onTouchStart: T,
|
|
1408
1525
|
onTouchEnd: E,
|
|
1409
1526
|
children: [
|
|
1410
|
-
/* @__PURE__ */
|
|
1527
|
+
/* @__PURE__ */ l("div", {
|
|
1411
1528
|
ref: y,
|
|
1412
1529
|
className: "relative w-full h-full",
|
|
1413
|
-
children: e.map((e, t) => /* @__PURE__ */
|
|
1530
|
+
children: e.map((e, t) => /* @__PURE__ */ u("div", {
|
|
1414
1531
|
"aria-hidden": t !== m,
|
|
1415
1532
|
className: ["absolute inset-0 transition-opacity duration-700", t === m ? "opacity-100 z-10" : "opacity-0 z-0"].join(" "),
|
|
1416
1533
|
style: { background: e.backgroundImage ? `url(${e.backgroundImage}) center/cover no-repeat` : e.backgroundColor ?? "linear-gradient(135deg, #1d4ed8 0%, #7c3aed 100%)" },
|
|
1417
|
-
children: [e.backgroundImage && /* @__PURE__ */
|
|
1534
|
+
children: [e.backgroundImage && /* @__PURE__ */ l("div", { className: "absolute inset-0 bg-gradient-to-r from-black/50 via-black/20 to-transparent" }), /* @__PURE__ */ u("div", {
|
|
1418
1535
|
className: "relative z-10 h-full flex items-center px-8 md:px-12 gap-8",
|
|
1419
|
-
children: [/* @__PURE__ */
|
|
1536
|
+
children: [/* @__PURE__ */ u("div", {
|
|
1420
1537
|
className: "flex-1 max-w-lg",
|
|
1421
1538
|
children: [
|
|
1422
|
-
e.eyebrow && /* @__PURE__ */
|
|
1539
|
+
e.eyebrow && /* @__PURE__ */ l("p", {
|
|
1423
1540
|
className: `text-xs font-semibold uppercase tracking-widest mb-2 ${O ? "text-white/70" : "text-gray-500"}`,
|
|
1424
1541
|
children: e.eyebrow
|
|
1425
1542
|
}),
|
|
1426
|
-
/* @__PURE__ */
|
|
1543
|
+
/* @__PURE__ */ l("h2", {
|
|
1427
1544
|
className: `text-2xl md:text-3xl lg:text-4xl font-bold leading-tight ${O ? "text-white" : "text-gray-900"}`,
|
|
1428
1545
|
children: e.title
|
|
1429
1546
|
}),
|
|
1430
|
-
e.subtitle && /* @__PURE__ */
|
|
1547
|
+
e.subtitle && /* @__PURE__ */ l("p", {
|
|
1431
1548
|
className: `mt-2 text-sm md:text-base ${O ? "text-white/80" : "text-gray-600"}`,
|
|
1432
1549
|
children: e.subtitle
|
|
1433
1550
|
}),
|
|
1434
|
-
e.ctaLabel && /* @__PURE__ */
|
|
1551
|
+
e.ctaLabel && /* @__PURE__ */ u("button", {
|
|
1435
1552
|
onClick: e.onCtaClick,
|
|
1436
1553
|
className: ["mt-5 inline-flex items-center gap-2 px-5 py-2.5 rounded-lg text-sm font-semibold transition-all", O ? "bg-white text-gray-900 hover:bg-gray-100" : "bg-primary-600 text-white hover:bg-primary-700"].join(" "),
|
|
1437
|
-
children: [e.ctaLabel, /* @__PURE__ */
|
|
1554
|
+
children: [e.ctaLabel, /* @__PURE__ */ l("svg", {
|
|
1438
1555
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1439
1556
|
fill: "none",
|
|
1440
1557
|
viewBox: "0 0 24 24",
|
|
1441
1558
|
strokeWidth: 2,
|
|
1442
1559
|
stroke: "currentColor",
|
|
1443
1560
|
className: "w-4 h-4",
|
|
1444
|
-
children: /* @__PURE__ */
|
|
1561
|
+
children: /* @__PURE__ */ l("path", {
|
|
1445
1562
|
strokeLinecap: "round",
|
|
1446
1563
|
strokeLinejoin: "round",
|
|
1447
1564
|
d: "M8.25 4.5l7.5 7.5-7.5 7.5"
|
|
@@ -1449,9 +1566,9 @@ function ke({ banners: e, autoPlay: r = !0, autoPlayInterval: l = 5e3, arrows: u
|
|
|
1449
1566
|
})]
|
|
1450
1567
|
})
|
|
1451
1568
|
]
|
|
1452
|
-
}), e.sideImage && /* @__PURE__ */
|
|
1569
|
+
}), e.sideImage && /* @__PURE__ */ l("div", {
|
|
1453
1570
|
className: "hidden md:block flex-1 h-full flex items-end justify-end overflow-hidden",
|
|
1454
|
-
children: /* @__PURE__ */
|
|
1571
|
+
children: /* @__PURE__ */ l("img", {
|
|
1455
1572
|
src: e.sideImage,
|
|
1456
1573
|
alt: "",
|
|
1457
1574
|
className: "h-full w-auto object-contain object-bottom drop-shadow-2xl"
|
|
@@ -1460,54 +1577,54 @@ function ke({ banners: e, autoPlay: r = !0, autoPlayInterval: l = 5e3, arrows: u
|
|
|
1460
1577
|
})]
|
|
1461
1578
|
}, e.id))
|
|
1462
1579
|
}),
|
|
1463
|
-
|
|
1580
|
+
a && b > 1 && /* @__PURE__ */ u(c, { children: [/* @__PURE__ */ l("button", {
|
|
1464
1581
|
onClick: S,
|
|
1465
1582
|
className: "absolute left-3 top-1/2 -translate-y-1/2 z-20 w-9 h-9 flex items-center justify-center rounded-full bg-black/30 text-white hover:bg-black/50 transition-colors backdrop-blur-sm",
|
|
1466
1583
|
"aria-label": "Previous banner",
|
|
1467
|
-
children: /* @__PURE__ */
|
|
1584
|
+
children: /* @__PURE__ */ l("svg", {
|
|
1468
1585
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1469
1586
|
fill: "none",
|
|
1470
1587
|
viewBox: "0 0 24 24",
|
|
1471
1588
|
strokeWidth: 2,
|
|
1472
1589
|
stroke: "currentColor",
|
|
1473
1590
|
className: "w-5 h-5",
|
|
1474
|
-
children: /* @__PURE__ */
|
|
1591
|
+
children: /* @__PURE__ */ l("path", {
|
|
1475
1592
|
strokeLinecap: "round",
|
|
1476
1593
|
strokeLinejoin: "round",
|
|
1477
1594
|
d: "M15.75 19.5L8.25 12l7.5-7.5"
|
|
1478
1595
|
})
|
|
1479
1596
|
})
|
|
1480
|
-
}), /* @__PURE__ */
|
|
1597
|
+
}), /* @__PURE__ */ l("button", {
|
|
1481
1598
|
onClick: C,
|
|
1482
1599
|
className: "absolute right-3 top-1/2 -translate-y-1/2 z-20 w-9 h-9 flex items-center justify-center rounded-full bg-black/30 text-white hover:bg-black/50 transition-colors backdrop-blur-sm",
|
|
1483
1600
|
"aria-label": "Next banner",
|
|
1484
|
-
children: /* @__PURE__ */
|
|
1601
|
+
children: /* @__PURE__ */ l("svg", {
|
|
1485
1602
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1486
1603
|
fill: "none",
|
|
1487
1604
|
viewBox: "0 0 24 24",
|
|
1488
1605
|
strokeWidth: 2,
|
|
1489
1606
|
stroke: "currentColor",
|
|
1490
1607
|
className: "w-5 h-5",
|
|
1491
|
-
children: /* @__PURE__ */
|
|
1608
|
+
children: /* @__PURE__ */ l("path", {
|
|
1492
1609
|
strokeLinecap: "round",
|
|
1493
1610
|
strokeLinejoin: "round",
|
|
1494
1611
|
d: "M8.25 4.5l7.5 7.5-7.5 7.5"
|
|
1495
1612
|
})
|
|
1496
1613
|
})
|
|
1497
1614
|
})] }),
|
|
1498
|
-
d && b > 1 && /* @__PURE__ */
|
|
1615
|
+
d && b > 1 && /* @__PURE__ */ l("div", {
|
|
1499
1616
|
className: "absolute bottom-3 left-1/2 -translate-x-1/2 z-20 flex gap-1.5",
|
|
1500
|
-
children: e.map((e, t) => /* @__PURE__ */
|
|
1617
|
+
children: e.map((e, t) => /* @__PURE__ */ l("button", {
|
|
1501
1618
|
onClick: () => x(t),
|
|
1502
1619
|
"aria-label": `Go to slide ${t + 1}`,
|
|
1503
1620
|
className: ["rounded-full transition-all duration-300", t === m ? "w-5 h-2 bg-white" : "w-2 h-2 bg-white/50 hover:bg-white/80"].join(" ")
|
|
1504
1621
|
}, t))
|
|
1505
1622
|
}),
|
|
1506
|
-
|
|
1623
|
+
t && b > 1 && /* @__PURE__ */ l("div", {
|
|
1507
1624
|
className: "absolute bottom-0 left-0 right-0 h-0.5 bg-white/20 z-20",
|
|
1508
|
-
children: /* @__PURE__ */
|
|
1625
|
+
children: /* @__PURE__ */ l("div", {
|
|
1509
1626
|
className: `h-full bg-white/60 ${g ? "" : "animate-progress"}`,
|
|
1510
|
-
style: { animation: g ? "none" : `progress ${
|
|
1627
|
+
style: { animation: g ? "none" : `progress ${i}ms linear` }
|
|
1511
1628
|
}, `${m}-${g}`)
|
|
1512
1629
|
})
|
|
1513
1630
|
]
|
|
@@ -1516,12 +1633,12 @@ function ke({ banners: e, autoPlay: r = !0, autoPlayInterval: l = 5e3, arrows: u
|
|
|
1516
1633
|
//#endregion
|
|
1517
1634
|
//#region src/components/ProductCard/ProductCard.tsx
|
|
1518
1635
|
function Ae({ filled: e }) {
|
|
1519
|
-
return /* @__PURE__ */
|
|
1636
|
+
return /* @__PURE__ */ l("svg", {
|
|
1520
1637
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1521
1638
|
viewBox: "0 0 24 24",
|
|
1522
1639
|
className: `w-3.5 h-3.5 ${e ? "fill-amber-400 stroke-amber-400" : "fill-gray-200 stroke-gray-300"}`,
|
|
1523
1640
|
strokeWidth: 1,
|
|
1524
|
-
children: /* @__PURE__ */
|
|
1641
|
+
children: /* @__PURE__ */ l("path", {
|
|
1525
1642
|
strokeLinecap: "round",
|
|
1526
1643
|
strokeLinejoin: "round",
|
|
1527
1644
|
d: "M11.48 3.499a.562.562 0 011.04 0l2.125 5.111a.563.563 0 00.475.345l5.518.442c.499.04.701.663.321.988l-4.204 3.602a.563.563 0 00-.182.557l1.285 5.385a.562.562 0 01-.84.61l-4.725-2.885a.563.563 0 00-.586 0L6.982 20.54a.562.562 0 01-.84-.61l1.285-5.386a.562.562 0 00-.182-.557l-4.204-3.602a.563.563 0 01.321-.988l5.518-.442a.563.563 0 00.475-.345L11.48 3.5z"
|
|
@@ -1529,9 +1646,9 @@ function Ae({ filled: e }) {
|
|
|
1529
1646
|
});
|
|
1530
1647
|
}
|
|
1531
1648
|
function je({ value: e, count: t }) {
|
|
1532
|
-
return /* @__PURE__ */
|
|
1649
|
+
return /* @__PURE__ */ u("div", {
|
|
1533
1650
|
className: "flex items-center gap-1",
|
|
1534
|
-
children: [/* @__PURE__ */
|
|
1651
|
+
children: [/* @__PURE__ */ l("div", {
|
|
1535
1652
|
className: "flex gap-0.5",
|
|
1536
1653
|
children: [
|
|
1537
1654
|
1,
|
|
@@ -1539,8 +1656,8 @@ function je({ value: e, count: t }) {
|
|
|
1539
1656
|
3,
|
|
1540
1657
|
4,
|
|
1541
1658
|
5
|
|
1542
|
-
].map((t) => /* @__PURE__ */
|
|
1543
|
-
}), t !== void 0 && /* @__PURE__ */
|
|
1659
|
+
].map((t) => /* @__PURE__ */ l(Ae, { filled: t <= Math.round(e) }, t))
|
|
1660
|
+
}), t !== void 0 && /* @__PURE__ */ u("span", {
|
|
1544
1661
|
className: "text-xs text-gray-400",
|
|
1545
1662
|
children: [
|
|
1546
1663
|
"(",
|
|
@@ -1554,50 +1671,50 @@ function Me(e) {
|
|
|
1554
1671
|
let t = e.toLowerCase();
|
|
1555
1672
|
return t === "sale" || t === "akce" ? "danger" : t === "new" || t === "nové" ? "primary" : t === "hot" ? "warning" : "default";
|
|
1556
1673
|
}
|
|
1557
|
-
function
|
|
1674
|
+
function $(e, t = "Kč") {
|
|
1558
1675
|
return `${e.toLocaleString("cs-CZ")} ${t}`;
|
|
1559
1676
|
}
|
|
1560
1677
|
function Ne(e, t) {
|
|
1561
1678
|
return Math.round((1 - t / e) * 100);
|
|
1562
1679
|
}
|
|
1563
|
-
function
|
|
1564
|
-
let [
|
|
1565
|
-
return /* @__PURE__ */
|
|
1680
|
+
function Pe({ product: e, onAddToCart: t, onWishlistToggle: n, isWishlisted: r = !1, onProductClick: i, size: a = "default", className: o = "" }) {
|
|
1681
|
+
let [c, d] = s(!1), [f, p] = s(!1), m = e.originalPrice !== void 0 && e.originalPrice > e.price;
|
|
1682
|
+
return /* @__PURE__ */ u("article", {
|
|
1566
1683
|
className: [
|
|
1567
1684
|
"group relative flex flex-col bg-white rounded-xl border border-gray-200",
|
|
1568
1685
|
"hover:shadow-md transition-shadow duration-200 overflow-hidden cursor-pointer",
|
|
1569
|
-
|
|
1686
|
+
o
|
|
1570
1687
|
].filter(Boolean).join(" "),
|
|
1571
1688
|
onClick: () => i?.(e),
|
|
1572
1689
|
onMouseEnter: () => d(!0),
|
|
1573
1690
|
onMouseLeave: () => d(!1),
|
|
1574
|
-
children: [/* @__PURE__ */
|
|
1575
|
-
className: `relative overflow-hidden bg-gray-50 ${
|
|
1691
|
+
children: [/* @__PURE__ */ u("div", {
|
|
1692
|
+
className: `relative overflow-hidden bg-gray-50 ${a === "compact" ? "aspect-square" : "aspect-4/3"}`,
|
|
1576
1693
|
children: [
|
|
1577
|
-
e.image ? /* @__PURE__ */
|
|
1578
|
-
src:
|
|
1694
|
+
e.image ? /* @__PURE__ */ l("img", {
|
|
1695
|
+
src: c && e.imageHover ? e.imageHover : e.image,
|
|
1579
1696
|
alt: e.name,
|
|
1580
1697
|
className: "w-full h-full object-contain p-4 transition-transform duration-300 group-hover:scale-105"
|
|
1581
|
-
}) : /* @__PURE__ */
|
|
1698
|
+
}) : /* @__PURE__ */ l("div", {
|
|
1582
1699
|
className: "w-full h-full flex items-center justify-center text-5xl bg-linear-to-br from-gray-100 to-gray-200",
|
|
1583
1700
|
children: "🛍️"
|
|
1584
1701
|
}),
|
|
1585
|
-
e.badge && /* @__PURE__ */
|
|
1702
|
+
e.badge && /* @__PURE__ */ l("div", {
|
|
1586
1703
|
className: "absolute top-2 left-2",
|
|
1587
|
-
children: /* @__PURE__ */
|
|
1704
|
+
children: /* @__PURE__ */ l(j, {
|
|
1588
1705
|
variant: Me(e.badge),
|
|
1589
1706
|
size: "sm",
|
|
1590
1707
|
children: e.badge === "sale" && m ? `-${Ne(e.originalPrice, e.price)}%` : e.badge
|
|
1591
1708
|
})
|
|
1592
1709
|
}),
|
|
1593
|
-
e.inStock === !1 && /* @__PURE__ */
|
|
1710
|
+
e.inStock === !1 && /* @__PURE__ */ l("div", {
|
|
1594
1711
|
className: "absolute inset-0 bg-white/70 flex items-center justify-center",
|
|
1595
|
-
children: /* @__PURE__ */
|
|
1712
|
+
children: /* @__PURE__ */ l("span", {
|
|
1596
1713
|
className: "text-sm font-semibold text-gray-500 bg-white/90 px-3 py-1 rounded-full border border-gray-200",
|
|
1597
1714
|
children: "Vyprodáno"
|
|
1598
1715
|
})
|
|
1599
1716
|
}),
|
|
1600
|
-
/* @__PURE__ */
|
|
1717
|
+
/* @__PURE__ */ l("button", {
|
|
1601
1718
|
onClick: (t) => {
|
|
1602
1719
|
t.stopPropagation(), n?.(e);
|
|
1603
1720
|
},
|
|
@@ -1608,22 +1725,22 @@ function Z({ product: e, onAddToCart: t, onWishlistToggle: n, isWishlisted: r =
|
|
|
1608
1725
|
"opacity-0 group-hover:opacity-100 focus:opacity-100",
|
|
1609
1726
|
r ? "text-danger-500" : "text-gray-400 hover:text-danger-400"
|
|
1610
1727
|
].join(" "),
|
|
1611
|
-
children: /* @__PURE__ */
|
|
1728
|
+
children: /* @__PURE__ */ l("svg", {
|
|
1612
1729
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1613
1730
|
viewBox: "0 0 24 24",
|
|
1614
1731
|
strokeWidth: 1.5,
|
|
1615
1732
|
stroke: "currentColor",
|
|
1616
1733
|
className: `w-4 h-4 ${r ? "fill-current" : "fill-none"}`,
|
|
1617
|
-
children: /* @__PURE__ */
|
|
1734
|
+
children: /* @__PURE__ */ l("path", {
|
|
1618
1735
|
strokeLinecap: "round",
|
|
1619
1736
|
strokeLinejoin: "round",
|
|
1620
1737
|
d: "M21 8.25c0-2.485-2.099-4.5-4.688-4.5-1.935 0-3.597 1.126-4.312 2.733-.715-1.607-2.377-2.733-4.313-2.733C5.1 3.75 3 5.765 3 8.25c0 7.22 9 12 9 12s9-4.78 9-12z"
|
|
1621
1738
|
})
|
|
1622
1739
|
})
|
|
1623
1740
|
}),
|
|
1624
|
-
/* @__PURE__ */
|
|
1625
|
-
className: ["absolute bottom-0 left-0 right-0 p-2 transition-transform duration-200",
|
|
1626
|
-
children: /* @__PURE__ */
|
|
1741
|
+
/* @__PURE__ */ l("div", {
|
|
1742
|
+
className: ["absolute bottom-0 left-0 right-0 p-2 transition-transform duration-200", c ? "translate-y-0" : "translate-y-full"].join(" "),
|
|
1743
|
+
children: /* @__PURE__ */ l(w, {
|
|
1627
1744
|
variant: "primary",
|
|
1628
1745
|
size: "sm",
|
|
1629
1746
|
fullWidth: !0,
|
|
@@ -1633,16 +1750,16 @@ function Z({ product: e, onAddToCart: t, onWishlistToggle: n, isWishlisted: r =
|
|
|
1633
1750
|
n.stopPropagation(), t?.(e), p(!0), setTimeout(() => p(!1), 1500);
|
|
1634
1751
|
},
|
|
1635
1752
|
className: "shadow-lg",
|
|
1636
|
-
children: f ? /* @__PURE__ */
|
|
1753
|
+
children: f ? /* @__PURE__ */ u("span", {
|
|
1637
1754
|
className: "flex items-center gap-1.5",
|
|
1638
|
-
children: [/* @__PURE__ */
|
|
1755
|
+
children: [/* @__PURE__ */ l("svg", {
|
|
1639
1756
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1640
1757
|
fill: "none",
|
|
1641
1758
|
viewBox: "0 0 24 24",
|
|
1642
1759
|
strokeWidth: 2,
|
|
1643
1760
|
stroke: "currentColor",
|
|
1644
1761
|
className: "w-4 h-4",
|
|
1645
|
-
children: /* @__PURE__ */
|
|
1762
|
+
children: /* @__PURE__ */ l("path", {
|
|
1646
1763
|
strokeLinecap: "round",
|
|
1647
1764
|
strokeLinejoin: "round",
|
|
1648
1765
|
d: "M4.5 12.75l6 6 9-13.5"
|
|
@@ -1652,36 +1769,36 @@ function Z({ product: e, onAddToCart: t, onWishlistToggle: n, isWishlisted: r =
|
|
|
1652
1769
|
})
|
|
1653
1770
|
})
|
|
1654
1771
|
]
|
|
1655
|
-
}), /* @__PURE__ */
|
|
1656
|
-
className: `flex flex-col gap-1.5 ${
|
|
1772
|
+
}), /* @__PURE__ */ u("div", {
|
|
1773
|
+
className: `flex flex-col gap-1.5 ${a === "compact" ? "p-3" : "p-4"}`,
|
|
1657
1774
|
children: [
|
|
1658
|
-
e.variants && e.variants.length > 0 && /* @__PURE__ */
|
|
1775
|
+
e.variants && e.variants.length > 0 && /* @__PURE__ */ u("div", {
|
|
1659
1776
|
className: "flex gap-1",
|
|
1660
|
-
children: [e.variants.slice(0, 5).map((e) => /* @__PURE__ */
|
|
1777
|
+
children: [e.variants.slice(0, 5).map((e) => /* @__PURE__ */ l("span", {
|
|
1661
1778
|
title: e.label,
|
|
1662
1779
|
className: "w-4 h-4 rounded-full border border-gray-300 shrink-0",
|
|
1663
1780
|
style: { backgroundColor: e.color ?? "#ccc" }
|
|
1664
|
-
}, e.id)), e.variants.length > 5 && /* @__PURE__ */
|
|
1781
|
+
}, e.id)), e.variants.length > 5 && /* @__PURE__ */ u("span", {
|
|
1665
1782
|
className: "text-xs text-gray-400",
|
|
1666
1783
|
children: ["+", e.variants.length - 5]
|
|
1667
1784
|
})]
|
|
1668
1785
|
}),
|
|
1669
|
-
/* @__PURE__ */
|
|
1670
|
-
className: `font-medium text-gray-900 leading-snug line-clamp-2 group-hover:text-primary-600 transition-colors ${
|
|
1786
|
+
/* @__PURE__ */ l("h3", {
|
|
1787
|
+
className: `font-medium text-gray-900 leading-snug line-clamp-2 group-hover:text-primary-600 transition-colors ${a === "compact" ? "text-xs" : "text-sm"}`,
|
|
1671
1788
|
children: e.name
|
|
1672
1789
|
}),
|
|
1673
|
-
e.rating !== void 0 && /* @__PURE__ */
|
|
1790
|
+
e.rating !== void 0 && /* @__PURE__ */ l(je, {
|
|
1674
1791
|
value: e.rating,
|
|
1675
1792
|
count: e.reviewCount
|
|
1676
1793
|
}),
|
|
1677
|
-
/* @__PURE__ */
|
|
1794
|
+
/* @__PURE__ */ u("div", {
|
|
1678
1795
|
className: "flex items-baseline gap-2 mt-auto pt-1",
|
|
1679
|
-
children: [/* @__PURE__ */
|
|
1680
|
-
className: `font-bold text-gray-900 ${
|
|
1681
|
-
children:
|
|
1682
|
-
}), m && /* @__PURE__ */
|
|
1796
|
+
children: [/* @__PURE__ */ l("span", {
|
|
1797
|
+
className: `font-bold text-gray-900 ${a === "compact" ? "text-base" : "text-lg"}`,
|
|
1798
|
+
children: $(e.price, e.currency)
|
|
1799
|
+
}), m && /* @__PURE__ */ l("span", {
|
|
1683
1800
|
className: "text-sm text-gray-400 line-through",
|
|
1684
|
-
children:
|
|
1801
|
+
children: $(e.originalPrice, e.currency)
|
|
1685
1802
|
})]
|
|
1686
1803
|
})
|
|
1687
1804
|
]
|
|
@@ -1690,12 +1807,12 @@ function Z({ product: e, onAddToCart: t, onWishlistToggle: n, isWishlisted: r =
|
|
|
1690
1807
|
}
|
|
1691
1808
|
//#endregion
|
|
1692
1809
|
//#region src/components/ProductGrid/ProductGrid.tsx
|
|
1693
|
-
var
|
|
1810
|
+
var Fe = {
|
|
1694
1811
|
2: "grid-cols-2",
|
|
1695
1812
|
3: "grid-cols-2 md:grid-cols-3",
|
|
1696
1813
|
4: "grid-cols-2 sm:grid-cols-3 lg:grid-cols-4",
|
|
1697
1814
|
5: "grid-cols-2 sm:grid-cols-3 md:grid-cols-4 lg:grid-cols-5"
|
|
1698
|
-
},
|
|
1815
|
+
}, Ie = [
|
|
1699
1816
|
{
|
|
1700
1817
|
value: "newest",
|
|
1701
1818
|
label: "Nejnovější"
|
|
@@ -1717,50 +1834,50 @@ var Q = {
|
|
|
1717
1834
|
label: "Bestsellery"
|
|
1718
1835
|
}
|
|
1719
1836
|
];
|
|
1720
|
-
function
|
|
1721
|
-
return /* @__PURE__ */
|
|
1837
|
+
function Le() {
|
|
1838
|
+
return /* @__PURE__ */ u("div", {
|
|
1722
1839
|
className: "rounded-xl border border-gray-100 overflow-hidden animate-pulse",
|
|
1723
|
-
children: [/* @__PURE__ */
|
|
1840
|
+
children: [/* @__PURE__ */ l("div", { className: "aspect-4/3 bg-gray-200" }), /* @__PURE__ */ u("div", {
|
|
1724
1841
|
className: "p-4 space-y-2",
|
|
1725
1842
|
children: [
|
|
1726
|
-
/* @__PURE__ */
|
|
1727
|
-
/* @__PURE__ */
|
|
1728
|
-
/* @__PURE__ */
|
|
1843
|
+
/* @__PURE__ */ l("div", { className: "h-3 bg-gray-200 rounded w-3/4" }),
|
|
1844
|
+
/* @__PURE__ */ l("div", { className: "h-3 bg-gray-200 rounded w-1/2" }),
|
|
1845
|
+
/* @__PURE__ */ l("div", { className: "h-5 bg-gray-200 rounded w-1/3 mt-2" })
|
|
1729
1846
|
]
|
|
1730
1847
|
})]
|
|
1731
1848
|
});
|
|
1732
1849
|
}
|
|
1733
|
-
function
|
|
1850
|
+
function Re({ products: e, totalCount: t, page: n = 1, onPageChange: r, perPage: i = 20, columns: a = 4, sortOptions: o = Ie, selectedSort: s, onSortChange: c, activeFilters: d = [], onRemoveFilter: f, onClearFilters: p, loading: m = !1, emptyState: h, onAddToCart: g, onWishlistToggle: _, onProductClick: v, wishlisted: y = [], className: b = "" }) {
|
|
1734
1851
|
let x = t ? Math.ceil(t / i) : void 0, S = a >= 5 ? "compact" : "default";
|
|
1735
|
-
return /* @__PURE__ */
|
|
1852
|
+
return /* @__PURE__ */ u("div", {
|
|
1736
1853
|
className: ["w-full", b].filter(Boolean).join(" "),
|
|
1737
1854
|
children: [
|
|
1738
|
-
/* @__PURE__ */
|
|
1855
|
+
/* @__PURE__ */ u("div", {
|
|
1739
1856
|
className: "flex flex-wrap items-center justify-between gap-3 mb-4",
|
|
1740
|
-
children: [/* @__PURE__ */
|
|
1857
|
+
children: [/* @__PURE__ */ u("div", {
|
|
1741
1858
|
className: "flex flex-wrap items-center gap-2",
|
|
1742
1859
|
children: [
|
|
1743
|
-
t !== void 0 && /* @__PURE__ */
|
|
1860
|
+
t !== void 0 && /* @__PURE__ */ u("span", {
|
|
1744
1861
|
className: "text-sm text-gray-500",
|
|
1745
|
-
children: [/* @__PURE__ */
|
|
1862
|
+
children: [/* @__PURE__ */ l("span", {
|
|
1746
1863
|
className: "font-semibold text-gray-900",
|
|
1747
1864
|
children: t
|
|
1748
1865
|
}), " produktů"]
|
|
1749
1866
|
}),
|
|
1750
|
-
d.map((e) => /* @__PURE__ */
|
|
1867
|
+
d.map((e) => /* @__PURE__ */ u("span", {
|
|
1751
1868
|
className: "inline-flex items-center gap-1 text-xs bg-primary-50 text-primary-700 border border-primary-200 rounded-full px-2.5 py-1",
|
|
1752
|
-
children: [e, /* @__PURE__ */
|
|
1869
|
+
children: [e, /* @__PURE__ */ l("button", {
|
|
1753
1870
|
onClick: () => f?.(e),
|
|
1754
1871
|
"aria-label": `Remove filter ${e}`,
|
|
1755
1872
|
className: "hover:text-primary-900 transition-colors",
|
|
1756
|
-
children: /* @__PURE__ */
|
|
1873
|
+
children: /* @__PURE__ */ l("svg", {
|
|
1757
1874
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1758
1875
|
fill: "none",
|
|
1759
1876
|
viewBox: "0 0 24 24",
|
|
1760
1877
|
strokeWidth: 2,
|
|
1761
1878
|
stroke: "currentColor",
|
|
1762
1879
|
className: "w-3 h-3",
|
|
1763
|
-
children: /* @__PURE__ */
|
|
1880
|
+
children: /* @__PURE__ */ l("path", {
|
|
1764
1881
|
strokeLinecap: "round",
|
|
1765
1882
|
strokeLinejoin: "round",
|
|
1766
1883
|
d: "M6 18L18 6M6 6l12 12"
|
|
@@ -1768,50 +1885,50 @@ function Ie({ products: e, totalCount: t, page: n = 1, onPageChange: r, perPage:
|
|
|
1768
1885
|
})
|
|
1769
1886
|
})]
|
|
1770
1887
|
}, e)),
|
|
1771
|
-
d.length > 1 && /* @__PURE__ */
|
|
1888
|
+
d.length > 1 && /* @__PURE__ */ l("button", {
|
|
1772
1889
|
onClick: p,
|
|
1773
1890
|
className: "text-xs text-gray-400 hover:text-gray-600 underline underline-offset-2 transition-colors",
|
|
1774
1891
|
children: "Zrušit vše"
|
|
1775
1892
|
})
|
|
1776
1893
|
]
|
|
1777
|
-
}), /* @__PURE__ */
|
|
1894
|
+
}), /* @__PURE__ */ l(O, {
|
|
1778
1895
|
options: o,
|
|
1779
|
-
value:
|
|
1780
|
-
onChange: (e) =>
|
|
1896
|
+
value: s ?? "",
|
|
1897
|
+
onChange: (e) => c?.(e.target.value),
|
|
1781
1898
|
"aria-label": "Sort products",
|
|
1782
1899
|
className: "text-sm"
|
|
1783
1900
|
})]
|
|
1784
1901
|
}),
|
|
1785
|
-
m ? /* @__PURE__ */
|
|
1786
|
-
className: `grid gap-4 ${
|
|
1787
|
-
children: Array.from({ length: i > 12 ? 12 : i }).map((e, t) => /* @__PURE__ */
|
|
1788
|
-
}) : e.length === 0 ? /* @__PURE__ */
|
|
1902
|
+
m ? /* @__PURE__ */ l("div", {
|
|
1903
|
+
className: `grid gap-4 ${Fe[a]}`,
|
|
1904
|
+
children: Array.from({ length: i > 12 ? 12 : i }).map((e, t) => /* @__PURE__ */ l(Le, {}, t))
|
|
1905
|
+
}) : e.length === 0 ? /* @__PURE__ */ l("div", {
|
|
1789
1906
|
className: "py-16 text-center",
|
|
1790
|
-
children: h ?? /* @__PURE__ */
|
|
1907
|
+
children: h ?? /* @__PURE__ */ u("div", {
|
|
1791
1908
|
className: "space-y-2",
|
|
1792
1909
|
children: [
|
|
1793
|
-
/* @__PURE__ */
|
|
1910
|
+
/* @__PURE__ */ l("p", {
|
|
1794
1911
|
className: "text-4xl",
|
|
1795
1912
|
children: "🔍"
|
|
1796
1913
|
}),
|
|
1797
|
-
/* @__PURE__ */
|
|
1914
|
+
/* @__PURE__ */ l("p", {
|
|
1798
1915
|
className: "font-semibold text-gray-900",
|
|
1799
1916
|
children: "Žádné produkty nenalezeny"
|
|
1800
1917
|
}),
|
|
1801
|
-
/* @__PURE__ */
|
|
1918
|
+
/* @__PURE__ */ l("p", {
|
|
1802
1919
|
className: "text-sm text-gray-500",
|
|
1803
1920
|
children: "Zkuste upravit filtry nebo hledat jinak."
|
|
1804
1921
|
}),
|
|
1805
|
-
d.length > 0 && /* @__PURE__ */
|
|
1922
|
+
d.length > 0 && /* @__PURE__ */ l("button", {
|
|
1806
1923
|
onClick: p,
|
|
1807
1924
|
className: "mt-3 text-sm text-primary-600 hover:underline",
|
|
1808
1925
|
children: "Zrušit všechny filtry"
|
|
1809
1926
|
})
|
|
1810
1927
|
]
|
|
1811
1928
|
})
|
|
1812
|
-
}) : /* @__PURE__ */
|
|
1813
|
-
className: `grid gap-4 ${
|
|
1814
|
-
children: e.map((e) => /* @__PURE__ */
|
|
1929
|
+
}) : /* @__PURE__ */ l("div", {
|
|
1930
|
+
className: `grid gap-4 ${Fe[a]}`,
|
|
1931
|
+
children: e.map((e) => /* @__PURE__ */ l(Pe, {
|
|
1815
1932
|
product: e,
|
|
1816
1933
|
size: S,
|
|
1817
1934
|
onAddToCart: g,
|
|
@@ -1820,9 +1937,9 @@ function Ie({ products: e, totalCount: t, page: n = 1, onPageChange: r, perPage:
|
|
|
1820
1937
|
isWishlisted: y.includes(e.id)
|
|
1821
1938
|
}, e.id))
|
|
1822
1939
|
}),
|
|
1823
|
-
x && x > 1 && r && /* @__PURE__ */
|
|
1940
|
+
x && x > 1 && r && /* @__PURE__ */ l("div", {
|
|
1824
1941
|
className: "flex justify-center mt-8",
|
|
1825
|
-
children: /* @__PURE__ */
|
|
1942
|
+
children: /* @__PURE__ */ l(J, {
|
|
1826
1943
|
page: n,
|
|
1827
1944
|
totalPages: x,
|
|
1828
1945
|
onPageChange: r
|
|
@@ -1833,14 +1950,14 @@ function Ie({ products: e, totalCount: t, page: n = 1, onPageChange: r, perPage:
|
|
|
1833
1950
|
}
|
|
1834
1951
|
//#endregion
|
|
1835
1952
|
//#region src/components/CallToAction/CallToAction.tsx
|
|
1836
|
-
var
|
|
1953
|
+
var ze = {
|
|
1837
1954
|
default: "bg-gray-50 border border-gray-200",
|
|
1838
1955
|
primary: "bg-primary-600",
|
|
1839
1956
|
dark: "bg-gray-900",
|
|
1840
1957
|
gradient: "bg-linear-to-br from-primary-600 via-primary-700 to-violet-700",
|
|
1841
1958
|
outline: "bg-white border-2 border-primary-600",
|
|
1842
1959
|
image: "relative overflow-hidden"
|
|
1843
|
-
},
|
|
1960
|
+
}, Be = {
|
|
1844
1961
|
default: {
|
|
1845
1962
|
eyebrow: "text-primary-600",
|
|
1846
1963
|
title: "text-gray-900",
|
|
@@ -1871,7 +1988,7 @@ var Le = {
|
|
|
1871
1988
|
title: "text-white",
|
|
1872
1989
|
description: "text-white/80"
|
|
1873
1990
|
}
|
|
1874
|
-
},
|
|
1991
|
+
}, Ve = {
|
|
1875
1992
|
sm: {
|
|
1876
1993
|
wrapper: "px-6 py-6 rounded-xl",
|
|
1877
1994
|
title: "text-xl font-bold",
|
|
@@ -1896,7 +2013,7 @@ var Le = {
|
|
|
1896
2013
|
description: "text-xl",
|
|
1897
2014
|
eyebrow: "text-sm"
|
|
1898
2015
|
}
|
|
1899
|
-
},
|
|
2016
|
+
}, He = {
|
|
1900
2017
|
left: {
|
|
1901
2018
|
wrapper: "items-start text-left",
|
|
1902
2019
|
actions: "justify-start"
|
|
@@ -1910,9 +2027,9 @@ var Le = {
|
|
|
1910
2027
|
actions: "justify-end"
|
|
1911
2028
|
}
|
|
1912
2029
|
};
|
|
1913
|
-
function
|
|
1914
|
-
let h =
|
|
1915
|
-
...
|
|
2030
|
+
function Ue({ eyebrow: e, title: t, description: n, actions: r = [], align: i = "center", layout: a = "stacked", size: o = "md", variant: s = "default", background: c, backgroundImage: d, media: f, className: p = "", style: m }) {
|
|
2031
|
+
let h = Be[s], g = Ve[o], _ = He[i], v = a === "inline", y = {
|
|
2032
|
+
...c ? { background: c } : {},
|
|
1916
2033
|
...d ? {
|
|
1917
2034
|
backgroundImage: `url(${d})`,
|
|
1918
2035
|
backgroundSize: "cover",
|
|
@@ -1920,48 +2037,48 @@ function Ve({ eyebrow: e, title: t, description: n, actions: r = [], align: i =
|
|
|
1920
2037
|
} : {},
|
|
1921
2038
|
...m
|
|
1922
2039
|
};
|
|
1923
|
-
return /* @__PURE__ */
|
|
2040
|
+
return /* @__PURE__ */ u("div", {
|
|
1924
2041
|
className: [
|
|
1925
2042
|
"w-full",
|
|
1926
|
-
|
|
2043
|
+
ze[s],
|
|
1927
2044
|
g.wrapper,
|
|
1928
2045
|
p
|
|
1929
2046
|
].filter(Boolean).join(" "),
|
|
1930
2047
|
style: Object.keys(y).length ? y : void 0,
|
|
1931
|
-
children: [(
|
|
2048
|
+
children: [(s === "image" || d) && /* @__PURE__ */ l("div", { className: "absolute inset-0 bg-black/50" }), /* @__PURE__ */ u("div", {
|
|
1932
2049
|
className: `relative ${v ? "flex flex-wrap items-center justify-between gap-6" : `flex flex-col gap-4 ${_.wrapper}`}`,
|
|
1933
2050
|
children: [
|
|
1934
|
-
/* @__PURE__ */
|
|
2051
|
+
/* @__PURE__ */ u("div", {
|
|
1935
2052
|
className: `flex flex-col gap-2 ${v ? "flex-1 min-w-0" : _.wrapper}`,
|
|
1936
2053
|
children: [
|
|
1937
|
-
e && /* @__PURE__ */
|
|
2054
|
+
e && /* @__PURE__ */ l("p", {
|
|
1938
2055
|
className: `font-semibold uppercase tracking-widest ${g.eyebrow} ${h.eyebrow}`,
|
|
1939
2056
|
children: e
|
|
1940
2057
|
}),
|
|
1941
|
-
/* @__PURE__ */
|
|
2058
|
+
/* @__PURE__ */ l("h2", {
|
|
1942
2059
|
className: `${g.title} ${h.title}`,
|
|
1943
2060
|
children: t
|
|
1944
2061
|
}),
|
|
1945
|
-
n && /* @__PURE__ */
|
|
2062
|
+
n && /* @__PURE__ */ l("p", {
|
|
1946
2063
|
className: `max-w-2xl ${g.description} ${h.description}`,
|
|
1947
2064
|
children: n
|
|
1948
2065
|
})
|
|
1949
2066
|
]
|
|
1950
2067
|
}),
|
|
1951
|
-
f && !v && /* @__PURE__ */
|
|
2068
|
+
f && !v && /* @__PURE__ */ l("div", {
|
|
1952
2069
|
className: "mt-2",
|
|
1953
2070
|
children: f
|
|
1954
2071
|
}),
|
|
1955
|
-
r.length > 0 && /* @__PURE__ */
|
|
2072
|
+
r.length > 0 && /* @__PURE__ */ l("div", {
|
|
1956
2073
|
className: `flex flex-wrap gap-3 ${v ? "shrink-0" : _.actions}`,
|
|
1957
2074
|
children: r.map((e, t) => {
|
|
1958
|
-
let n = /* @__PURE__ */
|
|
1959
|
-
variant: e.variant ?? (t === 0 ?
|
|
2075
|
+
let n = /* @__PURE__ */ l(w, {
|
|
2076
|
+
variant: e.variant ?? (t === 0 ? We(s) : "outline"),
|
|
1960
2077
|
size: e.size ?? (o === "sm" ? "sm" : o === "xl" ? "lg" : "md"),
|
|
1961
2078
|
onClick: e.onClick,
|
|
1962
2079
|
children: e.label
|
|
1963
2080
|
}, t);
|
|
1964
|
-
return e.href ? /* @__PURE__ */
|
|
2081
|
+
return e.href ? /* @__PURE__ */ l("a", {
|
|
1965
2082
|
href: e.href,
|
|
1966
2083
|
className: "contents",
|
|
1967
2084
|
children: n
|
|
@@ -1972,233 +2089,233 @@ function Ve({ eyebrow: e, title: t, description: n, actions: r = [], align: i =
|
|
|
1972
2089
|
})]
|
|
1973
2090
|
});
|
|
1974
2091
|
}
|
|
1975
|
-
function
|
|
2092
|
+
function We(e) {
|
|
1976
2093
|
return e === "default" || e === "outline" ? "primary" : "secondary";
|
|
1977
2094
|
}
|
|
1978
2095
|
//#endregion
|
|
1979
2096
|
//#region src/components/Footer/Footer.tsx
|
|
1980
|
-
function
|
|
1981
|
-
return /* @__PURE__ */
|
|
2097
|
+
function Ge() {
|
|
2098
|
+
return /* @__PURE__ */ l("svg", {
|
|
1982
2099
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1983
2100
|
fill: "none",
|
|
1984
2101
|
viewBox: "0 0 24 24",
|
|
1985
2102
|
strokeWidth: 1.5,
|
|
1986
2103
|
stroke: "currentColor",
|
|
1987
2104
|
className: "w-4 h-4 shrink-0",
|
|
1988
|
-
children: /* @__PURE__ */
|
|
2105
|
+
children: /* @__PURE__ */ l("path", {
|
|
1989
2106
|
strokeLinecap: "round",
|
|
1990
2107
|
strokeLinejoin: "round",
|
|
1991
2108
|
d: "M2.25 6.75c0 8.284 6.716 15 15 15h2.25a2.25 2.25 0 002.25-2.25v-1.372c0-.516-.351-.966-.852-1.091l-4.423-1.106c-.44-.11-.902.055-1.173.417l-.97 1.293c-.282.376-.769.542-1.21.38a12.035 12.035 0 01-7.143-7.143c-.162-.441.004-.928.38-1.21l1.293-.97c.363-.271.527-.734.417-1.173L6.963 3.102a1.125 1.125 0 00-1.091-.852H4.5A2.25 2.25 0 002.25 4.5v2.25z"
|
|
1992
2109
|
})
|
|
1993
2110
|
});
|
|
1994
2111
|
}
|
|
1995
|
-
function
|
|
1996
|
-
return /* @__PURE__ */
|
|
2112
|
+
function Ke() {
|
|
2113
|
+
return /* @__PURE__ */ l("svg", {
|
|
1997
2114
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1998
2115
|
fill: "none",
|
|
1999
2116
|
viewBox: "0 0 24 24",
|
|
2000
2117
|
strokeWidth: 1.5,
|
|
2001
2118
|
stroke: "currentColor",
|
|
2002
2119
|
className: "w-4 h-4 shrink-0",
|
|
2003
|
-
children: /* @__PURE__ */
|
|
2120
|
+
children: /* @__PURE__ */ l("path", {
|
|
2004
2121
|
strokeLinecap: "round",
|
|
2005
2122
|
strokeLinejoin: "round",
|
|
2006
2123
|
d: "M21.75 6.75v10.5a2.25 2.25 0 01-2.25 2.25h-15a2.25 2.25 0 01-2.25-2.25V6.75m19.5 0A2.25 2.25 0 0019.5 4.5h-15a2.25 2.25 0 00-2.25 2.25m19.5 0v.243a2.25 2.25 0 01-1.07 1.916l-7.5 4.615a2.25 2.25 0 01-2.36 0L3.32 8.91a2.25 2.25 0 01-1.07-1.916V6.75"
|
|
2007
2124
|
})
|
|
2008
2125
|
});
|
|
2009
2126
|
}
|
|
2010
|
-
function
|
|
2011
|
-
return /* @__PURE__ */
|
|
2127
|
+
function qe() {
|
|
2128
|
+
return /* @__PURE__ */ u("svg", {
|
|
2012
2129
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2013
2130
|
fill: "none",
|
|
2014
2131
|
viewBox: "0 0 24 24",
|
|
2015
2132
|
strokeWidth: 1.5,
|
|
2016
2133
|
stroke: "currentColor",
|
|
2017
2134
|
className: "w-4 h-4 shrink-0",
|
|
2018
|
-
children: [/* @__PURE__ */
|
|
2135
|
+
children: [/* @__PURE__ */ l("path", {
|
|
2019
2136
|
strokeLinecap: "round",
|
|
2020
2137
|
strokeLinejoin: "round",
|
|
2021
2138
|
d: "M15 10.5a3 3 0 11-6 0 3 3 0 016 0z"
|
|
2022
|
-
}), /* @__PURE__ */
|
|
2139
|
+
}), /* @__PURE__ */ l("path", {
|
|
2023
2140
|
strokeLinecap: "round",
|
|
2024
2141
|
strokeLinejoin: "round",
|
|
2025
2142
|
d: "M19.5 10.5c0 7.142-7.5 11.25-7.5 11.25S4.5 17.642 4.5 10.5a7.5 7.5 0 1115 0z"
|
|
2026
2143
|
})]
|
|
2027
2144
|
});
|
|
2028
2145
|
}
|
|
2029
|
-
function
|
|
2030
|
-
return /* @__PURE__ */
|
|
2146
|
+
function Je() {
|
|
2147
|
+
return /* @__PURE__ */ l("svg", {
|
|
2031
2148
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2032
2149
|
fill: "none",
|
|
2033
2150
|
viewBox: "0 0 24 24",
|
|
2034
2151
|
strokeWidth: 1.5,
|
|
2035
2152
|
stroke: "currentColor",
|
|
2036
2153
|
className: "w-4 h-4 shrink-0",
|
|
2037
|
-
children: /* @__PURE__ */
|
|
2154
|
+
children: /* @__PURE__ */ l("path", {
|
|
2038
2155
|
strokeLinecap: "round",
|
|
2039
2156
|
strokeLinejoin: "round",
|
|
2040
2157
|
d: "M12 6v6h4.5m4.5 0a9 9 0 11-18 0 9 9 0 0118 0z"
|
|
2041
2158
|
})
|
|
2042
2159
|
});
|
|
2043
2160
|
}
|
|
2044
|
-
function
|
|
2045
|
-
return /* @__PURE__ */
|
|
2161
|
+
function Ye() {
|
|
2162
|
+
return /* @__PURE__ */ l("svg", {
|
|
2046
2163
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2047
2164
|
viewBox: "0 0 24 24",
|
|
2048
2165
|
fill: "currentColor",
|
|
2049
2166
|
className: "w-4 h-4",
|
|
2050
|
-
children: /* @__PURE__ */
|
|
2167
|
+
children: /* @__PURE__ */ l("path", { d: "M24 12.073C24 5.405 18.627 0 12 0S0 5.405 0 12.073C0 18.1 4.388 23.094 10.125 24v-8.437H7.078v-3.49h3.047V9.41c0-3.025 1.792-4.697 4.533-4.697 1.312 0 2.686.236 2.686.236v2.97h-1.513c-1.491 0-1.956.93-1.956 1.886v2.267h3.328l-.532 3.49h-2.796V24C19.612 23.094 24 18.1 24 12.073z" })
|
|
2051
2168
|
});
|
|
2052
2169
|
}
|
|
2053
|
-
function
|
|
2054
|
-
return /* @__PURE__ */
|
|
2170
|
+
function Xe() {
|
|
2171
|
+
return /* @__PURE__ */ l("svg", {
|
|
2055
2172
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2056
2173
|
viewBox: "0 0 24 24",
|
|
2057
2174
|
fill: "currentColor",
|
|
2058
2175
|
className: "w-4 h-4",
|
|
2059
|
-
children: /* @__PURE__ */
|
|
2176
|
+
children: /* @__PURE__ */ l("path", { d: "M12 2.163c3.204 0 3.584.012 4.85.07 3.252.148 4.771 1.691 4.919 4.919.058 1.265.069 1.645.069 4.849 0 3.205-.012 3.584-.069 4.849-.149 3.225-1.664 4.771-4.919 4.919-1.266.058-1.644.07-4.85.07-3.204 0-3.584-.012-4.849-.07-3.26-.149-4.771-1.699-4.919-4.92-.058-1.265-.07-1.644-.07-4.849 0-3.204.013-3.583.07-4.849.149-3.227 1.664-4.771 4.919-4.919 1.266-.057 1.645-.069 4.849-.069zm0-2.163c-3.259 0-3.667.014-4.947.072-4.358.2-6.78 2.618-6.98 6.98-.059 1.281-.073 1.689-.073 4.948 0 3.259.014 3.668.072 4.948.2 4.358 2.618 6.78 6.98 6.98 1.281.058 1.689.072 4.948.072 3.259 0 3.668-.014 4.948-.072 4.354-.2 6.782-2.618 6.979-6.98.059-1.28.073-1.689.073-4.948 0-3.259-.014-3.667-.072-4.947-.196-4.354-2.617-6.78-6.979-6.98-1.281-.059-1.69-.073-4.949-.073zm0 5.838a6.162 6.162 0 100 12.324 6.162 6.162 0 000-12.324zM12 16a4 4 0 110-8 4 4 0 010 8zm6.406-11.845a1.44 1.44 0 100 2.881 1.44 1.44 0 000-2.881z" })
|
|
2060
2177
|
});
|
|
2061
2178
|
}
|
|
2062
|
-
function
|
|
2063
|
-
return /* @__PURE__ */
|
|
2179
|
+
function Ze() {
|
|
2180
|
+
return /* @__PURE__ */ l("svg", {
|
|
2064
2181
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2065
2182
|
viewBox: "0 0 24 24",
|
|
2066
2183
|
fill: "currentColor",
|
|
2067
2184
|
className: "w-4 h-4",
|
|
2068
|
-
children: /* @__PURE__ */
|
|
2185
|
+
children: /* @__PURE__ */ l("path", { d: "M18.244 2.25h3.308l-7.227 8.26 8.502 11.24H16.17l-5.214-6.817L4.99 21.75H1.68l7.73-8.835L1.254 2.25H8.08l4.713 6.231zm-1.161 17.52h1.833L7.084 4.126H5.117z" })
|
|
2069
2186
|
});
|
|
2070
2187
|
}
|
|
2071
|
-
function
|
|
2072
|
-
return /* @__PURE__ */
|
|
2188
|
+
function Qe() {
|
|
2189
|
+
return /* @__PURE__ */ l("svg", {
|
|
2073
2190
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2074
2191
|
viewBox: "0 0 24 24",
|
|
2075
2192
|
fill: "currentColor",
|
|
2076
2193
|
className: "w-4 h-4",
|
|
2077
|
-
children: /* @__PURE__ */
|
|
2194
|
+
children: /* @__PURE__ */ l("path", { d: "M23.498 6.186a3.016 3.016 0 00-2.122-2.136C19.505 3.545 12 3.545 12 3.545s-7.505 0-9.377.505A3.017 3.017 0 00.502 6.186C0 8.07 0 12 0 12s0 3.93.502 5.814a3.016 3.016 0 002.122 2.136c1.871.505 9.376.505 9.376.505s7.505 0 9.377-.505a3.015 3.015 0 002.122-2.136C24 15.93 24 12 24 12s0-3.93-.502-5.814zM9.545 15.568V8.432L15.818 12l-6.273 3.568z" })
|
|
2078
2195
|
});
|
|
2079
2196
|
}
|
|
2080
|
-
function
|
|
2081
|
-
return /* @__PURE__ */
|
|
2197
|
+
function $e() {
|
|
2198
|
+
return /* @__PURE__ */ l("svg", {
|
|
2082
2199
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2083
2200
|
viewBox: "0 0 24 24",
|
|
2084
2201
|
fill: "currentColor",
|
|
2085
2202
|
className: "w-4 h-4",
|
|
2086
|
-
children: /* @__PURE__ */
|
|
2203
|
+
children: /* @__PURE__ */ l("path", { d: "M19.59 6.69a4.83 4.83 0 01-3.77-4.25V2h-3.45v13.67a2.89 2.89 0 01-2.88 2.5 2.89 2.89 0 01-2.89-2.89 2.89 2.89 0 012.89-2.89c.28 0 .54.04.79.1V9.01a6.33 6.33 0 00-.79-.05 6.34 6.34 0 00-6.34 6.34 6.34 6.34 0 006.34 6.34 6.34 6.34 0 006.33-6.34V8.69a8.18 8.18 0 004.78 1.52V6.76a4.85 4.85 0 01-1.01-.07z" })
|
|
2087
2204
|
});
|
|
2088
2205
|
}
|
|
2089
|
-
var
|
|
2090
|
-
facebook:
|
|
2091
|
-
instagram:
|
|
2092
|
-
twitter:
|
|
2093
|
-
youtube:
|
|
2094
|
-
tiktok:
|
|
2095
|
-
},
|
|
2096
|
-
phone:
|
|
2097
|
-
email:
|
|
2098
|
-
address:
|
|
2099
|
-
hours:
|
|
2206
|
+
var et = {
|
|
2207
|
+
facebook: Ye,
|
|
2208
|
+
instagram: Xe,
|
|
2209
|
+
twitter: Ze,
|
|
2210
|
+
youtube: Qe,
|
|
2211
|
+
tiktok: $e
|
|
2212
|
+
}, tt = {
|
|
2213
|
+
phone: Ge,
|
|
2214
|
+
email: Ke,
|
|
2215
|
+
address: qe,
|
|
2216
|
+
hours: Je
|
|
2100
2217
|
};
|
|
2101
|
-
function
|
|
2218
|
+
function nt(e) {
|
|
2102
2219
|
if (!e) return null;
|
|
2103
2220
|
if (typeof e == "string") {
|
|
2104
|
-
let t =
|
|
2105
|
-
return t ? /* @__PURE__ */
|
|
2221
|
+
let t = tt[e];
|
|
2222
|
+
return t ? /* @__PURE__ */ l(t, {}) : null;
|
|
2106
2223
|
}
|
|
2107
2224
|
return e;
|
|
2108
2225
|
}
|
|
2109
|
-
function
|
|
2226
|
+
function rt(e) {
|
|
2110
2227
|
if (typeof e == "string") {
|
|
2111
|
-
let t =
|
|
2112
|
-
return t ? /* @__PURE__ */
|
|
2228
|
+
let t = et[e];
|
|
2229
|
+
return t ? /* @__PURE__ */ l(t, {}) : null;
|
|
2113
2230
|
}
|
|
2114
2231
|
return e;
|
|
2115
2232
|
}
|
|
2116
|
-
function
|
|
2233
|
+
function it({ logo: e, tagline: t, contactHeading: n = "Kontakty", contacts: r = [], linkGroups: i = [], socialLinks: a = [], copyright: o, bottomLinks: s = [], className: c = "" }) {
|
|
2117
2234
|
let d = (/* @__PURE__ */ new Date()).getFullYear();
|
|
2118
|
-
return /* @__PURE__ */
|
|
2119
|
-
className: ["bg-gray-900 text-gray-300",
|
|
2120
|
-
children: /* @__PURE__ */
|
|
2235
|
+
return /* @__PURE__ */ l("footer", {
|
|
2236
|
+
className: ["bg-gray-900 text-gray-300", c].filter(Boolean).join(" "),
|
|
2237
|
+
children: /* @__PURE__ */ u(x, { children: [/* @__PURE__ */ u("div", {
|
|
2121
2238
|
className: "max-w-7xl mx-auto px-4 py-12 grid grid-cols-1 md:grid-cols-2 gap-10 lg:gap-16",
|
|
2122
|
-
children: [/* @__PURE__ */
|
|
2239
|
+
children: [/* @__PURE__ */ u("div", {
|
|
2123
2240
|
className: "flex flex-col gap-6",
|
|
2124
2241
|
children: [
|
|
2125
|
-
/* @__PURE__ */
|
|
2242
|
+
/* @__PURE__ */ u("div", { children: [e ? /* @__PURE__ */ l("div", {
|
|
2126
2243
|
className: "mb-3",
|
|
2127
2244
|
children: e
|
|
2128
|
-
}) : /* @__PURE__ */
|
|
2245
|
+
}) : /* @__PURE__ */ l("span", {
|
|
2129
2246
|
className: "text-xl font-bold text-white tracking-tight mb-3 block",
|
|
2130
2247
|
children: "shopito"
|
|
2131
|
-
}), t && /* @__PURE__ */
|
|
2248
|
+
}), t && /* @__PURE__ */ l("p", {
|
|
2132
2249
|
className: "text-sm text-gray-400 max-w-xs",
|
|
2133
2250
|
children: t
|
|
2134
2251
|
})] }),
|
|
2135
|
-
r.length > 0 && /* @__PURE__ */
|
|
2252
|
+
r.length > 0 && /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("h3", {
|
|
2136
2253
|
className: "text-xs font-semibold uppercase tracking-widest text-gray-500 mb-3",
|
|
2137
2254
|
children: n
|
|
2138
|
-
}), /* @__PURE__ */
|
|
2255
|
+
}), /* @__PURE__ */ l("ul", {
|
|
2139
2256
|
className: "space-y-3",
|
|
2140
2257
|
children: r.map((e, t) => {
|
|
2141
|
-
let n =
|
|
2258
|
+
let n = nt(e.icon), r = /* @__PURE__ */ u("div", {
|
|
2142
2259
|
className: "flex items-start gap-2.5",
|
|
2143
|
-
children: [n && /* @__PURE__ */
|
|
2260
|
+
children: [n && /* @__PURE__ */ l("span", {
|
|
2144
2261
|
className: "mt-0.5 text-primary-400",
|
|
2145
2262
|
children: n
|
|
2146
|
-
}), /* @__PURE__ */
|
|
2263
|
+
}), /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
|
|
2147
2264
|
className: "text-xs text-gray-500 leading-none mb-0.5",
|
|
2148
2265
|
children: e.label
|
|
2149
|
-
}), /* @__PURE__ */
|
|
2266
|
+
}), /* @__PURE__ */ l("p", {
|
|
2150
2267
|
className: `text-sm text-gray-200 ${e.href ? "hover:text-white transition-colors" : ""}`,
|
|
2151
2268
|
children: e.value
|
|
2152
2269
|
})] })]
|
|
2153
2270
|
});
|
|
2154
|
-
return /* @__PURE__ */
|
|
2271
|
+
return /* @__PURE__ */ l("li", { children: e.href ? /* @__PURE__ */ l("a", {
|
|
2155
2272
|
href: e.href,
|
|
2156
2273
|
children: r
|
|
2157
2274
|
}) : r }, t);
|
|
2158
2275
|
})
|
|
2159
2276
|
})] }),
|
|
2160
|
-
a.length > 0 && /* @__PURE__ */
|
|
2277
|
+
a.length > 0 && /* @__PURE__ */ l("div", {
|
|
2161
2278
|
className: "flex gap-2 flex-wrap",
|
|
2162
|
-
children: a.map((e, t) => /* @__PURE__ */
|
|
2279
|
+
children: a.map((e, t) => /* @__PURE__ */ l("a", {
|
|
2163
2280
|
href: e.href,
|
|
2164
2281
|
"aria-label": e.label,
|
|
2165
2282
|
className: "w-8 h-8 flex items-center justify-center rounded-lg bg-gray-800 text-gray-400 hover:bg-primary-600 hover:text-white transition-colors",
|
|
2166
|
-
children:
|
|
2283
|
+
children: rt(e.icon)
|
|
2167
2284
|
}, t))
|
|
2168
2285
|
})
|
|
2169
2286
|
]
|
|
2170
|
-
}), i.length > 0 && /* @__PURE__ */
|
|
2287
|
+
}), i.length > 0 && /* @__PURE__ */ l("div", {
|
|
2171
2288
|
className: `grid gap-8 ${i.length === 1 ? "grid-cols-1" : i.length === 2 ? "grid-cols-2" : "grid-cols-2 sm:grid-cols-3"}`,
|
|
2172
|
-
children: i.map((e, t) => /* @__PURE__ */
|
|
2289
|
+
children: i.map((e, t) => /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("h3", {
|
|
2173
2290
|
className: "text-xs font-semibold uppercase tracking-widest text-gray-500 mb-3",
|
|
2174
2291
|
children: e.heading
|
|
2175
|
-
}), /* @__PURE__ */
|
|
2292
|
+
}), /* @__PURE__ */ l("ul", {
|
|
2176
2293
|
className: "space-y-2",
|
|
2177
|
-
children: e.links.map((e, t) => /* @__PURE__ */
|
|
2294
|
+
children: e.links.map((e, t) => /* @__PURE__ */ l("li", { children: e.href ? /* @__PURE__ */ l("a", {
|
|
2178
2295
|
href: e.href,
|
|
2179
2296
|
className: "text-sm text-gray-400 hover:text-white transition-colors",
|
|
2180
2297
|
children: e.label
|
|
2181
|
-
}) : /* @__PURE__ */
|
|
2298
|
+
}) : /* @__PURE__ */ l("button", {
|
|
2182
2299
|
onClick: e.onClick,
|
|
2183
2300
|
className: "text-sm text-gray-400 hover:text-white transition-colors text-left",
|
|
2184
2301
|
children: e.label
|
|
2185
2302
|
}) }, t))
|
|
2186
2303
|
})] }, t))
|
|
2187
2304
|
})]
|
|
2188
|
-
}), /* @__PURE__ */
|
|
2305
|
+
}), /* @__PURE__ */ l("div", {
|
|
2189
2306
|
className: "border-t border-gray-800",
|
|
2190
|
-
children: /* @__PURE__ */
|
|
2307
|
+
children: /* @__PURE__ */ u("div", {
|
|
2191
2308
|
className: "max-w-7xl mx-auto px-4 py-4 flex flex-wrap items-center justify-between gap-3",
|
|
2192
|
-
children: [/* @__PURE__ */
|
|
2309
|
+
children: [/* @__PURE__ */ l("p", {
|
|
2193
2310
|
className: "text-xs text-gray-500",
|
|
2194
2311
|
children: o ?? `© ${d} Shopito. Všechna práva vyhrazena.`
|
|
2195
|
-
}),
|
|
2312
|
+
}), s.length > 0 && /* @__PURE__ */ l("nav", {
|
|
2196
2313
|
className: "flex flex-wrap gap-4",
|
|
2197
|
-
children:
|
|
2314
|
+
children: s.map((e, t) => e.href ? /* @__PURE__ */ l("a", {
|
|
2198
2315
|
href: e.href,
|
|
2199
2316
|
className: "text-xs text-gray-500 hover:text-gray-300 transition-colors",
|
|
2200
2317
|
children: e.label
|
|
2201
|
-
}, t) : /* @__PURE__ */
|
|
2318
|
+
}, t) : /* @__PURE__ */ l("button", {
|
|
2202
2319
|
onClick: e.onClick,
|
|
2203
2320
|
className: "text-xs text-gray-500 hover:text-gray-300 transition-colors",
|
|
2204
2321
|
children: e.label
|
|
@@ -2209,6 +2326,6 @@ function tt({ logo: e, tagline: t, contactHeading: n = "Kontakty", contacts: r =
|
|
|
2209
2326
|
});
|
|
2210
2327
|
}
|
|
2211
2328
|
//#endregion
|
|
2212
|
-
export {
|
|
2329
|
+
export { z as Alert, ne as Avatar, j as Badge, ke as BannerCarousel, w as Button, Ue as CallToAction, N as Card, F as CardBody, I as CardFooter, P as CardHeader, xe as Carousel, Ee as CategoryTree, B as Checkbox, W as Col, x as Container, it as Footer, U as Grid, Ce as Header, k as Heading, E as IconButton, D as Input, T as LoadingSpin, S as Main, Oe as MegaMenu, te as Modal, J as Pagination, Pe as ProductCard, Re as ProductGrid, G as QuantityInput, O as Select, L as Spinner, re as Stack, A as Text, V as Toggle };
|
|
2213
2330
|
|
|
2214
2331
|
//# sourceMappingURL=index.js.map
|