@starasia/theme 1.0.1 → 1.0.2

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,828 +1,195 @@
1
- import jr, { createContext as ya, useState as xa, useMemo as Tr, useRef as ma, useEffect as ha, useContext as Ea } from "react";
2
- var or = { exports: {} }, Y = {};
3
- /**
4
- * @license React
5
- * react-jsx-runtime.production.min.js
6
- *
7
- * Copyright (c) Facebook, Inc. and its affiliates.
8
- *
9
- * This source code is licensed under the MIT license found in the
10
- * LICENSE file in the root directory of this source tree.
11
- */
12
- var $r;
13
- function _a() {
14
- if ($r)
15
- return Y;
16
- $r = 1;
17
- var o = jr, t = Symbol.for("react.element"), i = Symbol.for("react.fragment"), s = Object.prototype.hasOwnProperty, c = o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, l = { key: !0, ref: !0, __self: !0, __source: !0 };
18
- function v(g, d, m) {
19
- var x, R = {}, S = null, C = null;
20
- m !== void 0 && (S = "" + m), d.key !== void 0 && (S = "" + d.key), d.ref !== void 0 && (C = d.ref);
21
- for (x in d)
22
- s.call(d, x) && !l.hasOwnProperty(x) && (R[x] = d[x]);
23
- if (g && g.defaultProps)
24
- for (x in d = g.defaultProps, d)
25
- R[x] === void 0 && (R[x] = d[x]);
26
- return { $$typeof: t, type: g, key: S, ref: C, props: R, _owner: c.current };
27
- }
28
- return Y.Fragment = i, Y.jsx = v, Y.jsxs = v, Y;
29
- }
30
- var N = {};
31
- /**
32
- * @license React
33
- * react-jsx-runtime.development.js
34
- *
35
- * Copyright (c) Facebook, Inc. and its affiliates.
36
- *
37
- * This source code is licensed under the MIT license found in the
38
- * LICENSE file in the root directory of this source tree.
39
- */
40
- var Cr;
41
- function Ra() {
42
- return Cr || (Cr = 1, process.env.NODE_ENV !== "production" && function() {
43
- var o = jr, t = Symbol.for("react.element"), i = Symbol.for("react.portal"), s = Symbol.for("react.fragment"), c = Symbol.for("react.strict_mode"), l = Symbol.for("react.profiler"), v = Symbol.for("react.provider"), g = Symbol.for("react.context"), d = Symbol.for("react.forward_ref"), m = Symbol.for("react.suspense"), x = Symbol.for("react.suspense_list"), R = Symbol.for("react.memo"), S = Symbol.for("react.lazy"), C = Symbol.for("react.offscreen"), D = Symbol.iterator, L = "@@iterator";
44
- function Ir(r) {
45
- if (r === null || typeof r != "object")
46
- return null;
47
- var a = D && r[D] || r[L];
48
- return typeof a == "function" ? a : null;
49
- }
50
- var j = o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
51
- function h(r) {
52
- {
53
- for (var a = arguments.length, e = new Array(a > 1 ? a - 1 : 0), n = 1; n < a; n++)
54
- e[n - 1] = arguments[n];
55
- Wr("error", r, e);
56
- }
57
- }
58
- function Wr(r, a, e) {
59
- {
60
- var n = j.ReactDebugCurrentFrame, f = n.getStackAddendum();
61
- f !== "" && (a += "%s", e = e.concat([f]));
62
- var p = e.map(function(b) {
63
- return String(b);
64
- });
65
- p.unshift("Warning: " + a), Function.prototype.apply.call(console[r], console, p);
66
- }
67
- }
68
- var Yr = !1, Nr = !1, Lr = !1, Mr = !1, Vr = !1, er;
69
- er = Symbol.for("react.module.reference");
70
- function Ur(r) {
71
- return !!(typeof r == "string" || typeof r == "function" || r === s || r === l || Vr || r === c || r === m || r === x || Mr || r === C || Yr || Nr || Lr || typeof r == "object" && r !== null && (r.$$typeof === S || r.$$typeof === R || r.$$typeof === v || r.$$typeof === g || r.$$typeof === d || // This needs to include all possible module reference object
72
- // types supported by any Flight configuration anywhere since
73
- // we don't know which Flight build this will end up being used
74
- // with.
75
- r.$$typeof === er || r.getModuleId !== void 0));
76
- }
77
- function Jr(r, a, e) {
78
- var n = r.displayName;
79
- if (n)
80
- return n;
81
- var f = a.displayName || a.name || "";
82
- return f !== "" ? e + "(" + f + ")" : e;
83
- }
84
- function tr(r) {
85
- return r.displayName || "Context";
86
- }
87
- function $(r) {
88
- if (r == null)
89
- return null;
90
- if (typeof r.tag == "number" && h("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."), typeof r == "function")
91
- return r.displayName || r.name || null;
92
- if (typeof r == "string")
93
- return r;
94
- switch (r) {
95
- case s:
96
- return "Fragment";
97
- case i:
98
- return "Portal";
99
- case l:
100
- return "Profiler";
101
- case c:
102
- return "StrictMode";
103
- case m:
104
- return "Suspense";
105
- case x:
106
- return "SuspenseList";
107
- }
108
- if (typeof r == "object")
109
- switch (r.$$typeof) {
110
- case g:
111
- var a = r;
112
- return tr(a) + ".Consumer";
113
- case v:
114
- var e = r;
115
- return tr(e._context) + ".Provider";
116
- case d:
117
- return Jr(r, r.render, "ForwardRef");
118
- case R:
119
- var n = r.displayName || null;
120
- return n !== null ? n : $(r.type) || "Memo";
121
- case S: {
122
- var f = r, p = f._payload, b = f._init;
123
- try {
124
- return $(b(p));
125
- } catch {
126
- return null;
127
- }
128
- }
129
- }
130
- return null;
131
- }
132
- var O = Object.assign, A = 0, ir, sr, nr, cr, lr, ur, br;
133
- function gr() {
134
- }
135
- gr.__reactDisabledLog = !0;
136
- function Br() {
137
- {
138
- if (A === 0) {
139
- ir = console.log, sr = console.info, nr = console.warn, cr = console.error, lr = console.group, ur = console.groupCollapsed, br = console.groupEnd;
140
- var r = {
141
- configurable: !0,
142
- enumerable: !0,
143
- value: gr,
144
- writable: !0
145
- };
146
- Object.defineProperties(console, {
147
- info: r,
148
- log: r,
149
- warn: r,
150
- error: r,
151
- group: r,
152
- groupCollapsed: r,
153
- groupEnd: r
154
- });
155
- }
156
- A++;
157
- }
158
- }
159
- function qr() {
160
- {
161
- if (A--, A === 0) {
162
- var r = {
163
- configurable: !0,
164
- enumerable: !0,
165
- writable: !0
166
- };
167
- Object.defineProperties(console, {
168
- log: O({}, r, {
169
- value: ir
170
- }),
171
- info: O({}, r, {
172
- value: sr
173
- }),
174
- warn: O({}, r, {
175
- value: nr
176
- }),
177
- error: O({}, r, {
178
- value: cr
179
- }),
180
- group: O({}, r, {
181
- value: lr
182
- }),
183
- groupCollapsed: O({}, r, {
184
- value: ur
185
- }),
186
- groupEnd: O({}, r, {
187
- value: br
188
- })
189
- });
190
- }
191
- A < 0 && h("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
192
- }
193
- }
194
- var q = j.ReactCurrentDispatcher, K;
195
- function M(r, a, e) {
196
- {
197
- if (K === void 0)
198
- try {
199
- throw Error();
200
- } catch (f) {
201
- var n = f.stack.trim().match(/\n( *(at )?)/);
202
- K = n && n[1] || "";
203
- }
204
- return `
205
- ` + K + r;
206
- }
207
- }
208
- var z = !1, V;
209
- {
210
- var Kr = typeof WeakMap == "function" ? WeakMap : Map;
211
- V = new Kr();
212
- }
213
- function fr(r, a) {
214
- if (!r || z)
215
- return "";
216
- {
217
- var e = V.get(r);
218
- if (e !== void 0)
219
- return e;
220
- }
221
- var n;
222
- z = !0;
223
- var f = Error.prepareStackTrace;
224
- Error.prepareStackTrace = void 0;
225
- var p;
226
- p = q.current, q.current = null, Br();
227
- try {
228
- if (a) {
229
- var b = function() {
230
- throw Error();
231
- };
232
- if (Object.defineProperty(b.prototype, "props", {
233
- set: function() {
234
- throw Error();
235
- }
236
- }), typeof Reflect == "object" && Reflect.construct) {
237
- try {
238
- Reflect.construct(b, []);
239
- } catch (_) {
240
- n = _;
241
- }
242
- Reflect.construct(r, [], b);
243
- } else {
244
- try {
245
- b.call();
246
- } catch (_) {
247
- n = _;
248
- }
249
- r.call(b.prototype);
250
- }
251
- } else {
252
- try {
253
- throw Error();
254
- } catch (_) {
255
- n = _;
256
- }
257
- r();
258
- }
259
- } catch (_) {
260
- if (_ && n && typeof _.stack == "string") {
261
- for (var u = _.stack.split(`
262
- `), E = n.stack.split(`
263
- `), w = u.length - 1, y = E.length - 1; w >= 1 && y >= 0 && u[w] !== E[y]; )
264
- y--;
265
- for (; w >= 1 && y >= 0; w--, y--)
266
- if (u[w] !== E[y]) {
267
- if (w !== 1 || y !== 1)
268
- do
269
- if (w--, y--, y < 0 || u[w] !== E[y]) {
270
- var k = `
271
- ` + u[w].replace(" at new ", " at ");
272
- return r.displayName && k.includes("<anonymous>") && (k = k.replace("<anonymous>", r.displayName)), typeof r == "function" && V.set(r, k), k;
273
- }
274
- while (w >= 1 && y >= 0);
275
- break;
276
- }
277
- }
278
- } finally {
279
- z = !1, q.current = p, qr(), Error.prepareStackTrace = f;
280
- }
281
- var F = r ? r.displayName || r.name : "", P = F ? M(F) : "";
282
- return typeof r == "function" && V.set(r, P), P;
283
- }
284
- function zr(r, a, e) {
285
- return fr(r, !1);
286
- }
287
- function Gr(r) {
288
- var a = r.prototype;
289
- return !!(a && a.isReactComponent);
290
- }
291
- function U(r, a, e) {
292
- if (r == null)
293
- return "";
294
- if (typeof r == "function")
295
- return fr(r, Gr(r));
296
- if (typeof r == "string")
297
- return M(r);
298
- switch (r) {
299
- case m:
300
- return M("Suspense");
301
- case x:
302
- return M("SuspenseList");
303
- }
304
- if (typeof r == "object")
305
- switch (r.$$typeof) {
306
- case d:
307
- return zr(r.render);
308
- case R:
309
- return U(r.type, a, e);
310
- case S: {
311
- var n = r, f = n._payload, p = n._init;
312
- try {
313
- return U(p(f), a, e);
314
- } catch {
315
- }
316
- }
317
- }
318
- return "";
319
- }
320
- var I = Object.prototype.hasOwnProperty, vr = {}, dr = j.ReactDebugCurrentFrame;
321
- function J(r) {
322
- if (r) {
323
- var a = r._owner, e = U(r.type, r._source, a ? a.type : null);
324
- dr.setExtraStackFrame(e);
325
- } else
326
- dr.setExtraStackFrame(null);
327
- }
328
- function Hr(r, a, e, n, f) {
329
- {
330
- var p = Function.call.bind(I);
331
- for (var b in r)
332
- if (p(r, b)) {
333
- var u = void 0;
334
- try {
335
- if (typeof r[b] != "function") {
336
- var E = Error((n || "React class") + ": " + e + " type `" + b + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof r[b] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
337
- throw E.name = "Invariant Violation", E;
338
- }
339
- u = r[b](a, b, n, e, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
340
- } catch (w) {
341
- u = w;
342
- }
343
- u && !(u instanceof Error) && (J(f), h("%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", e, b, typeof u), J(null)), u instanceof Error && !(u.message in vr) && (vr[u.message] = !0, J(f), h("Failed %s type: %s", e, u.message), J(null));
344
- }
345
- }
346
- }
347
- var Xr = Array.isArray;
348
- function G(r) {
349
- return Xr(r);
350
- }
351
- function Zr(r) {
352
- {
353
- var a = typeof Symbol == "function" && Symbol.toStringTag, e = a && r[Symbol.toStringTag] || r.constructor.name || "Object";
354
- return e;
355
- }
356
- }
357
- function Qr(r) {
358
- try {
359
- return pr(r), !1;
360
- } catch {
361
- return !0;
362
- }
363
- }
364
- function pr(r) {
365
- return "" + r;
366
- }
367
- function wr(r) {
368
- if (Qr(r))
369
- return h("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Zr(r)), pr(r);
370
- }
371
- var W = j.ReactCurrentOwner, ra = {
372
- key: !0,
373
- ref: !0,
374
- __self: !0,
375
- __source: !0
376
- }, yr, xr, H;
377
- H = {};
378
- function aa(r) {
379
- if (I.call(r, "ref")) {
380
- var a = Object.getOwnPropertyDescriptor(r, "ref").get;
381
- if (a && a.isReactWarning)
382
- return !1;
383
- }
384
- return r.ref !== void 0;
385
- }
386
- function oa(r) {
387
- if (I.call(r, "key")) {
388
- var a = Object.getOwnPropertyDescriptor(r, "key").get;
389
- if (a && a.isReactWarning)
390
- return !1;
391
- }
392
- return r.key !== void 0;
393
- }
394
- function ea(r, a) {
395
- if (typeof r.ref == "string" && W.current && a && W.current.stateNode !== a) {
396
- var e = $(W.current.type);
397
- H[e] || (h('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', $(W.current.type), r.ref), H[e] = !0);
398
- }
399
- }
400
- function ta(r, a) {
401
- {
402
- var e = function() {
403
- yr || (yr = !0, h("%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)", a));
404
- };
405
- e.isReactWarning = !0, Object.defineProperty(r, "key", {
406
- get: e,
407
- configurable: !0
408
- });
409
- }
410
- }
411
- function ia(r, a) {
412
- {
413
- var e = function() {
414
- xr || (xr = !0, h("%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)", a));
415
- };
416
- e.isReactWarning = !0, Object.defineProperty(r, "ref", {
417
- get: e,
418
- configurable: !0
419
- });
420
- }
421
- }
422
- var sa = function(r, a, e, n, f, p, b) {
423
- var u = {
424
- // This tag allows us to uniquely identify this as a React Element
425
- $$typeof: t,
426
- // Built-in properties that belong on the element
427
- type: r,
428
- key: a,
429
- ref: e,
430
- props: b,
431
- // Record the component responsible for creating this element.
432
- _owner: p
433
- };
434
- return u._store = {}, Object.defineProperty(u._store, "validated", {
435
- configurable: !1,
436
- enumerable: !1,
437
- writable: !0,
438
- value: !1
439
- }), Object.defineProperty(u, "_self", {
440
- configurable: !1,
441
- enumerable: !1,
442
- writable: !1,
443
- value: n
444
- }), Object.defineProperty(u, "_source", {
445
- configurable: !1,
446
- enumerable: !1,
447
- writable: !1,
448
- value: f
449
- }), Object.freeze && (Object.freeze(u.props), Object.freeze(u)), u;
450
- };
451
- function na(r, a, e, n, f) {
452
- {
453
- var p, b = {}, u = null, E = null;
454
- e !== void 0 && (wr(e), u = "" + e), oa(a) && (wr(a.key), u = "" + a.key), aa(a) && (E = a.ref, ea(a, f));
455
- for (p in a)
456
- I.call(a, p) && !ra.hasOwnProperty(p) && (b[p] = a[p]);
457
- if (r && r.defaultProps) {
458
- var w = r.defaultProps;
459
- for (p in w)
460
- b[p] === void 0 && (b[p] = w[p]);
461
- }
462
- if (u || E) {
463
- var y = typeof r == "function" ? r.displayName || r.name || "Unknown" : r;
464
- u && ta(b, y), E && ia(b, y);
465
- }
466
- return sa(r, u, E, f, n, W.current, b);
467
- }
468
- }
469
- var X = j.ReactCurrentOwner, mr = j.ReactDebugCurrentFrame;
470
- function T(r) {
471
- if (r) {
472
- var a = r._owner, e = U(r.type, r._source, a ? a.type : null);
473
- mr.setExtraStackFrame(e);
474
- } else
475
- mr.setExtraStackFrame(null);
476
- }
477
- var Z;
478
- Z = !1;
479
- function Q(r) {
480
- return typeof r == "object" && r !== null && r.$$typeof === t;
481
- }
482
- function hr() {
483
- {
484
- if (X.current) {
485
- var r = $(X.current.type);
486
- if (r)
487
- return `
488
-
489
- Check the render method of \`` + r + "`.";
490
- }
491
- return "";
492
- }
493
- }
494
- function ca(r) {
495
- return "";
496
- }
497
- var Er = {};
498
- function la(r) {
499
- {
500
- var a = hr();
501
- if (!a) {
502
- var e = typeof r == "string" ? r : r.displayName || r.name;
503
- e && (a = `
504
-
505
- Check the top-level render call using <` + e + ">.");
506
- }
507
- return a;
508
- }
509
- }
510
- function _r(r, a) {
511
- {
512
- if (!r._store || r._store.validated || r.key != null)
513
- return;
514
- r._store.validated = !0;
515
- var e = la(a);
516
- if (Er[e])
517
- return;
518
- Er[e] = !0;
519
- var n = "";
520
- r && r._owner && r._owner !== X.current && (n = " It was passed a child from " + $(r._owner.type) + "."), T(r), h('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', e, n), T(null);
521
- }
522
- }
523
- function Rr(r, a) {
524
- {
525
- if (typeof r != "object")
526
- return;
527
- if (G(r))
528
- for (var e = 0; e < r.length; e++) {
529
- var n = r[e];
530
- Q(n) && _r(n, a);
531
- }
532
- else if (Q(r))
533
- r._store && (r._store.validated = !0);
534
- else if (r) {
535
- var f = Ir(r);
536
- if (typeof f == "function" && f !== r.entries)
537
- for (var p = f.call(r), b; !(b = p.next()).done; )
538
- Q(b.value) && _r(b.value, a);
539
- }
540
- }
541
- }
542
- function ua(r) {
543
- {
544
- var a = r.type;
545
- if (a == null || typeof a == "string")
546
- return;
547
- var e;
548
- if (typeof a == "function")
549
- e = a.propTypes;
550
- else if (typeof a == "object" && (a.$$typeof === d || // Note: Memo only checks outer props here.
551
- // Inner props are checked in the reconciler.
552
- a.$$typeof === R))
553
- e = a.propTypes;
554
- else
555
- return;
556
- if (e) {
557
- var n = $(a);
558
- Hr(e, r.props, "prop", n, r);
559
- } else if (a.PropTypes !== void 0 && !Z) {
560
- Z = !0;
561
- var f = $(a);
562
- h("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", f || "Unknown");
563
- }
564
- typeof a.getDefaultProps == "function" && !a.getDefaultProps.isReactClassApproved && h("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
565
- }
566
- }
567
- function ba(r) {
568
- {
569
- for (var a = Object.keys(r.props), e = 0; e < a.length; e++) {
570
- var n = a[e];
571
- if (n !== "children" && n !== "key") {
572
- T(r), h("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", n), T(null);
573
- break;
574
- }
575
- }
576
- r.ref !== null && (T(r), h("Invalid attribute `ref` supplied to `React.Fragment`."), T(null));
577
- }
578
- }
579
- var kr = {};
580
- function Sr(r, a, e, n, f, p) {
581
- {
582
- var b = Ur(r);
583
- if (!b) {
584
- var u = "";
585
- (r === void 0 || typeof r == "object" && r !== null && Object.keys(r).length === 0) && (u += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
586
- var E = ca();
587
- E ? u += E : u += hr();
588
- var w;
589
- r === null ? w = "null" : G(r) ? w = "array" : r !== void 0 && r.$$typeof === t ? (w = "<" + ($(r.type) || "Unknown") + " />", u = " Did you accidentally export a JSX literal instead of a component?") : w = typeof r, h("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", w, u);
590
- }
591
- var y = na(r, a, e, f, p);
592
- if (y == null)
593
- return y;
594
- if (b) {
595
- var k = a.children;
596
- if (k !== void 0)
597
- if (n)
598
- if (G(k)) {
599
- for (var F = 0; F < k.length; F++)
600
- Rr(k[F], r);
601
- Object.freeze && Object.freeze(k);
602
- } else
603
- h("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
604
- else
605
- Rr(k, r);
606
- }
607
- if (I.call(a, "key")) {
608
- var P = $(r), _ = Object.keys(a).filter(function(wa) {
609
- return wa !== "key";
610
- }), rr = _.length > 0 ? "{key: someKey, " + _.join(": ..., ") + ": ...}" : "{key: someKey}";
611
- if (!kr[P + rr]) {
612
- var pa = _.length > 0 ? "{" + _.join(": ..., ") + ": ...}" : "{}";
613
- h(`A props object containing a "key" prop is being spread into JSX:
614
- let props = %s;
615
- <%s {...props} />
616
- React keys must be passed directly to JSX without using spread:
617
- let props = %s;
618
- <%s key={someKey} {...props} />`, rr, P, pa, P), kr[P + rr] = !0;
619
- }
620
- }
621
- return r === s ? ba(y) : ua(y), y;
622
- }
623
- }
624
- function ga(r, a, e) {
625
- return Sr(r, a, e, !0);
626
- }
627
- function fa(r, a, e) {
628
- return Sr(r, a, e, !1);
629
- }
630
- var va = fa, da = ga;
631
- N.Fragment = s, N.jsx = va, N.jsxs = da;
632
- }()), N;
633
- }
634
- process.env.NODE_ENV === "production" ? or.exports = _a() : or.exports = Ra();
635
- var ka = or.exports;
636
- function Or(o, t = "") {
637
- let i = "";
638
- for (const s in o)
639
- if (Object.hasOwnProperty.call(o, s)) {
640
- const c = o[s];
641
- i += `/* ${s} */
1
+ import { jsx as C } from "react/jsx-runtime";
2
+ import { createContext as h, useState as j, useMemo as f, useRef as O, useEffect as E, useContext as P } from "react";
3
+ function y(r, a = "") {
4
+ let o = "";
5
+ for (const s in r)
6
+ if (Object.hasOwnProperty.call(r, s)) {
7
+ const t = r[s];
8
+ o += `/* ${s} */
642
9
  `;
643
- for (const l in c)
644
- if (Object.hasOwnProperty.call(c, l)) {
645
- const v = c[l];
646
- i += `--${t}-${s}-${l}: ${v};
10
+ for (const i in t)
11
+ if (Object.hasOwnProperty.call(t, i)) {
12
+ const e = t[i];
13
+ o += `--${a}-${s}-${i}: ${e};
647
14
  `;
648
15
  }
649
16
  }
650
- return i;
17
+ return o;
651
18
  }
652
- function Pr(o, t) {
653
- let i = "";
654
- for (const s in o) {
655
- const c = o[s];
656
- for (const l in c) {
657
- const v = c[l], g = `${t}-${s}-${l}`;
658
- i += `--${g}: ${v};
19
+ function $(r, a) {
20
+ let o = "";
21
+ for (const s in r) {
22
+ const t = r[s];
23
+ for (const i in t) {
24
+ const e = t[i], c = `${a}-${s}-${i}`;
25
+ o += `--${c}: ${e};
659
26
  `;
660
27
  }
661
28
  }
662
- return i;
29
+ return o;
663
30
  }
664
- function Sa(o, t) {
665
- let i = "";
666
- function s(c, l, v = "", g = "", d = "") {
667
- if (d) {
668
- const m = `${v}${d}-${g}-${c}`;
669
- i += `--${m}: ${l};
31
+ function F(r, a) {
32
+ let o = "";
33
+ function s(t, i, e = "", c = "", l = "") {
34
+ if (l) {
35
+ const b = `${e}${l}-${c}-${t}`;
36
+ o += `--${b}: ${i};
670
37
  `;
671
38
  } else {
672
- const m = `${v}${c}-${g}`;
673
- i += `--${m}: ${l};
39
+ const b = `${e}${t}-${c}`;
40
+ o += `--${b}: ${i};
674
41
  `;
675
42
  }
676
43
  }
677
- for (const c in o) {
678
- const l = o[c];
679
- for (const v in l) {
680
- const g = l[v];
681
- if (typeof g == "object")
682
- for (const d in g) {
683
- const m = g[d], x = `${t}-`;
44
+ for (const t in r) {
45
+ const i = r[t];
46
+ for (const e in i) {
47
+ const c = i[e];
48
+ if (typeof c == "object")
49
+ for (const l in c) {
50
+ const b = c[l], u = `${a}-`;
684
51
  s(
685
- v,
686
- m,
687
- x,
688
- c,
689
- d
52
+ e,
53
+ b,
54
+ u,
55
+ t,
56
+ l
690
57
  );
691
58
  }
692
59
  else {
693
- const d = `${t}-`;
694
- s(v, g, d, c);
60
+ const l = `${a}-`;
61
+ s(e, c, l, t);
695
62
  }
696
63
  }
697
64
  }
698
- return i;
65
+ return o;
699
66
  }
700
- function $a(o, t = "") {
701
- let i = "";
702
- function s(c, l, v = "") {
703
- if (typeof l == "object")
704
- for (const g in l) {
705
- const d = l[g], m = `--${v}-${c}-${g}`;
706
- i += `${m}: ${d};
67
+ function N(r, a = "") {
68
+ let o = "";
69
+ function s(t, i, e = "") {
70
+ if (typeof i == "object")
71
+ for (const c in i) {
72
+ const l = i[c], b = `--${e}-${t}-${c}`;
73
+ o += `${b}: ${l};
707
74
  `;
708
75
  }
709
76
  else {
710
- const g = `--${v}-${c}`;
711
- i += `${g}: ${l};
77
+ const c = `--${e}-${t}`;
78
+ o += `${c}: ${i};
712
79
  `;
713
80
  }
714
81
  }
715
- for (const c in o) {
716
- const l = o[c];
717
- if (typeof l == "object")
718
- s(c, l, `${t}`);
82
+ for (const t in r) {
83
+ const i = r[t];
84
+ if (typeof i == "object")
85
+ s(t, i, `${a}`);
719
86
  else {
720
- const v = `--${t}-${c}`;
721
- i += `${v}: ${l};
87
+ const e = `--${a}-${t}`;
88
+ o += `${e}: ${i};
722
89
  `;
723
90
  }
724
91
  }
725
- return i;
92
+ return o;
726
93
  }
727
- function Ca(o, t = "") {
728
- let i = "";
729
- for (const s in o) {
730
- const c = o[s];
731
- for (const l in c) {
732
- const v = `--${t}-${s}-${l}`, g = c[l];
733
- i += `${v}: ${g};
94
+ function M(r, a = "") {
95
+ let o = "";
96
+ for (const s in r) {
97
+ const t = r[s];
98
+ for (const i in t) {
99
+ const e = `--${a}-${s}-${i}`, c = t[i];
100
+ o += `${e}: ${c};
734
101
  `;
735
102
  }
736
103
  }
737
- return i;
104
+ return o;
738
105
  }
739
- function Oa(o, t) {
740
- let i = "";
741
- for (const s in o)
742
- if (Object.hasOwnProperty.call(o, s)) {
743
- const c = o[s];
744
- s === "default" ? i += `--${t}: ${c};
745
- ` : i += `--${t}-${s}: ${c};
106
+ function D(r, a) {
107
+ let o = "";
108
+ for (const s in r)
109
+ if (Object.hasOwnProperty.call(r, s)) {
110
+ const t = r[s];
111
+ s === "default" ? o += `--${a}: ${t};
112
+ ` : o += `--${a}-${s}: ${t};
746
113
  `;
747
114
  }
748
- return i;
115
+ return o;
749
116
  }
750
- const Pa = (o) => {
751
- const t = document.getElementById(o);
752
- if (t)
753
- return t;
754
- const i = document.createElement("style");
755
- return i.id = o, document.head.appendChild(i), i;
117
+ const J = (r) => {
118
+ const a = document.getElementById(r);
119
+ if (a)
120
+ return a;
121
+ const o = document.createElement("style");
122
+ return o.id = r, document.head.appendChild(o), o;
756
123
  };
757
- function Fr(o, t) {
758
- let i = "";
759
- return Object.keys(o).forEach((s) => {
760
- const c = o[s];
761
- if (c && typeof c == "object") {
762
- i += Fr(c, `${t}-${s}`);
124
+ function m(r, a) {
125
+ let o = "";
126
+ return Object.keys(r).forEach((s) => {
127
+ const t = r[s];
128
+ if (t && typeof t == "object") {
129
+ o += m(t, `${a}-${s}`);
763
130
  return;
764
131
  }
765
- i += `${t}-${s}: ${c};
132
+ o += `${a}-${s}: ${t};
766
133
  `;
767
- }), i;
134
+ }), o;
768
135
  }
769
- function ja(o, t) {
770
- let i = "";
771
- return o && (i += Fr(o, t)), i;
136
+ function B(r, a) {
137
+ let o = "";
138
+ return r && (o += m(r, a)), o;
772
139
  }
773
- function Ta(o) {
774
- var x, R, S, C, D, L;
775
- if (!o)
140
+ function H(r) {
141
+ var u, v, w, d, p, x;
142
+ if (!r)
776
143
  return;
777
- const t = (x = o.colors) != null && x.raw ? Pr(
778
- o.colors.raw,
144
+ const a = (u = r.colors) != null && u.raw ? $(
145
+ r.colors.raw,
779
146
  "starasia-ui-raw-color"
780
- ) : "", i = (R = o.colors) != null && R.computed ? Pr(
781
- o.colors.computed,
147
+ ) : "", o = (v = r.colors) != null && v.computed ? $(
148
+ r.colors.computed,
782
149
  "starasia-ui-color"
783
- ) : "", s = (S = o.colors) != null && S.main ? Sa(o.colors.main, "starasia-ui") : "", c = (C = o.colors) != null && C.brand ? Or(o.colors.brand, "starasia-ui-brand") : "", l = (D = o.colors) != null && D.utility ? Or(
784
- o.colors.utility,
150
+ ) : "", s = (w = r.colors) != null && w.main ? F(r.colors.main, "starasia-ui") : "", t = (d = r.colors) != null && d.brand ? y(r.colors.brand, "starasia-ui-brand") : "", i = (p = r.colors) != null && p.utility ? y(
151
+ r.colors.utility,
785
152
  "starasia-ui-utility"
786
- ) : "", v = (L = o.colors) != null && L.text ? Oa(
787
- o.colors.text,
153
+ ) : "", e = (x = r.colors) != null && x.text ? D(
154
+ r.colors.text,
788
155
  "starasia-ui-color-text"
789
- ) : "", g = o.metrics ? $a(o.metrics, "starasia-ui") : "", d = o.font ? Ca(o.font, "starasia-ui") : "", m = o.components ? ja(o.components, "--starasia-ui") : "";
156
+ ) : "", c = r.metrics ? N(r.metrics, "starasia-ui") : "", l = r.font ? M(r.font, "starasia-ui") : "", b = r.components ? B(r.components, "--starasia-ui") : "";
790
157
  return `
791
158
  :root {
159
+ ${a}
160
+ ${o}
161
+ ${s}
792
162
  ${t}
793
163
  ${i}
794
- ${s}
164
+ ${e}
795
165
  ${c}
796
166
  ${l}
797
- ${v}
798
- ${g}
799
- ${d}
800
- ${m}
167
+ ${b}
801
168
  }
802
169
  `;
803
170
  }
804
- const Dr = ya({
171
+ const k = h({
805
172
  theme: void 0,
806
173
  setTheme: () => {
807
174
  }
808
- }), Fa = "starasia-theme-style";
809
- function Na({ value: o, children: t }) {
810
- const [i, s] = xa(o), c = Tr(
811
- () => i ? JSON.stringify(i) : "",
812
- [i]
813
- ), l = ma(Pa(Fa));
814
- ha(() => {
815
- if (c) {
816
- const g = Ta(JSON.parse(c));
817
- g && (l != null && l.current) && (l.current.textContent = g);
818
- }
819
- }, [c]);
820
- const v = (g) => {
821
- g && s(g);
175
+ }), L = "starasia-theme-style";
176
+ function K({ value: r, children: a }) {
177
+ const [o, s] = j(r), t = f(
178
+ () => o ? JSON.stringify(o) : "",
179
+ [o]
180
+ ), i = O(J(L));
181
+ E(() => {
182
+ if (t) {
183
+ const c = H(JSON.parse(t));
184
+ c && (i != null && i.current) && (i.current.textContent = c);
185
+ }
186
+ }, [t]);
187
+ const e = (c) => {
188
+ c && s(c);
822
189
  };
823
- return /* @__PURE__ */ ka.jsx(Dr.Provider, { value: { theme: i, setTheme: v }, children: t });
190
+ return /* @__PURE__ */ C(k.Provider, { value: { theme: o, setTheme: e }, children: a });
824
191
  }
825
- const Da = {
192
+ const V = {
826
193
  raw: {
827
194
  white: {
828
195
  900: "255, 255, 255"
@@ -1253,7 +620,7 @@ const Da = {
1253
620
  tertiary: "rgba(120, 134, 127, 0.1)"
1254
621
  }
1255
622
  }
1256
- }, Aa = {
623
+ }, _ = {
1257
624
  radii: {
1258
625
  none: "0",
1259
626
  xs: "0.25rem",
@@ -1311,7 +678,7 @@ const Da = {
1311
678
  inner: "inset 0 2px 4px 0 rgb(0 0 0 / 0.05)",
1312
679
  card: "0px 4px 35px 0px rgba(112, 144, 176, 0.25)"
1313
680
  }
1314
- }, Ia = {
681
+ }, q = {
1315
682
  fontSizes: {
1316
683
  xs: "0.625rem",
1317
684
  sm: "0.75rem",
@@ -1351,64 +718,64 @@ const Da = {
1351
718
  relaxed: 1.625,
1352
719
  loose: 2
1353
720
  }
1354
- }, Wa = {
1355
- colors: Da,
1356
- metrics: Aa,
1357
- font: Ia
1358
- }, ar = Wa, Ar = (o, t) => {
1359
- const i = {};
1360
- return Object.keys(o).forEach((s) => {
1361
- if (o != null && o[s] && typeof (o == null ? void 0 : o[s]) == "object") {
1362
- i[s] = {
1363
- ...o == null ? void 0 : o[s],
1364
- ...t == null ? void 0 : t[s],
1365
- ...Ar(o == null ? void 0 : o[s], t == null ? void 0 : t[s])
721
+ }, z = {
722
+ colors: V,
723
+ metrics: _,
724
+ font: q
725
+ }, n = z, S = (r, a) => {
726
+ const o = {};
727
+ return Object.keys(r).forEach((s) => {
728
+ if (r != null && r[s] && typeof (r == null ? void 0 : r[s]) == "object") {
729
+ o[s] = {
730
+ ...r == null ? void 0 : r[s],
731
+ ...a == null ? void 0 : a[s],
732
+ ...S(r == null ? void 0 : r[s], a == null ? void 0 : a[s])
1366
733
  };
1367
734
  return;
1368
735
  }
1369
- i[s] = (t == null ? void 0 : t[s]) || (o == null ? void 0 : o[s]);
1370
- }), i;
736
+ o[s] = (a == null ? void 0 : a[s]) || (r == null ? void 0 : r[s]);
737
+ }), o;
1371
738
  };
1372
- function B() {
1373
- const o = Ea(Dr), t = Tr(
739
+ function g() {
740
+ const r = P(k), a = f(
1374
741
  () => ({
1375
- ...ar,
1376
- ...o.theme,
1377
- ...Ar(ar, o.theme)
742
+ ...n,
743
+ ...r.theme,
744
+ ...S(n, r.theme)
1378
745
  }),
1379
- [o.theme, ar]
746
+ [r.theme, n]
1380
747
  );
1381
- return { ...o, theme: t };
748
+ return { ...r, theme: a };
1382
749
  }
1383
- function La() {
1384
- const { theme: o } = B();
1385
- return o.colors;
750
+ function R() {
751
+ const { theme: r } = g();
752
+ return r.colors;
1386
753
  }
1387
- function Ma() {
1388
- var t;
1389
- const { theme: o } = B();
1390
- return (t = o.metrics) == null ? void 0 : t.spacing;
754
+ function U() {
755
+ var a;
756
+ const { theme: r } = g();
757
+ return (a = r.metrics) == null ? void 0 : a.spacing;
1391
758
  }
1392
- function Va() {
1393
- var t;
1394
- const { theme: o } = B();
1395
- return (t = o.metrics) == null ? void 0 : t.radii;
759
+ function W() {
760
+ var a;
761
+ const { theme: r } = g();
762
+ return (a = r.metrics) == null ? void 0 : a.radii;
1396
763
  }
1397
- function Ua() {
1398
- var t;
1399
- const { theme: o } = B();
1400
- return (t = o == null ? void 0 : o.metrics) == null ? void 0 : t.shadows;
764
+ function Y() {
765
+ var a;
766
+ const { theme: r } = g();
767
+ return (a = r == null ? void 0 : r.metrics) == null ? void 0 : a.shadows;
1401
768
  }
1402
- function Ja(o) {
1403
- return o;
769
+ function G(r) {
770
+ return r;
1404
771
  }
1405
772
  export {
1406
- Dr as ThemeContext,
1407
- Na as ThemeProvider,
1408
- Ja as createTheme,
1409
- La as useColor,
1410
- Va as useRadius,
1411
- Ua as useShadow,
1412
- Ma as useSpacing,
1413
- B as useTheme
773
+ k as ThemeContext,
774
+ K as ThemeProvider,
775
+ G as createTheme,
776
+ R as useColor,
777
+ W as useRadius,
778
+ Y as useShadow,
779
+ U as useSpacing,
780
+ g as useTheme
1414
781
  };
package/dist/index.umd.js CHANGED
@@ -1,54 +1,25 @@
1
- (function(R,k){typeof exports=="object"&&typeof module<"u"?k(exports,require("react")):typeof define=="function"&&define.amd?define(["exports","react"],k):(R=typeof globalThis<"u"?globalThis:R||self,k(R["@starasia/theme"]={},R.React))})(this,function(R,k){"use strict";var G={exports:{}},I={};/**
2
- * @license React
3
- * react-jsx-runtime.production.min.js
4
- *
5
- * Copyright (c) Facebook, Inc. and its affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- */var sr;function Ir(){if(sr)return I;sr=1;var o=k,t=Symbol.for("react.element"),i=Symbol.for("react.fragment"),s=Object.prototype.hasOwnProperty,c=o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,l={key:!0,ref:!0,__self:!0,__source:!0};function v(g,d,m){var x,S={},O=null,j=null;m!==void 0&&(O=""+m),d.key!==void 0&&(O=""+d.key),d.ref!==void 0&&(j=d.ref);for(x in d)s.call(d,x)&&!l.hasOwnProperty(x)&&(S[x]=d[x]);if(g&&g.defaultProps)for(x in d=g.defaultProps,d)S[x]===void 0&&(S[x]=d[x]);return{$$typeof:t,type:g,key:O,ref:j,props:S,_owner:c.current}}return I.Fragment=i,I.jsx=v,I.jsxs=v,I}var W={};/**
10
- * @license React
11
- * react-jsx-runtime.development.js
12
- *
13
- * Copyright (c) Facebook, Inc. and its affiliates.
14
- *
15
- * This source code is licensed under the MIT license found in the
16
- * LICENSE file in the root directory of this source tree.
17
- */var nr;function Wr(){return nr||(nr=1,process.env.NODE_ENV!=="production"&&function(){var o=k,t=Symbol.for("react.element"),i=Symbol.for("react.portal"),s=Symbol.for("react.fragment"),c=Symbol.for("react.strict_mode"),l=Symbol.for("react.profiler"),v=Symbol.for("react.provider"),g=Symbol.for("react.context"),d=Symbol.for("react.forward_ref"),m=Symbol.for("react.suspense"),x=Symbol.for("react.suspense_list"),S=Symbol.for("react.memo"),O=Symbol.for("react.lazy"),j=Symbol.for("react.offscreen"),M=Symbol.iterator,U="@@iterator";function Qr(r){if(r===null||typeof r!="object")return null;var a=M&&r[M]||r[U];return typeof a=="function"?a:null}var F=o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function h(r){{for(var a=arguments.length,e=new Array(a>1?a-1:0),n=1;n<a;n++)e[n-1]=arguments[n];ra("error",r,e)}}function ra(r,a,e){{var n=F.ReactDebugCurrentFrame,f=n.getStackAddendum();f!==""&&(a+="%s",e=e.concat([f]));var p=e.map(function(b){return String(b)});p.unshift("Warning: "+a),Function.prototype.apply.call(console[r],console,p)}}var aa=!1,oa=!1,ea=!1,ta=!1,ia=!1,gr;gr=Symbol.for("react.module.reference");function sa(r){return!!(typeof r=="string"||typeof r=="function"||r===s||r===l||ia||r===c||r===m||r===x||ta||r===j||aa||oa||ea||typeof r=="object"&&r!==null&&(r.$$typeof===O||r.$$typeof===S||r.$$typeof===v||r.$$typeof===g||r.$$typeof===d||r.$$typeof===gr||r.getModuleId!==void 0))}function na(r,a,e){var n=r.displayName;if(n)return n;var f=a.displayName||a.name||"";return f!==""?e+"("+f+")":e}function fr(r){return r.displayName||"Context"}function P(r){if(r==null)return null;if(typeof r.tag=="number"&&h("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof r=="function")return r.displayName||r.name||null;if(typeof r=="string")return r;switch(r){case s:return"Fragment";case i:return"Portal";case l:return"Profiler";case c:return"StrictMode";case m:return"Suspense";case x:return"SuspenseList"}if(typeof r=="object")switch(r.$$typeof){case g:var a=r;return fr(a)+".Consumer";case v:var e=r;return fr(e._context)+".Provider";case d:return na(r,r.render,"ForwardRef");case S:var n=r.displayName||null;return n!==null?n:P(r.type)||"Memo";case O:{var f=r,p=f._payload,b=f._init;try{return P(b(p))}catch{return null}}}return null}var $=Object.assign,L=0,vr,dr,pr,wr,yr,xr,mr;function hr(){}hr.__reactDisabledLog=!0;function ca(){{if(L===0){vr=console.log,dr=console.info,pr=console.warn,wr=console.error,yr=console.group,xr=console.groupCollapsed,mr=console.groupEnd;var r={configurable:!0,enumerable:!0,value:hr,writable:!0};Object.defineProperties(console,{info:r,log:r,warn:r,error:r,group:r,groupCollapsed:r,groupEnd:r})}L++}}function la(){{if(L--,L===0){var r={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:$({},r,{value:vr}),info:$({},r,{value:dr}),warn:$({},r,{value:pr}),error:$({},r,{value:wr}),group:$({},r,{value:yr}),groupCollapsed:$({},r,{value:xr}),groupEnd:$({},r,{value:mr})})}L<0&&h("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var q=F.ReactCurrentDispatcher,Z;function J(r,a,e){{if(Z===void 0)try{throw Error()}catch(f){var n=f.stack.trim().match(/\n( *(at )?)/);Z=n&&n[1]||""}return`
18
- `+Z+r}}var Q=!1,B;{var ua=typeof WeakMap=="function"?WeakMap:Map;B=new ua}function Er(r,a){if(!r||Q)return"";{var e=B.get(r);if(e!==void 0)return e}var n;Q=!0;var f=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var p;p=q.current,q.current=null,ca();try{if(a){var b=function(){throw Error()};if(Object.defineProperty(b.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(b,[])}catch(_){n=_}Reflect.construct(r,[],b)}else{try{b.call()}catch(_){n=_}r.call(b.prototype)}}else{try{throw Error()}catch(_){n=_}r()}}catch(_){if(_&&n&&typeof _.stack=="string"){for(var u=_.stack.split(`
19
- `),E=n.stack.split(`
20
- `),w=u.length-1,y=E.length-1;w>=1&&y>=0&&u[w]!==E[y];)y--;for(;w>=1&&y>=0;w--,y--)if(u[w]!==E[y]){if(w!==1||y!==1)do if(w--,y--,y<0||u[w]!==E[y]){var C=`
21
- `+u[w].replace(" at new "," at ");return r.displayName&&C.includes("<anonymous>")&&(C=C.replace("<anonymous>",r.displayName)),typeof r=="function"&&B.set(r,C),C}while(w>=1&&y>=0);break}}}finally{Q=!1,q.current=p,la(),Error.prepareStackTrace=f}var A=r?r.displayName||r.name:"",T=A?J(A):"";return typeof r=="function"&&B.set(r,T),T}function ba(r,a,e){return Er(r,!1)}function ga(r){var a=r.prototype;return!!(a&&a.isReactComponent)}function K(r,a,e){if(r==null)return"";if(typeof r=="function")return Er(r,ga(r));if(typeof r=="string")return J(r);switch(r){case m:return J("Suspense");case x:return J("SuspenseList")}if(typeof r=="object")switch(r.$$typeof){case d:return ba(r.render);case S:return K(r.type,a,e);case O:{var n=r,f=n._payload,p=n._init;try{return K(p(f),a,e)}catch{}}}return""}var N=Object.prototype.hasOwnProperty,Rr={},_r=F.ReactDebugCurrentFrame;function z(r){if(r){var a=r._owner,e=K(r.type,r._source,a?a.type:null);_r.setExtraStackFrame(e)}else _r.setExtraStackFrame(null)}function fa(r,a,e,n,f){{var p=Function.call.bind(N);for(var b in r)if(p(r,b)){var u=void 0;try{if(typeof r[b]!="function"){var E=Error((n||"React class")+": "+e+" type `"+b+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof r[b]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw E.name="Invariant Violation",E}u=r[b](a,b,n,e,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(w){u=w}u&&!(u instanceof Error)&&(z(f),h("%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",e,b,typeof u),z(null)),u instanceof Error&&!(u.message in Rr)&&(Rr[u.message]=!0,z(f),h("Failed %s type: %s",e,u.message),z(null))}}}var va=Array.isArray;function rr(r){return va(r)}function da(r){{var a=typeof Symbol=="function"&&Symbol.toStringTag,e=a&&r[Symbol.toStringTag]||r.constructor.name||"Object";return e}}function pa(r){try{return kr(r),!1}catch{return!0}}function kr(r){return""+r}function Sr(r){if(pa(r))return h("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",da(r)),kr(r)}var V=F.ReactCurrentOwner,wa={key:!0,ref:!0,__self:!0,__source:!0},Cr,Or,ar;ar={};function ya(r){if(N.call(r,"ref")){var a=Object.getOwnPropertyDescriptor(r,"ref").get;if(a&&a.isReactWarning)return!1}return r.ref!==void 0}function xa(r){if(N.call(r,"key")){var a=Object.getOwnPropertyDescriptor(r,"key").get;if(a&&a.isReactWarning)return!1}return r.key!==void 0}function ma(r,a){if(typeof r.ref=="string"&&V.current&&a&&V.current.stateNode!==a){var e=P(V.current.type);ar[e]||(h('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',P(V.current.type),r.ref),ar[e]=!0)}}function ha(r,a){{var e=function(){Cr||(Cr=!0,h("%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)",a))};e.isReactWarning=!0,Object.defineProperty(r,"key",{get:e,configurable:!0})}}function Ea(r,a){{var e=function(){Or||(Or=!0,h("%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)",a))};e.isReactWarning=!0,Object.defineProperty(r,"ref",{get:e,configurable:!0})}}var Ra=function(r,a,e,n,f,p,b){var u={$$typeof:t,type:r,key:a,ref:e,props:b,_owner:p};return u._store={},Object.defineProperty(u._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(u,"_self",{configurable:!1,enumerable:!1,writable:!1,value:n}),Object.defineProperty(u,"_source",{configurable:!1,enumerable:!1,writable:!1,value:f}),Object.freeze&&(Object.freeze(u.props),Object.freeze(u)),u};function _a(r,a,e,n,f){{var p,b={},u=null,E=null;e!==void 0&&(Sr(e),u=""+e),xa(a)&&(Sr(a.key),u=""+a.key),ya(a)&&(E=a.ref,ma(a,f));for(p in a)N.call(a,p)&&!wa.hasOwnProperty(p)&&(b[p]=a[p]);if(r&&r.defaultProps){var w=r.defaultProps;for(p in w)b[p]===void 0&&(b[p]=w[p])}if(u||E){var y=typeof r=="function"?r.displayName||r.name||"Unknown":r;u&&ha(b,y),E&&Ea(b,y)}return Ra(r,u,E,f,n,V.current,b)}}var or=F.ReactCurrentOwner,Pr=F.ReactDebugCurrentFrame;function D(r){if(r){var a=r._owner,e=K(r.type,r._source,a?a.type:null);Pr.setExtraStackFrame(e)}else Pr.setExtraStackFrame(null)}var er;er=!1;function tr(r){return typeof r=="object"&&r!==null&&r.$$typeof===t}function jr(){{if(or.current){var r=P(or.current.type);if(r)return`
22
-
23
- Check the render method of \``+r+"`."}return""}}function ka(r){return""}var $r={};function Sa(r){{var a=jr();if(!a){var e=typeof r=="string"?r:r.displayName||r.name;e&&(a=`
24
-
25
- Check the top-level render call using <`+e+">.")}return a}}function Tr(r,a){{if(!r._store||r._store.validated||r.key!=null)return;r._store.validated=!0;var e=Sa(a);if($r[e])return;$r[e]=!0;var n="";r&&r._owner&&r._owner!==or.current&&(n=" It was passed a child from "+P(r._owner.type)+"."),D(r),h('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',e,n),D(null)}}function Fr(r,a){{if(typeof r!="object")return;if(rr(r))for(var e=0;e<r.length;e++){var n=r[e];tr(n)&&Tr(n,a)}else if(tr(r))r._store&&(r._store.validated=!0);else if(r){var f=Qr(r);if(typeof f=="function"&&f!==r.entries)for(var p=f.call(r),b;!(b=p.next()).done;)tr(b.value)&&Tr(b.value,a)}}}function Ca(r){{var a=r.type;if(a==null||typeof a=="string")return;var e;if(typeof a=="function")e=a.propTypes;else if(typeof a=="object"&&(a.$$typeof===d||a.$$typeof===S))e=a.propTypes;else return;if(e){var n=P(a);fa(e,r.props,"prop",n,r)}else if(a.PropTypes!==void 0&&!er){er=!0;var f=P(a);h("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",f||"Unknown")}typeof a.getDefaultProps=="function"&&!a.getDefaultProps.isReactClassApproved&&h("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function Oa(r){{for(var a=Object.keys(r.props),e=0;e<a.length;e++){var n=a[e];if(n!=="children"&&n!=="key"){D(r),h("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",n),D(null);break}}r.ref!==null&&(D(r),h("Invalid attribute `ref` supplied to `React.Fragment`."),D(null))}}var Dr={};function Ar(r,a,e,n,f,p){{var b=sa(r);if(!b){var u="";(r===void 0||typeof r=="object"&&r!==null&&Object.keys(r).length===0)&&(u+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var E=ka();E?u+=E:u+=jr();var w;r===null?w="null":rr(r)?w="array":r!==void 0&&r.$$typeof===t?(w="<"+(P(r.type)||"Unknown")+" />",u=" Did you accidentally export a JSX literal instead of a component?"):w=typeof r,h("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",w,u)}var y=_a(r,a,e,f,p);if(y==null)return y;if(b){var C=a.children;if(C!==void 0)if(n)if(rr(C)){for(var A=0;A<C.length;A++)Fr(C[A],r);Object.freeze&&Object.freeze(C)}else h("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Fr(C,r)}if(N.call(a,"key")){var T=P(r),_=Object.keys(a).filter(function(Da){return Da!=="key"}),ir=_.length>0?"{key: someKey, "+_.join(": ..., ")+": ...}":"{key: someKey}";if(!Dr[T+ir]){var Fa=_.length>0?"{"+_.join(": ..., ")+": ...}":"{}";h(`A props object containing a "key" prop is being spread into JSX:
26
- let props = %s;
27
- <%s {...props} />
28
- React keys must be passed directly to JSX without using spread:
29
- let props = %s;
30
- <%s key={someKey} {...props} />`,ir,T,Fa,T),Dr[T+ir]=!0}}return r===s?Oa(y):Ca(y),y}}function Pa(r,a,e){return Ar(r,a,e,!0)}function ja(r,a,e){return Ar(r,a,e,!1)}var $a=ja,Ta=Pa;W.Fragment=s,W.jsx=$a,W.jsxs=Ta}()),W}process.env.NODE_ENV==="production"?G.exports=Ir():G.exports=Wr();var Yr=G.exports;function cr(o,t=""){let i="";for(const s in o)if(Object.hasOwnProperty.call(o,s)){const c=o[s];i+=`/* ${s} */
31
- `;for(const l in c)if(Object.hasOwnProperty.call(c,l)){const v=c[l];i+=`--${t}-${s}-${l}: ${v};
32
- `}}return i}function lr(o,t){let i="";for(const s in o){const c=o[s];for(const l in c){const v=c[l],g=`${t}-${s}-${l}`;i+=`--${g}: ${v};
33
- `}}return i}function Mr(o,t){let i="";function s(c,l,v="",g="",d=""){if(d){const m=`${v}${d}-${g}-${c}`;i+=`--${m}: ${l};
34
- `}else{const m=`${v}${c}-${g}`;i+=`--${m}: ${l};
35
- `}}for(const c in o){const l=o[c];for(const v in l){const g=l[v];if(typeof g=="object")for(const d in g){const m=g[d],x=`${t}-`;s(v,m,x,c,d)}else{const d=`${t}-`;s(v,g,d,c)}}}return i}function Lr(o,t=""){let i="";function s(c,l,v=""){if(typeof l=="object")for(const g in l){const d=l[g],m=`--${v}-${c}-${g}`;i+=`${m}: ${d};
36
- `}else{const g=`--${v}-${c}`;i+=`${g}: ${l};
37
- `}}for(const c in o){const l=o[c];if(typeof l=="object")s(c,l,`${t}`);else{const v=`--${t}-${c}`;i+=`${v}: ${l};
38
- `}}return i}function Nr(o,t=""){let i="";for(const s in o){const c=o[s];for(const l in c){const v=`--${t}-${s}-${l}`,g=c[l];i+=`${v}: ${g};
39
- `}}return i}function Vr(o,t){let i="";for(const s in o)if(Object.hasOwnProperty.call(o,s)){const c=o[s];s==="default"?i+=`--${t}: ${c};
40
- `:i+=`--${t}-${s}: ${c};
41
- `}return i}const Ur=o=>{const t=document.getElementById(o);if(t)return t;const i=document.createElement("style");return i.id=o,document.head.appendChild(i),i};function ur(o,t){let i="";return Object.keys(o).forEach(s=>{const c=o[s];if(c&&typeof c=="object"){i+=ur(c,`${t}-${s}`);return}i+=`${t}-${s}: ${c};
42
- `}),i}function Jr(o,t){let i="";return o&&(i+=ur(o,t)),i}function Br(o){var x,S,O,j,M,U;if(!o)return;const t=(x=o.colors)!=null&&x.raw?lr(o.colors.raw,"starasia-ui-raw-color"):"",i=(S=o.colors)!=null&&S.computed?lr(o.colors.computed,"starasia-ui-color"):"",s=(O=o.colors)!=null&&O.main?Mr(o.colors.main,"starasia-ui"):"",c=(j=o.colors)!=null&&j.brand?cr(o.colors.brand,"starasia-ui-brand"):"",l=(M=o.colors)!=null&&M.utility?cr(o.colors.utility,"starasia-ui-utility"):"",v=(U=o.colors)!=null&&U.text?Vr(o.colors.text,"starasia-ui-color-text"):"",g=o.metrics?Lr(o.metrics,"starasia-ui"):"",d=o.font?Nr(o.font,"starasia-ui"):"",m=o.components?Jr(o.components,"--starasia-ui"):"";return`
1
+ (function(l,n){typeof exports=="object"&&typeof module<"u"?n(exports,require("react/jsx-runtime"),require("react")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react"],n):(l=typeof globalThis<"u"?globalThis:l||self,n(l["@starasia/theme"]={},l.jsxRuntime,l.React))})(this,function(l,n,g){"use strict";function x(r,a=""){let o="";for(const s in r)if(Object.hasOwnProperty.call(r,s)){const i=r[s];o+=`/* ${s} */
2
+ `;for(const t in i)if(Object.hasOwnProperty.call(i,t)){const c=i[t];o+=`--${a}-${s}-${t}: ${c};
3
+ `}}return o}function y(r,a){let o="";for(const s in r){const i=r[s];for(const t in i){const c=i[t],e=`${a}-${s}-${t}`;o+=`--${e}: ${c};
4
+ `}}return o}function j(r,a){let o="";function s(i,t,c="",e="",u=""){if(u){const b=`${c}${u}-${e}-${i}`;o+=`--${b}: ${t};
5
+ `}else{const b=`${c}${i}-${e}`;o+=`--${b}: ${t};
6
+ `}}for(const i in r){const t=r[i];for(const c in t){const e=t[c];if(typeof e=="object")for(const u in e){const b=e[u],w=`${a}-`;s(c,b,w,i,u)}else{const u=`${a}-`;s(c,e,u,i)}}}return o}function E(r,a=""){let o="";function s(i,t,c=""){if(typeof t=="object")for(const e in t){const u=t[e],b=`--${c}-${i}-${e}`;o+=`${b}: ${u};
7
+ `}else{const e=`--${c}-${i}`;o+=`${e}: ${t};
8
+ `}}for(const i in r){const t=r[i];if(typeof t=="object")s(i,t,`${a}`);else{const c=`--${a}-${i}`;o+=`${c}: ${t};
9
+ `}}return o}function O(r,a=""){let o="";for(const s in r){const i=r[s];for(const t in i){const c=`--${a}-${s}-${t}`,e=i[t];o+=`${c}: ${e};
10
+ `}}return o}function P(r,a){let o="";for(const s in r)if(Object.hasOwnProperty.call(r,s)){const i=r[s];s==="default"?o+=`--${a}: ${i};
11
+ `:o+=`--${a}-${s}: ${i};
12
+ `}return o}const F=r=>{const a=document.getElementById(r);if(a)return a;const o=document.createElement("style");return o.id=r,document.head.appendChild(o),o};function f(r,a){let o="";return Object.keys(r).forEach(s=>{const i=r[s];if(i&&typeof i=="object"){o+=f(i,`${a}-${s}`);return}o+=`${a}-${s}: ${i};
13
+ `}),o}function N(r,a){let o="";return r&&(o+=f(r,a)),o}function M(r){var w,$,k,S,h,C;if(!r)return;const a=(w=r.colors)!=null&&w.raw?y(r.colors.raw,"starasia-ui-raw-color"):"",o=($=r.colors)!=null&&$.computed?y(r.colors.computed,"starasia-ui-color"):"",s=(k=r.colors)!=null&&k.main?j(r.colors.main,"starasia-ui"):"",i=(S=r.colors)!=null&&S.brand?x(r.colors.brand,"starasia-ui-brand"):"",t=(h=r.colors)!=null&&h.utility?x(r.colors.utility,"starasia-ui-utility"):"",c=(C=r.colors)!=null&&C.text?P(r.colors.text,"starasia-ui-color-text"):"",e=r.metrics?E(r.metrics,"starasia-ui"):"",u=r.font?O(r.font,"starasia-ui"):"",b=r.components?N(r.components,"--starasia-ui"):"";return`
43
14
  :root {
44
- ${t}
45
- ${i}
15
+ ${a}
16
+ ${o}
46
17
  ${s}
18
+ ${i}
19
+ ${t}
47
20
  ${c}
48
- ${l}
49
- ${v}
50
- ${g}
51
- ${d}
52
- ${m}
21
+ ${e}
22
+ ${u}
23
+ ${b}
53
24
  }
54
- `}const H=k.createContext({theme:void 0,setTheme:()=>{}}),Kr="starasia-theme-style";function zr({value:o,children:t}){const[i,s]=k.useState(o),c=k.useMemo(()=>i?JSON.stringify(i):"",[i]),l=k.useRef(Ur(Kr));k.useEffect(()=>{if(c){const g=Br(JSON.parse(c));g&&(l!=null&&l.current)&&(l.current.textContent=g)}},[c]);const v=g=>{g&&s(g)};return Yr.jsx(H.Provider,{value:{theme:i,setTheme:v},children:t})}const X={colors:{raw:{white:{900:"255, 255, 255"},black:{900:"0, 0, 0"},blue:{50:"227, 242, 253",100:"187, 222, 251",200:"144, 202, 249",300:"100, 181, 246",400:"66, 165, 245",500:"33, 150, 243",600:"30, 136, 229",700:"25, 118, 210",800:"21, 101, 192",900:"13, 71, 161"},pink:{50:"251, 219, 241",100:"248, 183, 228",200:"245, 147, 215",300:"241, 111, 202",400:"238, 75, 189",500:"235, 39, 176",600:"215, 19, 157",700:"179, 16, 131",800:"143, 13, 104",900:"107, 9, 78"},purple:{50:"233, 222, 245",100:"212, 189, 235",200:"190, 156, 226",300:"169, 123, 216",400:"147, 90, 207",500:"126, 57, 197",600:"105, 47, 164",700:"84, 38, 131",800:"63, 28, 98",900:"42, 19, 65"},gray:{50:"255, 254, 255",100:"239, 243, 248",200:"201, 206, 204",300:"174, 182, 178",400:"147, 158, 153",500:"120, 134, 127",600:"96, 107, 102",700:"72, 80, 76",800:"48, 53, 51",900:"24, 26, 25"},red:{50:"255, 240, 243",100:"255, 204, 213",200:"255, 179, 193",300:"255, 143, 163",400:"255, 117, 143",500:"255, 77, 109",600:"201, 24, 74",700:"164, 19, 60",800:"128, 15, 47",900:"89, 13, 34"},orange:{50:"250, 246, 224",100:"255, 245, 193",200:"255, 225, 139",300:"255, 203, 105",400:"234, 183, 84",500:"210, 160, 58",600:"179, 130, 10",700:"152, 104, 0",800:"126, 80, 0",900:"97, 52, 0"},aloha:{50:"219, 247, 242",100:"184, 240, 230",200:"149, 232, 218",300:"114, 225, 206",400:"79, 218, 194",500:"44, 210, 182",600:"36, 175, 152",700:"29, 140, 121",800:"22, 105, 91",900:"14, 70, 60"},green:{50:"220, 246, 234",100:"186, 238, 214",200:"151, 230, 193",300:"117, 222, 173",400:"82, 214, 152",500:"48, 206, 132",600:"40, 172, 110",700:"32, 137, 88",800:"24, 103, 66",900:"16, 68, 44"}},computed:{white:{900:"rgba(var(--starasia-ui-raw-color-white-900), 1)"},black:{900:"rgba(var(--starasia-ui-raw-color-black-900), 1)"},blue:{50:"rgba(var(--starasia-ui-raw-color-blue-50), 1)",100:"rgba(var(--starasia-ui-raw-color-blue-100), 1)",200:"rgba(var(--starasia-ui-raw-color-blue-200), 1)",300:"rgba(var(--starasia-ui-raw-color-blue-300), 1)",400:"rgba(var(--starasia-ui-raw-color-blue-400), 1)",500:"rgba(var(--starasia-ui-raw-color-blue-500), 1)",600:"rgba(var(--starasia-ui-raw-color-blue-600), 1)",700:"rgba(var(--starasia-ui-raw-color-blue-700), 1)",800:"rgba(var(--starasia-ui-raw-color-blue-800), 1)",900:"rgba(var(--starasia-ui-raw-color-blue-900), 1)"},pink:{50:"rgba(var(--starasia-ui-raw-color-pink-50), 1)",100:"rgba(var(--starasia-ui-raw-color-pink-100), 1)",200:"rgba(var(--starasia-ui-raw-color-pink-200), 1)",300:"rgba(var(--starasia-ui-raw-color-pink-300), 1)",400:"rgba(var(--starasia-ui-raw-color-pink-400), 1)",500:"rgba(var(--starasia-ui-raw-color-pink-500), 1)",600:"rgba(var(--starasia-ui-raw-color-pink-600), 1)",700:"rgba(var(--starasia-ui-raw-color-pink-700), 1)",800:"rgba(var(--starasia-ui-raw-color-pink-800), 1)",900:"rgba(var(--starasia-ui-raw-color-pink-900), 1)"},purple:{50:"rgba(var(--starasia-ui-raw-color-purple-50), 1)",100:"rgba(var(--starasia-ui-raw-color-purple-100), 1)",200:"rgba(var(--starasia-ui-raw-color-purple-200), 1)",300:"rgba(var(--starasia-ui-raw-color-purple-300), 1)",400:"rgba(var(--starasia-ui-raw-color-purple-400), 1)",500:"rgba(var(--starasia-ui-raw-color-purple-500), 1)",600:"rgba(var(--starasia-ui-raw-color-purple-600), 1)",700:"rgba(var(--starasia-ui-raw-color-purple-700), 1)",800:"rgba(var(--starasia-ui-raw-color-purple-800), 1)",900:"rgba(var(--starasia-ui-raw-color-purple-900), 1)"},gray:{50:"rgba(var(--starasia-ui-raw-color-gray-50), 1)",100:"rgba(var(--starasia-ui-raw-color-gray-100), 1)",200:"rgba(var(--starasia-ui-raw-color-gray-200), 1)",300:"rgba(var(--starasia-ui-raw-color-gray-300), 1)",400:"rgba(var(--starasia-ui-raw-color-gray-400), 1)",500:"rgba(var(--starasia-ui-raw-color-gray-500), 1)",600:"rgba(var(--starasia-ui-raw-color-gray-600), 1)",700:"rgba(var(--starasia-ui-raw-color-gray-700), 1)",800:"rgba(var(--starasia-ui-raw-color-gray-800), 1)",900:"rgba(var(--starasia-ui-raw-color-gray-900), 1)"},red:{50:"rgba(var(--starasia-ui-raw-color-red-50), 1)",100:"rgba(var(--starasia-ui-raw-color-red-100), 1)",200:"rgba(var(--starasia-ui-raw-color-red-200), 1)",300:"rgba(var(--starasia-ui-raw-color-red-300), 1)",400:"rgba(var(--starasia-ui-raw-color-red-400), 1)",500:"rgba(var(--starasia-ui-raw-color-red-500), 1)",600:"rgba(var(--starasia-ui-raw-color-red-600), 1)",700:"rgba(var(--starasia-ui-raw-color-red-700), 1)",800:"rgba(var(--starasia-ui-raw-color-red-800), 1)",900:"rgba(var(--starasia-ui-raw-color-red-900), 1)"},orange:{50:"rgba(var(--starasia-ui-raw-color-orange-50), 1)",100:"rgba(var(--starasia-ui-raw-color-orange-100), 1)",200:"rgba(var(--starasia-ui-raw-color-orange-200), 1)",300:"rgba(var(--starasia-ui-raw-color-orange-300), 1)",400:"rgba(var(--starasia-ui-raw-color-orange-400), 1)",500:"rgba(var(--starasia-ui-raw-color-orange-500), 1)",600:"rgba(var(--starasia-ui-raw-color-orange-600), 1)",700:"rgba(var(--starasia-ui-raw-color-orange-700), 1)",800:"rgba(var(--starasia-ui-raw-color-orange-800), 1)",900:"rgba(var(--starasia-ui-raw-color-orange-900), 1)"},aloha:{50:"rgba(var(--starasia-ui-raw-color-aloha-50), 1)",100:"rgba(var(--starasia-ui-raw-color-aloha-100), 1)",200:"rgba(var(--starasia-ui-raw-color-aloha-200), 1)",300:"rgba(var(--starasia-ui-raw-color-aloha-300), 1)",400:"rgba(var(--starasia-ui-raw-color-aloha-400), 1)",500:"rgba(var(--starasia-ui-raw-color-aloha-500), 1)",600:"rgba(var(--starasia-ui-raw-color-aloha-600), 1)",700:"rgba(var(--starasia-ui-raw-color-aloha-700), 1)",800:"rgba(var(--starasia-ui-raw-color-aloha-800), 1)",900:"rgba(var(--starasia-ui-raw-color-aloha-900), 1)"},green:{50:"rgba(var(--starasia-ui-raw-color-green-50), 1)",100:"rgba(var(--starasia-ui-raw-color-green-100), 1)",200:"rgba(var(--starasia-ui-raw-color-green-200), 1)",300:"rgba(var(--starasia-ui-raw-color-green-300), 1)",400:"rgba(var(--starasia-ui-raw-color-green-400), 1)",500:"rgba(var(--starasia-ui-raw-color-green-500), 1)",600:"rgba(var(--starasia-ui-raw-color-green-600), 1)",700:"rgba(var(--starasia-ui-raw-color-green-700), 1)",800:"rgba(var(--starasia-ui-raw-color-green-800), 1)",900:"rgba(var(--starasia-ui-raw-color-green-900), 1)"}},main:{primary:{"background-color":"rgb(var(--starasia-ui-raw-color-blue-700))","text-color":"rgb(255, 255, 255)","border-color":"rgb(var(--starasia-ui-raw-color-blue-700))",hover:{"background-color":"rgba(var(--starasia-ui-raw-color-blue-700), 0.9)","border-color":"rgba(var(--starasia-ui-raw-color-blue-700), 0.9)","text-color":"rgb(255, 255, 255)"},active:{"background-color":"rgb(var(--starasia-ui-raw-color-blue-800))","border-color":"rgb(var(--starasia-ui-raw-color-blue-800))","text-color":"rgb(255, 255, 255)",shadow:"0px 0px 0px 3px rgba(var(--starasia-ui-raw-color-blue-300), 0.28)"},disable:{"background-color":"rgba(var(--starasia-ui-raw-color-gray-200), 0.68)","border-color":"rgba(var(--starasia-ui-raw-color-gray-200), 0.68)","text-color":"rgba(var(--starasia-ui-raw-color-gray-500), 0.62)"}},secondary:{"background-color":"rgb(var(--starasia-ui-raw-color-gray-50))","text-color":"rgb(72, 80, 76)","border-color":"rgba(120, 134, 127, 0.2)",hover:{"background-color":"rgba(var(--starasia-ui-raw-color-gray-100), 0.9)","border-color":"rgba(120, 134, 127, 0.2)","text-color":"rgb(72, 80, 76)",shadow:"0px 0px 0px -1px #f0f0f0"},active:{"background-color":"rgba(var(--starasia-ui-raw-color-gray-200), 0.1)","border-color":"rgba(120, 134, 127, 0.2)","text-color":"rgb(72, 80, 76)",shadow:"0px 0px 0px 3px rgba(var(--starasia-ui-raw-color-gray-200), 0.28), 0px 0px 0px -1px #f0f0f0"},disable:{"background-color":"rgba(var(--starasia-ui-raw-color-gray-200), 0.68)","border-color":"rgba(var(--starasia-ui-raw-color-gray-200), 0.68)","text-color":"rgba(var(--starasia-ui-raw-color-gray-500), 0.62)"}},tertiary:{"background-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.21)","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))","border-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.21)",hover:{"background-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.3)","border-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.3)","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))",shadow:"0px 0px 0px -1px #f0f0f0"},active:{"background-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.46)","border-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.46)","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))",shadow:"0px 0px 0px 3px rgba(var(--starasia-ui-raw-color-blue-300), 0.28)"},disable:{"background-color":"rgba(var(--starasia-ui-raw-color-blue-200), 0.8)","border-color":"rgba(var(--starasia-ui-raw-color-blue-200), 0.8)","text-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.5)"}},quaternary:{"background-color":"rgba(255, 255, 255, 0)","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))","border-color":"rgb(var(--starasia-ui-raw-color-blue-700))",hover:{"background-color":"rgba(255, 255, 255, 0)","border-color":"rgba(var(--starasia-ui-raw-color-blue-700), 0.9)","text-color":"rgba(var(--starasia-ui-raw-color-blue-700), 0.9)"},active:{"background-color":"rgb(255, 255, 255)","border-color":"rgb(var(--starasia-ui-raw-color-blue-700))","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))",shadow:"0px 0px 0px 3px rgba(var(--starasia-ui-raw-color-blue-300), 0.28)"},disable:{"background-color":"rgba(255, 255, 255, 0)","border-color":"rgba(var(--starasia-ui-raw-color-gray-500), 0.62)","text-color":"rgba(var(--starasia-ui-raw-color-gray-500), 0.62)"}},link:{"background-color":"rgba(255, 255, 255, 0)","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))","border-color":"rgba(255, 255, 255, 0)",hover:{"background-color":"rgba(255, 255, 255, 0)","border-color":"rgba(255, 255, 255, 0)","text-color":"rgba(var(--starasia-ui-raw-color-blue-900), 0.9)"},active:{"background-color":"rgba(255, 255, 255, 0)","border-color":"rgba(255, 255, 255, 0)","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))"},disable:{"background-color":"rgba(255, 255, 255, 0)","border-color":"rgba(255, 255, 255, 0)","text-color":"rgba(var(--starasia-ui-raw-color-gray-500), 0.62)"}},success:{"background-color":"rgb(var(--starasia-ui-raw-color-green-500))","text-color":"rgb(255, 255, 255)","border-color":"rgb(var(--starasia-ui-raw-color-green-500))",hover:{"background-color":"rgba(var(--starasia-ui-raw-color-green-500), 0.9)","border-color":"rgba(var(--starasia-ui-raw-color-green-500), 0.9)","text-color":"rgb(255, 255, 255)"},active:{"background-color":"rgba(var(--starasia-ui-raw-color-green-600), 0.75)","border-color":"rgba(var(--starasia-ui-raw-color-green-600), 0.75)","text-color":"rgb(255, 255, 255)",shadow:"0px 0px 0px 3px rgba(var(--starasia-ui-raw-color-green-800), 0.28)"},disable:{"background-color":"rgb(var(--starasia-ui-raw-color-gray-400))","border-color":"rgb(var(--starasia-ui-raw-color-gray-400))","text-color":"rgba(120, 134, 127, 0.62)"}},danger:{"background-color":"rgb(var(--starasia-ui-raw-color-red-600))","text-color":"rgb(255, 255, 255)","border-color":"rgb(var(--starasia-ui-raw-color-red-600))",hover:{"background-color":"rgba(var(--starasia-ui-raw-color-red-600), 0.9)","border-color":"rgba(var(--starasia-ui-raw-color-red-600), 0.9)","text-color":"rgb(255, 255, 255)"},active:{"background-color":"rgba(var(--starasia-ui-raw-color-red-800), 0.68)","border-color":"rgba(var(--starasia-ui-raw-color-red-800), 0.68)","text-color":"rgb(255, 255, 255)",shadow:"0px 0px 0px 3px rgba(var(--starasia-ui-raw-color-red-800), 0.28)"},disable:{"background-color":"rgb(var(--starasia-ui-raw-color-red-300))","border-color":"rgb(var(--starasia-ui-raw-color-red-300))","text-color":"rgba(201, 24, 74, 0.3)"}},warning:{"background-color":"rgb(var(--starasia-ui-raw-color-orange-600))","text-color":"rgb(255, 255, 255)","border-color":"rgb(var(--starasia-ui-raw-color-orange-600))",hover:{"background-color":"rgba(var(--starasia-ui-raw-color-orange-600), 0.9)","border-color":"rgba(var(--starasia-ui-raw-color-orange-600), 0.9)","text-color":"rgb(255, 255, 255)"},active:{"background-color":"rgba(var(--starasia-ui-raw-color-orange-800), 0.75)","border-color":"rgba(var(--starasia-ui-raw-color-orange-800), 0.75)","text-color":"rgb(255, 255, 255)",shadow:"0px 0px 0px 2px rgba(var(--starasia-ui-raw-color-orange-800), 0.28)"},disable:{"background-color":"rgb(var(--starasia-ui-raw-color-orange-300))","border-color":"rgb(var(--starasia-ui-raw-color-orange-300))","text-color":"rgb(var(--starasia-ui-raw-color-orange-600))"}}},brand:{primary:{default:"var(--starasia-ui-color-blue-700)",secondary:"var(--starasia-ui-color-blue-300)",tertiary:"var(--starasia-ui-color-blue-50)"},secondary:{default:"var(--starasia-ui-color-pink-700)",secondary:"var(--starasia-ui-color-pink-300)",tertiary:"var(--starasia-ui-color-pink-50)"}},text:{default:"var(--starasia-ui-color-gray-900)",secondary:"var(--starasia-ui-color-gray-700)",tertiary:"var(--starasia-ui-color-gray-500)",disable:"var(--starasia-ui-color-gray-200)",white:"var(--starasia-ui-color-white-900)"},utility:{success:{default:"var(--starasia-ui-color-green-600)",secondary:"var(--starasia-ui-color-green-200)",tertiary:"var(--starasia-ui-color-green-50)"},danger:{default:"var(--starasia-ui-color-red-600)",secondary:"var(--starasia-ui-color-red-200)",tertiary:"var(--starasia-ui-color-red-50)"},warning:{default:"var(--starasia-ui-color-orange-600)",secondary:"var(--starasia-ui-color-orange-200)",tertiary:"var(--starasia-ui-color-orange-50)"},information:{default:"var(--starasia-ui-color-blue-600)",secondary:"var(--starasia-ui-color-blue-200)",tertiary:"var(--starasia-ui-color-blue-50)"},dark:{default:"var(--starasia-ui-color-gray-600)",secondary:"var(--starasia-ui-color-gray-200)",tertiary:"var(--starasia-ui-color-gray-50)"},fill:{default:"rgba(120, 134, 127, 0.2)",secondary:"rgba(120, 134, 127, 0.16)",tertiary:"rgba(120, 134, 127, 0.1)"}}},metrics:{radii:{none:"0",xs:"0.25rem",sm:"0.375rem",md:"0.5rem",lg:"0.75rem",xl:"0.875rem","2xl":"1rem",full:"12rem"},spacing:{0:"0rem",1:"0.063rem",2:"0.125rem",4:"0.25rem",6:"0.375rem",8:"0.5rem",10:"0.625rem",12:"0.75rem",14:"0.875rem",16:"1rem",18:"1.125rem",20:"1.25rem",24:"1.5rem",28:"1.75rem",32:"2rem",36:"2.25rem",40:"2.5rem",48:"3rem",64:"4rem",80:"5rem",96:"6rem",128:"8rem",160:"10rem",192:"12rem",224:"14rem",256:"16rem",xs:"0.25rem",sm:"0.5rem",md:"0.75rem",lg:"1rem",xl:"1.5rem","2xl":"2rem","3xl":"4rem"},border:{default:"1px solid var(--starasia-ui-color-border)"},shadows:{sm:"0 1px 2px 0 rgb(0 0 0 / 0.05)",md:"0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1)",lg:"0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1)",xl:"0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1)","2xl":"0 25px 50px -12px rgb(0 0 0 / 0.25)",inner:"inset 0 2px 4px 0 rgb(0 0 0 / 0.05)",card:"0px 4px 35px 0px rgba(112, 144, 176, 0.25)"}},font:{fontSizes:{xs:"0.625rem",sm:"0.75rem",md:"0.875rem",lg:"1rem",xl:"1.125rem","2xl":"1.25rem","3xl":"1.5rem","4xl":"2rem","5xl":"2.25rem","6xl":"3rem"},fontWeights:{hairline:100,thin:100,light:200,normal:300,medium:400,semibold:500,bold:600,extrabold:700,black:800},lineHeights:{3:"0.75rem",4:"1rem",5:"1.25rem",6:"1.5rem",7:"1.75rem",8:"1.875rem",9:"2.25rem",10:"2.5rem",none:1,tight:1.25,snug:1.375,normal:1.5,relaxed:1.625,loose:2}}},br=(o,t)=>{const i={};return Object.keys(o).forEach(s=>{if(o!=null&&o[s]&&typeof(o==null?void 0:o[s])=="object"){i[s]={...o==null?void 0:o[s],...t==null?void 0:t[s],...br(o==null?void 0:o[s],t==null?void 0:t[s])};return}i[s]=(t==null?void 0:t[s])||(o==null?void 0:o[s])}),i};function Y(){const o=k.useContext(H),t=k.useMemo(()=>({...X,...o.theme,...br(X,o.theme)}),[o.theme,X]);return{...o,theme:t}}function Gr(){const{theme:o}=Y();return o.colors}function Hr(){var t;const{theme:o}=Y();return(t=o.metrics)==null?void 0:t.spacing}function Xr(){var t;const{theme:o}=Y();return(t=o.metrics)==null?void 0:t.radii}function qr(){var t;const{theme:o}=Y();return(t=o==null?void 0:o.metrics)==null?void 0:t.shadows}function Zr(o){return o}R.ThemeContext=H,R.ThemeProvider=zr,R.createTheme=Zr,R.useColor=Gr,R.useRadius=Xr,R.useShadow=qr,R.useSpacing=Hr,R.useTheme=Y,Object.defineProperty(R,Symbol.toStringTag,{value:"Module"})});
25
+ `}const d=g.createContext({theme:void 0,setTheme:()=>{}}),D="starasia-theme-style";function R({value:r,children:a}){const[o,s]=g.useState(r),i=g.useMemo(()=>o?JSON.stringify(o):"",[o]),t=g.useRef(F(D));g.useEffect(()=>{if(i){const e=M(JSON.parse(i));e&&(t!=null&&t.current)&&(t.current.textContent=e)}},[i]);const c=e=>{e&&s(e)};return n.jsx(d.Provider,{value:{theme:o,setTheme:c},children:a})}const p={colors:{raw:{white:{900:"255, 255, 255"},black:{900:"0, 0, 0"},blue:{50:"227, 242, 253",100:"187, 222, 251",200:"144, 202, 249",300:"100, 181, 246",400:"66, 165, 245",500:"33, 150, 243",600:"30, 136, 229",700:"25, 118, 210",800:"21, 101, 192",900:"13, 71, 161"},pink:{50:"251, 219, 241",100:"248, 183, 228",200:"245, 147, 215",300:"241, 111, 202",400:"238, 75, 189",500:"235, 39, 176",600:"215, 19, 157",700:"179, 16, 131",800:"143, 13, 104",900:"107, 9, 78"},purple:{50:"233, 222, 245",100:"212, 189, 235",200:"190, 156, 226",300:"169, 123, 216",400:"147, 90, 207",500:"126, 57, 197",600:"105, 47, 164",700:"84, 38, 131",800:"63, 28, 98",900:"42, 19, 65"},gray:{50:"255, 254, 255",100:"239, 243, 248",200:"201, 206, 204",300:"174, 182, 178",400:"147, 158, 153",500:"120, 134, 127",600:"96, 107, 102",700:"72, 80, 76",800:"48, 53, 51",900:"24, 26, 25"},red:{50:"255, 240, 243",100:"255, 204, 213",200:"255, 179, 193",300:"255, 143, 163",400:"255, 117, 143",500:"255, 77, 109",600:"201, 24, 74",700:"164, 19, 60",800:"128, 15, 47",900:"89, 13, 34"},orange:{50:"250, 246, 224",100:"255, 245, 193",200:"255, 225, 139",300:"255, 203, 105",400:"234, 183, 84",500:"210, 160, 58",600:"179, 130, 10",700:"152, 104, 0",800:"126, 80, 0",900:"97, 52, 0"},aloha:{50:"219, 247, 242",100:"184, 240, 230",200:"149, 232, 218",300:"114, 225, 206",400:"79, 218, 194",500:"44, 210, 182",600:"36, 175, 152",700:"29, 140, 121",800:"22, 105, 91",900:"14, 70, 60"},green:{50:"220, 246, 234",100:"186, 238, 214",200:"151, 230, 193",300:"117, 222, 173",400:"82, 214, 152",500:"48, 206, 132",600:"40, 172, 110",700:"32, 137, 88",800:"24, 103, 66",900:"16, 68, 44"}},computed:{white:{900:"rgba(var(--starasia-ui-raw-color-white-900), 1)"},black:{900:"rgba(var(--starasia-ui-raw-color-black-900), 1)"},blue:{50:"rgba(var(--starasia-ui-raw-color-blue-50), 1)",100:"rgba(var(--starasia-ui-raw-color-blue-100), 1)",200:"rgba(var(--starasia-ui-raw-color-blue-200), 1)",300:"rgba(var(--starasia-ui-raw-color-blue-300), 1)",400:"rgba(var(--starasia-ui-raw-color-blue-400), 1)",500:"rgba(var(--starasia-ui-raw-color-blue-500), 1)",600:"rgba(var(--starasia-ui-raw-color-blue-600), 1)",700:"rgba(var(--starasia-ui-raw-color-blue-700), 1)",800:"rgba(var(--starasia-ui-raw-color-blue-800), 1)",900:"rgba(var(--starasia-ui-raw-color-blue-900), 1)"},pink:{50:"rgba(var(--starasia-ui-raw-color-pink-50), 1)",100:"rgba(var(--starasia-ui-raw-color-pink-100), 1)",200:"rgba(var(--starasia-ui-raw-color-pink-200), 1)",300:"rgba(var(--starasia-ui-raw-color-pink-300), 1)",400:"rgba(var(--starasia-ui-raw-color-pink-400), 1)",500:"rgba(var(--starasia-ui-raw-color-pink-500), 1)",600:"rgba(var(--starasia-ui-raw-color-pink-600), 1)",700:"rgba(var(--starasia-ui-raw-color-pink-700), 1)",800:"rgba(var(--starasia-ui-raw-color-pink-800), 1)",900:"rgba(var(--starasia-ui-raw-color-pink-900), 1)"},purple:{50:"rgba(var(--starasia-ui-raw-color-purple-50), 1)",100:"rgba(var(--starasia-ui-raw-color-purple-100), 1)",200:"rgba(var(--starasia-ui-raw-color-purple-200), 1)",300:"rgba(var(--starasia-ui-raw-color-purple-300), 1)",400:"rgba(var(--starasia-ui-raw-color-purple-400), 1)",500:"rgba(var(--starasia-ui-raw-color-purple-500), 1)",600:"rgba(var(--starasia-ui-raw-color-purple-600), 1)",700:"rgba(var(--starasia-ui-raw-color-purple-700), 1)",800:"rgba(var(--starasia-ui-raw-color-purple-800), 1)",900:"rgba(var(--starasia-ui-raw-color-purple-900), 1)"},gray:{50:"rgba(var(--starasia-ui-raw-color-gray-50), 1)",100:"rgba(var(--starasia-ui-raw-color-gray-100), 1)",200:"rgba(var(--starasia-ui-raw-color-gray-200), 1)",300:"rgba(var(--starasia-ui-raw-color-gray-300), 1)",400:"rgba(var(--starasia-ui-raw-color-gray-400), 1)",500:"rgba(var(--starasia-ui-raw-color-gray-500), 1)",600:"rgba(var(--starasia-ui-raw-color-gray-600), 1)",700:"rgba(var(--starasia-ui-raw-color-gray-700), 1)",800:"rgba(var(--starasia-ui-raw-color-gray-800), 1)",900:"rgba(var(--starasia-ui-raw-color-gray-900), 1)"},red:{50:"rgba(var(--starasia-ui-raw-color-red-50), 1)",100:"rgba(var(--starasia-ui-raw-color-red-100), 1)",200:"rgba(var(--starasia-ui-raw-color-red-200), 1)",300:"rgba(var(--starasia-ui-raw-color-red-300), 1)",400:"rgba(var(--starasia-ui-raw-color-red-400), 1)",500:"rgba(var(--starasia-ui-raw-color-red-500), 1)",600:"rgba(var(--starasia-ui-raw-color-red-600), 1)",700:"rgba(var(--starasia-ui-raw-color-red-700), 1)",800:"rgba(var(--starasia-ui-raw-color-red-800), 1)",900:"rgba(var(--starasia-ui-raw-color-red-900), 1)"},orange:{50:"rgba(var(--starasia-ui-raw-color-orange-50), 1)",100:"rgba(var(--starasia-ui-raw-color-orange-100), 1)",200:"rgba(var(--starasia-ui-raw-color-orange-200), 1)",300:"rgba(var(--starasia-ui-raw-color-orange-300), 1)",400:"rgba(var(--starasia-ui-raw-color-orange-400), 1)",500:"rgba(var(--starasia-ui-raw-color-orange-500), 1)",600:"rgba(var(--starasia-ui-raw-color-orange-600), 1)",700:"rgba(var(--starasia-ui-raw-color-orange-700), 1)",800:"rgba(var(--starasia-ui-raw-color-orange-800), 1)",900:"rgba(var(--starasia-ui-raw-color-orange-900), 1)"},aloha:{50:"rgba(var(--starasia-ui-raw-color-aloha-50), 1)",100:"rgba(var(--starasia-ui-raw-color-aloha-100), 1)",200:"rgba(var(--starasia-ui-raw-color-aloha-200), 1)",300:"rgba(var(--starasia-ui-raw-color-aloha-300), 1)",400:"rgba(var(--starasia-ui-raw-color-aloha-400), 1)",500:"rgba(var(--starasia-ui-raw-color-aloha-500), 1)",600:"rgba(var(--starasia-ui-raw-color-aloha-600), 1)",700:"rgba(var(--starasia-ui-raw-color-aloha-700), 1)",800:"rgba(var(--starasia-ui-raw-color-aloha-800), 1)",900:"rgba(var(--starasia-ui-raw-color-aloha-900), 1)"},green:{50:"rgba(var(--starasia-ui-raw-color-green-50), 1)",100:"rgba(var(--starasia-ui-raw-color-green-100), 1)",200:"rgba(var(--starasia-ui-raw-color-green-200), 1)",300:"rgba(var(--starasia-ui-raw-color-green-300), 1)",400:"rgba(var(--starasia-ui-raw-color-green-400), 1)",500:"rgba(var(--starasia-ui-raw-color-green-500), 1)",600:"rgba(var(--starasia-ui-raw-color-green-600), 1)",700:"rgba(var(--starasia-ui-raw-color-green-700), 1)",800:"rgba(var(--starasia-ui-raw-color-green-800), 1)",900:"rgba(var(--starasia-ui-raw-color-green-900), 1)"}},main:{primary:{"background-color":"rgb(var(--starasia-ui-raw-color-blue-700))","text-color":"rgb(255, 255, 255)","border-color":"rgb(var(--starasia-ui-raw-color-blue-700))",hover:{"background-color":"rgba(var(--starasia-ui-raw-color-blue-700), 0.9)","border-color":"rgba(var(--starasia-ui-raw-color-blue-700), 0.9)","text-color":"rgb(255, 255, 255)"},active:{"background-color":"rgb(var(--starasia-ui-raw-color-blue-800))","border-color":"rgb(var(--starasia-ui-raw-color-blue-800))","text-color":"rgb(255, 255, 255)",shadow:"0px 0px 0px 3px rgba(var(--starasia-ui-raw-color-blue-300), 0.28)"},disable:{"background-color":"rgba(var(--starasia-ui-raw-color-gray-200), 0.68)","border-color":"rgba(var(--starasia-ui-raw-color-gray-200), 0.68)","text-color":"rgba(var(--starasia-ui-raw-color-gray-500), 0.62)"}},secondary:{"background-color":"rgb(var(--starasia-ui-raw-color-gray-50))","text-color":"rgb(72, 80, 76)","border-color":"rgba(120, 134, 127, 0.2)",hover:{"background-color":"rgba(var(--starasia-ui-raw-color-gray-100), 0.9)","border-color":"rgba(120, 134, 127, 0.2)","text-color":"rgb(72, 80, 76)",shadow:"0px 0px 0px -1px #f0f0f0"},active:{"background-color":"rgba(var(--starasia-ui-raw-color-gray-200), 0.1)","border-color":"rgba(120, 134, 127, 0.2)","text-color":"rgb(72, 80, 76)",shadow:"0px 0px 0px 3px rgba(var(--starasia-ui-raw-color-gray-200), 0.28), 0px 0px 0px -1px #f0f0f0"},disable:{"background-color":"rgba(var(--starasia-ui-raw-color-gray-200), 0.68)","border-color":"rgba(var(--starasia-ui-raw-color-gray-200), 0.68)","text-color":"rgba(var(--starasia-ui-raw-color-gray-500), 0.62)"}},tertiary:{"background-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.21)","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))","border-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.21)",hover:{"background-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.3)","border-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.3)","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))",shadow:"0px 0px 0px -1px #f0f0f0"},active:{"background-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.46)","border-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.46)","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))",shadow:"0px 0px 0px 3px rgba(var(--starasia-ui-raw-color-blue-300), 0.28)"},disable:{"background-color":"rgba(var(--starasia-ui-raw-color-blue-200), 0.8)","border-color":"rgba(var(--starasia-ui-raw-color-blue-200), 0.8)","text-color":"rgba(var(--starasia-ui-raw-color-blue-300), 0.5)"}},quaternary:{"background-color":"rgba(255, 255, 255, 0)","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))","border-color":"rgb(var(--starasia-ui-raw-color-blue-700))",hover:{"background-color":"rgba(255, 255, 255, 0)","border-color":"rgba(var(--starasia-ui-raw-color-blue-700), 0.9)","text-color":"rgba(var(--starasia-ui-raw-color-blue-700), 0.9)"},active:{"background-color":"rgb(255, 255, 255)","border-color":"rgb(var(--starasia-ui-raw-color-blue-700))","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))",shadow:"0px 0px 0px 3px rgba(var(--starasia-ui-raw-color-blue-300), 0.28)"},disable:{"background-color":"rgba(255, 255, 255, 0)","border-color":"rgba(var(--starasia-ui-raw-color-gray-500), 0.62)","text-color":"rgba(var(--starasia-ui-raw-color-gray-500), 0.62)"}},link:{"background-color":"rgba(255, 255, 255, 0)","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))","border-color":"rgba(255, 255, 255, 0)",hover:{"background-color":"rgba(255, 255, 255, 0)","border-color":"rgba(255, 255, 255, 0)","text-color":"rgba(var(--starasia-ui-raw-color-blue-900), 0.9)"},active:{"background-color":"rgba(255, 255, 255, 0)","border-color":"rgba(255, 255, 255, 0)","text-color":"rgb(var(--starasia-ui-raw-color-blue-700))"},disable:{"background-color":"rgba(255, 255, 255, 0)","border-color":"rgba(255, 255, 255, 0)","text-color":"rgba(var(--starasia-ui-raw-color-gray-500), 0.62)"}},success:{"background-color":"rgb(var(--starasia-ui-raw-color-green-500))","text-color":"rgb(255, 255, 255)","border-color":"rgb(var(--starasia-ui-raw-color-green-500))",hover:{"background-color":"rgba(var(--starasia-ui-raw-color-green-500), 0.9)","border-color":"rgba(var(--starasia-ui-raw-color-green-500), 0.9)","text-color":"rgb(255, 255, 255)"},active:{"background-color":"rgba(var(--starasia-ui-raw-color-green-600), 0.75)","border-color":"rgba(var(--starasia-ui-raw-color-green-600), 0.75)","text-color":"rgb(255, 255, 255)",shadow:"0px 0px 0px 3px rgba(var(--starasia-ui-raw-color-green-800), 0.28)"},disable:{"background-color":"rgb(var(--starasia-ui-raw-color-gray-400))","border-color":"rgb(var(--starasia-ui-raw-color-gray-400))","text-color":"rgba(120, 134, 127, 0.62)"}},danger:{"background-color":"rgb(var(--starasia-ui-raw-color-red-600))","text-color":"rgb(255, 255, 255)","border-color":"rgb(var(--starasia-ui-raw-color-red-600))",hover:{"background-color":"rgba(var(--starasia-ui-raw-color-red-600), 0.9)","border-color":"rgba(var(--starasia-ui-raw-color-red-600), 0.9)","text-color":"rgb(255, 255, 255)"},active:{"background-color":"rgba(var(--starasia-ui-raw-color-red-800), 0.68)","border-color":"rgba(var(--starasia-ui-raw-color-red-800), 0.68)","text-color":"rgb(255, 255, 255)",shadow:"0px 0px 0px 3px rgba(var(--starasia-ui-raw-color-red-800), 0.28)"},disable:{"background-color":"rgb(var(--starasia-ui-raw-color-red-300))","border-color":"rgb(var(--starasia-ui-raw-color-red-300))","text-color":"rgba(201, 24, 74, 0.3)"}},warning:{"background-color":"rgb(var(--starasia-ui-raw-color-orange-600))","text-color":"rgb(255, 255, 255)","border-color":"rgb(var(--starasia-ui-raw-color-orange-600))",hover:{"background-color":"rgba(var(--starasia-ui-raw-color-orange-600), 0.9)","border-color":"rgba(var(--starasia-ui-raw-color-orange-600), 0.9)","text-color":"rgb(255, 255, 255)"},active:{"background-color":"rgba(var(--starasia-ui-raw-color-orange-800), 0.75)","border-color":"rgba(var(--starasia-ui-raw-color-orange-800), 0.75)","text-color":"rgb(255, 255, 255)",shadow:"0px 0px 0px 2px rgba(var(--starasia-ui-raw-color-orange-800), 0.28)"},disable:{"background-color":"rgb(var(--starasia-ui-raw-color-orange-300))","border-color":"rgb(var(--starasia-ui-raw-color-orange-300))","text-color":"rgb(var(--starasia-ui-raw-color-orange-600))"}}},brand:{primary:{default:"var(--starasia-ui-color-blue-700)",secondary:"var(--starasia-ui-color-blue-300)",tertiary:"var(--starasia-ui-color-blue-50)"},secondary:{default:"var(--starasia-ui-color-pink-700)",secondary:"var(--starasia-ui-color-pink-300)",tertiary:"var(--starasia-ui-color-pink-50)"}},text:{default:"var(--starasia-ui-color-gray-900)",secondary:"var(--starasia-ui-color-gray-700)",tertiary:"var(--starasia-ui-color-gray-500)",disable:"var(--starasia-ui-color-gray-200)",white:"var(--starasia-ui-color-white-900)"},utility:{success:{default:"var(--starasia-ui-color-green-600)",secondary:"var(--starasia-ui-color-green-200)",tertiary:"var(--starasia-ui-color-green-50)"},danger:{default:"var(--starasia-ui-color-red-600)",secondary:"var(--starasia-ui-color-red-200)",tertiary:"var(--starasia-ui-color-red-50)"},warning:{default:"var(--starasia-ui-color-orange-600)",secondary:"var(--starasia-ui-color-orange-200)",tertiary:"var(--starasia-ui-color-orange-50)"},information:{default:"var(--starasia-ui-color-blue-600)",secondary:"var(--starasia-ui-color-blue-200)",tertiary:"var(--starasia-ui-color-blue-50)"},dark:{default:"var(--starasia-ui-color-gray-600)",secondary:"var(--starasia-ui-color-gray-200)",tertiary:"var(--starasia-ui-color-gray-50)"},fill:{default:"rgba(120, 134, 127, 0.2)",secondary:"rgba(120, 134, 127, 0.16)",tertiary:"rgba(120, 134, 127, 0.1)"}}},metrics:{radii:{none:"0",xs:"0.25rem",sm:"0.375rem",md:"0.5rem",lg:"0.75rem",xl:"0.875rem","2xl":"1rem",full:"12rem"},spacing:{0:"0rem",1:"0.063rem",2:"0.125rem",4:"0.25rem",6:"0.375rem",8:"0.5rem",10:"0.625rem",12:"0.75rem",14:"0.875rem",16:"1rem",18:"1.125rem",20:"1.25rem",24:"1.5rem",28:"1.75rem",32:"2rem",36:"2.25rem",40:"2.5rem",48:"3rem",64:"4rem",80:"5rem",96:"6rem",128:"8rem",160:"10rem",192:"12rem",224:"14rem",256:"16rem",xs:"0.25rem",sm:"0.5rem",md:"0.75rem",lg:"1rem",xl:"1.5rem","2xl":"2rem","3xl":"4rem"},border:{default:"1px solid var(--starasia-ui-color-border)"},shadows:{sm:"0 1px 2px 0 rgb(0 0 0 / 0.05)",md:"0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1)",lg:"0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1)",xl:"0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1)","2xl":"0 25px 50px -12px rgb(0 0 0 / 0.25)",inner:"inset 0 2px 4px 0 rgb(0 0 0 / 0.05)",card:"0px 4px 35px 0px rgba(112, 144, 176, 0.25)"}},font:{fontSizes:{xs:"0.625rem",sm:"0.75rem",md:"0.875rem",lg:"1rem",xl:"1.125rem","2xl":"1.25rem","3xl":"1.5rem","4xl":"2rem","5xl":"2.25rem","6xl":"3rem"},fontWeights:{hairline:100,thin:100,light:200,normal:300,medium:400,semibold:500,bold:600,extrabold:700,black:800},lineHeights:{3:"0.75rem",4:"1rem",5:"1.25rem",6:"1.5rem",7:"1.75rem",8:"1.875rem",9:"2.25rem",10:"2.5rem",none:1,tight:1.25,snug:1.375,normal:1.5,relaxed:1.625,loose:2}}},m=(r,a)=>{const o={};return Object.keys(r).forEach(s=>{if(r!=null&&r[s]&&typeof(r==null?void 0:r[s])=="object"){o[s]={...r==null?void 0:r[s],...a==null?void 0:a[s],...m(r==null?void 0:r[s],a==null?void 0:a[s])};return}o[s]=(a==null?void 0:a[s])||(r==null?void 0:r[s])}),o};function v(){const r=g.useContext(d),a=g.useMemo(()=>({...p,...r.theme,...m(p,r.theme)}),[r.theme,p]);return{...r,theme:a}}function q(){const{theme:r}=v();return r.colors}function H(){var a;const{theme:r}=v();return(a=r.metrics)==null?void 0:a.spacing}function J(){var a;const{theme:r}=v();return(a=r.metrics)==null?void 0:a.radii}function L(){var a;const{theme:r}=v();return(a=r==null?void 0:r.metrics)==null?void 0:a.shadows}function _(r){return r}l.ThemeContext=d,l.ThemeProvider=R,l.createTheme=_,l.useColor=q,l.useRadius=J,l.useShadow=L,l.useSpacing=H,l.useTheme=v,Object.defineProperty(l,Symbol.toStringTag,{value:"Module"})});
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@starasia/theme",
3
3
  "author": "Prawito Hudoro",
4
- "version": "1.0.1",
4
+ "version": "1.0.2",
5
5
  "description": "Theme component for starasia UI",
6
6
  "main": "dist/index.umd.js",
7
7
  "module": "dist/index.es.js",
@@ -9,10 +9,6 @@
9
9
  "files": [
10
10
  "dist"
11
11
  ],
12
- "scripts": {
13
- "dev": "vite --config vite.config.ts --port 3000",
14
- "build": "vite build --config vite.config.ts"
15
- },
16
12
  "keywords": [],
17
13
  "license": "ISC",
18
14
  "type": "module",
@@ -42,5 +38,9 @@
42
38
  },
43
39
  "dependencies": {
44
40
  "@starasia/css": "^1.0.1"
41
+ },
42
+ "scripts": {
43
+ "dev": "vite --config vite.config.ts --port 3000",
44
+ "build": "vite build --config vite.config.ts"
45
45
  }
46
- }
46
+ }