@minimalstuff/ui 0.0.3 → 0.0.8

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