@pismo/marola 2.1.64 → 2.1.65
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/Button-CJaBSdv1.js +135 -0
- package/dist/ClassNameConfigurator-CVRWfyIa.js +847 -0
- package/dist/{ClickAwayListener-Z08peX_P.js → ClickAwayListener-BnYMO5Ki.js} +26 -33
- package/dist/Popup-D267EI4e.js +1338 -0
- package/dist/{Portal-DJapUCn6.js → Portal-BrGvxB96.js} +32 -36
- package/dist/RadioOption-DyRY8xlF.js +1094 -0
- package/dist/{Toggle-DcZTfLrC.js → Toggle-nnDfpqI1.js} +31 -31
- package/dist/assets/Checkbox.css +1 -1
- package/dist/assets/DropdownMenu.css +1 -1
- package/dist/assets/ToastCard.css +1 -1
- package/dist/assets/Toggle2.css +1 -1
- package/dist/combineHooksSlotProps-j-8UVeYo.js +86 -0
- package/dist/components/Alert/Alert.stories.d.ts +6 -6
- package/dist/components/Autocomplete/Autocomplete.d.ts +1 -1
- package/dist/components/Autocomplete/Autocomplete.js +311 -320
- package/dist/components/Autocomplete/Autocomplete.stories.d.ts +1 -1
- package/dist/components/Avatar/Avatar.stories.d.ts +4 -4
- package/dist/components/BankingCard/BankingCard.d.ts +0 -1
- package/dist/components/Button/Button.js +1 -1
- package/dist/components/Checkbox/Checkbox.js +56 -56
- package/dist/components/Checkbox/Checkbox.stories.d.ts +8 -8
- package/dist/components/Chip/Chip.js +3 -3
- package/dist/components/DatePicker/DatePicker.js +742 -639
- package/dist/components/DatePicker/DatePicker.stories.d.ts +8 -8
- package/dist/components/DatePicker/dateUtils.d.ts +2 -2
- package/dist/components/DatePicker/dateUtils.js +1 -1
- package/dist/components/DatePicker/keyboardNavigation.d.ts +1 -1
- package/dist/components/DatePicker/renderCalendarDays.js +1 -1
- package/dist/components/DatePicker/renderPeriodSelection.js +1 -1
- package/dist/components/Dialog/CloseIconButton.js +1 -1
- package/dist/components/Dialog/Dialog.js +372 -352
- package/dist/components/Dialog/Dialog.stories.d.ts +96 -135
- package/dist/components/DoubleAutocomplete/DoubleAutocomplete.d.ts +1 -1
- package/dist/components/DoubleAutocomplete/DoubleAutocomplete.js +2 -2
- package/dist/components/DoubleAutocomplete/DoubleAutocomplete.stories.d.ts +1 -1
- package/dist/components/DoubleInput/DoubleInput.stories.d.ts +1 -1
- package/dist/components/Draggable/Draggable.d.ts +0 -1
- package/dist/components/Draggable/Draggable.js +1 -1
- package/dist/components/Draggable/Draggable.stories.d.ts +2 -3
- package/dist/components/Draggable/useDraggable.js +1 -1
- package/dist/components/DropdownMenu/DropdownMenu.d.ts +3 -1
- package/dist/components/DropdownMenu/DropdownMenu.js +39 -34
- package/dist/components/DropdownMenu/DropdownMenu.stories.d.ts +6 -4
- package/dist/components/EllipsisTooltip/EllipsisTooltip.stories.d.ts +4 -4
- package/dist/components/IconButton/IconButton.js +1 -1
- package/dist/components/Input/Input.js +335 -320
- package/dist/components/InputSearch/InputSearch.d.ts +31 -31
- package/dist/components/InputSearch/InputSearch.stories.d.ts +31 -31
- package/dist/components/Popover/Popover.d.ts +3 -3
- package/dist/components/Popover/Popover.js +2 -2
- package/dist/components/Popover/Popover.stories.d.ts +3 -3
- package/dist/components/Popover/PopoverBody.d.ts +0 -1
- package/dist/components/Popover/PopoverFooter.d.ts +0 -1
- package/dist/components/Popover/PopoverHeader.d.ts +0 -1
- package/dist/components/RadioButton/RadioButton.d.ts +0 -1
- package/dist/components/RadioButton/RadioButton.js +684 -769
- package/dist/components/RadioButton/RadioOption.d.ts +0 -1
- package/dist/components/RadioButton/RadioOption.js +3 -3
- package/dist/components/ResultContainer/ResultContainer.d.ts +0 -1
- package/dist/components/ResultContainer/ResultContainer.stories.d.ts +9 -9
- package/dist/components/ResultWithChips/ResultWithChips.js +1 -1
- package/dist/components/ResultWithChips/ResultWithChips.stories.d.ts +9 -9
- package/dist/components/RowItem/RowItem.js +2 -2
- package/dist/components/Select/Select.js +625 -591
- package/dist/components/Skeleton/Skeleton.d.ts +0 -1
- package/dist/components/Snackbar/Snackbar.js +295 -239
- package/dist/components/Snackbar/Snackbar.stories.d.ts +113 -113
- package/dist/components/StepperNavigator/StepperNavigator.d.ts +0 -1
- package/dist/components/Table/Table.stories.d.ts +5 -5
- package/dist/components/Tabs/Tab.js +107 -98
- package/dist/components/Tabs/TabPanel.js +58 -55
- package/dist/components/Tabs/Tabs.js +246 -231
- package/dist/components/ToastCard/ToastCard.js +31 -31
- package/dist/components/Toggle/Toggle.js +147 -137
- package/dist/components/Toggle/Toggle.stories.d.ts +5 -5
- package/dist/components/ToggleGroup/Toggle.d.ts +0 -1
- package/dist/components/ToggleGroup/Toggle.js +2 -2
- package/dist/components/ToggleGroup/ToggleGroup.js +1 -1
- package/dist/components/ToggleGroup/ToggleGroup.stories.d.ts +1 -1
- package/dist/components/Tooltip/Tooltip.js +266 -325
- package/dist/components/Tooltip/Tooltip.stories.d.ts +4 -4
- package/dist/components/TransactionRow/TransactionRow.stories.d.ts +21 -21
- package/dist/contexts/DraggableProvider/DraggableProvider.d.ts +0 -1
- package/dist/contexts/DraggableProvider/DraggableProvider.js +1 -1
- package/dist/contexts/SnackbarProvider/SnackbarProvider.js +1 -1
- package/dist/{dayjs.min-ClQKmc--.js → dayjs.min-BtgZiFZY.js} +14 -14
- package/dist/getReactElementRef-iorwYm2A.js +19 -0
- package/dist/{index-1UpBa69h.js → index-ew-96uBP.js} +2129 -2128
- package/dist/isFocusVisible-CPZqtjv2.js +12 -0
- package/dist/main.js +2 -2
- package/dist/{ownerDocument-By592Iy6.js → ownerDocument-CU-LCrtd.js} +1 -1
- package/dist/react-BTbo_5A3.js +526 -0
- package/dist/setRef-Bo0HEdBB.js +6 -0
- package/dist/useButton-C2E_LFJp.js +90 -0
- package/dist/useControlled-BYdyS7Pn.js +31 -0
- package/dist/useId-CK6Kn3Tn.js +21 -0
- package/dist/useList-BLW78Lq7.js +446 -0
- package/dist/utils/draggable.d.ts +2 -2
- package/package.json +1 -1
- package/dist/Button-BrEDdtHO.js +0 -130
- package/dist/Popup-Dffqo7wT.js +0 -1246
- package/dist/RadioOption-DYovqiwF.js +0 -720
- package/dist/combineHooksSlotProps-BhQ14uyD.js +0 -79
- package/dist/exactProp-SYjL19cU.js +0 -13
- package/dist/react-BvI-Sw9b.js +0 -509
- package/dist/useButton-CezPDte8.js +0 -105
- package/dist/useControlled-CCMYYdCM.js +0 -31
- package/dist/useId-BW-oWmul.js +0 -19
- package/dist/useIsFocusVisible-BH4IAdcw.js +0 -69
- package/dist/useList-nqLfZem8.js +0 -435
- package/dist/useSlotProps-CYHDC4TN.js +0 -834
- package/dist/useTimeout-DxF9kiZL.js +0 -36
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
import { f as E, _ as c } from "./useSlotProps-CYHDC4TN.js";
|
|
2
|
-
import * as r from "react";
|
|
3
|
-
const m = {
|
|
4
|
-
blur: "list:blur",
|
|
5
|
-
itemClick: "list:itemClick",
|
|
6
|
-
itemHover: "list:itemHover",
|
|
7
|
-
itemsChange: "list:itemsChange",
|
|
8
|
-
keyDown: "list:keyDown",
|
|
9
|
-
resetHighlight: "list:resetHighlight",
|
|
10
|
-
highlightLast: "list:highlightLast",
|
|
11
|
-
textNavigation: "list:textNavigation",
|
|
12
|
-
clearSelection: "list:clearSelection"
|
|
13
|
-
}, f = /* @__PURE__ */ r.createContext(null);
|
|
14
|
-
process.env.NODE_ENV !== "production" && (f.displayName = "ListContext");
|
|
15
|
-
function x(l) {
|
|
16
|
-
const {
|
|
17
|
-
handlePointerOverEvents: a = !1,
|
|
18
|
-
item: t
|
|
19
|
-
} = l, s = r.useContext(f);
|
|
20
|
-
if (!s)
|
|
21
|
-
throw new Error("useListItem must be used within a ListProvider");
|
|
22
|
-
const {
|
|
23
|
-
dispatch: n,
|
|
24
|
-
getItemState: d
|
|
25
|
-
} = s, {
|
|
26
|
-
highlighted: u,
|
|
27
|
-
selected: p,
|
|
28
|
-
focusable: g
|
|
29
|
-
} = d(t), v = r.useCallback((i) => (e) => {
|
|
30
|
-
var o;
|
|
31
|
-
if ((o = i.onClick) == null || o.call(i, e), !e.defaultPrevented) {
|
|
32
|
-
if (process.env.NODE_ENV !== "production" && t === void 0)
|
|
33
|
-
throw new Error(["MUI: The `item` provided to useListItem() is undefined.", "This should happen only during server-side rendering under React 17."].join(`
|
|
34
|
-
`));
|
|
35
|
-
n({
|
|
36
|
-
type: m.itemClick,
|
|
37
|
-
item: t,
|
|
38
|
-
event: e
|
|
39
|
-
});
|
|
40
|
-
}
|
|
41
|
-
}, [n, t]), C = r.useCallback((i) => (e) => {
|
|
42
|
-
var o;
|
|
43
|
-
if ((o = i.onMouseOver) == null || o.call(i, e), !e.defaultPrevented) {
|
|
44
|
-
if (process.env.NODE_ENV !== "production" && t === void 0)
|
|
45
|
-
throw new Error(["MUI: The `item` provided to useListItem() is undefined.", "This should happen only during server-side rendering under React 17."].join(`
|
|
46
|
-
`));
|
|
47
|
-
n({
|
|
48
|
-
type: m.itemHover,
|
|
49
|
-
item: t,
|
|
50
|
-
event: e
|
|
51
|
-
});
|
|
52
|
-
}
|
|
53
|
-
}, [n, t]);
|
|
54
|
-
let h;
|
|
55
|
-
return g && (h = u ? 0 : -1), {
|
|
56
|
-
getRootProps: (i = {}) => {
|
|
57
|
-
const e = E(i);
|
|
58
|
-
return c({}, i, {
|
|
59
|
-
onClick: v(e),
|
|
60
|
-
onPointerOver: a ? C(e) : void 0,
|
|
61
|
-
tabIndex: h
|
|
62
|
-
});
|
|
63
|
-
},
|
|
64
|
-
highlighted: u,
|
|
65
|
-
selected: p
|
|
66
|
-
};
|
|
67
|
-
}
|
|
68
|
-
function H(l, a) {
|
|
69
|
-
return function(s = {}) {
|
|
70
|
-
const n = c({}, s, l(s));
|
|
71
|
-
return c({}, n, a(n));
|
|
72
|
-
};
|
|
73
|
-
}
|
|
74
|
-
export {
|
|
75
|
-
m as L,
|
|
76
|
-
f as a,
|
|
77
|
-
H as c,
|
|
78
|
-
x as u
|
|
79
|
-
};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { _ as n } from "./useSlotProps-CYHDC4TN.js";
|
|
2
|
-
const s = "exact-prop: ";
|
|
3
|
-
function u(e) {
|
|
4
|
-
return process.env.NODE_ENV === "production" ? e : n({}, e, {
|
|
5
|
-
[s]: (o) => {
|
|
6
|
-
const t = Object.keys(o).filter((r) => !e.hasOwnProperty(r));
|
|
7
|
-
return t.length > 0 ? new Error(`The following props are not supported: ${t.map((r) => `\`${r}\``).join(", ")}. Please remove them.`) : null;
|
|
8
|
-
}
|
|
9
|
-
});
|
|
10
|
-
}
|
|
11
|
-
export {
|
|
12
|
-
u as e
|
|
13
|
-
};
|
package/dist/react-BvI-Sw9b.js
DELETED
|
@@ -1,509 +0,0 @@
|
|
|
1
|
-
import te, { useRef as ue, createElement as de, createContext as fe, useReducer as ae, useEffect as ve, useDebugValue as _e, useCallback as he, useContext as we } from "react";
|
|
2
|
-
const I = {}, Y = (e, t) => e.unstable_is ? e.unstable_is(t) : t === e, Z = (e) => "init" in e, $ = (e) => !!e.write, k = (e) => "v" in e || "e" in e, V = (e) => {
|
|
3
|
-
if ("e" in e)
|
|
4
|
-
throw e.e;
|
|
5
|
-
if ((I ? "production" : void 0) !== "production" && !("v" in e))
|
|
6
|
-
throw new Error("[Bug] atom state is not initialized");
|
|
7
|
-
return e.v;
|
|
8
|
-
}, j = /* @__PURE__ */ new WeakMap(), B = (e) => {
|
|
9
|
-
var t;
|
|
10
|
-
return x(e) && !!((t = j.get(e)) != null && t[0]);
|
|
11
|
-
}, Se = (e) => {
|
|
12
|
-
const t = j.get(e);
|
|
13
|
-
t != null && t[0] && (t[0] = !1, t[1].forEach((n) => n()));
|
|
14
|
-
}, ne = (e, t) => {
|
|
15
|
-
let n = j.get(e);
|
|
16
|
-
if (!n) {
|
|
17
|
-
n = [!0, /* @__PURE__ */ new Set()], j.set(e, n);
|
|
18
|
-
const o = () => {
|
|
19
|
-
n[0] = !1;
|
|
20
|
-
};
|
|
21
|
-
e.then(o, o);
|
|
22
|
-
}
|
|
23
|
-
n[1].add(t);
|
|
24
|
-
}, x = (e) => typeof (e == null ? void 0 : e.then) == "function", re = (e, t, n) => {
|
|
25
|
-
n.p.has(e) || (n.p.add(e), t.then(
|
|
26
|
-
() => {
|
|
27
|
-
n.p.delete(e);
|
|
28
|
-
},
|
|
29
|
-
() => {
|
|
30
|
-
n.p.delete(e);
|
|
31
|
-
}
|
|
32
|
-
));
|
|
33
|
-
}, C = (e, t, n) => {
|
|
34
|
-
const o = n(e), u = "v" in o, f = o.v;
|
|
35
|
-
if (x(t))
|
|
36
|
-
for (const a of o.d.keys())
|
|
37
|
-
re(e, t, n(a));
|
|
38
|
-
o.v = t, delete o.e, (!u || !Object.is(f, o.v)) && (++o.n, x(f) && Se(f));
|
|
39
|
-
}, H = (e, t, n) => {
|
|
40
|
-
var o;
|
|
41
|
-
const u = /* @__PURE__ */ new Set();
|
|
42
|
-
for (const f of ((o = n.get(e)) == null ? void 0 : o.t) || [])
|
|
43
|
-
n.has(f) && u.add(f);
|
|
44
|
-
for (const f of t.p)
|
|
45
|
-
u.add(f);
|
|
46
|
-
return u;
|
|
47
|
-
}, ge = () => {
|
|
48
|
-
const e = /* @__PURE__ */ new Set(), t = () => {
|
|
49
|
-
e.forEach((n) => n());
|
|
50
|
-
};
|
|
51
|
-
return t.add = (n) => (e.add(n), () => {
|
|
52
|
-
e.delete(n);
|
|
53
|
-
}), t;
|
|
54
|
-
}, G = () => {
|
|
55
|
-
const e = {}, t = /* @__PURE__ */ new WeakMap(), n = (o) => {
|
|
56
|
-
var u, f;
|
|
57
|
-
(u = t.get(e)) == null || u.forEach((a) => a(o)), (f = t.get(o)) == null || f.forEach((a) => a());
|
|
58
|
-
};
|
|
59
|
-
return n.add = (o, u) => {
|
|
60
|
-
const f = o || e, a = (t.has(f) ? t : t.set(f, /* @__PURE__ */ new Set())).get(f);
|
|
61
|
-
return a.add(u), () => {
|
|
62
|
-
a == null || a.delete(u), a.size || t.delete(f);
|
|
63
|
-
};
|
|
64
|
-
}, n;
|
|
65
|
-
}, ye = (e) => (e.c || (e.c = G()), e.m || (e.m = G()), e.u || (e.u = G()), e.f || (e.f = ge()), e), pe = Symbol(), be = (e = /* @__PURE__ */ new WeakMap(), t = /* @__PURE__ */ new WeakMap(), n = /* @__PURE__ */ new WeakMap(), o = /* @__PURE__ */ new Set(), u = /* @__PURE__ */ new Set(), f = /* @__PURE__ */ new Set(), a = {}, S = (_, ...b) => _.read(...b), y = (_, ...b) => _.write(...b), v = (_, b) => {
|
|
66
|
-
var A;
|
|
67
|
-
return (A = _.unstable_onInit) == null ? void 0 : A.call(_, b);
|
|
68
|
-
}, h = (_, b) => {
|
|
69
|
-
var A;
|
|
70
|
-
return (A = _.onMount) == null ? void 0 : A.call(_, b);
|
|
71
|
-
}, ...g) => {
|
|
72
|
-
const _ = g[0] || ((r) => {
|
|
73
|
-
if ((I ? "production" : void 0) !== "production" && !r)
|
|
74
|
-
throw new Error("Atom is undefined or null");
|
|
75
|
-
let d = e.get(r);
|
|
76
|
-
return d || (d = { d: /* @__PURE__ */ new Map(), p: /* @__PURE__ */ new Set(), n: 0 }, e.set(r, d), v == null || v(r, U)), d;
|
|
77
|
-
}), b = g[1] || (() => {
|
|
78
|
-
const r = [], d = (l) => {
|
|
79
|
-
try {
|
|
80
|
-
l();
|
|
81
|
-
} catch (s) {
|
|
82
|
-
r.push(s);
|
|
83
|
-
}
|
|
84
|
-
};
|
|
85
|
-
do {
|
|
86
|
-
a.f && d(a.f);
|
|
87
|
-
const l = /* @__PURE__ */ new Set(), s = l.add.bind(l);
|
|
88
|
-
o.forEach((i) => {
|
|
89
|
-
var c;
|
|
90
|
-
return (c = t.get(i)) == null ? void 0 : c.l.forEach(s);
|
|
91
|
-
}), o.clear(), f.forEach(s), f.clear(), u.forEach(s), u.clear(), l.forEach(d), o.size && A();
|
|
92
|
-
} while (o.size || f.size || u.size);
|
|
93
|
-
if (r.length)
|
|
94
|
-
throw new AggregateError(r);
|
|
95
|
-
}), A = g[2] || (() => {
|
|
96
|
-
const r = [], d = /* @__PURE__ */ new WeakSet(), l = /* @__PURE__ */ new WeakSet(), s = Array.from(o);
|
|
97
|
-
for (; s.length; ) {
|
|
98
|
-
const i = s[s.length - 1], c = _(i);
|
|
99
|
-
if (l.has(i)) {
|
|
100
|
-
s.pop();
|
|
101
|
-
continue;
|
|
102
|
-
}
|
|
103
|
-
if (d.has(i)) {
|
|
104
|
-
if (n.get(i) === c.n)
|
|
105
|
-
r.push([i, c]);
|
|
106
|
-
else if ((I ? "production" : void 0) !== "production" && n.has(i))
|
|
107
|
-
throw new Error("[Bug] invalidated atom exists");
|
|
108
|
-
l.add(i), s.pop();
|
|
109
|
-
continue;
|
|
110
|
-
}
|
|
111
|
-
d.add(i);
|
|
112
|
-
for (const p of H(i, c, t))
|
|
113
|
-
d.has(p) || s.push(p);
|
|
114
|
-
}
|
|
115
|
-
for (let i = r.length - 1; i >= 0; --i) {
|
|
116
|
-
const [c, p] = r[i];
|
|
117
|
-
let E = !1;
|
|
118
|
-
for (const R of p.d.keys())
|
|
119
|
-
if (R !== c && o.has(R)) {
|
|
120
|
-
E = !0;
|
|
121
|
-
break;
|
|
122
|
-
}
|
|
123
|
-
E && (P(c), L(c)), n.delete(c);
|
|
124
|
-
}
|
|
125
|
-
}), P = g[3] || ((r) => {
|
|
126
|
-
var d;
|
|
127
|
-
const l = _(r);
|
|
128
|
-
if (k(l) && (t.has(r) && n.get(r) !== l.n || Array.from(l.d).every(
|
|
129
|
-
([w, N]) => (
|
|
130
|
-
// Recursively, read the atom state of the dependency, and
|
|
131
|
-
// check if the atom epoch number is unchanged
|
|
132
|
-
P(w).n === N
|
|
133
|
-
)
|
|
134
|
-
)))
|
|
135
|
-
return l;
|
|
136
|
-
l.d.clear();
|
|
137
|
-
let s = !0;
|
|
138
|
-
const i = () => {
|
|
139
|
-
t.has(r) && (L(r), A(), b());
|
|
140
|
-
}, c = (w) => {
|
|
141
|
-
var N;
|
|
142
|
-
if (Y(r, w)) {
|
|
143
|
-
const X = _(w);
|
|
144
|
-
if (!k(X))
|
|
145
|
-
if (Z(w))
|
|
146
|
-
C(w, w.init, _);
|
|
147
|
-
else
|
|
148
|
-
throw new Error("no atom init");
|
|
149
|
-
return V(X);
|
|
150
|
-
}
|
|
151
|
-
const J = P(w);
|
|
152
|
-
try {
|
|
153
|
-
return V(J);
|
|
154
|
-
} finally {
|
|
155
|
-
l.d.set(w, J.n), B(l.v) && re(r, l.v, J), (N = t.get(w)) == null || N.t.add(r), s || i();
|
|
156
|
-
}
|
|
157
|
-
};
|
|
158
|
-
let p, E;
|
|
159
|
-
const R = {
|
|
160
|
-
get signal() {
|
|
161
|
-
return p || (p = new AbortController()), p.signal;
|
|
162
|
-
},
|
|
163
|
-
get setSelf() {
|
|
164
|
-
return (I ? "production" : void 0) !== "production" && !$(r) && console.warn("setSelf function cannot be used with read-only atom"), !E && $(r) && (E = (...w) => {
|
|
165
|
-
if ((I ? "production" : void 0) !== "production" && s && console.warn("setSelf function cannot be called in sync"), !s)
|
|
166
|
-
try {
|
|
167
|
-
return T(r, ...w);
|
|
168
|
-
} finally {
|
|
169
|
-
A(), b();
|
|
170
|
-
}
|
|
171
|
-
}), E;
|
|
172
|
-
}
|
|
173
|
-
}, O = l.n;
|
|
174
|
-
try {
|
|
175
|
-
const w = S(r, c, R);
|
|
176
|
-
return C(r, w, _), x(w) && (ne(w, () => p == null ? void 0 : p.abort()), w.then(
|
|
177
|
-
i,
|
|
178
|
-
i
|
|
179
|
-
)), l;
|
|
180
|
-
} catch (w) {
|
|
181
|
-
return delete l.v, l.e = w, ++l.n, l;
|
|
182
|
-
} finally {
|
|
183
|
-
s = !1, O !== l.n && n.get(r) === O && (n.set(r, l.n), o.add(r), (d = a.c) == null || d.call(a, r));
|
|
184
|
-
}
|
|
185
|
-
}), M = g[4] || ((r) => {
|
|
186
|
-
const d = [r];
|
|
187
|
-
for (; d.length; ) {
|
|
188
|
-
const l = d.pop(), s = _(l);
|
|
189
|
-
for (const i of H(l, s, t)) {
|
|
190
|
-
const c = _(i);
|
|
191
|
-
n.set(i, c.n), d.push(i);
|
|
192
|
-
}
|
|
193
|
-
}
|
|
194
|
-
}), T = g[5] || ((r, ...d) => {
|
|
195
|
-
let l = !0;
|
|
196
|
-
const s = (c) => V(P(c)), i = (c, ...p) => {
|
|
197
|
-
var E;
|
|
198
|
-
const R = _(c);
|
|
199
|
-
try {
|
|
200
|
-
if (Y(r, c)) {
|
|
201
|
-
if (!Z(c))
|
|
202
|
-
throw new Error("atom not writable");
|
|
203
|
-
const O = R.n, w = p[0];
|
|
204
|
-
C(c, w, _), L(c), O !== R.n && (o.add(c), (E = a.c) == null || E.call(a, c), M(c));
|
|
205
|
-
return;
|
|
206
|
-
} else
|
|
207
|
-
return T(c, ...p);
|
|
208
|
-
} finally {
|
|
209
|
-
l || (A(), b());
|
|
210
|
-
}
|
|
211
|
-
};
|
|
212
|
-
try {
|
|
213
|
-
return y(r, s, i, ...d);
|
|
214
|
-
} finally {
|
|
215
|
-
l = !1;
|
|
216
|
-
}
|
|
217
|
-
}), L = g[6] || ((r) => {
|
|
218
|
-
var d;
|
|
219
|
-
const l = _(r), s = t.get(r);
|
|
220
|
-
if (s && !B(l.v)) {
|
|
221
|
-
for (const [i, c] of l.d)
|
|
222
|
-
if (!s.d.has(i)) {
|
|
223
|
-
const p = _(i);
|
|
224
|
-
W(i).t.add(r), s.d.add(i), c !== p.n && (o.add(i), (d = a.c) == null || d.call(a, i), M(i));
|
|
225
|
-
}
|
|
226
|
-
for (const i of s.d || [])
|
|
227
|
-
if (!l.d.has(i)) {
|
|
228
|
-
s.d.delete(i);
|
|
229
|
-
const c = z(i);
|
|
230
|
-
c == null || c.t.delete(r);
|
|
231
|
-
}
|
|
232
|
-
}
|
|
233
|
-
}), W = g[7] || ((r) => {
|
|
234
|
-
var d;
|
|
235
|
-
const l = _(r);
|
|
236
|
-
let s = t.get(r);
|
|
237
|
-
if (!s) {
|
|
238
|
-
P(r);
|
|
239
|
-
for (const i of l.d.keys())
|
|
240
|
-
W(i).t.add(r);
|
|
241
|
-
if (s = {
|
|
242
|
-
l: /* @__PURE__ */ new Set(),
|
|
243
|
-
d: new Set(l.d.keys()),
|
|
244
|
-
t: /* @__PURE__ */ new Set()
|
|
245
|
-
}, t.set(r, s), (d = a.m) == null || d.call(a, r), $(r)) {
|
|
246
|
-
const i = () => {
|
|
247
|
-
let c = !0;
|
|
248
|
-
const p = (...E) => {
|
|
249
|
-
try {
|
|
250
|
-
return T(r, ...E);
|
|
251
|
-
} finally {
|
|
252
|
-
c || (A(), b());
|
|
253
|
-
}
|
|
254
|
-
};
|
|
255
|
-
try {
|
|
256
|
-
const E = h(r, p);
|
|
257
|
-
E && (s.u = () => {
|
|
258
|
-
c = !0;
|
|
259
|
-
try {
|
|
260
|
-
E();
|
|
261
|
-
} finally {
|
|
262
|
-
c = !1;
|
|
263
|
-
}
|
|
264
|
-
});
|
|
265
|
-
} finally {
|
|
266
|
-
c = !1;
|
|
267
|
-
}
|
|
268
|
-
};
|
|
269
|
-
u.add(i);
|
|
270
|
-
}
|
|
271
|
-
}
|
|
272
|
-
return s;
|
|
273
|
-
}), z = g[8] || ((r) => {
|
|
274
|
-
var d;
|
|
275
|
-
const l = _(r);
|
|
276
|
-
let s = t.get(r);
|
|
277
|
-
if (s && !s.l.size && !Array.from(s.t).some((i) => {
|
|
278
|
-
var c;
|
|
279
|
-
return (c = t.get(i)) == null ? void 0 : c.d.has(r);
|
|
280
|
-
})) {
|
|
281
|
-
s.u && f.add(s.u), s = void 0, t.delete(r), (d = a.u) == null || d.call(a, r);
|
|
282
|
-
for (const i of l.d.keys()) {
|
|
283
|
-
const c = z(i);
|
|
284
|
-
c == null || c.t.delete(r);
|
|
285
|
-
}
|
|
286
|
-
return;
|
|
287
|
-
}
|
|
288
|
-
return s;
|
|
289
|
-
}), le = [
|
|
290
|
-
// store state
|
|
291
|
-
e,
|
|
292
|
-
t,
|
|
293
|
-
n,
|
|
294
|
-
o,
|
|
295
|
-
u,
|
|
296
|
-
f,
|
|
297
|
-
a,
|
|
298
|
-
// atom interceptors
|
|
299
|
-
S,
|
|
300
|
-
y,
|
|
301
|
-
v,
|
|
302
|
-
h,
|
|
303
|
-
// building-block functions
|
|
304
|
-
_,
|
|
305
|
-
b,
|
|
306
|
-
A,
|
|
307
|
-
P,
|
|
308
|
-
M,
|
|
309
|
-
T,
|
|
310
|
-
L,
|
|
311
|
-
W,
|
|
312
|
-
z
|
|
313
|
-
], U = {
|
|
314
|
-
get: (r) => V(P(r)),
|
|
315
|
-
set: (r, ...d) => {
|
|
316
|
-
try {
|
|
317
|
-
return T(r, ...d);
|
|
318
|
-
} finally {
|
|
319
|
-
A(), b();
|
|
320
|
-
}
|
|
321
|
-
},
|
|
322
|
-
sub: (r, d) => {
|
|
323
|
-
const s = W(r).l;
|
|
324
|
-
return s.add(d), b(), () => {
|
|
325
|
-
s.delete(d), z(r), b();
|
|
326
|
-
};
|
|
327
|
-
}
|
|
328
|
-
};
|
|
329
|
-
return Object.defineProperty(U, pe, { value: le }), U;
|
|
330
|
-
}, oe = be, Ee = ye, m = ne, Q = {};
|
|
331
|
-
let Ae = 0;
|
|
332
|
-
function Ne(e, t) {
|
|
333
|
-
const n = `atom${++Ae}`, o = {
|
|
334
|
-
toString() {
|
|
335
|
-
return (Q ? "production" : void 0) !== "production" && this.debugLabel ? n + ":" + this.debugLabel : n;
|
|
336
|
-
}
|
|
337
|
-
};
|
|
338
|
-
return o.init = e, o.read = Pe, o.write = Re, o;
|
|
339
|
-
}
|
|
340
|
-
function Pe(e) {
|
|
341
|
-
return e(this);
|
|
342
|
-
}
|
|
343
|
-
function Re(e, t, n) {
|
|
344
|
-
return t(
|
|
345
|
-
this,
|
|
346
|
-
typeof n == "function" ? n(e(this)) : n
|
|
347
|
-
);
|
|
348
|
-
}
|
|
349
|
-
const Te = () => {
|
|
350
|
-
let e = 0;
|
|
351
|
-
const t = Ee({}), n = /* @__PURE__ */ new WeakMap(), o = /* @__PURE__ */ new WeakMap(), u = oe(
|
|
352
|
-
n,
|
|
353
|
-
o,
|
|
354
|
-
void 0,
|
|
355
|
-
void 0,
|
|
356
|
-
void 0,
|
|
357
|
-
void 0,
|
|
358
|
-
t,
|
|
359
|
-
void 0,
|
|
360
|
-
(S, y, v, ...h) => e ? v(S, ...h) : S.write(y, v, ...h)
|
|
361
|
-
), f = /* @__PURE__ */ new Set();
|
|
362
|
-
return t.m.add(void 0, (S) => {
|
|
363
|
-
f.add(S);
|
|
364
|
-
const y = n.get(S);
|
|
365
|
-
y.m = o.get(S);
|
|
366
|
-
}), t.u.add(void 0, (S) => {
|
|
367
|
-
f.delete(S);
|
|
368
|
-
const y = n.get(S);
|
|
369
|
-
delete y.m;
|
|
370
|
-
}), Object.assign(u, {
|
|
371
|
-
// store dev methods (these are tentative and subject to change without notice)
|
|
372
|
-
dev4_get_internal_weak_map: () => (console.log("Deprecated: Use devstore from the devtools library"), n),
|
|
373
|
-
dev4_get_mounted_atoms: () => f,
|
|
374
|
-
dev4_restore_atoms: (S) => {
|
|
375
|
-
const y = {
|
|
376
|
-
read: () => null,
|
|
377
|
-
write: (v, h) => {
|
|
378
|
-
++e;
|
|
379
|
-
try {
|
|
380
|
-
for (const [g, _] of S)
|
|
381
|
-
"init" in g && h(g, _);
|
|
382
|
-
} finally {
|
|
383
|
-
--e;
|
|
384
|
-
}
|
|
385
|
-
}
|
|
386
|
-
};
|
|
387
|
-
u.set(y);
|
|
388
|
-
}
|
|
389
|
-
});
|
|
390
|
-
};
|
|
391
|
-
function ie() {
|
|
392
|
-
return (Q ? "production" : void 0) !== "production" ? Te() : oe();
|
|
393
|
-
}
|
|
394
|
-
let D;
|
|
395
|
-
function De() {
|
|
396
|
-
return D || (D = ie(), (Q ? "production" : void 0) !== "production" && (globalThis.__JOTAI_DEFAULT_STORE__ || (globalThis.__JOTAI_DEFAULT_STORE__ = D), globalThis.__JOTAI_DEFAULT_STORE__ !== D && console.warn(
|
|
397
|
-
"Detected multiple Jotai instances. It may cause unexpected behavior with the default store. https://github.com/pmndrs/jotai/discussions/2044"
|
|
398
|
-
))), D;
|
|
399
|
-
}
|
|
400
|
-
const Ie = {}, se = fe(
|
|
401
|
-
void 0
|
|
402
|
-
);
|
|
403
|
-
function ce(e) {
|
|
404
|
-
return we(se) || De();
|
|
405
|
-
}
|
|
406
|
-
function Ve({
|
|
407
|
-
children: e,
|
|
408
|
-
store: t
|
|
409
|
-
}) {
|
|
410
|
-
const n = ue(void 0);
|
|
411
|
-
return !t && !n.current && (n.current = ie()), de(
|
|
412
|
-
se.Provider,
|
|
413
|
-
{
|
|
414
|
-
value: t || n.current
|
|
415
|
-
},
|
|
416
|
-
e
|
|
417
|
-
);
|
|
418
|
-
}
|
|
419
|
-
const q = (e) => typeof (e == null ? void 0 : e.then) == "function", F = (e) => {
|
|
420
|
-
e.status || (e.status = "pending", e.then(
|
|
421
|
-
(t) => {
|
|
422
|
-
e.status = "fulfilled", e.value = t;
|
|
423
|
-
},
|
|
424
|
-
(t) => {
|
|
425
|
-
e.status = "rejected", e.reason = t;
|
|
426
|
-
}
|
|
427
|
-
));
|
|
428
|
-
}, Le = te.use || // A shim for older React versions
|
|
429
|
-
((e) => {
|
|
430
|
-
if (e.status === "pending")
|
|
431
|
-
throw e;
|
|
432
|
-
if (e.status === "fulfilled")
|
|
433
|
-
return e.value;
|
|
434
|
-
throw e.status === "rejected" ? e.reason : (F(e), e);
|
|
435
|
-
}), K = /* @__PURE__ */ new WeakMap(), ee = (e, t) => {
|
|
436
|
-
let n = K.get(e);
|
|
437
|
-
return n || (n = new Promise((o, u) => {
|
|
438
|
-
let f = e;
|
|
439
|
-
const a = (v) => (h) => {
|
|
440
|
-
f === v && o(h);
|
|
441
|
-
}, S = (v) => (h) => {
|
|
442
|
-
f === v && u(h);
|
|
443
|
-
}, y = () => {
|
|
444
|
-
try {
|
|
445
|
-
const v = t();
|
|
446
|
-
q(v) ? (K.set(v, n), f = v, v.then(a(v), S(v)), m(v, y)) : o(v);
|
|
447
|
-
} catch (v) {
|
|
448
|
-
u(v);
|
|
449
|
-
}
|
|
450
|
-
};
|
|
451
|
-
e.then(a(e), S(e)), m(e, y);
|
|
452
|
-
}), K.set(e, n)), n;
|
|
453
|
-
};
|
|
454
|
-
function We(e, t) {
|
|
455
|
-
const { delay: n, unstable_promiseStatus: o = !te.use } = {}, u = ce(), [[f, a, S], y] = ae(
|
|
456
|
-
(h) => {
|
|
457
|
-
const g = u.get(e);
|
|
458
|
-
return Object.is(h[0], g) && h[1] === u && h[2] === e ? h : [g, u, e];
|
|
459
|
-
},
|
|
460
|
-
void 0,
|
|
461
|
-
() => [u.get(e), u, e]
|
|
462
|
-
);
|
|
463
|
-
let v = f;
|
|
464
|
-
if ((a !== u || S !== e) && (y(), v = u.get(e)), ve(() => {
|
|
465
|
-
const h = u.sub(e, () => {
|
|
466
|
-
if (o)
|
|
467
|
-
try {
|
|
468
|
-
const g = u.get(e);
|
|
469
|
-
q(g) && F(
|
|
470
|
-
ee(g, () => u.get(e))
|
|
471
|
-
);
|
|
472
|
-
} catch {
|
|
473
|
-
}
|
|
474
|
-
if (typeof n == "number") {
|
|
475
|
-
setTimeout(y, n);
|
|
476
|
-
return;
|
|
477
|
-
}
|
|
478
|
-
y();
|
|
479
|
-
});
|
|
480
|
-
return y(), h;
|
|
481
|
-
}, [u, e, n, o]), _e(v), q(v)) {
|
|
482
|
-
const h = ee(v, () => u.get(e));
|
|
483
|
-
return o && F(h), Le(h);
|
|
484
|
-
}
|
|
485
|
-
return v;
|
|
486
|
-
}
|
|
487
|
-
function ze(e, t) {
|
|
488
|
-
const n = ce();
|
|
489
|
-
return he(
|
|
490
|
-
(...u) => {
|
|
491
|
-
if ((Ie ? "production" : void 0) !== "production" && !("write" in e))
|
|
492
|
-
throw new Error("not writable atom");
|
|
493
|
-
return n.set(e, ...u);
|
|
494
|
-
},
|
|
495
|
-
[n, e]
|
|
496
|
-
);
|
|
497
|
-
}
|
|
498
|
-
function je(e, t) {
|
|
499
|
-
return [
|
|
500
|
-
We(e),
|
|
501
|
-
// We do wrong type assertion here, which results in throwing an error.
|
|
502
|
-
ze(e)
|
|
503
|
-
];
|
|
504
|
-
}
|
|
505
|
-
export {
|
|
506
|
-
Ve as P,
|
|
507
|
-
Ne as a,
|
|
508
|
-
je as u
|
|
509
|
-
};
|
|
@@ -1,105 +0,0 @@
|
|
|
1
|
-
import { u as L, _ as D, f as k } from "./useSlotProps-CYHDC4TN.js";
|
|
2
|
-
import * as i from "react";
|
|
3
|
-
import { u as S } from "./useIsFocusVisible-BH4IAdcw.js";
|
|
4
|
-
function v(p) {
|
|
5
|
-
const {
|
|
6
|
-
rootElementName: n = "",
|
|
7
|
-
componentName: l
|
|
8
|
-
} = p, [c, y] = i.useState(n.toUpperCase());
|
|
9
|
-
process.env.NODE_ENV !== "production" && i.useEffect(() => {
|
|
10
|
-
n && c !== n.toUpperCase() && console.error(`useRootElementName: the \`rootElementName\` prop of ${l ? `the ${l} component` : "a component"} expected the '${n}' element, but a '${c.toLowerCase()}' was rendered instead`, "This may cause hydration issues in an SSR context, for example in a Next.js app");
|
|
11
|
-
}, [n, c, l]);
|
|
12
|
-
const u = i.useCallback((m) => {
|
|
13
|
-
var s;
|
|
14
|
-
y((s = m == null ? void 0 : m.tagName) != null ? s : "");
|
|
15
|
-
}, []);
|
|
16
|
-
return [c, u];
|
|
17
|
-
}
|
|
18
|
-
function W(p = {}) {
|
|
19
|
-
const {
|
|
20
|
-
disabled: n = !1,
|
|
21
|
-
focusableWhenDisabled: l,
|
|
22
|
-
href: c,
|
|
23
|
-
rootRef: y,
|
|
24
|
-
tabIndex: u,
|
|
25
|
-
to: m,
|
|
26
|
-
type: s,
|
|
27
|
-
rootElementName: T
|
|
28
|
-
} = p, b = i.useRef(), [B, N] = i.useState(!1), {
|
|
29
|
-
isFocusVisibleRef: E,
|
|
30
|
-
onFocus: F,
|
|
31
|
-
onBlur: M,
|
|
32
|
-
ref: U
|
|
33
|
-
} = S(), [d, R] = i.useState(!1);
|
|
34
|
-
n && !l && d && R(!1), i.useEffect(() => {
|
|
35
|
-
E.current = d;
|
|
36
|
-
}, [d, E]);
|
|
37
|
-
const [f, V] = v({
|
|
38
|
-
rootElementName: T ?? (c || m ? "a" : void 0),
|
|
39
|
-
componentName: "Button"
|
|
40
|
-
}), w = (t) => (e) => {
|
|
41
|
-
var o;
|
|
42
|
-
d && e.preventDefault(), (o = t.onMouseLeave) == null || o.call(t, e);
|
|
43
|
-
}, K = (t) => (e) => {
|
|
44
|
-
var o;
|
|
45
|
-
M(e), E.current === !1 && R(!1), (o = t.onBlur) == null || o.call(t, e);
|
|
46
|
-
}, P = (t) => (e) => {
|
|
47
|
-
var o;
|
|
48
|
-
if (b.current || (b.current = e.currentTarget), F(e), E.current === !0) {
|
|
49
|
-
var r;
|
|
50
|
-
R(!0), (r = t.onFocusVisible) == null || r.call(t, e);
|
|
51
|
-
}
|
|
52
|
-
(o = t.onFocus) == null || o.call(t, e);
|
|
53
|
-
}, g = () => {
|
|
54
|
-
const t = b.current;
|
|
55
|
-
return f === "BUTTON" || f === "INPUT" && ["button", "submit", "reset"].includes(t == null ? void 0 : t.type) || f === "A" && (t == null ? void 0 : t.href);
|
|
56
|
-
}, I = (t) => (e) => {
|
|
57
|
-
if (!n) {
|
|
58
|
-
var o;
|
|
59
|
-
(o = t.onClick) == null || o.call(t, e);
|
|
60
|
-
}
|
|
61
|
-
}, $ = (t) => (e) => {
|
|
62
|
-
var o;
|
|
63
|
-
n || (N(!0), document.addEventListener("mouseup", () => {
|
|
64
|
-
N(!1);
|
|
65
|
-
}, {
|
|
66
|
-
once: !0
|
|
67
|
-
})), (o = t.onMouseDown) == null || o.call(t, e);
|
|
68
|
-
}, C = (t) => (e) => {
|
|
69
|
-
var o;
|
|
70
|
-
if ((o = t.onKeyDown) == null || o.call(t, e), !e.defaultMuiPrevented && (e.target === e.currentTarget && !g() && e.key === " " && e.preventDefault(), e.target === e.currentTarget && e.key === " " && !n && N(!0), e.target === e.currentTarget && !g() && e.key === "Enter" && !n)) {
|
|
71
|
-
var r;
|
|
72
|
-
(r = t.onClick) == null || r.call(t, e), e.preventDefault();
|
|
73
|
-
}
|
|
74
|
-
}, _ = (t) => (e) => {
|
|
75
|
-
var o;
|
|
76
|
-
if (e.target === e.currentTarget && N(!1), (o = t.onKeyUp) == null || o.call(t, e), e.target === e.currentTarget && !g() && !n && e.key === " " && !e.defaultMuiPrevented) {
|
|
77
|
-
var r;
|
|
78
|
-
(r = t.onClick) == null || r.call(t, e);
|
|
79
|
-
}
|
|
80
|
-
}, x = L(V, y, U, b), a = {};
|
|
81
|
-
return u !== void 0 && (a.tabIndex = u), f === "BUTTON" ? (a.type = s ?? "button", l ? a["aria-disabled"] = n : a.disabled = n) : f === "INPUT" ? s && ["button", "submit", "reset"].includes(s) && (l ? a["aria-disabled"] = n : a.disabled = n) : f !== "" && (!c && !m && (a.role = "button", a.tabIndex = u ?? 0), n && (a["aria-disabled"] = n, a.tabIndex = l ? u ?? 0 : -1)), {
|
|
82
|
-
getRootProps: (t = {}) => {
|
|
83
|
-
const e = D({}, k(p), k(t)), o = D({
|
|
84
|
-
type: s
|
|
85
|
-
}, e, a, t, {
|
|
86
|
-
onBlur: K(e),
|
|
87
|
-
onClick: I(e),
|
|
88
|
-
onFocus: P(e),
|
|
89
|
-
onKeyDown: C(e),
|
|
90
|
-
onKeyUp: _(e),
|
|
91
|
-
onMouseDown: $(e),
|
|
92
|
-
onMouseLeave: w(e),
|
|
93
|
-
ref: x
|
|
94
|
-
});
|
|
95
|
-
return delete o.onFocusVisible, o;
|
|
96
|
-
},
|
|
97
|
-
focusVisible: d,
|
|
98
|
-
setFocusVisible: R,
|
|
99
|
-
active: B,
|
|
100
|
-
rootRef: x
|
|
101
|
-
};
|
|
102
|
-
}
|
|
103
|
-
export {
|
|
104
|
-
W as u
|
|
105
|
-
};
|