@raghu5707/react-ui-kit 1.0.2 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Button/Button.d.ts +8 -0
- package/dist/components/Button/index.d.ts +2 -0
- package/dist/index.d.ts +2 -0
- package/dist/react-ui-kit.js +654 -0
- package/dist/react-ui-kit.umd.cjs +14 -0
- package/package.json +9 -10
- package/dist/assets/index-BUbVPl4B.js +0 -9
- package/dist/assets/index-CzJksujP.css +0 -1
- package/dist/assets/react-CHdo91hT.svg +0 -1
- package/dist/index.html +0 -14
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { ButtonHTMLAttributes } from 'react';
|
|
2
|
+
export type ButtonVariant = "primary" | "secondary" | "danger" | "outline";
|
|
3
|
+
export type ButtonSize = "sm" | "md" | "lg";
|
|
4
|
+
export interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
5
|
+
variant?: ButtonVariant;
|
|
6
|
+
size?: ButtonSize;
|
|
7
|
+
}
|
|
8
|
+
export declare const Button: import('react').ForwardRefExoticComponent<ButtonProps & import('react').RefAttributes<HTMLButtonElement>>;
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,654 @@
|
|
|
1
|
+
import we, { forwardRef as cr } from "react";
|
|
2
|
+
var U = { exports: {} }, F = {};
|
|
3
|
+
var Te;
|
|
4
|
+
function dr() {
|
|
5
|
+
if (Te) return F;
|
|
6
|
+
Te = 1;
|
|
7
|
+
var c = we, d = /* @__PURE__ */ Symbol.for("react.element"), v = /* @__PURE__ */ Symbol.for("react.fragment"), s = Object.prototype.hasOwnProperty, E = c.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, $ = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
8
|
+
function k(T, p, C) {
|
|
9
|
+
var h, R = {}, x = null, W = null;
|
|
10
|
+
C !== void 0 && (x = "" + C), p.key !== void 0 && (x = "" + p.key), p.ref !== void 0 && (W = p.ref);
|
|
11
|
+
for (h in p) s.call(p, h) && !$.hasOwnProperty(h) && (R[h] = p[h]);
|
|
12
|
+
if (T && T.defaultProps) for (h in p = T.defaultProps, p) R[h] === void 0 && (R[h] = p[h]);
|
|
13
|
+
return { $$typeof: d, type: T, key: x, ref: W, props: R, _owner: E.current };
|
|
14
|
+
}
|
|
15
|
+
return F.Fragment = v, F.jsx = k, F.jsxs = k, F;
|
|
16
|
+
}
|
|
17
|
+
var I = {};
|
|
18
|
+
var xe;
|
|
19
|
+
function vr() {
|
|
20
|
+
return xe || (xe = 1, process.env.NODE_ENV !== "production" && (function() {
|
|
21
|
+
var c = we, d = /* @__PURE__ */ Symbol.for("react.element"), v = /* @__PURE__ */ Symbol.for("react.portal"), s = /* @__PURE__ */ Symbol.for("react.fragment"), E = /* @__PURE__ */ Symbol.for("react.strict_mode"), $ = /* @__PURE__ */ Symbol.for("react.profiler"), k = /* @__PURE__ */ Symbol.for("react.provider"), T = /* @__PURE__ */ Symbol.for("react.context"), p = /* @__PURE__ */ Symbol.for("react.forward_ref"), C = /* @__PURE__ */ Symbol.for("react.suspense"), h = /* @__PURE__ */ Symbol.for("react.suspense_list"), R = /* @__PURE__ */ Symbol.for("react.memo"), x = /* @__PURE__ */ Symbol.for("react.lazy"), W = /* @__PURE__ */ Symbol.for("react.offscreen"), H = Symbol.iterator, Se = "@@iterator";
|
|
22
|
+
function Pe(e) {
|
|
23
|
+
if (e === null || typeof e != "object")
|
|
24
|
+
return null;
|
|
25
|
+
var r = H && e[H] || e[Se];
|
|
26
|
+
return typeof r == "function" ? r : null;
|
|
27
|
+
}
|
|
28
|
+
var S = c.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
|
29
|
+
function g(e) {
|
|
30
|
+
{
|
|
31
|
+
for (var r = arguments.length, t = new Array(r > 1 ? r - 1 : 0), n = 1; n < r; n++)
|
|
32
|
+
t[n - 1] = arguments[n];
|
|
33
|
+
je("error", e, t);
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
function je(e, r, t) {
|
|
37
|
+
{
|
|
38
|
+
var n = S.ReactDebugCurrentFrame, o = n.getStackAddendum();
|
|
39
|
+
o !== "" && (r += "%s", t = t.concat([o]));
|
|
40
|
+
var u = t.map(function(i) {
|
|
41
|
+
return String(i);
|
|
42
|
+
});
|
|
43
|
+
u.unshift("Warning: " + r), Function.prototype.apply.call(console[e], console, u);
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
var ke = !1, De = !1, Ae = !1, Fe = !1, Ie = !1, Z;
|
|
47
|
+
Z = /* @__PURE__ */ Symbol.for("react.module.reference");
|
|
48
|
+
function $e(e) {
|
|
49
|
+
return !!(typeof e == "string" || typeof e == "function" || e === s || e === $ || Ie || e === E || e === C || e === h || Fe || e === W || ke || De || Ae || typeof e == "object" && e !== null && (e.$$typeof === x || e.$$typeof === R || e.$$typeof === k || e.$$typeof === T || e.$$typeof === p || // This needs to include all possible module reference object
|
|
50
|
+
// types supported by any Flight configuration anywhere since
|
|
51
|
+
// we don't know which Flight build this will end up being used
|
|
52
|
+
// with.
|
|
53
|
+
e.$$typeof === Z || e.getModuleId !== void 0));
|
|
54
|
+
}
|
|
55
|
+
function We(e, r, t) {
|
|
56
|
+
var n = e.displayName;
|
|
57
|
+
if (n)
|
|
58
|
+
return n;
|
|
59
|
+
var o = r.displayName || r.name || "";
|
|
60
|
+
return o !== "" ? t + "(" + o + ")" : t;
|
|
61
|
+
}
|
|
62
|
+
function Q(e) {
|
|
63
|
+
return e.displayName || "Context";
|
|
64
|
+
}
|
|
65
|
+
function _(e) {
|
|
66
|
+
if (e == null)
|
|
67
|
+
return null;
|
|
68
|
+
if (typeof e.tag == "number" && g("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof e == "function")
|
|
69
|
+
return e.displayName || e.name || null;
|
|
70
|
+
if (typeof e == "string")
|
|
71
|
+
return e;
|
|
72
|
+
switch (e) {
|
|
73
|
+
case s:
|
|
74
|
+
return "Fragment";
|
|
75
|
+
case v:
|
|
76
|
+
return "Portal";
|
|
77
|
+
case $:
|
|
78
|
+
return "Profiler";
|
|
79
|
+
case E:
|
|
80
|
+
return "StrictMode";
|
|
81
|
+
case C:
|
|
82
|
+
return "Suspense";
|
|
83
|
+
case h:
|
|
84
|
+
return "SuspenseList";
|
|
85
|
+
}
|
|
86
|
+
if (typeof e == "object")
|
|
87
|
+
switch (e.$$typeof) {
|
|
88
|
+
case T:
|
|
89
|
+
var r = e;
|
|
90
|
+
return Q(r) + ".Consumer";
|
|
91
|
+
case k:
|
|
92
|
+
var t = e;
|
|
93
|
+
return Q(t._context) + ".Provider";
|
|
94
|
+
case p:
|
|
95
|
+
return We(e, e.render, "ForwardRef");
|
|
96
|
+
case R:
|
|
97
|
+
var n = e.displayName || null;
|
|
98
|
+
return n !== null ? n : _(e.type) || "Memo";
|
|
99
|
+
case x: {
|
|
100
|
+
var o = e, u = o._payload, i = o._init;
|
|
101
|
+
try {
|
|
102
|
+
return _(i(u));
|
|
103
|
+
} catch {
|
|
104
|
+
return null;
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
return null;
|
|
109
|
+
}
|
|
110
|
+
var O = Object.assign, D = 0, ee, re, te, ne, ae, ie, oe;
|
|
111
|
+
function ue() {
|
|
112
|
+
}
|
|
113
|
+
ue.__reactDisabledLog = !0;
|
|
114
|
+
function Ye() {
|
|
115
|
+
{
|
|
116
|
+
if (D === 0) {
|
|
117
|
+
ee = console.log, re = console.info, te = console.warn, ne = console.error, ae = console.group, ie = console.groupCollapsed, oe = console.groupEnd;
|
|
118
|
+
var e = {
|
|
119
|
+
configurable: !0,
|
|
120
|
+
enumerable: !0,
|
|
121
|
+
value: ue,
|
|
122
|
+
writable: !0
|
|
123
|
+
};
|
|
124
|
+
Object.defineProperties(console, {
|
|
125
|
+
info: e,
|
|
126
|
+
log: e,
|
|
127
|
+
warn: e,
|
|
128
|
+
error: e,
|
|
129
|
+
group: e,
|
|
130
|
+
groupCollapsed: e,
|
|
131
|
+
groupEnd: e
|
|
132
|
+
});
|
|
133
|
+
}
|
|
134
|
+
D++;
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
function Le() {
|
|
138
|
+
{
|
|
139
|
+
if (D--, D === 0) {
|
|
140
|
+
var e = {
|
|
141
|
+
configurable: !0,
|
|
142
|
+
enumerable: !0,
|
|
143
|
+
writable: !0
|
|
144
|
+
};
|
|
145
|
+
Object.defineProperties(console, {
|
|
146
|
+
log: O({}, e, {
|
|
147
|
+
value: ee
|
|
148
|
+
}),
|
|
149
|
+
info: O({}, e, {
|
|
150
|
+
value: re
|
|
151
|
+
}),
|
|
152
|
+
warn: O({}, e, {
|
|
153
|
+
value: te
|
|
154
|
+
}),
|
|
155
|
+
error: O({}, e, {
|
|
156
|
+
value: ne
|
|
157
|
+
}),
|
|
158
|
+
group: O({}, e, {
|
|
159
|
+
value: ae
|
|
160
|
+
}),
|
|
161
|
+
groupCollapsed: O({}, e, {
|
|
162
|
+
value: ie
|
|
163
|
+
}),
|
|
164
|
+
groupEnd: O({}, e, {
|
|
165
|
+
value: oe
|
|
166
|
+
})
|
|
167
|
+
});
|
|
168
|
+
}
|
|
169
|
+
D < 0 && g("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
var N = S.ReactCurrentDispatcher, B;
|
|
173
|
+
function Y(e, r, t) {
|
|
174
|
+
{
|
|
175
|
+
if (B === void 0)
|
|
176
|
+
try {
|
|
177
|
+
throw Error();
|
|
178
|
+
} catch (o) {
|
|
179
|
+
var n = o.stack.trim().match(/\n( *(at )?)/);
|
|
180
|
+
B = n && n[1] || "";
|
|
181
|
+
}
|
|
182
|
+
return `
|
|
183
|
+
` + B + e;
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
var J = !1, L;
|
|
187
|
+
{
|
|
188
|
+
var Ve = typeof WeakMap == "function" ? WeakMap : Map;
|
|
189
|
+
L = new Ve();
|
|
190
|
+
}
|
|
191
|
+
function se(e, r) {
|
|
192
|
+
if (!e || J)
|
|
193
|
+
return "";
|
|
194
|
+
{
|
|
195
|
+
var t = L.get(e);
|
|
196
|
+
if (t !== void 0)
|
|
197
|
+
return t;
|
|
198
|
+
}
|
|
199
|
+
var n;
|
|
200
|
+
J = !0;
|
|
201
|
+
var o = Error.prepareStackTrace;
|
|
202
|
+
Error.prepareStackTrace = void 0;
|
|
203
|
+
var u;
|
|
204
|
+
u = N.current, N.current = null, Ye();
|
|
205
|
+
try {
|
|
206
|
+
if (r) {
|
|
207
|
+
var i = function() {
|
|
208
|
+
throw Error();
|
|
209
|
+
};
|
|
210
|
+
if (Object.defineProperty(i.prototype, "props", {
|
|
211
|
+
set: function() {
|
|
212
|
+
throw Error();
|
|
213
|
+
}
|
|
214
|
+
}), typeof Reflect == "object" && Reflect.construct) {
|
|
215
|
+
try {
|
|
216
|
+
Reflect.construct(i, []);
|
|
217
|
+
} catch (b) {
|
|
218
|
+
n = b;
|
|
219
|
+
}
|
|
220
|
+
Reflect.construct(e, [], i);
|
|
221
|
+
} else {
|
|
222
|
+
try {
|
|
223
|
+
i.call();
|
|
224
|
+
} catch (b) {
|
|
225
|
+
n = b;
|
|
226
|
+
}
|
|
227
|
+
e.call(i.prototype);
|
|
228
|
+
}
|
|
229
|
+
} else {
|
|
230
|
+
try {
|
|
231
|
+
throw Error();
|
|
232
|
+
} catch (b) {
|
|
233
|
+
n = b;
|
|
234
|
+
}
|
|
235
|
+
e();
|
|
236
|
+
}
|
|
237
|
+
} catch (b) {
|
|
238
|
+
if (b && n && typeof b.stack == "string") {
|
|
239
|
+
for (var a = b.stack.split(`
|
|
240
|
+
`), y = n.stack.split(`
|
|
241
|
+
`), f = a.length - 1, l = y.length - 1; f >= 1 && l >= 0 && a[f] !== y[l]; )
|
|
242
|
+
l--;
|
|
243
|
+
for (; f >= 1 && l >= 0; f--, l--)
|
|
244
|
+
if (a[f] !== y[l]) {
|
|
245
|
+
if (f !== 1 || l !== 1)
|
|
246
|
+
do
|
|
247
|
+
if (f--, l--, l < 0 || a[f] !== y[l]) {
|
|
248
|
+
var m = `
|
|
249
|
+
` + a[f].replace(" at new ", " at ");
|
|
250
|
+
return e.displayName && m.includes("<anonymous>") && (m = m.replace("<anonymous>", e.displayName)), typeof e == "function" && L.set(e, m), m;
|
|
251
|
+
}
|
|
252
|
+
while (f >= 1 && l >= 0);
|
|
253
|
+
break;
|
|
254
|
+
}
|
|
255
|
+
}
|
|
256
|
+
} finally {
|
|
257
|
+
J = !1, N.current = u, Le(), Error.prepareStackTrace = o;
|
|
258
|
+
}
|
|
259
|
+
var j = e ? e.displayName || e.name : "", w = j ? Y(j) : "";
|
|
260
|
+
return typeof e == "function" && L.set(e, w), w;
|
|
261
|
+
}
|
|
262
|
+
function Me(e, r, t) {
|
|
263
|
+
return se(e, !1);
|
|
264
|
+
}
|
|
265
|
+
function Ue(e) {
|
|
266
|
+
var r = e.prototype;
|
|
267
|
+
return !!(r && r.isReactComponent);
|
|
268
|
+
}
|
|
269
|
+
function V(e, r, t) {
|
|
270
|
+
if (e == null)
|
|
271
|
+
return "";
|
|
272
|
+
if (typeof e == "function")
|
|
273
|
+
return se(e, Ue(e));
|
|
274
|
+
if (typeof e == "string")
|
|
275
|
+
return Y(e);
|
|
276
|
+
switch (e) {
|
|
277
|
+
case C:
|
|
278
|
+
return Y("Suspense");
|
|
279
|
+
case h:
|
|
280
|
+
return Y("SuspenseList");
|
|
281
|
+
}
|
|
282
|
+
if (typeof e == "object")
|
|
283
|
+
switch (e.$$typeof) {
|
|
284
|
+
case p:
|
|
285
|
+
return Me(e.render);
|
|
286
|
+
case R:
|
|
287
|
+
return V(e.type, r, t);
|
|
288
|
+
case x: {
|
|
289
|
+
var n = e, o = n._payload, u = n._init;
|
|
290
|
+
try {
|
|
291
|
+
return V(u(o), r, t);
|
|
292
|
+
} catch {
|
|
293
|
+
}
|
|
294
|
+
}
|
|
295
|
+
}
|
|
296
|
+
return "";
|
|
297
|
+
}
|
|
298
|
+
var A = Object.prototype.hasOwnProperty, fe = {}, le = S.ReactDebugCurrentFrame;
|
|
299
|
+
function M(e) {
|
|
300
|
+
if (e) {
|
|
301
|
+
var r = e._owner, t = V(e.type, e._source, r ? r.type : null);
|
|
302
|
+
le.setExtraStackFrame(t);
|
|
303
|
+
} else
|
|
304
|
+
le.setExtraStackFrame(null);
|
|
305
|
+
}
|
|
306
|
+
function Ne(e, r, t, n, o) {
|
|
307
|
+
{
|
|
308
|
+
var u = Function.call.bind(A);
|
|
309
|
+
for (var i in e)
|
|
310
|
+
if (u(e, i)) {
|
|
311
|
+
var a = void 0;
|
|
312
|
+
try {
|
|
313
|
+
if (typeof e[i] != "function") {
|
|
314
|
+
var y = Error((n || "React class") + ": " + t + " type `" + i + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof e[i] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
|
|
315
|
+
throw y.name = "Invariant Violation", y;
|
|
316
|
+
}
|
|
317
|
+
a = e[i](r, i, n, t, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
|
|
318
|
+
} catch (f) {
|
|
319
|
+
a = f;
|
|
320
|
+
}
|
|
321
|
+
a && !(a instanceof Error) && (M(o), g("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", n || "React class", t, i, typeof a), M(null)), a instanceof Error && !(a.message in fe) && (fe[a.message] = !0, M(o), g("Failed %s type: %s", t, a.message), M(null));
|
|
322
|
+
}
|
|
323
|
+
}
|
|
324
|
+
}
|
|
325
|
+
var Be = Array.isArray;
|
|
326
|
+
function q(e) {
|
|
327
|
+
return Be(e);
|
|
328
|
+
}
|
|
329
|
+
function Je(e) {
|
|
330
|
+
{
|
|
331
|
+
var r = typeof Symbol == "function" && Symbol.toStringTag, t = r && e[Symbol.toStringTag] || e.constructor.name || "Object";
|
|
332
|
+
return t;
|
|
333
|
+
}
|
|
334
|
+
}
|
|
335
|
+
function qe(e) {
|
|
336
|
+
try {
|
|
337
|
+
return ce(e), !1;
|
|
338
|
+
} catch {
|
|
339
|
+
return !0;
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
function ce(e) {
|
|
343
|
+
return "" + e;
|
|
344
|
+
}
|
|
345
|
+
function de(e) {
|
|
346
|
+
if (qe(e))
|
|
347
|
+
return g("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Je(e)), ce(e);
|
|
348
|
+
}
|
|
349
|
+
var ve = S.ReactCurrentOwner, Ke = {
|
|
350
|
+
key: !0,
|
|
351
|
+
ref: !0,
|
|
352
|
+
__self: !0,
|
|
353
|
+
__source: !0
|
|
354
|
+
}, pe, ge;
|
|
355
|
+
function ze(e) {
|
|
356
|
+
if (A.call(e, "ref")) {
|
|
357
|
+
var r = Object.getOwnPropertyDescriptor(e, "ref").get;
|
|
358
|
+
if (r && r.isReactWarning)
|
|
359
|
+
return !1;
|
|
360
|
+
}
|
|
361
|
+
return e.ref !== void 0;
|
|
362
|
+
}
|
|
363
|
+
function Ge(e) {
|
|
364
|
+
if (A.call(e, "key")) {
|
|
365
|
+
var r = Object.getOwnPropertyDescriptor(e, "key").get;
|
|
366
|
+
if (r && r.isReactWarning)
|
|
367
|
+
return !1;
|
|
368
|
+
}
|
|
369
|
+
return e.key !== void 0;
|
|
370
|
+
}
|
|
371
|
+
function Xe(e, r) {
|
|
372
|
+
typeof e.ref == "string" && ve.current;
|
|
373
|
+
}
|
|
374
|
+
function He(e, r) {
|
|
375
|
+
{
|
|
376
|
+
var t = function() {
|
|
377
|
+
pe || (pe = !0, g("%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://reactjs.org/link/special-props)", r));
|
|
378
|
+
};
|
|
379
|
+
t.isReactWarning = !0, Object.defineProperty(e, "key", {
|
|
380
|
+
get: t,
|
|
381
|
+
configurable: !0
|
|
382
|
+
});
|
|
383
|
+
}
|
|
384
|
+
}
|
|
385
|
+
function Ze(e, r) {
|
|
386
|
+
{
|
|
387
|
+
var t = function() {
|
|
388
|
+
ge || (ge = !0, g("%s: `ref` 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://reactjs.org/link/special-props)", r));
|
|
389
|
+
};
|
|
390
|
+
t.isReactWarning = !0, Object.defineProperty(e, "ref", {
|
|
391
|
+
get: t,
|
|
392
|
+
configurable: !0
|
|
393
|
+
});
|
|
394
|
+
}
|
|
395
|
+
}
|
|
396
|
+
var Qe = function(e, r, t, n, o, u, i) {
|
|
397
|
+
var a = {
|
|
398
|
+
// This tag allows us to uniquely identify this as a React Element
|
|
399
|
+
$$typeof: d,
|
|
400
|
+
// Built-in properties that belong on the element
|
|
401
|
+
type: e,
|
|
402
|
+
key: r,
|
|
403
|
+
ref: t,
|
|
404
|
+
props: i,
|
|
405
|
+
// Record the component responsible for creating this element.
|
|
406
|
+
_owner: u
|
|
407
|
+
};
|
|
408
|
+
return a._store = {}, Object.defineProperty(a._store, "validated", {
|
|
409
|
+
configurable: !1,
|
|
410
|
+
enumerable: !1,
|
|
411
|
+
writable: !0,
|
|
412
|
+
value: !1
|
|
413
|
+
}), Object.defineProperty(a, "_self", {
|
|
414
|
+
configurable: !1,
|
|
415
|
+
enumerable: !1,
|
|
416
|
+
writable: !1,
|
|
417
|
+
value: n
|
|
418
|
+
}), Object.defineProperty(a, "_source", {
|
|
419
|
+
configurable: !1,
|
|
420
|
+
enumerable: !1,
|
|
421
|
+
writable: !1,
|
|
422
|
+
value: o
|
|
423
|
+
}), Object.freeze && (Object.freeze(a.props), Object.freeze(a)), a;
|
|
424
|
+
};
|
|
425
|
+
function er(e, r, t, n, o) {
|
|
426
|
+
{
|
|
427
|
+
var u, i = {}, a = null, y = null;
|
|
428
|
+
t !== void 0 && (de(t), a = "" + t), Ge(r) && (de(r.key), a = "" + r.key), ze(r) && (y = r.ref, Xe(r, o));
|
|
429
|
+
for (u in r)
|
|
430
|
+
A.call(r, u) && !Ke.hasOwnProperty(u) && (i[u] = r[u]);
|
|
431
|
+
if (e && e.defaultProps) {
|
|
432
|
+
var f = e.defaultProps;
|
|
433
|
+
for (u in f)
|
|
434
|
+
i[u] === void 0 && (i[u] = f[u]);
|
|
435
|
+
}
|
|
436
|
+
if (a || y) {
|
|
437
|
+
var l = typeof e == "function" ? e.displayName || e.name || "Unknown" : e;
|
|
438
|
+
a && He(i, l), y && Ze(i, l);
|
|
439
|
+
}
|
|
440
|
+
return Qe(e, a, y, o, n, ve.current, i);
|
|
441
|
+
}
|
|
442
|
+
}
|
|
443
|
+
var K = S.ReactCurrentOwner, ye = S.ReactDebugCurrentFrame;
|
|
444
|
+
function P(e) {
|
|
445
|
+
if (e) {
|
|
446
|
+
var r = e._owner, t = V(e.type, e._source, r ? r.type : null);
|
|
447
|
+
ye.setExtraStackFrame(t);
|
|
448
|
+
} else
|
|
449
|
+
ye.setExtraStackFrame(null);
|
|
450
|
+
}
|
|
451
|
+
var z;
|
|
452
|
+
z = !1;
|
|
453
|
+
function G(e) {
|
|
454
|
+
return typeof e == "object" && e !== null && e.$$typeof === d;
|
|
455
|
+
}
|
|
456
|
+
function be() {
|
|
457
|
+
{
|
|
458
|
+
if (K.current) {
|
|
459
|
+
var e = _(K.current.type);
|
|
460
|
+
if (e)
|
|
461
|
+
return `
|
|
462
|
+
|
|
463
|
+
Check the render method of \`` + e + "`.";
|
|
464
|
+
}
|
|
465
|
+
return "";
|
|
466
|
+
}
|
|
467
|
+
}
|
|
468
|
+
function rr(e) {
|
|
469
|
+
return "";
|
|
470
|
+
}
|
|
471
|
+
var he = {};
|
|
472
|
+
function tr(e) {
|
|
473
|
+
{
|
|
474
|
+
var r = be();
|
|
475
|
+
if (!r) {
|
|
476
|
+
var t = typeof e == "string" ? e : e.displayName || e.name;
|
|
477
|
+
t && (r = `
|
|
478
|
+
|
|
479
|
+
Check the top-level render call using <` + t + ">.");
|
|
480
|
+
}
|
|
481
|
+
return r;
|
|
482
|
+
}
|
|
483
|
+
}
|
|
484
|
+
function me(e, r) {
|
|
485
|
+
{
|
|
486
|
+
if (!e._store || e._store.validated || e.key != null)
|
|
487
|
+
return;
|
|
488
|
+
e._store.validated = !0;
|
|
489
|
+
var t = tr(r);
|
|
490
|
+
if (he[t])
|
|
491
|
+
return;
|
|
492
|
+
he[t] = !0;
|
|
493
|
+
var n = "";
|
|
494
|
+
e && e._owner && e._owner !== K.current && (n = " It was passed a child from " + _(e._owner.type) + "."), P(e), g('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', t, n), P(null);
|
|
495
|
+
}
|
|
496
|
+
}
|
|
497
|
+
function Ee(e, r) {
|
|
498
|
+
{
|
|
499
|
+
if (typeof e != "object")
|
|
500
|
+
return;
|
|
501
|
+
if (q(e))
|
|
502
|
+
for (var t = 0; t < e.length; t++) {
|
|
503
|
+
var n = e[t];
|
|
504
|
+
G(n) && me(n, r);
|
|
505
|
+
}
|
|
506
|
+
else if (G(e))
|
|
507
|
+
e._store && (e._store.validated = !0);
|
|
508
|
+
else if (e) {
|
|
509
|
+
var o = Pe(e);
|
|
510
|
+
if (typeof o == "function" && o !== e.entries)
|
|
511
|
+
for (var u = o.call(e), i; !(i = u.next()).done; )
|
|
512
|
+
G(i.value) && me(i.value, r);
|
|
513
|
+
}
|
|
514
|
+
}
|
|
515
|
+
}
|
|
516
|
+
function nr(e) {
|
|
517
|
+
{
|
|
518
|
+
var r = e.type;
|
|
519
|
+
if (r == null || typeof r == "string")
|
|
520
|
+
return;
|
|
521
|
+
var t;
|
|
522
|
+
if (typeof r == "function")
|
|
523
|
+
t = r.propTypes;
|
|
524
|
+
else if (typeof r == "object" && (r.$$typeof === p || // Note: Memo only checks outer props here.
|
|
525
|
+
// Inner props are checked in the reconciler.
|
|
526
|
+
r.$$typeof === R))
|
|
527
|
+
t = r.propTypes;
|
|
528
|
+
else
|
|
529
|
+
return;
|
|
530
|
+
if (t) {
|
|
531
|
+
var n = _(r);
|
|
532
|
+
Ne(t, e.props, "prop", n, e);
|
|
533
|
+
} else if (r.PropTypes !== void 0 && !z) {
|
|
534
|
+
z = !0;
|
|
535
|
+
var o = _(r);
|
|
536
|
+
g("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", o || "Unknown");
|
|
537
|
+
}
|
|
538
|
+
typeof r.getDefaultProps == "function" && !r.getDefaultProps.isReactClassApproved && g("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
|
|
539
|
+
}
|
|
540
|
+
}
|
|
541
|
+
function ar(e) {
|
|
542
|
+
{
|
|
543
|
+
for (var r = Object.keys(e.props), t = 0; t < r.length; t++) {
|
|
544
|
+
var n = r[t];
|
|
545
|
+
if (n !== "children" && n !== "key") {
|
|
546
|
+
P(e), g("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", n), P(null);
|
|
547
|
+
break;
|
|
548
|
+
}
|
|
549
|
+
}
|
|
550
|
+
e.ref !== null && (P(e), g("Invalid attribute `ref` supplied to `React.Fragment`."), P(null));
|
|
551
|
+
}
|
|
552
|
+
}
|
|
553
|
+
var Re = {};
|
|
554
|
+
function _e(e, r, t, n, o, u) {
|
|
555
|
+
{
|
|
556
|
+
var i = $e(e);
|
|
557
|
+
if (!i) {
|
|
558
|
+
var a = "";
|
|
559
|
+
(e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (a += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
560
|
+
var y = rr();
|
|
561
|
+
y ? a += y : a += be();
|
|
562
|
+
var f;
|
|
563
|
+
e === null ? f = "null" : q(e) ? f = "array" : e !== void 0 && e.$$typeof === d ? (f = "<" + (_(e.type) || "Unknown") + " />", a = " Did you accidentally export a JSX literal instead of a component?") : f = typeof e, g("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", f, a);
|
|
564
|
+
}
|
|
565
|
+
var l = er(e, r, t, o, u);
|
|
566
|
+
if (l == null)
|
|
567
|
+
return l;
|
|
568
|
+
if (i) {
|
|
569
|
+
var m = r.children;
|
|
570
|
+
if (m !== void 0)
|
|
571
|
+
if (n)
|
|
572
|
+
if (q(m)) {
|
|
573
|
+
for (var j = 0; j < m.length; j++)
|
|
574
|
+
Ee(m[j], e);
|
|
575
|
+
Object.freeze && Object.freeze(m);
|
|
576
|
+
} else
|
|
577
|
+
g("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
578
|
+
else
|
|
579
|
+
Ee(m, e);
|
|
580
|
+
}
|
|
581
|
+
if (A.call(r, "key")) {
|
|
582
|
+
var w = _(e), b = Object.keys(r).filter(function(lr) {
|
|
583
|
+
return lr !== "key";
|
|
584
|
+
}), X = b.length > 0 ? "{key: someKey, " + b.join(": ..., ") + ": ...}" : "{key: someKey}";
|
|
585
|
+
if (!Re[w + X]) {
|
|
586
|
+
var fr = b.length > 0 ? "{" + b.join(": ..., ") + ": ...}" : "{}";
|
|
587
|
+
g(`A props object containing a "key" prop is being spread into JSX:
|
|
588
|
+
let props = %s;
|
|
589
|
+
<%s {...props} />
|
|
590
|
+
React keys must be passed directly to JSX without using spread:
|
|
591
|
+
let props = %s;
|
|
592
|
+
<%s key={someKey} {...props} />`, X, w, fr, w), Re[w + X] = !0;
|
|
593
|
+
}
|
|
594
|
+
}
|
|
595
|
+
return e === s ? ar(l) : nr(l), l;
|
|
596
|
+
}
|
|
597
|
+
}
|
|
598
|
+
function ir(e, r, t) {
|
|
599
|
+
return _e(e, r, t, !0);
|
|
600
|
+
}
|
|
601
|
+
function or(e, r, t) {
|
|
602
|
+
return _e(e, r, t, !1);
|
|
603
|
+
}
|
|
604
|
+
var ur = or, sr = ir;
|
|
605
|
+
I.Fragment = s, I.jsx = ur, I.jsxs = sr;
|
|
606
|
+
})()), I;
|
|
607
|
+
}
|
|
608
|
+
var Oe;
|
|
609
|
+
function pr() {
|
|
610
|
+
return Oe || (Oe = 1, process.env.NODE_ENV === "production" ? U.exports = dr() : U.exports = vr()), U.exports;
|
|
611
|
+
}
|
|
612
|
+
var gr = pr();
|
|
613
|
+
function Ce(c) {
|
|
614
|
+
var d, v, s = "";
|
|
615
|
+
if (typeof c == "string" || typeof c == "number") s += c;
|
|
616
|
+
else if (typeof c == "object") if (Array.isArray(c)) {
|
|
617
|
+
var E = c.length;
|
|
618
|
+
for (d = 0; d < E; d++) c[d] && (v = Ce(c[d])) && (s && (s += " "), s += v);
|
|
619
|
+
} else for (v in c) c[v] && (s && (s += " "), s += v);
|
|
620
|
+
return s;
|
|
621
|
+
}
|
|
622
|
+
function yr() {
|
|
623
|
+
for (var c, d, v = 0, s = "", E = arguments.length; v < E; v++) (c = arguments[v]) && (d = Ce(c)) && (s && (s += " "), s += d);
|
|
624
|
+
return s;
|
|
625
|
+
}
|
|
626
|
+
const br = {
|
|
627
|
+
primary: "bg-primary text-white hover:bg-primary-hover focus:ring-primary-light",
|
|
628
|
+
secondary: "bg-secondary text-white hover:bg-secondary-hover",
|
|
629
|
+
danger: "bg-danger text-white hover:bg-danger-hover",
|
|
630
|
+
outline: "border border-primary text-primary hover:bg-primary-light"
|
|
631
|
+
}, hr = {
|
|
632
|
+
sm: "px-3 py-1.5 text-sm",
|
|
633
|
+
md: "px-4 py-2 text-sm",
|
|
634
|
+
lg: "px-6 py-3 text-base"
|
|
635
|
+
}, mr = cr(
|
|
636
|
+
({ variant: c = "primary", size: d = "md", className: v, ...s }, E) => /* @__PURE__ */ gr.jsx(
|
|
637
|
+
"button",
|
|
638
|
+
{
|
|
639
|
+
ref: E,
|
|
640
|
+
className: yr(
|
|
641
|
+
"inline-flex items-center justify-center rounded-md font-medium transition-all focus:outline-none focus:ring-2 focus:ring-offset-2",
|
|
642
|
+
br[c],
|
|
643
|
+
hr[d],
|
|
644
|
+
s.disabled && "opacity-50 cursor-not-allowed",
|
|
645
|
+
v
|
|
646
|
+
),
|
|
647
|
+
...s
|
|
648
|
+
}
|
|
649
|
+
)
|
|
650
|
+
);
|
|
651
|
+
mr.displayName = "Button";
|
|
652
|
+
export {
|
|
653
|
+
mr as Button
|
|
654
|
+
};
|