@konstructio/ui 0.1.2-alpha.67 → 0.1.2-alpha.69
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/AdditionalOptions-C2FDVZhu.js +45 -0
- package/dist/Modal-BGcucTHv.js +120 -0
- package/dist/assets/icons/components/CloudLockOutline.d.ts +3 -0
- package/dist/assets/icons/components/CloudLockOutline.js +28 -0
- package/dist/assets/icons/components/index.d.ts +1 -0
- package/dist/assets/icons/components/index.js +106 -104
- package/dist/assets/icons/index.js +106 -104
- package/dist/components/ButtonGroup/ButtonGroup.js +65 -61
- package/dist/components/ButtonGroup/ButtonGroup.types.d.ts +6 -0
- package/dist/components/ButtonGroup/components/ButtonGroupItem/ButtonGroupItem.js +32 -30
- package/dist/components/ButtonGroup/components/ButtonGroupItem/ButtonGroupItem.types.d.ts +3 -1
- package/dist/components/ButtonGroup/components/ButtonGroupItem/ButtonGroupItem.variants.d.ts +4 -1
- package/dist/components/ButtonGroup/components/ButtonGroupItem/ButtonGroupItem.variants.js +37 -17
- package/dist/components/DateRangePicker/components/CalendarPanel/components/IndependentModeCalendar/IndependentModeCalendar.js +1 -1
- package/dist/components/DateRangePicker/components/CalendarPanel/components/TogetherModeCalendar/TogetherModeCalendar.js +1 -1
- package/dist/components/Modal/Modal.js +1 -1
- package/dist/components/Modal/Modal.types.d.ts +7 -2
- package/dist/components/Modal/components/Wrapper/Wrapper.js +3 -2
- package/dist/components/Modal/components/Wrapper/Wrapper.types.d.ts +3 -0
- package/dist/components/Modal/components/Wrapper/Wrapper.variants.js +2 -2
- package/dist/components/Modal/components/index.js +1 -1
- package/dist/components/Select/Select.d.ts +1 -0
- package/dist/components/Select/Select.js +65 -42
- package/dist/components/Select/Select.types.d.ts +18 -2
- package/dist/components/Select/Select.variants.js +1 -1
- package/dist/components/Select/components/AdditionalOptions/AdditionalOptions.d.ts +3 -0
- package/dist/components/Select/components/AdditionalOptions/AdditionalOptions.js +11 -0
- package/dist/components/Select/components/AdditionalOptions/AdditionalOptions.types.d.ts +4 -0
- package/dist/components/Select/components/AdditionalOptions/AdditionalOptions.variants.d.ts +1 -0
- package/dist/components/Select/components/AdditionalOptions/AdditionalOptions.variants.js +26 -0
- package/dist/components/Select/components/List/List.js +131 -132
- package/dist/components/Select/components/List/List.types.d.ts +1 -0
- package/dist/components/Select/components/List/List.variants.d.ts +1 -0
- package/dist/components/Select/components/List/List.variants.js +18 -3
- package/dist/components/Select/components/Wrapper.d.ts +3 -1
- package/dist/components/Select/components/Wrapper.js +65 -63
- package/dist/components/Select/components/index.d.ts +1 -0
- package/dist/components/Select/components/index.js +8 -6
- package/dist/components/index.js +1 -1
- package/dist/icons.d.ts +1 -1
- package/dist/icons.js +106 -104
- package/dist/index.js +1 -1
- package/dist/package.json +3 -3
- package/dist/{proxy-BIRlSMN_.js → proxy-CngVm5qA.js} +1834 -1852
- package/dist/styles.css +1 -1
- package/package.json +3 -3
- package/dist/Modal--z642-Wv.js +0 -112
package/dist/Modal--z642-Wv.js
DELETED
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
import { Body as R } from "./components/Modal/components/Body/Body.js";
|
|
2
|
-
import { Footer as g } from "./components/Modal/components/Footer/Footer.js";
|
|
3
|
-
import { Header as k } from "./components/Modal/components/Header/Header.js";
|
|
4
|
-
import { jsx as n, jsxs as c, Fragment as v } from "react/jsx-runtime";
|
|
5
|
-
import { Children as d, isValidElement as m, useRef as w, useState as A, useEffect as b } from "react";
|
|
6
|
-
import { createPortal as F } from "react-dom";
|
|
7
|
-
import { R as N } from "./index-BKjcReYh.js";
|
|
8
|
-
import { R as x } from "./Combination-BtmnusWq.js";
|
|
9
|
-
import { cn as h } from "./utils/index.js";
|
|
10
|
-
import { buttonCloseVariants as B, modalVariants as C } from "./components/Modal/components/Wrapper/Wrapper.variants.js";
|
|
11
|
-
import { X as E } from "./x-Eoa9FJjA.js";
|
|
12
|
-
const H = ({
|
|
13
|
-
buttonCloseClassName: l,
|
|
14
|
-
children: r,
|
|
15
|
-
className: s,
|
|
16
|
-
showCloseButton: i = !0,
|
|
17
|
-
theme: f,
|
|
18
|
-
onClose: a
|
|
19
|
-
}) => {
|
|
20
|
-
const p = d.toArray(r).find(
|
|
21
|
-
(e) => m(e) && e.type === t.Header
|
|
22
|
-
), u = d.toArray(r).find(
|
|
23
|
-
(e) => m(e) && e.type === t.Body
|
|
24
|
-
), o = d.toArray(r).find(
|
|
25
|
-
(e) => m(e) && e.type === t.Footer
|
|
26
|
-
), y = d.toArray(r).filter(
|
|
27
|
-
(e) => !m(e) || ![t.Header, t.Body, t.Footer].includes(
|
|
28
|
-
e.type
|
|
29
|
-
)
|
|
30
|
-
);
|
|
31
|
-
return /* @__PURE__ */ n(x, { children: /* @__PURE__ */ c(
|
|
32
|
-
"div",
|
|
33
|
-
{
|
|
34
|
-
className: "fixed inset-0 grid place-content-center",
|
|
35
|
-
"data-theme": f,
|
|
36
|
-
children: [
|
|
37
|
-
/* @__PURE__ */ n(
|
|
38
|
-
"div",
|
|
39
|
-
{
|
|
40
|
-
className: "absolute inset-0 bg-black opacity-70 dark:opacity-85 animate-in fade-in-0",
|
|
41
|
-
onClick: a,
|
|
42
|
-
role: "presentation"
|
|
43
|
-
}
|
|
44
|
-
),
|
|
45
|
-
/* @__PURE__ */ c(
|
|
46
|
-
"div",
|
|
47
|
-
{
|
|
48
|
-
className: h(
|
|
49
|
-
C({
|
|
50
|
-
className: s
|
|
51
|
-
})
|
|
52
|
-
),
|
|
53
|
-
role: "dialog",
|
|
54
|
-
"aria-modal": "true",
|
|
55
|
-
children: [
|
|
56
|
-
p,
|
|
57
|
-
i && /* @__PURE__ */ c(
|
|
58
|
-
"button",
|
|
59
|
-
{
|
|
60
|
-
className: h(
|
|
61
|
-
B({
|
|
62
|
-
className: l
|
|
63
|
-
})
|
|
64
|
-
),
|
|
65
|
-
onClick: a,
|
|
66
|
-
children: [
|
|
67
|
-
/* @__PURE__ */ n(E, {}),
|
|
68
|
-
/* @__PURE__ */ n(N, { children: "Dismiss modal" })
|
|
69
|
-
]
|
|
70
|
-
}
|
|
71
|
-
),
|
|
72
|
-
u ?? y,
|
|
73
|
-
o
|
|
74
|
-
]
|
|
75
|
-
}
|
|
76
|
-
)
|
|
77
|
-
]
|
|
78
|
-
}
|
|
79
|
-
) });
|
|
80
|
-
}, t = ({ isOpen: l, onClose: r, container: s, theme: i, ...f }) => {
|
|
81
|
-
const a = w(null), [p, u] = A(
|
|
82
|
-
null
|
|
83
|
-
);
|
|
84
|
-
return b(() => {
|
|
85
|
-
if (!a.current || i || s)
|
|
86
|
-
return;
|
|
87
|
-
const o = a.current.closest("[data-theme]");
|
|
88
|
-
o && u(o);
|
|
89
|
-
}, [i, s]), b(() => {
|
|
90
|
-
const o = new AbortController(), y = (e) => {
|
|
91
|
-
e.code === "Escape" && r?.();
|
|
92
|
-
};
|
|
93
|
-
return window.addEventListener("keydown", y, {
|
|
94
|
-
signal: o.signal
|
|
95
|
-
}), () => {
|
|
96
|
-
o.abort();
|
|
97
|
-
};
|
|
98
|
-
}, [r]), /* @__PURE__ */ c(v, { children: [
|
|
99
|
-
/* @__PURE__ */ n("span", { ref: a, "data-testid": "modal-anchor", hidden: !0 }),
|
|
100
|
-
l && F(
|
|
101
|
-
/* @__PURE__ */ n(H, { ...f, theme: i, onClose: r }),
|
|
102
|
-
s || p || document.body
|
|
103
|
-
)
|
|
104
|
-
] });
|
|
105
|
-
};
|
|
106
|
-
t.Header = k;
|
|
107
|
-
t.Body = R;
|
|
108
|
-
t.Footer = g;
|
|
109
|
-
export {
|
|
110
|
-
t as M,
|
|
111
|
-
H as W
|
|
112
|
-
};
|