@contentmunch/contentmunch-ui 1.0.30 → 1.0.33
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/lib/index.cjs.js +5 -5
- package/lib/index.es.js +439 -446
- package/lib/index.umd.js +5 -5
- package/lib/input/Select.d.ts +6 -2
- package/package.json +1 -1
package/lib/index.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
var
|
|
1
|
+
import oe, { useState as T, Fragment as s, useRef as de, useCallback as G, useEffect as Q, useMemo as te } from "react";
|
|
2
|
+
var K = { exports: {} }, B = {};
|
|
3
3
|
/**
|
|
4
4
|
* @license React
|
|
5
5
|
* react-jsx-runtime.production.js
|
|
@@ -9,29 +9,29 @@ var X = { exports: {} }, W = {};
|
|
|
9
9
|
* This source code is licensed under the MIT license found in the
|
|
10
10
|
* LICENSE file in the root directory of this source tree.
|
|
11
11
|
*/
|
|
12
|
-
var
|
|
13
|
-
function
|
|
14
|
-
if (
|
|
15
|
-
|
|
12
|
+
var le;
|
|
13
|
+
function ue() {
|
|
14
|
+
if (le) return B;
|
|
15
|
+
le = 1;
|
|
16
16
|
var n = Symbol.for("react.transitional.element"), t = Symbol.for("react.fragment");
|
|
17
|
-
function r(
|
|
17
|
+
function r(i, c, a) {
|
|
18
18
|
var x = null;
|
|
19
|
-
if (a !== void 0 && (x = "" + a),
|
|
19
|
+
if (a !== void 0 && (x = "" + a), c.key !== void 0 && (x = "" + c.key), "key" in c) {
|
|
20
20
|
a = {};
|
|
21
|
-
for (var o in
|
|
22
|
-
o !== "key" && (a[o] =
|
|
23
|
-
} else a =
|
|
24
|
-
return
|
|
21
|
+
for (var o in c)
|
|
22
|
+
o !== "key" && (a[o] = c[o]);
|
|
23
|
+
} else a = c;
|
|
24
|
+
return c = a.ref, {
|
|
25
25
|
$$typeof: n,
|
|
26
|
-
type:
|
|
26
|
+
type: i,
|
|
27
27
|
key: x,
|
|
28
|
-
ref:
|
|
28
|
+
ref: c !== void 0 ? c : null,
|
|
29
29
|
props: a
|
|
30
30
|
};
|
|
31
31
|
}
|
|
32
|
-
return
|
|
32
|
+
return B.Fragment = t, B.jsx = r, B.jsxs = r, B;
|
|
33
33
|
}
|
|
34
|
-
var
|
|
34
|
+
var J = {};
|
|
35
35
|
/**
|
|
36
36
|
* @license React
|
|
37
37
|
* react-jsx-runtime.development.js
|
|
@@ -41,26 +41,26 @@ var B = {};
|
|
|
41
41
|
* This source code is licensed under the MIT license found in the
|
|
42
42
|
* LICENSE file in the root directory of this source tree.
|
|
43
43
|
*/
|
|
44
|
-
var
|
|
45
|
-
function
|
|
46
|
-
return
|
|
44
|
+
var ce;
|
|
45
|
+
function ye() {
|
|
46
|
+
return ce || (ce = 1, process.env.NODE_ENV !== "production" && function() {
|
|
47
47
|
function n(l) {
|
|
48
48
|
if (l == null) return null;
|
|
49
49
|
if (typeof l == "function")
|
|
50
|
-
return l.$$typeof ===
|
|
50
|
+
return l.$$typeof === C ? null : l.displayName || l.name || null;
|
|
51
51
|
if (typeof l == "string") return l;
|
|
52
52
|
switch (l) {
|
|
53
|
-
case v:
|
|
54
|
-
return "Fragment";
|
|
55
53
|
case g:
|
|
54
|
+
return "Fragment";
|
|
55
|
+
case v:
|
|
56
56
|
return "Profiler";
|
|
57
|
-
case
|
|
57
|
+
case A:
|
|
58
58
|
return "StrictMode";
|
|
59
|
-
case
|
|
59
|
+
case k:
|
|
60
60
|
return "Suspense";
|
|
61
|
-
case
|
|
61
|
+
case H:
|
|
62
62
|
return "SuspenseList";
|
|
63
|
-
case
|
|
63
|
+
case M:
|
|
64
64
|
return "Activity";
|
|
65
65
|
}
|
|
66
66
|
if (typeof l == "object")
|
|
@@ -69,19 +69,19 @@ function ue() {
|
|
|
69
69
|
), l.$$typeof) {
|
|
70
70
|
case N:
|
|
71
71
|
return "Portal";
|
|
72
|
-
case
|
|
72
|
+
case S:
|
|
73
73
|
return (l.displayName || "Context") + ".Provider";
|
|
74
|
-
case
|
|
74
|
+
case _:
|
|
75
75
|
return (l._context.displayName || "Context") + ".Consumer";
|
|
76
|
-
case S:
|
|
77
|
-
var p = l.render;
|
|
78
|
-
return l = l.displayName, l || (l = p.displayName || p.name || "", l = l !== "" ? "ForwardRef(" + l + ")" : "ForwardRef"), l;
|
|
79
|
-
case k:
|
|
80
|
-
return p = l.displayName || null, p !== null ? p : n(l.type) || "Memo";
|
|
81
76
|
case z:
|
|
82
|
-
|
|
77
|
+
var y = l.render;
|
|
78
|
+
return l = l.displayName, l || (l = y.displayName || y.name || "", l = l !== "" ? "ForwardRef(" + l + ")" : "ForwardRef"), l;
|
|
79
|
+
case P:
|
|
80
|
+
return y = l.displayName || null, y !== null ? y : n(l.type) || "Memo";
|
|
81
|
+
case m:
|
|
82
|
+
y = l._payload, l = l._init;
|
|
83
83
|
try {
|
|
84
|
-
return n(l(
|
|
84
|
+
return n(l(y));
|
|
85
85
|
} catch {
|
|
86
86
|
}
|
|
87
87
|
}
|
|
@@ -93,50 +93,50 @@ function ue() {
|
|
|
93
93
|
function r(l) {
|
|
94
94
|
try {
|
|
95
95
|
t(l);
|
|
96
|
-
var
|
|
96
|
+
var y = !1;
|
|
97
97
|
} catch {
|
|
98
|
-
|
|
98
|
+
y = !0;
|
|
99
99
|
}
|
|
100
|
-
if (
|
|
101
|
-
|
|
102
|
-
var b =
|
|
100
|
+
if (y) {
|
|
101
|
+
y = console;
|
|
102
|
+
var b = y.error, E = typeof Symbol == "function" && Symbol.toStringTag && l[Symbol.toStringTag] || l.constructor.name || "Object";
|
|
103
103
|
return b.call(
|
|
104
|
-
|
|
104
|
+
y,
|
|
105
105
|
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
106
106
|
E
|
|
107
107
|
), t(l);
|
|
108
108
|
}
|
|
109
109
|
}
|
|
110
|
-
function
|
|
111
|
-
if (l ===
|
|
112
|
-
if (typeof l == "object" && l !== null && l.$$typeof ===
|
|
110
|
+
function i(l) {
|
|
111
|
+
if (l === g) return "<>";
|
|
112
|
+
if (typeof l == "object" && l !== null && l.$$typeof === m)
|
|
113
113
|
return "<...>";
|
|
114
114
|
try {
|
|
115
|
-
var
|
|
116
|
-
return
|
|
115
|
+
var y = n(l);
|
|
116
|
+
return y ? "<" + y + ">" : "<...>";
|
|
117
117
|
} catch {
|
|
118
118
|
return "<...>";
|
|
119
119
|
}
|
|
120
120
|
}
|
|
121
|
-
function
|
|
122
|
-
var l =
|
|
121
|
+
function c() {
|
|
122
|
+
var l = L.A;
|
|
123
123
|
return l === null ? null : l.getOwner();
|
|
124
124
|
}
|
|
125
125
|
function a() {
|
|
126
126
|
return Error("react-stack-top-frame");
|
|
127
127
|
}
|
|
128
128
|
function x(l) {
|
|
129
|
-
if (
|
|
130
|
-
var
|
|
131
|
-
if (
|
|
129
|
+
if (X.call(l, "key")) {
|
|
130
|
+
var y = Object.getOwnPropertyDescriptor(l, "key").get;
|
|
131
|
+
if (y && y.isReactWarning) return !1;
|
|
132
132
|
}
|
|
133
133
|
return l.key !== void 0;
|
|
134
134
|
}
|
|
135
|
-
function o(l,
|
|
135
|
+
function o(l, y) {
|
|
136
136
|
function b() {
|
|
137
|
-
|
|
137
|
+
Y || (Y = !0, console.error(
|
|
138
138
|
"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",
|
|
139
|
-
|
|
139
|
+
y
|
|
140
140
|
));
|
|
141
141
|
}
|
|
142
142
|
b.isReactWarning = !0, Object.defineProperty(l, "key", {
|
|
@@ -150,13 +150,13 @@ function ue() {
|
|
|
150
150
|
"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
|
|
151
151
|
)), l = this.props.ref, l !== void 0 ? l : null;
|
|
152
152
|
}
|
|
153
|
-
function h(l,
|
|
153
|
+
function h(l, y, b, E, D, V, ee, se) {
|
|
154
154
|
return b = V.ref, l = {
|
|
155
155
|
$$typeof: f,
|
|
156
156
|
type: l,
|
|
157
|
-
key:
|
|
157
|
+
key: y,
|
|
158
158
|
props: V,
|
|
159
|
-
_owner:
|
|
159
|
+
_owner: D
|
|
160
160
|
}, (b !== void 0 ? b : null) !== null ? Object.defineProperty(l, "ref", {
|
|
161
161
|
enumerable: !1,
|
|
162
162
|
get: d
|
|
@@ -174,19 +174,19 @@ function ue() {
|
|
|
174
174
|
configurable: !1,
|
|
175
175
|
enumerable: !1,
|
|
176
176
|
writable: !0,
|
|
177
|
-
value:
|
|
177
|
+
value: ee
|
|
178
178
|
}), Object.defineProperty(l, "_debugTask", {
|
|
179
179
|
configurable: !1,
|
|
180
180
|
enumerable: !1,
|
|
181
181
|
writable: !0,
|
|
182
|
-
value:
|
|
182
|
+
value: se
|
|
183
183
|
}), Object.freeze && (Object.freeze(l.props), Object.freeze(l)), l;
|
|
184
184
|
}
|
|
185
|
-
function j(l,
|
|
186
|
-
var R =
|
|
185
|
+
function j(l, y, b, E, D, V, ee, se) {
|
|
186
|
+
var R = y.children;
|
|
187
187
|
if (R !== void 0)
|
|
188
188
|
if (E)
|
|
189
|
-
if (
|
|
189
|
+
if (Z(R)) {
|
|
190
190
|
for (E = 0; E < R.length; E++)
|
|
191
191
|
u(R[E]);
|
|
192
192
|
Object.freeze && Object.freeze(R);
|
|
@@ -195,12 +195,12 @@ function ue() {
|
|
|
195
195
|
"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead."
|
|
196
196
|
);
|
|
197
197
|
else u(R);
|
|
198
|
-
if (
|
|
198
|
+
if (X.call(y, "key")) {
|
|
199
199
|
R = n(l);
|
|
200
|
-
var
|
|
201
|
-
return
|
|
200
|
+
var F = Object.keys(y).filter(function(je) {
|
|
201
|
+
return je !== "key";
|
|
202
202
|
});
|
|
203
|
-
E = 0 <
|
|
203
|
+
E = 0 < F.length ? "{key: someKey, " + F.join(": ..., ") + ": ...}" : "{key: someKey}", re[R + E] || (F = 0 < F.length ? "{" + F.join(": ..., ") + ": ...}" : "{}", console.error(
|
|
204
204
|
`A props object containing a "key" prop is being spread into JSX:
|
|
205
205
|
let props = %s;
|
|
206
206
|
<%s {...props} />
|
|
@@ -209,15 +209,15 @@ React keys must be passed directly to JSX without using spread:
|
|
|
209
209
|
<%s key={someKey} {...props} />`,
|
|
210
210
|
E,
|
|
211
211
|
R,
|
|
212
|
-
|
|
212
|
+
F,
|
|
213
213
|
R
|
|
214
214
|
), re[R + E] = !0);
|
|
215
215
|
}
|
|
216
|
-
if (R = null, b !== void 0 && (r(b), R = "" + b), x(
|
|
216
|
+
if (R = null, b !== void 0 && (r(b), R = "" + b), x(y) && (r(y.key), R = "" + y.key), "key" in y) {
|
|
217
217
|
b = {};
|
|
218
|
-
for (var
|
|
219
|
-
|
|
220
|
-
} else b =
|
|
218
|
+
for (var ne in y)
|
|
219
|
+
ne !== "key" && (b[ne] = y[ne]);
|
|
220
|
+
} else b = y;
|
|
221
221
|
return R && o(
|
|
222
222
|
b,
|
|
223
223
|
typeof l == "function" ? l.displayName || l.name || "Unknown" : l
|
|
@@ -225,68 +225,68 @@ React keys must be passed directly to JSX without using spread:
|
|
|
225
225
|
l,
|
|
226
226
|
R,
|
|
227
227
|
V,
|
|
228
|
-
|
|
229
|
-
|
|
228
|
+
D,
|
|
229
|
+
c(),
|
|
230
230
|
b,
|
|
231
|
-
|
|
232
|
-
|
|
231
|
+
ee,
|
|
232
|
+
se
|
|
233
233
|
);
|
|
234
234
|
}
|
|
235
235
|
function u(l) {
|
|
236
236
|
typeof l == "object" && l !== null && l.$$typeof === f && l._store && (l._store.validated = 1);
|
|
237
237
|
}
|
|
238
|
-
var
|
|
238
|
+
var p = oe, f = Symbol.for("react.transitional.element"), N = Symbol.for("react.portal"), g = Symbol.for("react.fragment"), A = Symbol.for("react.strict_mode"), v = Symbol.for("react.profiler"), _ = Symbol.for("react.consumer"), S = Symbol.for("react.context"), z = Symbol.for("react.forward_ref"), k = Symbol.for("react.suspense"), H = Symbol.for("react.suspense_list"), P = Symbol.for("react.memo"), m = Symbol.for("react.lazy"), M = Symbol.for("react.activity"), C = Symbol.for("react.client.reference"), L = p.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, X = Object.prototype.hasOwnProperty, Z = Array.isArray, I = console.createTask ? console.createTask : function() {
|
|
239
239
|
return null;
|
|
240
240
|
};
|
|
241
|
-
|
|
241
|
+
p = {
|
|
242
242
|
"react-stack-bottom-frame": function(l) {
|
|
243
243
|
return l();
|
|
244
244
|
}
|
|
245
245
|
};
|
|
246
|
-
var
|
|
247
|
-
|
|
246
|
+
var Y, $ = {}, U = p["react-stack-bottom-frame"].bind(
|
|
247
|
+
p,
|
|
248
248
|
a
|
|
249
|
-
)(),
|
|
250
|
-
|
|
251
|
-
var V = 1e4 >
|
|
249
|
+
)(), W = I(i(a)), re = {};
|
|
250
|
+
J.Fragment = g, J.jsx = function(l, y, b, E, D) {
|
|
251
|
+
var V = 1e4 > L.recentlyCreatedOwnerStacks++;
|
|
252
252
|
return j(
|
|
253
253
|
l,
|
|
254
|
-
|
|
254
|
+
y,
|
|
255
255
|
b,
|
|
256
256
|
!1,
|
|
257
257
|
E,
|
|
258
|
-
|
|
259
|
-
V ? Error("react-stack-top-frame") :
|
|
260
|
-
V ?
|
|
258
|
+
D,
|
|
259
|
+
V ? Error("react-stack-top-frame") : U,
|
|
260
|
+
V ? I(i(l)) : W
|
|
261
261
|
);
|
|
262
|
-
},
|
|
263
|
-
var V = 1e4 >
|
|
262
|
+
}, J.jsxs = function(l, y, b, E, D) {
|
|
263
|
+
var V = 1e4 > L.recentlyCreatedOwnerStacks++;
|
|
264
264
|
return j(
|
|
265
265
|
l,
|
|
266
|
-
|
|
266
|
+
y,
|
|
267
267
|
b,
|
|
268
268
|
!0,
|
|
269
269
|
E,
|
|
270
|
-
|
|
271
|
-
V ? Error("react-stack-top-frame") :
|
|
272
|
-
V ?
|
|
270
|
+
D,
|
|
271
|
+
V ? Error("react-stack-top-frame") : U,
|
|
272
|
+
V ? I(i(l)) : W
|
|
273
273
|
);
|
|
274
274
|
};
|
|
275
|
-
}()),
|
|
275
|
+
}()), J;
|
|
276
276
|
}
|
|
277
277
|
var ie;
|
|
278
|
-
function
|
|
279
|
-
return ie || (ie = 1, process.env.NODE_ENV === "production" ?
|
|
278
|
+
function pe() {
|
|
279
|
+
return ie || (ie = 1, process.env.NODE_ENV === "production" ? K.exports = ue() : K.exports = ye()), K.exports;
|
|
280
280
|
}
|
|
281
|
-
var e =
|
|
282
|
-
const
|
|
283
|
-
const { folds: r } = t, [
|
|
281
|
+
var e = pe();
|
|
282
|
+
const Re = ({ variant: n, children: t }) => {
|
|
283
|
+
const { folds: r } = t, [i, c] = T(0), a = (d) => d === i ? "fold active" : "fold", x = (d) => "fold-button" + (n ? " fold-button--" + n : "") + (r[d].foldColor ? " fold-button--primary fold-button--" + r[d].foldColor : ""), o = (d) => {
|
|
284
284
|
const h = d.which.toString(), j = d.ctrlKey && h.match(/33|34/);
|
|
285
285
|
if (h.match(/38|40/) || j) {
|
|
286
|
-
const u = h.match(/34|40/) ? 1 : -1,
|
|
287
|
-
|
|
286
|
+
const u = h.match(/34|40/) ? 1 : -1, p = r.length, f = (i + p + u) % p;
|
|
287
|
+
c(f);
|
|
288
288
|
} else
|
|
289
|
-
h === "36" &&
|
|
289
|
+
h === "36" && c(0), h === "35" && c(r.length - 1);
|
|
290
290
|
d.preventDefault();
|
|
291
291
|
};
|
|
292
292
|
return /* @__PURE__ */ e.jsx("div", { className: "muncher-accordion", children: r.map(
|
|
@@ -294,14 +294,14 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
294
294
|
"div",
|
|
295
295
|
{
|
|
296
296
|
className: a(h),
|
|
297
|
-
"aria-expanded":
|
|
297
|
+
"aria-expanded": i === h,
|
|
298
298
|
children: [
|
|
299
299
|
/* @__PURE__ */ e.jsx(
|
|
300
300
|
"button",
|
|
301
301
|
{
|
|
302
302
|
className: x(h),
|
|
303
303
|
onKeyDown: o,
|
|
304
|
-
onClick: () =>
|
|
304
|
+
onClick: () => c(h),
|
|
305
305
|
children: /* @__PURE__ */ e.jsx("span", { children: d.heading })
|
|
306
306
|
}
|
|
307
307
|
),
|
|
@@ -311,11 +311,11 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
311
311
|
"muncher-accordion-fold-" + h
|
|
312
312
|
)
|
|
313
313
|
) });
|
|
314
|
-
},
|
|
314
|
+
}, me = ({
|
|
315
315
|
show: n = !1,
|
|
316
316
|
backdropClickHandler: t,
|
|
317
317
|
...r
|
|
318
|
-
}) => n ? /* @__PURE__ */ e.jsx("div", { className: "muncher-backdrop", onClick: t, ...r }) : null,
|
|
318
|
+
}) => n ? /* @__PURE__ */ e.jsx("div", { className: "muncher-backdrop", onClick: t, ...r }) : null, fe = ({ variant: n, children: t, ...r }) => /* @__PURE__ */ e.jsx("div", { className: n ? "muncher-badge muncher-badge--" + n : "muncher-badge", ...r, children: t }), ae = {
|
|
319
319
|
"align-center": /* @__PURE__ */ e.jsxs(s, { children: [
|
|
320
320
|
/* @__PURE__ */ e.jsx("line", { x1: "18", y1: "10", x2: "6", y2: "10" }),
|
|
321
321
|
/* @__PURE__ */ e.jsx("line", { x1: "21", y1: "6", x2: "3", y2: "6" }),
|
|
@@ -1069,7 +1069,7 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1069
1069
|
/* @__PURE__ */ e.jsx("path", { d: "M20.49 15a9 9 0 1 1-2.12-9.36L23 10" }),
|
|
1070
1070
|
/* @__PURE__ */ e.jsx("text", { x: "6", y: "14", fontSize: "6", fontFamily: "'Lucida Grande', sans-serif", children: "360" })
|
|
1071
1071
|
] })
|
|
1072
|
-
}, w = ({ color: n, name: t, size: r = "small", weight:
|
|
1072
|
+
}, w = ({ color: n, name: t, size: r = "small", weight: i = 2, onClick: c, iconString: a, orientation: x, children: o }) => {
|
|
1073
1073
|
const d = r ? "muncher-icon--" + r : "muncher-icon--small";
|
|
1074
1074
|
return /* @__PURE__ */ e.jsxs("span", { className: "muncher-icon", children: [
|
|
1075
1075
|
o && x && x === "right" ? /* @__PURE__ */ e.jsx("span", { className: "content-left", children: o }) : "",
|
|
@@ -1081,38 +1081,38 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1081
1081
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1082
1082
|
viewBox: "0 0 24 24",
|
|
1083
1083
|
fill: "none",
|
|
1084
|
-
strokeWidth:
|
|
1084
|
+
strokeWidth: i || 2,
|
|
1085
1085
|
strokeLinecap: "round",
|
|
1086
1086
|
strokeLinejoin: "round",
|
|
1087
|
-
onClick:
|
|
1088
|
-
children: t ?
|
|
1087
|
+
onClick: c,
|
|
1088
|
+
children: t ? ae[t] : a ? Object(ae)[a] : ""
|
|
1089
1089
|
}
|
|
1090
1090
|
),
|
|
1091
1091
|
o && (!x || x === "left") ? /* @__PURE__ */ e.jsx("span", { className: "content-right", children: o }) : ""
|
|
1092
1092
|
] });
|
|
1093
|
-
},
|
|
1093
|
+
}, Te = ({
|
|
1094
1094
|
variant: n = "primary",
|
|
1095
1095
|
icon: t = "bell",
|
|
1096
1096
|
text: r,
|
|
1097
|
-
onClick:
|
|
1098
|
-
...
|
|
1097
|
+
onClick: i,
|
|
1098
|
+
...c
|
|
1099
1099
|
}) => /* @__PURE__ */ e.jsxs(
|
|
1100
1100
|
"div",
|
|
1101
1101
|
{
|
|
1102
1102
|
className: "muncher-icon-badge",
|
|
1103
|
-
onClick:
|
|
1104
|
-
...
|
|
1103
|
+
onClick: i,
|
|
1104
|
+
...c,
|
|
1105
1105
|
children: [
|
|
1106
1106
|
/* @__PURE__ */ e.jsx(w, { name: t }),
|
|
1107
|
-
r === "" ? "" : /* @__PURE__ */ e.jsx(
|
|
1107
|
+
r === "" ? "" : /* @__PURE__ */ e.jsx(fe, { variant: n, children: r })
|
|
1108
1108
|
]
|
|
1109
1109
|
}
|
|
1110
1110
|
), O = ({
|
|
1111
1111
|
type: n = "button",
|
|
1112
1112
|
variant: t,
|
|
1113
1113
|
size: r = "medium",
|
|
1114
|
-
title:
|
|
1115
|
-
active:
|
|
1114
|
+
title: i,
|
|
1115
|
+
active: c,
|
|
1116
1116
|
disabled: a,
|
|
1117
1117
|
rounded: x,
|
|
1118
1118
|
onClick: o,
|
|
@@ -1120,30 +1120,30 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1120
1120
|
onMouseEnter: h,
|
|
1121
1121
|
onMouseLeave: j,
|
|
1122
1122
|
children: u,
|
|
1123
|
-
...
|
|
1123
|
+
...p
|
|
1124
1124
|
}) => {
|
|
1125
|
-
const f = "muncher-button" + (n && n === "nav" ? " muncher-button--nav" : "") + (t ? " muncher-button--" + t : "") + (r ? " muncher-button--" + r : "") + (
|
|
1125
|
+
const f = "muncher-button" + (n && n === "nav" ? " muncher-button--nav" : "") + (t ? " muncher-button--" + t : "") + (r ? " muncher-button--" + r : "") + (c ? " muncher-button--active" : "") + (x ? " muncher-button--rounded" : "");
|
|
1126
1126
|
return /* @__PURE__ */ e.jsx(
|
|
1127
1127
|
"button",
|
|
1128
1128
|
{
|
|
1129
1129
|
type: n && n !== "nav" ? n : "button",
|
|
1130
1130
|
className: f,
|
|
1131
1131
|
disabled: !!a,
|
|
1132
|
-
title:
|
|
1132
|
+
title: i,
|
|
1133
1133
|
onClick: o,
|
|
1134
1134
|
onMouseDown: d,
|
|
1135
1135
|
onMouseEnter: h,
|
|
1136
1136
|
onMouseLeave: j,
|
|
1137
|
-
...
|
|
1137
|
+
...p,
|
|
1138
1138
|
children: u
|
|
1139
1139
|
}
|
|
1140
1140
|
);
|
|
1141
|
-
},
|
|
1141
|
+
}, ve = ({
|
|
1142
1142
|
variant: n,
|
|
1143
1143
|
size: t = "medium",
|
|
1144
1144
|
title: r,
|
|
1145
|
-
active:
|
|
1146
|
-
disabled:
|
|
1145
|
+
active: i,
|
|
1146
|
+
disabled: c,
|
|
1147
1147
|
element: a,
|
|
1148
1148
|
onMouseDown: x,
|
|
1149
1149
|
rounded: o,
|
|
@@ -1151,35 +1151,35 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1151
1151
|
onClick: h,
|
|
1152
1152
|
onClose: j,
|
|
1153
1153
|
showContent: u,
|
|
1154
|
-
setShowContent:
|
|
1154
|
+
setShowContent: p,
|
|
1155
1155
|
withDropIcon: f,
|
|
1156
1156
|
children: N,
|
|
1157
|
-
...
|
|
1157
|
+
...g
|
|
1158
1158
|
}) => {
|
|
1159
|
-
const
|
|
1160
|
-
|
|
1161
|
-
},
|
|
1162
|
-
|
|
1163
|
-
}, [j,
|
|
1164
|
-
|
|
1165
|
-
}, [
|
|
1166
|
-
|
|
1167
|
-
const
|
|
1168
|
-
|
|
1159
|
+
const A = de(null), v = (k) => {
|
|
1160
|
+
k.preventDefault(), h && h(k), p && p(!0);
|
|
1161
|
+
}, _ = G(() => {
|
|
1162
|
+
p(!1), j && j();
|
|
1163
|
+
}, [j, p]), S = G((k) => {
|
|
1164
|
+
k.keyCode === 27 && _();
|
|
1165
|
+
}, [_]);
|
|
1166
|
+
Q(() => {
|
|
1167
|
+
const k = (H) => {
|
|
1168
|
+
A && A.current && H.target instanceof HTMLElement && !A.current.contains(H.target) && _();
|
|
1169
1169
|
};
|
|
1170
|
-
return document.addEventListener("keydown",
|
|
1171
|
-
document.removeEventListener("keydown",
|
|
1170
|
+
return document.addEventListener("keydown", S, !1), document.addEventListener("mousedown", k), () => {
|
|
1171
|
+
document.removeEventListener("keydown", S, !1);
|
|
1172
1172
|
};
|
|
1173
|
-
}, [
|
|
1174
|
-
const
|
|
1175
|
-
var
|
|
1176
|
-
const
|
|
1177
|
-
if (
|
|
1178
|
-
if (
|
|
1179
|
-
if (
|
|
1180
|
-
if (
|
|
1181
|
-
const
|
|
1182
|
-
if (
|
|
1173
|
+
}, [S, _]);
|
|
1174
|
+
const z = () => {
|
|
1175
|
+
var P;
|
|
1176
|
+
const k = (P = A.current) == null ? void 0 : P.offsetLeft, H = window.innerWidth;
|
|
1177
|
+
if (k) {
|
|
1178
|
+
if (k < 100) return "muncher-dropdown--content";
|
|
1179
|
+
if (H - k < 150) return "muncher-dropdown--content drop-left";
|
|
1180
|
+
if (H - k < 250) {
|
|
1181
|
+
const m = Math.round((H - k) / H * 100);
|
|
1182
|
+
if (m > 40 || m < 60) return "muncher-dropdown--content drop-middle";
|
|
1183
1183
|
}
|
|
1184
1184
|
}
|
|
1185
1185
|
switch (d) {
|
|
@@ -1191,18 +1191,18 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1191
1191
|
return "muncher-dropdown--content";
|
|
1192
1192
|
}
|
|
1193
1193
|
};
|
|
1194
|
-
return /* @__PURE__ */ e.jsxs("div", { className: "muncher-dropdown", ref:
|
|
1194
|
+
return /* @__PURE__ */ e.jsxs("div", { className: "muncher-dropdown", ref: A, children: [
|
|
1195
1195
|
/* @__PURE__ */ e.jsxs(
|
|
1196
1196
|
O,
|
|
1197
1197
|
{
|
|
1198
|
-
onMouseDown:
|
|
1198
|
+
onMouseDown: v,
|
|
1199
1199
|
title: r,
|
|
1200
|
-
disabled:
|
|
1200
|
+
disabled: c,
|
|
1201
1201
|
rounded: o,
|
|
1202
|
-
active:
|
|
1202
|
+
active: i,
|
|
1203
1203
|
variant: n,
|
|
1204
1204
|
size: t,
|
|
1205
|
-
...
|
|
1205
|
+
...g,
|
|
1206
1206
|
children: [
|
|
1207
1207
|
a,
|
|
1208
1208
|
f ? /* @__PURE__ */ e.jsx(
|
|
@@ -1215,14 +1215,14 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1215
1215
|
]
|
|
1216
1216
|
}
|
|
1217
1217
|
),
|
|
1218
|
-
u ? /* @__PURE__ */ e.jsx("div", { className:
|
|
1218
|
+
u ? /* @__PURE__ */ e.jsx("div", { className: z(), children: N }) : ""
|
|
1219
1219
|
] });
|
|
1220
|
-
},
|
|
1220
|
+
}, Ae = ({
|
|
1221
1221
|
title: n,
|
|
1222
1222
|
active: t,
|
|
1223
1223
|
disabled: r,
|
|
1224
|
-
element:
|
|
1225
|
-
rounded:
|
|
1224
|
+
element: i,
|
|
1225
|
+
rounded: c,
|
|
1226
1226
|
children: a,
|
|
1227
1227
|
...x
|
|
1228
1228
|
}) => /* @__PURE__ */ e.jsxs("div", { className: "muncher-dropdown-nav", children: [
|
|
@@ -1232,23 +1232,23 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1232
1232
|
type: "nav",
|
|
1233
1233
|
title: n,
|
|
1234
1234
|
disabled: r,
|
|
1235
|
-
rounded:
|
|
1235
|
+
rounded: c,
|
|
1236
1236
|
active: t,
|
|
1237
1237
|
...x,
|
|
1238
|
-
children:
|
|
1238
|
+
children: i
|
|
1239
1239
|
}
|
|
1240
1240
|
),
|
|
1241
1241
|
/* @__PURE__ */ e.jsx("div", { className: "muncher-dropdown-nav--content", children: a })
|
|
1242
|
-
] }),
|
|
1242
|
+
] }), ge = (n) => {
|
|
1243
1243
|
navigator.clipboard.writeText(n);
|
|
1244
|
-
},
|
|
1244
|
+
}, be = ({
|
|
1245
1245
|
text: n,
|
|
1246
1246
|
variant: t = "secondary",
|
|
1247
1247
|
size: r = "small"
|
|
1248
1248
|
}) => {
|
|
1249
|
-
const [
|
|
1250
|
-
|
|
1251
|
-
|
|
1249
|
+
const [i, c] = T(), [a, x] = T("copy"), [o, d] = T("copy link"), h = () => {
|
|
1250
|
+
ge(n), c("green"), x("check"), d("copied!"), setTimeout(function() {
|
|
1251
|
+
c(""), x("copy");
|
|
1252
1252
|
}, 2e3);
|
|
1253
1253
|
};
|
|
1254
1254
|
return /* @__PURE__ */ e.jsx(
|
|
@@ -1258,21 +1258,21 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1258
1258
|
variant: t,
|
|
1259
1259
|
title: o,
|
|
1260
1260
|
onClick: h,
|
|
1261
|
-
children: /* @__PURE__ */ e.jsx(w, { name: a, color:
|
|
1261
|
+
children: /* @__PURE__ */ e.jsx(w, { name: a, color: i })
|
|
1262
1262
|
}
|
|
1263
1263
|
);
|
|
1264
|
-
},
|
|
1264
|
+
}, _e = ({
|
|
1265
1265
|
variant: n = "secondary",
|
|
1266
1266
|
size: t = "medium",
|
|
1267
1267
|
title: r
|
|
1268
1268
|
}) => {
|
|
1269
|
-
const [
|
|
1269
|
+
const [i, c] = T(!1);
|
|
1270
1270
|
return /* @__PURE__ */ e.jsx("div", { className: "muncher-share", children: /* @__PURE__ */ e.jsxs(
|
|
1271
|
-
|
|
1271
|
+
ve,
|
|
1272
1272
|
{
|
|
1273
1273
|
title: "Share to Social Media",
|
|
1274
|
-
showContent:
|
|
1275
|
-
setShowContent:
|
|
1274
|
+
showContent: i,
|
|
1275
|
+
setShowContent: c,
|
|
1276
1276
|
variant: n,
|
|
1277
1277
|
size: t,
|
|
1278
1278
|
element: /* @__PURE__ */ e.jsx(w, { name: "share", orientation: "right", children: "Share" }),
|
|
@@ -1304,16 +1304,16 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1304
1304
|
children: /* @__PURE__ */ e.jsx(w, { name: "mail" })
|
|
1305
1305
|
}
|
|
1306
1306
|
) }),
|
|
1307
|
-
/* @__PURE__ */ e.jsx(
|
|
1307
|
+
/* @__PURE__ */ e.jsx(be, { text: window.location.href })
|
|
1308
1308
|
]
|
|
1309
1309
|
}
|
|
1310
1310
|
) });
|
|
1311
|
-
},
|
|
1311
|
+
}, we = ({
|
|
1312
1312
|
header: n,
|
|
1313
1313
|
data: t,
|
|
1314
1314
|
filename: r,
|
|
1315
|
-
variant:
|
|
1316
|
-
size:
|
|
1315
|
+
variant: i,
|
|
1316
|
+
size: c,
|
|
1317
1317
|
title: a,
|
|
1318
1318
|
active: x,
|
|
1319
1319
|
disabled: o,
|
|
@@ -1322,18 +1322,18 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1322
1322
|
const h = encodeURI("data:text/csv;charset=utf-8," + n.join(",") + `
|
|
1323
1323
|
` + t.map((j) => j.join(",")).join(`
|
|
1324
1324
|
`));
|
|
1325
|
-
return /* @__PURE__ */ e.jsx("div", { className: "muncher-csv", children: /* @__PURE__ */ e.jsx(O, { variant:
|
|
1326
|
-
},
|
|
1325
|
+
return /* @__PURE__ */ e.jsx("div", { className: "muncher-csv", children: /* @__PURE__ */ e.jsx(O, { variant: i, size: c, active: x, disabled: o, rounded: d, children: /* @__PURE__ */ e.jsx("a", { href: h, download: r + ".csv", children: /* @__PURE__ */ e.jsx(w, { name: "download", children: a || "Download" }) }) }) });
|
|
1326
|
+
}, Ne = ({
|
|
1327
1327
|
variant: n = "transparent",
|
|
1328
1328
|
size: t = "small",
|
|
1329
1329
|
title: r,
|
|
1330
|
-
sortAsc:
|
|
1331
|
-
active:
|
|
1330
|
+
sortAsc: i = "true",
|
|
1331
|
+
active: c,
|
|
1332
1332
|
rounded: a,
|
|
1333
1333
|
onClick: x,
|
|
1334
1334
|
children: o
|
|
1335
1335
|
}) => {
|
|
1336
|
-
const [d, h] = T(!1), j = () => !
|
|
1336
|
+
const [d, h] = T(!1), j = () => !c || c && !d ? i ? /* @__PURE__ */ e.jsx(w, { name: "sort-asc" }) : /* @__PURE__ */ e.jsx(w, { name: "sort-desc" }) : i ? /* @__PURE__ */ e.jsx(w, { name: "sort-desc" }) : /* @__PURE__ */ e.jsx(w, { name: "sort-asc" });
|
|
1337
1337
|
return /* @__PURE__ */ e.jsxs(
|
|
1338
1338
|
O,
|
|
1339
1339
|
{
|
|
@@ -1350,16 +1350,16 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1350
1350
|
onClick: x,
|
|
1351
1351
|
children: [
|
|
1352
1352
|
o,
|
|
1353
|
-
|
|
1353
|
+
c || d ? /* @__PURE__ */ e.jsx(j, {}) : ""
|
|
1354
1354
|
]
|
|
1355
1355
|
}
|
|
1356
1356
|
);
|
|
1357
|
-
},
|
|
1357
|
+
}, xe = ({
|
|
1358
1358
|
direction: n,
|
|
1359
1359
|
size: t = "small",
|
|
1360
1360
|
weight: r,
|
|
1361
|
-
isDisabled:
|
|
1362
|
-
variant:
|
|
1361
|
+
isDisabled: i,
|
|
1362
|
+
variant: c = "primary",
|
|
1363
1363
|
navIcon: a = "chevron",
|
|
1364
1364
|
onClick: x
|
|
1365
1365
|
}) => {
|
|
@@ -1383,27 +1383,27 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1383
1383
|
O,
|
|
1384
1384
|
{
|
|
1385
1385
|
onClick: x,
|
|
1386
|
-
disabled:
|
|
1386
|
+
disabled: i,
|
|
1387
1387
|
size: "small",
|
|
1388
|
-
variant:
|
|
1388
|
+
variant: c,
|
|
1389
1389
|
title: n === "left" ? "Navigate Left" : "Navigate Right",
|
|
1390
1390
|
children: /* @__PURE__ */ e.jsx(w, { name: o(), size: t, weight: r })
|
|
1391
1391
|
}
|
|
1392
1392
|
)
|
|
1393
1393
|
}
|
|
1394
1394
|
);
|
|
1395
|
-
},
|
|
1395
|
+
}, q = ({ label: n, onClick: t, id: r, required: i = !1 }) => /* @__PURE__ */ e.jsxs("label", { htmlFor: r, onClick: t, children: [
|
|
1396
1396
|
n,
|
|
1397
|
-
|
|
1398
|
-
] }),
|
|
1397
|
+
i ? /* @__PURE__ */ e.jsx("span", { className: "required", children: "*" }) : ""
|
|
1398
|
+
] }), Se = ({
|
|
1399
1399
|
name: n,
|
|
1400
1400
|
required: t = !1,
|
|
1401
1401
|
onChange: r,
|
|
1402
|
-
checked:
|
|
1403
|
-
label:
|
|
1402
|
+
checked: i = !1,
|
|
1403
|
+
label: c,
|
|
1404
1404
|
...a
|
|
1405
1405
|
}) => {
|
|
1406
|
-
const [x, o] = T(
|
|
1406
|
+
const [x, o] = T(i || !1);
|
|
1407
1407
|
return /* @__PURE__ */ e.jsx("div", { className: "muncher-input--div", children: /* @__PURE__ */ e.jsxs("div", { className: "muncher-checkbox", children: [
|
|
1408
1408
|
/* @__PURE__ */ e.jsx(
|
|
1409
1409
|
"input",
|
|
@@ -1419,10 +1419,10 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1419
1419
|
...a
|
|
1420
1420
|
}
|
|
1421
1421
|
),
|
|
1422
|
-
|
|
1423
|
-
|
|
1422
|
+
c ? /* @__PURE__ */ e.jsx(
|
|
1423
|
+
q,
|
|
1424
1424
|
{
|
|
1425
|
-
label:
|
|
1425
|
+
label: c,
|
|
1426
1426
|
required: t,
|
|
1427
1427
|
id: n,
|
|
1428
1428
|
onClick: (d) => {
|
|
@@ -1431,18 +1431,18 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1431
1431
|
}
|
|
1432
1432
|
) : ""
|
|
1433
1433
|
] }) });
|
|
1434
|
-
},
|
|
1434
|
+
}, he = ({ size: n, ...t }) => /* @__PURE__ */ e.jsx(
|
|
1435
1435
|
"div",
|
|
1436
1436
|
{
|
|
1437
1437
|
className: n ? "muncher-spinner muncher-spinner-" + n : "muncher-spinner",
|
|
1438
1438
|
...t
|
|
1439
1439
|
}
|
|
1440
|
-
),
|
|
1440
|
+
), Me = ({
|
|
1441
1441
|
name: n,
|
|
1442
1442
|
label: t,
|
|
1443
1443
|
variant: r = "secondary",
|
|
1444
|
-
size:
|
|
1445
|
-
required:
|
|
1444
|
+
size: i = "medium",
|
|
1445
|
+
required: c,
|
|
1446
1446
|
active: a,
|
|
1447
1447
|
isUploading: x,
|
|
1448
1448
|
handleOnChange: o,
|
|
@@ -1450,7 +1450,7 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1450
1450
|
successMessage: h,
|
|
1451
1451
|
...j
|
|
1452
1452
|
}) => {
|
|
1453
|
-
const u = "muncher-button" + (r ? " muncher-button--" + r : "") + (
|
|
1453
|
+
const u = "muncher-button" + (r ? " muncher-button--" + r : "") + (i ? " muncher-button--" + i : "") + (a ? " muncher-button--active" : ""), p = (f) => {
|
|
1454
1454
|
o && o(f.currentTarget.files[0]);
|
|
1455
1455
|
};
|
|
1456
1456
|
return /* @__PURE__ */ e.jsx("div", { className: "muncher-file-input--div", children: /* @__PURE__ */ e.jsxs("div", { className: "file-input-element", children: [
|
|
@@ -1458,8 +1458,8 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1458
1458
|
/* @__PURE__ */ e.jsx(w, { name: "upload" }),
|
|
1459
1459
|
" ",
|
|
1460
1460
|
t || "Upload CSV",
|
|
1461
|
-
|
|
1462
|
-
x ? /* @__PURE__ */ e.jsx(
|
|
1461
|
+
c ? /* @__PURE__ */ e.jsx("span", { className: "required", children: " *" }) : "",
|
|
1462
|
+
x ? /* @__PURE__ */ e.jsx(he, { size: "tiny" }) : ""
|
|
1463
1463
|
] }),
|
|
1464
1464
|
/* @__PURE__ */ e.jsx(
|
|
1465
1465
|
"input",
|
|
@@ -1467,8 +1467,8 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1467
1467
|
id: n,
|
|
1468
1468
|
type: "file",
|
|
1469
1469
|
className: "muncher-file-input",
|
|
1470
|
-
required:
|
|
1471
|
-
onChange:
|
|
1470
|
+
required: c,
|
|
1471
|
+
onChange: p,
|
|
1472
1472
|
accept: "text/csv",
|
|
1473
1473
|
...j
|
|
1474
1474
|
}
|
|
@@ -1480,8 +1480,8 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1480
1480
|
name: n,
|
|
1481
1481
|
label: t,
|
|
1482
1482
|
variant: r = "secondary",
|
|
1483
|
-
size:
|
|
1484
|
-
required:
|
|
1483
|
+
size: i = "large",
|
|
1484
|
+
required: c,
|
|
1485
1485
|
active: a,
|
|
1486
1486
|
setFiles: x,
|
|
1487
1487
|
error: o,
|
|
@@ -1489,20 +1489,20 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1489
1489
|
maxFiles: h,
|
|
1490
1490
|
...j
|
|
1491
1491
|
}) => {
|
|
1492
|
-
const [u,
|
|
1492
|
+
const [u, p] = T(""), [f, N] = T(""), g = h || 3, A = "muncher-button" + (r ? " muncher-button--" + r : "") + (i ? " muncher-button--" + i : "") + (a ? " muncher-button--active" : ""), v = (S) => {
|
|
1493
1493
|
if (d) {
|
|
1494
|
-
let
|
|
1495
|
-
|
|
1494
|
+
let z = Array.from(S.currentTarget.files);
|
|
1495
|
+
z.length > g && (z = z.slice(0, g), N("Only first " + g + " files included")), x(z), p(z.map((k) => k.name).join(", "));
|
|
1496
1496
|
} else
|
|
1497
|
-
x(Array.from(
|
|
1498
|
-
},
|
|
1497
|
+
x(Array.from(S.currentTarget.files[0])), p(S.currentTarget.files[0].name);
|
|
1498
|
+
}, _ = () => o && o !== "";
|
|
1499
1499
|
return /* @__PURE__ */ e.jsxs("div", { className: "muncher-file-input--div", children: [
|
|
1500
1500
|
/* @__PURE__ */ e.jsxs("div", { className: "file-input-element", children: [
|
|
1501
|
-
/* @__PURE__ */ e.jsxs("label", { htmlFor: n, className:
|
|
1501
|
+
/* @__PURE__ */ e.jsxs("label", { htmlFor: n, className: A, children: [
|
|
1502
1502
|
/* @__PURE__ */ e.jsx(w, { name: "image" }),
|
|
1503
1503
|
" ",
|
|
1504
1504
|
t,
|
|
1505
|
-
|
|
1505
|
+
c ? /* @__PURE__ */ e.jsx("span", { className: "required", children: " *" }) : ""
|
|
1506
1506
|
] }),
|
|
1507
1507
|
/* @__PURE__ */ e.jsx("span", { className: "span-file-name", children: u }),
|
|
1508
1508
|
/* @__PURE__ */ e.jsx(
|
|
@@ -1512,7 +1512,7 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1512
1512
|
type: "file",
|
|
1513
1513
|
className: "muncher-file-input",
|
|
1514
1514
|
name: n,
|
|
1515
|
-
onChange:
|
|
1515
|
+
onChange: v,
|
|
1516
1516
|
multiple: d,
|
|
1517
1517
|
accept: "image/*",
|
|
1518
1518
|
...j
|
|
@@ -1520,14 +1520,14 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1520
1520
|
)
|
|
1521
1521
|
] }),
|
|
1522
1522
|
f !== "" ? /* @__PURE__ */ e.jsx("p", { className: "text-danger", children: f }) : "",
|
|
1523
|
-
|
|
1523
|
+
_() ? /* @__PURE__ */ e.jsx("div", { className: "muncher-input-error-message", children: /* @__PURE__ */ e.jsx(w, { name: "alert", children: o }) }) : ""
|
|
1524
1524
|
] });
|
|
1525
|
-
},
|
|
1525
|
+
}, ke = ({
|
|
1526
1526
|
name: n,
|
|
1527
1527
|
label: t,
|
|
1528
1528
|
required: r,
|
|
1529
|
-
readOnly:
|
|
1530
|
-
icon:
|
|
1529
|
+
readOnly: i,
|
|
1530
|
+
icon: c,
|
|
1531
1531
|
hoverIcon: a,
|
|
1532
1532
|
onHoverIconClick: x,
|
|
1533
1533
|
type: o = "text",
|
|
@@ -1535,28 +1535,28 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1535
1535
|
onBlur: h,
|
|
1536
1536
|
labelPosition: j = "top",
|
|
1537
1537
|
onKeyDown: u,
|
|
1538
|
-
error:
|
|
1538
|
+
error: p,
|
|
1539
1539
|
focus: f = !1,
|
|
1540
1540
|
placeholder: N,
|
|
1541
|
-
onChange:
|
|
1542
|
-
step:
|
|
1543
|
-
value:
|
|
1544
|
-
maxLength:
|
|
1545
|
-
onEnterPress:
|
|
1546
|
-
displayLoader:
|
|
1547
|
-
...
|
|
1541
|
+
onChange: g,
|
|
1542
|
+
step: A,
|
|
1543
|
+
value: v,
|
|
1544
|
+
maxLength: _,
|
|
1545
|
+
onEnterPress: S,
|
|
1546
|
+
displayLoader: z,
|
|
1547
|
+
...k
|
|
1548
1548
|
}) => {
|
|
1549
|
-
const
|
|
1550
|
-
let
|
|
1551
|
-
return (
|
|
1552
|
-
},
|
|
1553
|
-
|
|
1549
|
+
const H = () => p && p !== "", P = () => {
|
|
1550
|
+
let C = "muncher-input";
|
|
1551
|
+
return (c || a) && (C += " muncher-input-icon"), H() && (C += " muncher-input-error"), j === "side" && (C += " muncher-label-side"), C;
|
|
1552
|
+
}, m = () => t ? /* @__PURE__ */ e.jsx(q, { label: t, required: r, id: n }) : "", M = (C) => {
|
|
1553
|
+
C.key === "Enter" && S && S(), u && u(C);
|
|
1554
1554
|
};
|
|
1555
1555
|
return /* @__PURE__ */ e.jsxs("div", { className: "muncher-input--div", children: [
|
|
1556
|
-
j !== "side" ?
|
|
1556
|
+
j !== "side" ? m() : "",
|
|
1557
1557
|
/* @__PURE__ */ e.jsxs("div", { className: "muncher-input-element", children: [
|
|
1558
|
-
j === "side" ?
|
|
1559
|
-
|
|
1558
|
+
j === "side" ? m() : "",
|
|
1559
|
+
c ? /* @__PURE__ */ e.jsx(w, { name: c }) : "",
|
|
1560
1560
|
a ? /* @__PURE__ */ e.jsxs("span", { className: "muncher-icon-hover", children: [
|
|
1561
1561
|
/* @__PURE__ */ e.jsx(w, { name: a, onClick: x }),
|
|
1562
1562
|
" "
|
|
@@ -1566,31 +1566,31 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1566
1566
|
"input",
|
|
1567
1567
|
{
|
|
1568
1568
|
id: n,
|
|
1569
|
-
className:
|
|
1569
|
+
className: P(),
|
|
1570
1570
|
name: n,
|
|
1571
1571
|
autoFocus: f,
|
|
1572
|
-
value:
|
|
1572
|
+
value: v,
|
|
1573
1573
|
type: o || "text",
|
|
1574
1574
|
autoComplete: "off",
|
|
1575
1575
|
placeholder: N,
|
|
1576
|
-
onChange:
|
|
1576
|
+
onChange: g,
|
|
1577
1577
|
required: r,
|
|
1578
|
-
readOnly:
|
|
1578
|
+
readOnly: i,
|
|
1579
1579
|
list: d,
|
|
1580
|
-
onKeyDown:
|
|
1580
|
+
onKeyDown: M,
|
|
1581
1581
|
onBlur: h,
|
|
1582
|
-
step:
|
|
1583
|
-
maxLength:
|
|
1584
|
-
...
|
|
1582
|
+
step: A,
|
|
1583
|
+
maxLength: _,
|
|
1584
|
+
...k
|
|
1585
1585
|
}
|
|
1586
1586
|
),
|
|
1587
|
-
|
|
1587
|
+
z ? /* @__PURE__ */ e.jsx(he, { size: "tiny" }) : ""
|
|
1588
1588
|
] })
|
|
1589
1589
|
] }),
|
|
1590
|
-
|
|
1590
|
+
H() ? /* @__PURE__ */ e.jsx("div", { className: "muncher-input-error-message", children: /* @__PURE__ */ e.jsx(w, { name: "alert", children: p }) }) : ""
|
|
1591
1591
|
] });
|
|
1592
|
-
},
|
|
1593
|
-
const [x, o] = T(
|
|
1592
|
+
}, He = ({ name: n, required: t = !1, onChange: r, checked: i = !1, label: c, ...a }) => {
|
|
1593
|
+
const [x, o] = T(i || !1);
|
|
1594
1594
|
return /* @__PURE__ */ e.jsx("div", { className: "muncher-input--div", children: /* @__PURE__ */ e.jsxs("div", { className: "muncher-radio", children: [
|
|
1595
1595
|
/* @__PURE__ */ e.jsx(
|
|
1596
1596
|
"input",
|
|
@@ -1605,10 +1605,10 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1605
1605
|
...a
|
|
1606
1606
|
}
|
|
1607
1607
|
),
|
|
1608
|
-
|
|
1609
|
-
|
|
1608
|
+
c ? /* @__PURE__ */ e.jsx(
|
|
1609
|
+
q,
|
|
1610
1610
|
{
|
|
1611
|
-
label:
|
|
1611
|
+
label: c,
|
|
1612
1612
|
required: t,
|
|
1613
1613
|
id: n,
|
|
1614
1614
|
onClick: () => {
|
|
@@ -1617,12 +1617,12 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1617
1617
|
}
|
|
1618
1618
|
) : ""
|
|
1619
1619
|
] }) });
|
|
1620
|
-
},
|
|
1620
|
+
}, Ce = ({
|
|
1621
1621
|
name: n,
|
|
1622
1622
|
options: t,
|
|
1623
1623
|
label: r,
|
|
1624
|
-
required:
|
|
1625
|
-
multiple:
|
|
1624
|
+
required: i,
|
|
1625
|
+
multiple: c,
|
|
1626
1626
|
error: a,
|
|
1627
1627
|
onChange: x,
|
|
1628
1628
|
value: o,
|
|
@@ -1633,7 +1633,7 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1633
1633
|
return h() && (u += " muncher-input-error"), u;
|
|
1634
1634
|
};
|
|
1635
1635
|
return /* @__PURE__ */ e.jsxs("div", { className: "muncher-input--div", children: [
|
|
1636
|
-
r ? /* @__PURE__ */ e.jsx(
|
|
1636
|
+
r ? /* @__PURE__ */ e.jsx(q, { label: r, required: i, id: n }) : "",
|
|
1637
1637
|
/* @__PURE__ */ e.jsx("div", { className: "muncher-input-element", children: /* @__PURE__ */ e.jsxs(
|
|
1638
1638
|
"select",
|
|
1639
1639
|
{
|
|
@@ -1642,23 +1642,25 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1642
1642
|
name: n,
|
|
1643
1643
|
value: o,
|
|
1644
1644
|
onChange: x,
|
|
1645
|
-
required:
|
|
1646
|
-
multiple:
|
|
1645
|
+
required: i,
|
|
1646
|
+
multiple: c,
|
|
1647
1647
|
...d,
|
|
1648
1648
|
children: [
|
|
1649
|
-
|
|
1650
|
-
t.map(
|
|
1649
|
+
i ? /* @__PURE__ */ e.jsx("option", { value: "", children: "-- Select --" }) : "",
|
|
1650
|
+
t.map(
|
|
1651
|
+
(u, p) => /* @__PURE__ */ e.jsx("option", { value: u.value, children: u.label }, `select-option-${p}`)
|
|
1652
|
+
)
|
|
1651
1653
|
]
|
|
1652
1654
|
}
|
|
1653
1655
|
) }),
|
|
1654
1656
|
h() ? /* @__PURE__ */ e.jsx("div", { className: "muncher-input-error-message", children: /* @__PURE__ */ e.jsx(w, { name: "alert", children: a }) }) : ""
|
|
1655
1657
|
] });
|
|
1656
|
-
},
|
|
1658
|
+
}, Oe = ({
|
|
1657
1659
|
name: n,
|
|
1658
1660
|
label: t,
|
|
1659
1661
|
required: r,
|
|
1660
|
-
readOnly:
|
|
1661
|
-
rows:
|
|
1662
|
+
readOnly: i = !1,
|
|
1663
|
+
rows: c = 6,
|
|
1662
1664
|
maxLength: a = 1e3,
|
|
1663
1665
|
focus: x = !1,
|
|
1664
1666
|
placeholder: o,
|
|
@@ -1666,17 +1668,17 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1666
1668
|
value: h,
|
|
1667
1669
|
...j
|
|
1668
1670
|
}) => {
|
|
1669
|
-
const [u,
|
|
1670
|
-
|
|
1671
|
+
const [u, p] = T(h), f = (N) => {
|
|
1672
|
+
p(N.target.value), d && d(N);
|
|
1671
1673
|
};
|
|
1672
1674
|
return /* @__PURE__ */ e.jsxs("div", { className: "muncher-input--div", children: [
|
|
1673
|
-
t ? /* @__PURE__ */ e.jsx(
|
|
1675
|
+
t ? /* @__PURE__ */ e.jsx(q, { label: t, required: r, id: n }) : "",
|
|
1674
1676
|
/* @__PURE__ */ e.jsx(
|
|
1675
1677
|
"textarea",
|
|
1676
1678
|
{
|
|
1677
1679
|
id: n,
|
|
1678
1680
|
className: "muncher-textarea",
|
|
1679
|
-
rows:
|
|
1681
|
+
rows: c,
|
|
1680
1682
|
maxLength: a,
|
|
1681
1683
|
name: n,
|
|
1682
1684
|
autoFocus: x,
|
|
@@ -1684,7 +1686,7 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1684
1686
|
placeholder: o,
|
|
1685
1687
|
onChange: f,
|
|
1686
1688
|
required: r,
|
|
1687
|
-
readOnly:
|
|
1689
|
+
readOnly: i,
|
|
1688
1690
|
...j
|
|
1689
1691
|
}
|
|
1690
1692
|
),
|
|
@@ -1693,12 +1695,12 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1693
1695
|
" characters left"
|
|
1694
1696
|
] })
|
|
1695
1697
|
] });
|
|
1696
|
-
},
|
|
1698
|
+
}, Ve = ({
|
|
1697
1699
|
focus: n = !1,
|
|
1698
1700
|
inputPlaceHolder: t,
|
|
1699
1701
|
handleInputChange: r,
|
|
1700
|
-
showContent:
|
|
1701
|
-
setShowContent:
|
|
1702
|
+
showContent: i = !1,
|
|
1703
|
+
setShowContent: c,
|
|
1702
1704
|
readOnly: a,
|
|
1703
1705
|
value: x,
|
|
1704
1706
|
label: o,
|
|
@@ -1706,31 +1708,31 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1706
1708
|
required: h,
|
|
1707
1709
|
children: j
|
|
1708
1710
|
}) => {
|
|
1709
|
-
const u =
|
|
1710
|
-
|
|
1711
|
-
}, f =
|
|
1712
|
-
|
|
1713
|
-
}, [
|
|
1714
|
-
|
|
1711
|
+
const u = de(null), p = (g) => {
|
|
1712
|
+
c(!0), r(g.target.value);
|
|
1713
|
+
}, f = G(() => {
|
|
1714
|
+
c(!1);
|
|
1715
|
+
}, [c]), N = G((g) => {
|
|
1716
|
+
g.keyCode === 27 && f();
|
|
1715
1717
|
}, [f]);
|
|
1716
|
-
return
|
|
1717
|
-
const
|
|
1718
|
+
return Q(() => {
|
|
1719
|
+
const g = (A) => {
|
|
1718
1720
|
if (u && u !== null) {
|
|
1719
|
-
const
|
|
1720
|
-
|
|
1721
|
+
const v = u.current;
|
|
1722
|
+
v && !v.contains(A.target) && f();
|
|
1721
1723
|
}
|
|
1722
1724
|
};
|
|
1723
|
-
return document.addEventListener("keydown", N, !1), document.addEventListener("mousedown",
|
|
1725
|
+
return document.addEventListener("keydown", N, !1), document.addEventListener("mousedown", g), () => {
|
|
1724
1726
|
document.removeEventListener("keydown", N, !1);
|
|
1725
1727
|
};
|
|
1726
1728
|
}, [N, f]), /* @__PURE__ */ e.jsxs("div", { className: "muncher-input-drop-down", ref: u, children: [
|
|
1727
1729
|
/* @__PURE__ */ e.jsx(
|
|
1728
|
-
|
|
1730
|
+
ke,
|
|
1729
1731
|
{
|
|
1730
1732
|
focus: n,
|
|
1731
1733
|
placeholder: t,
|
|
1732
1734
|
name: "query",
|
|
1733
|
-
onChange:
|
|
1735
|
+
onChange: p,
|
|
1734
1736
|
readOnly: a,
|
|
1735
1737
|
value: x,
|
|
1736
1738
|
label: o,
|
|
@@ -1738,27 +1740,27 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1738
1740
|
error: d
|
|
1739
1741
|
}
|
|
1740
1742
|
),
|
|
1741
|
-
|
|
1743
|
+
i ? /* @__PURE__ */ e.jsx("div", { className: "muncher-input-drop-down--content", children: j }) : ""
|
|
1742
1744
|
] });
|
|
1743
|
-
},
|
|
1745
|
+
}, Le = ({ children: n }) => /* @__PURE__ */ e.jsx("ul", { className: "muncher-ul", children: n }), Pe = ({ isFeatured: n, bulletIcon: t = "arrow-right", bulletWeight: r = 2, bulletSize: i = "small", bulletColor: c, children: a }) => /* @__PURE__ */ e.jsx("li", { className: n ? "muncher-li featured" : "muncher-li", children: /* @__PURE__ */ e.jsx(
|
|
1744
1746
|
w,
|
|
1745
1747
|
{
|
|
1746
1748
|
name: t,
|
|
1747
1749
|
weight: r,
|
|
1748
|
-
size:
|
|
1749
|
-
color:
|
|
1750
|
+
size: i,
|
|
1751
|
+
color: c,
|
|
1750
1752
|
children: a
|
|
1751
1753
|
}
|
|
1752
|
-
) }),
|
|
1753
|
-
const
|
|
1754
|
+
) }), De = ({ show: n = !1, setShow: t, children: r, ...i }) => {
|
|
1755
|
+
const c = G((a) => {
|
|
1754
1756
|
a.keyCode === 27 && t(!1);
|
|
1755
1757
|
}, [t]);
|
|
1756
|
-
return
|
|
1757
|
-
document.removeEventListener("keydown",
|
|
1758
|
-
}), [
|
|
1758
|
+
return Q(() => (document.addEventListener("keydown", c, !1), () => {
|
|
1759
|
+
document.removeEventListener("keydown", c, !1);
|
|
1760
|
+
}), [c]), Q(() => {
|
|
1759
1761
|
n ? document.body.style.overflow = "hidden" : document.body.style.overflow = "unset";
|
|
1760
|
-
}, [n]), /* @__PURE__ */ e.jsxs(
|
|
1761
|
-
/* @__PURE__ */ e.jsx(
|
|
1762
|
+
}, [n]), /* @__PURE__ */ e.jsxs(oe.Fragment, { children: [
|
|
1763
|
+
/* @__PURE__ */ e.jsx(me, { show: n, backdropClickHandler: () => t(!1) }),
|
|
1762
1764
|
/* @__PURE__ */ e.jsx(
|
|
1763
1765
|
"div",
|
|
1764
1766
|
{
|
|
@@ -1767,53 +1769,53 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1767
1769
|
transform: n ? "translateY(0)" : "translateY(-100vh)",
|
|
1768
1770
|
opacity: n ? "1" : "0"
|
|
1769
1771
|
},
|
|
1770
|
-
...
|
|
1772
|
+
...i,
|
|
1771
1773
|
children: r
|
|
1772
1774
|
}
|
|
1773
1775
|
)
|
|
1774
1776
|
] });
|
|
1775
|
-
},
|
|
1776
|
-
const
|
|
1777
|
-
return /* @__PURE__ */ e.jsx("section", { className:
|
|
1778
|
-
},
|
|
1777
|
+
}, Fe = ({ showHoverEffect: n, onClick: t, children: r }) => {
|
|
1778
|
+
const i = () => n ? "muncher-paper muncher-paper-hover" : "muncher-paper";
|
|
1779
|
+
return /* @__PURE__ */ e.jsx("section", { className: i(), onClick: t, children: r });
|
|
1780
|
+
}, Ie = ({ pillCloseHandler: n, children: t, ...r }) => /* @__PURE__ */ e.jsxs("div", { className: "muncher-pill", ...r, children: [
|
|
1779
1781
|
/* @__PURE__ */ e.jsx("div", { className: "close", onClick: n, children: /* @__PURE__ */ e.jsx(w, { name: "close" }) }),
|
|
1780
1782
|
/* @__PURE__ */ e.jsxs("div", { className: "content", children: [
|
|
1781
1783
|
" ",
|
|
1782
1784
|
t
|
|
1783
1785
|
] })
|
|
1784
|
-
] }),
|
|
1785
|
-
const
|
|
1786
|
-
const
|
|
1787
|
-
return r ? r + " " +
|
|
1786
|
+
] }), Ye = ({ value: n, max: t, label: r }) => {
|
|
1787
|
+
const i = () => {
|
|
1788
|
+
const c = Math.round(n / t * 100) + "%";
|
|
1789
|
+
return r ? r + " " + c : c;
|
|
1788
1790
|
};
|
|
1789
1791
|
return /* @__PURE__ */ e.jsxs("div", { className: "muncher-progress", children: [
|
|
1790
|
-
/* @__PURE__ */ e.jsx("label", { htmlFor: "progress", children:
|
|
1791
|
-
/* @__PURE__ */ e.jsx("progress", { id: "progress", value: n, max: t, children:
|
|
1792
|
+
/* @__PURE__ */ e.jsx("label", { htmlFor: "progress", children: i() }),
|
|
1793
|
+
/* @__PURE__ */ e.jsx("progress", { id: "progress", value: n, max: t, children: i() })
|
|
1792
1794
|
] });
|
|
1793
|
-
},
|
|
1794
|
-
const
|
|
1795
|
-
return /* @__PURE__ */ e.jsx("hr", { className:
|
|
1796
|
-
}, Ue = ({ sliderItems: n, navButtonSize: t = "large", navButtonWeight: r = 2, variant:
|
|
1795
|
+
}, $e = ({ variant: n, size: t, style: r }) => {
|
|
1796
|
+
const i = "muncher-hr" + (n ? " muncher-hr--" + n : "") + (t ? " muncher-hr--" + t : "") + (r ? " muncher-hr--" + r : "");
|
|
1797
|
+
return /* @__PURE__ */ e.jsx("hr", { className: i });
|
|
1798
|
+
}, Ue = ({ sliderItems: n, navButtonSize: t = "large", navButtonWeight: r = 2, variant: i, navIcon: c, navButtonPlacement: a = "inside" }) => {
|
|
1797
1799
|
const [x, o] = T(0), [d, h] = T(0), j = () => n.length > 1 && x > 0 ? /* @__PURE__ */ e.jsx(
|
|
1798
|
-
|
|
1800
|
+
xe,
|
|
1799
1801
|
{
|
|
1800
1802
|
direction: "left",
|
|
1801
1803
|
size: t,
|
|
1802
|
-
variant:
|
|
1803
|
-
navIcon:
|
|
1804
|
+
variant: i,
|
|
1805
|
+
navIcon: c,
|
|
1804
1806
|
weight: r,
|
|
1805
1807
|
onClick: () => {
|
|
1806
1808
|
x === 0 ? (h(-(n.length - 1) * 100), o(n.length - 1)) : (h(d + 100), o(x - 1));
|
|
1807
1809
|
}
|
|
1808
1810
|
}
|
|
1809
1811
|
) : "", u = () => n.length > 1 && x < n.length - 1 ? /* @__PURE__ */ e.jsx(
|
|
1810
|
-
|
|
1812
|
+
xe,
|
|
1811
1813
|
{
|
|
1812
1814
|
direction: "right",
|
|
1813
1815
|
size: t,
|
|
1814
1816
|
weight: r,
|
|
1815
|
-
navIcon:
|
|
1816
|
-
variant:
|
|
1817
|
+
navIcon: c,
|
|
1818
|
+
variant: i,
|
|
1817
1819
|
onClick: () => {
|
|
1818
1820
|
x === n.length - 1 ? (o(0), h(0)) : (h(d - 100), o(x + 1));
|
|
1819
1821
|
}
|
|
@@ -1824,12 +1826,12 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1824
1826
|
/* @__PURE__ */ e.jsxs("div", { className: "muncher-item-slider", children: [
|
|
1825
1827
|
a === "inside" ? j() : "",
|
|
1826
1828
|
/* @__PURE__ */ e.jsx("div", { className: "slider-container", style: { width: `${100 * n.length}%` }, children: n.map(
|
|
1827
|
-
(
|
|
1829
|
+
(p, f) => /* @__PURE__ */ e.jsx(
|
|
1828
1830
|
"div",
|
|
1829
1831
|
{
|
|
1830
1832
|
className: "slider-item",
|
|
1831
1833
|
style: { transform: `translateX(${d}%)` },
|
|
1832
|
-
children:
|
|
1834
|
+
children: p
|
|
1833
1835
|
},
|
|
1834
1836
|
"slider-item" + f
|
|
1835
1837
|
)
|
|
@@ -1838,12 +1840,12 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1838
1840
|
] }),
|
|
1839
1841
|
a === "outside" ? u() : ""
|
|
1840
1842
|
] });
|
|
1841
|
-
},
|
|
1843
|
+
}, We = ({
|
|
1842
1844
|
min: n,
|
|
1843
1845
|
max: t,
|
|
1844
1846
|
minValue: r,
|
|
1845
|
-
maxValue:
|
|
1846
|
-
setMinValue:
|
|
1847
|
+
maxValue: i,
|
|
1848
|
+
setMinValue: c,
|
|
1847
1849
|
setMaxValue: a,
|
|
1848
1850
|
numberFormatter: x = (o) => new Intl.NumberFormat("en-US", {
|
|
1849
1851
|
style: "currency",
|
|
@@ -1851,14 +1853,14 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1851
1853
|
}).format(o)
|
|
1852
1854
|
}) => {
|
|
1853
1855
|
const o = (j) => {
|
|
1854
|
-
const u = +j.target.value,
|
|
1855
|
-
|
|
1856
|
+
const u = +j.target.value, p = u < i - 1 ? u : r;
|
|
1857
|
+
c(p);
|
|
1856
1858
|
}, d = (j) => {
|
|
1857
|
-
const u = +j.target.value,
|
|
1858
|
-
a(
|
|
1859
|
+
const u = +j.target.value, p = u > r + 1 ? u : i;
|
|
1860
|
+
a(p);
|
|
1859
1861
|
}, h = (j) => x && j ? x(j) : j;
|
|
1860
1862
|
return /* @__PURE__ */ e.jsxs("div", { className: "muncher-slider", children: [
|
|
1861
|
-
/* @__PURE__ */ e.jsx("div", { className: "slider-header", children: /* @__PURE__ */ e.jsx("p", { children: h(r) + " - " + h(
|
|
1863
|
+
/* @__PURE__ */ e.jsx("div", { className: "slider-header", children: /* @__PURE__ */ e.jsx("p", { children: h(r) + " - " + h(i) }) }),
|
|
1862
1864
|
/* @__PURE__ */ e.jsx(
|
|
1863
1865
|
"input",
|
|
1864
1866
|
{
|
|
@@ -1877,7 +1879,7 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1877
1879
|
type: "range",
|
|
1878
1880
|
min: n,
|
|
1879
1881
|
max: t,
|
|
1880
|
-
value:
|
|
1882
|
+
value: i,
|
|
1881
1883
|
onChange: d
|
|
1882
1884
|
}
|
|
1883
1885
|
),
|
|
@@ -1886,19 +1888,19 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1886
1888
|
/* @__PURE__ */ e.jsx("div", { className: "slider-max", children: h(t) })
|
|
1887
1889
|
] })
|
|
1888
1890
|
] });
|
|
1889
|
-
},
|
|
1891
|
+
}, Be = ({
|
|
1890
1892
|
min: n,
|
|
1891
1893
|
max: t,
|
|
1892
1894
|
value: r,
|
|
1893
|
-
setValue:
|
|
1894
|
-
numberFormatter:
|
|
1895
|
+
setValue: i,
|
|
1896
|
+
numberFormatter: c = (a) => new Intl.NumberFormat("en-US", {
|
|
1895
1897
|
style: "currency",
|
|
1896
1898
|
currency: "USD"
|
|
1897
1899
|
}).format(a)
|
|
1898
1900
|
}) => {
|
|
1899
|
-
const a = (o) =>
|
|
1901
|
+
const a = (o) => c ? c(o) : o, x = (o) => {
|
|
1900
1902
|
const d = +o.target.value;
|
|
1901
|
-
|
|
1903
|
+
i(d);
|
|
1902
1904
|
};
|
|
1903
1905
|
return /* @__PURE__ */ e.jsxs("div", { className: "muncher-slider", children: [
|
|
1904
1906
|
/* @__PURE__ */ e.jsx("div", { className: "slider-header", children: /* @__PURE__ */ e.jsx("p", { children: a(r) }) }),
|
|
@@ -1918,20 +1920,20 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1918
1920
|
/* @__PURE__ */ e.jsx("div", { className: "slider-max", children: a(t) })
|
|
1919
1921
|
] })
|
|
1920
1922
|
] });
|
|
1921
|
-
},
|
|
1922
|
-
const
|
|
1923
|
+
}, Je = ({ isFeatured: n, onClick: t }) => /* @__PURE__ */ e.jsx("span", { className: "span-featured", children: /* @__PURE__ */ e.jsx("span", { className: n ? "featured-star" : "un-featured-star", onClick: t }) }), Ge = ({ rating: n, color: t, size: r, ...i }) => {
|
|
1924
|
+
const c = {
|
|
1923
1925
|
"--r": n
|
|
1924
1926
|
}, a = () => {
|
|
1925
1927
|
let x = "muncher-star";
|
|
1926
1928
|
return t && (x += " star-" + t), r && (x += " star-" + r), x;
|
|
1927
1929
|
};
|
|
1928
|
-
return /* @__PURE__ */ e.jsx("span", { className: a(), style:
|
|
1929
|
-
},
|
|
1930
|
-
const [r,
|
|
1931
|
-
|
|
1930
|
+
return /* @__PURE__ */ e.jsx("span", { className: a(), style: c, ...i });
|
|
1931
|
+
}, qe = ({ handleTabSelected: n, children: t }) => {
|
|
1932
|
+
const [r, i] = T(0), { tabs: c } = t, a = (x) => {
|
|
1933
|
+
i(x), n && n(x);
|
|
1932
1934
|
};
|
|
1933
1935
|
return /* @__PURE__ */ e.jsxs("section", { className: "muncher-tabs", children: [
|
|
1934
|
-
/* @__PURE__ */ e.jsx("header", { children:
|
|
1936
|
+
/* @__PURE__ */ e.jsx("header", { children: c.map(
|
|
1935
1937
|
(x, o) => /* @__PURE__ */ e.jsxs("div", { className: "muncher-tab-header--item", children: [
|
|
1936
1938
|
/* @__PURE__ */ e.jsx(
|
|
1937
1939
|
O,
|
|
@@ -1946,10 +1948,10 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1946
1948
|
children: x.header
|
|
1947
1949
|
}
|
|
1948
1950
|
),
|
|
1949
|
-
o !==
|
|
1951
|
+
o !== c.length - 1 ? /* @__PURE__ */ e.jsx("span", { className: "spacer", children: "|" }) : ""
|
|
1950
1952
|
] }, "muncher-tab-header" + o)
|
|
1951
1953
|
) }),
|
|
1952
|
-
|
|
1954
|
+
c.map(
|
|
1953
1955
|
(x, o) => /* @__PURE__ */ e.jsx(
|
|
1954
1956
|
"section",
|
|
1955
1957
|
{
|
|
@@ -1960,12 +1962,12 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1960
1962
|
)
|
|
1961
1963
|
)
|
|
1962
1964
|
] });
|
|
1963
|
-
},
|
|
1965
|
+
}, Xe = ({
|
|
1964
1966
|
fileName: n,
|
|
1965
|
-
defaultPageSize: t,
|
|
1967
|
+
defaultPageSize: t = 50,
|
|
1966
1968
|
skeleton: r,
|
|
1967
|
-
handleOnUpload:
|
|
1968
|
-
sortBy:
|
|
1969
|
+
handleOnUpload: i,
|
|
1970
|
+
sortBy: c,
|
|
1969
1971
|
excludeDownload: a,
|
|
1970
1972
|
includeUpload: x,
|
|
1971
1973
|
isUploading: o,
|
|
@@ -1973,106 +1975,101 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
1973
1975
|
uploadSuccessMessage: h,
|
|
1974
1976
|
excludePagination: j,
|
|
1975
1977
|
footer: u,
|
|
1976
|
-
children:
|
|
1978
|
+
children: p
|
|
1977
1979
|
}) => {
|
|
1978
|
-
const { header: f, rows: N } =
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
if (f[v.index].sort) {
|
|
1982
|
-
const y = N.sort(f[v.index].sort);
|
|
1983
|
-
return v.desc ? y.reverse() : y;
|
|
1984
|
-
}
|
|
1985
|
-
return N.sort(
|
|
1986
|
-
(y, k) => {
|
|
1987
|
-
var D, Y, q, F, U, $;
|
|
1988
|
-
if (((D = y[v.index]) == null ? void 0 : D.value) === null || ((Y = k[v.index]) == null ? void 0 : Y.value) === null)
|
|
1989
|
-
return 0;
|
|
1990
|
-
const z = (F = (q = y[v.index]) == null ? void 0 : q.value) == null ? void 0 : F.toString().toLowerCase(), L = ($ = (U = k[v.index]) == null ? void 0 : U.value) == null ? void 0 : $.toString().toLowerCase();
|
|
1991
|
-
let H = z.localeCompare(L);
|
|
1992
|
-
return v.desc ? -H : H;
|
|
1993
|
-
}
|
|
1980
|
+
const { header: f, rows: N } = p, [g, A] = T(c ?? { index: 0 }), [v, _] = T({ num: 0, size: t }), S = (m) => {
|
|
1981
|
+
A(
|
|
1982
|
+
(M) => M.index === m ? { ...M, desc: !M.desc } : { index: m }
|
|
1994
1983
|
);
|
|
1995
|
-
},
|
|
1984
|
+
}, z = te(() => {
|
|
1985
|
+
var C;
|
|
1986
|
+
const m = [...N], M = (C = f[g.index]) == null ? void 0 : C.sort;
|
|
1987
|
+
return M ? m.sort(M) : m.sort((L, X) => {
|
|
1988
|
+
var Y, $, U, W;
|
|
1989
|
+
const Z = (($ = (Y = L[g.index]) == null ? void 0 : Y.value) == null ? void 0 : $.toString().toLowerCase()) ?? "", I = ((W = (U = X[g.index]) == null ? void 0 : U.value) == null ? void 0 : W.toString().toLowerCase()) ?? "";
|
|
1990
|
+
return Z.localeCompare(I);
|
|
1991
|
+
}), g.desc ? m.reverse() : m;
|
|
1992
|
+
}, [N, g, f]), k = te(
|
|
1993
|
+
() => z.slice(v.num * v.size, (v.num + 1) * v.size),
|
|
1994
|
+
[z, v]
|
|
1995
|
+
), H = f.filter((m) => !m.csvExclude).map((m) => typeof m.name == "string" ? m.name : ""), P = N.map(
|
|
1996
|
+
(m) => m.filter((M, C) => !f[C].csvExclude).map((M) => M.csv ?? M.value ?? "")
|
|
1997
|
+
);
|
|
1996
1998
|
return /* @__PURE__ */ e.jsxs("section", { className: "muncher-table", children: [
|
|
1997
1999
|
/* @__PURE__ */ e.jsx("div", { className: "row head", children: f.map(
|
|
1998
|
-
(
|
|
2000
|
+
(m, M) => m.visibility === "hidden" ? null : /* @__PURE__ */ e.jsx(
|
|
1999
2001
|
"div",
|
|
2000
2002
|
{
|
|
2001
|
-
title:
|
|
2002
|
-
className:
|
|
2003
|
-
children: typeof
|
|
2004
|
-
|
|
2003
|
+
title: m.title,
|
|
2004
|
+
className: m.visibility ? "col main" : "col",
|
|
2005
|
+
children: typeof m.name == "string" ? /* @__PURE__ */ e.jsx("div", { className: "sort-button", children: /* @__PURE__ */ e.jsx(
|
|
2006
|
+
Ne,
|
|
2005
2007
|
{
|
|
2006
|
-
onClick: () =>
|
|
2007
|
-
|
|
2008
|
-
|
|
2009
|
-
|
|
2010
|
-
sortAsc: !v.desc,
|
|
2011
|
-
children: y.name
|
|
2008
|
+
onClick: () => S(M),
|
|
2009
|
+
active: g.index === M,
|
|
2010
|
+
sortAsc: !g.desc,
|
|
2011
|
+
children: m.name
|
|
2012
2012
|
}
|
|
2013
|
-
) }) :
|
|
2013
|
+
) }) : m.name
|
|
2014
2014
|
},
|
|
2015
|
-
|
|
2015
|
+
`row-head-${M}`
|
|
2016
2016
|
)
|
|
2017
2017
|
) }),
|
|
2018
|
-
r ||
|
|
2019
|
-
(
|
|
2018
|
+
r || k.map((m, M) => /* @__PURE__ */ e.jsx("div", { className: "row", children: m.map(
|
|
2019
|
+
(C, L) => f[L].visibility === "hidden" ? null : /* @__PURE__ */ e.jsx(
|
|
2020
2020
|
"div",
|
|
2021
2021
|
{
|
|
2022
2022
|
className: f[L].visibility ? "col main" : "col",
|
|
2023
|
-
children:
|
|
2023
|
+
children: C.content
|
|
2024
2024
|
},
|
|
2025
|
-
|
|
2026
|
-
)
|
|
2027
|
-
),
|
|
2028
|
-
u
|
|
2025
|
+
`row-col-${M}-${L}`
|
|
2026
|
+
)
|
|
2027
|
+
) }, `row-${M}`)),
|
|
2028
|
+
u ?? null,
|
|
2029
2029
|
/* @__PURE__ */ e.jsxs("div", { className: "row-footer", children: [
|
|
2030
2030
|
/* @__PURE__ */ e.jsxs("div", { className: "row-footer-buttons", children: [
|
|
2031
|
-
a
|
|
2032
|
-
|
|
2031
|
+
!a && /* @__PURE__ */ e.jsx(
|
|
2032
|
+
we,
|
|
2033
2033
|
{
|
|
2034
|
-
filename: n
|
|
2034
|
+
filename: n ?? "download",
|
|
2035
2035
|
variant: "secondary",
|
|
2036
2036
|
title: "Download",
|
|
2037
|
-
header:
|
|
2038
|
-
data:
|
|
2039
|
-
(y) => y.filter((k, z) => !f[z].csvExclude).map((k) => k.csv ? k.csv ? k.csv : "" : k.value ? k.value : "")
|
|
2040
|
-
)
|
|
2037
|
+
header: H,
|
|
2038
|
+
data: P
|
|
2041
2039
|
}
|
|
2042
2040
|
),
|
|
2043
|
-
x
|
|
2044
|
-
|
|
2041
|
+
x && /* @__PURE__ */ e.jsx(
|
|
2042
|
+
Me,
|
|
2045
2043
|
{
|
|
2046
2044
|
name: "csv-input-file",
|
|
2047
|
-
handleOnChange:
|
|
2045
|
+
handleOnChange: i,
|
|
2048
2046
|
isUploading: o,
|
|
2049
2047
|
warningMessage: d,
|
|
2050
2048
|
successMessage: h
|
|
2051
2049
|
}
|
|
2052
|
-
)
|
|
2050
|
+
)
|
|
2053
2051
|
] }),
|
|
2054
|
-
j
|
|
2052
|
+
!j && /* @__PURE__ */ e.jsxs("div", { className: "pagination", children: [
|
|
2055
2053
|
/* @__PURE__ */ e.jsxs("div", { className: "left", children: [
|
|
2056
|
-
"Rows:
|
|
2054
|
+
"Rows:",
|
|
2057
2055
|
/* @__PURE__ */ e.jsx(
|
|
2058
|
-
|
|
2056
|
+
Ce,
|
|
2059
2057
|
{
|
|
2060
2058
|
name: "pageSize",
|
|
2061
|
-
options: [
|
|
2062
|
-
|
|
2063
|
-
|
|
2064
|
-
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
|
|
2068
|
-
}
|
|
2059
|
+
options: [
|
|
2060
|
+
{ label: "50", value: "50" },
|
|
2061
|
+
{ label: "100", value: "100" },
|
|
2062
|
+
{ label: "500", value: "500" }
|
|
2063
|
+
],
|
|
2064
|
+
value: String(v.size),
|
|
2065
|
+
onChange: (m) => _({ num: 0, size: parseInt(m.target.value, 10) })
|
|
2069
2066
|
}
|
|
2070
2067
|
)
|
|
2071
2068
|
] }),
|
|
2072
2069
|
/* @__PURE__ */ e.jsxs("div", { className: "center", children: [
|
|
2073
|
-
|
|
2074
|
-
" -
|
|
2075
|
-
|
|
2070
|
+
v.num * v.size + 1,
|
|
2071
|
+
" -",
|
|
2072
|
+
Math.min((v.num + 1) * v.size, N.length),
|
|
2076
2073
|
" of ",
|
|
2077
2074
|
N.length
|
|
2078
2075
|
] }),
|
|
@@ -2081,11 +2078,9 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
2081
2078
|
O,
|
|
2082
2079
|
{
|
|
2083
2080
|
variant: "transparent",
|
|
2084
|
-
disabled:
|
|
2081
|
+
disabled: v.num === 0,
|
|
2085
2082
|
size: "small",
|
|
2086
|
-
onClick: () => {
|
|
2087
|
-
A({ ...g, num: g.num - 1 });
|
|
2088
|
-
},
|
|
2083
|
+
onClick: () => _({ ...v, num: v.num - 1 }),
|
|
2089
2084
|
children: /* @__PURE__ */ e.jsx(w, { name: "chevron-left" })
|
|
2090
2085
|
}
|
|
2091
2086
|
),
|
|
@@ -2093,11 +2088,9 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
2093
2088
|
O,
|
|
2094
2089
|
{
|
|
2095
2090
|
variant: "transparent",
|
|
2096
|
-
disabled:
|
|
2091
|
+
disabled: (v.num + 1) * v.size >= N.length,
|
|
2097
2092
|
size: "small",
|
|
2098
|
-
onClick: () => {
|
|
2099
|
-
A({ ...g, num: g.num + 1 });
|
|
2100
|
-
},
|
|
2093
|
+
onClick: () => _({ ...v, num: v.num + 1 }),
|
|
2101
2094
|
children: /* @__PURE__ */ e.jsx(w, { name: "chevron-right" })
|
|
2102
2095
|
}
|
|
2103
2096
|
)
|
|
@@ -2107,42 +2100,42 @@ const Ee = ({ variant: n, children: t }) => {
|
|
|
2107
2100
|
] });
|
|
2108
2101
|
};
|
|
2109
2102
|
export {
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
|
|
2103
|
+
Re as Accordion,
|
|
2104
|
+
me as Backdrop,
|
|
2105
|
+
fe as Badge,
|
|
2113
2106
|
O as Button,
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2107
|
+
Se as Checkbox,
|
|
2108
|
+
be as CopyButton,
|
|
2109
|
+
we as CsvButton,
|
|
2110
|
+
Me as CsvInput,
|
|
2111
|
+
ve as DropdownButton,
|
|
2112
|
+
Ae as DropdownNavButton,
|
|
2113
|
+
Je as Featured,
|
|
2114
|
+
$e as Hr,
|
|
2122
2115
|
w as Icon,
|
|
2123
|
-
|
|
2116
|
+
Te as IconBadge,
|
|
2124
2117
|
ze as ImageInput,
|
|
2125
|
-
|
|
2118
|
+
ke as Input,
|
|
2126
2119
|
Ue as ItemSlider,
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2120
|
+
q as Label,
|
|
2121
|
+
Pe as Li,
|
|
2122
|
+
De as Modal,
|
|
2123
|
+
xe as NavigateButton,
|
|
2124
|
+
Fe as Paper,
|
|
2125
|
+
Ie as Pill,
|
|
2126
|
+
Ye as Progress,
|
|
2127
|
+
He as Radio,
|
|
2128
|
+
We as RangeSlider,
|
|
2129
|
+
Ce as Select,
|
|
2130
|
+
_e as ShareButton,
|
|
2131
|
+
Be as Slider,
|
|
2132
|
+
Ne as SortButton,
|
|
2133
|
+
he as Spinner,
|
|
2134
|
+
Ge as Star,
|
|
2135
|
+
Xe as Table,
|
|
2136
|
+
qe as Tabs,
|
|
2137
|
+
Ve as TextInputDropdown,
|
|
2138
|
+
Oe as Textarea,
|
|
2139
|
+
Le as Ul,
|
|
2140
|
+
ge as copyToClipboard
|
|
2148
2141
|
};
|