laif-ds 0.1.21 → 0.1.22

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.
Files changed (48) hide show
  1. package/README.md +84 -3
  2. package/dist/_virtual/index.js +2 -7
  3. package/dist/_virtual/index2.js +2 -5
  4. package/dist/_virtual/index3.js +7 -2
  5. package/dist/_virtual/index4.js +5 -2
  6. package/dist/_virtual/index5.js +5 -2
  7. package/dist/_virtual/index6.js +2 -5
  8. package/dist/components/ui/app-sidebar.js +113 -98
  9. package/dist/components/ui/data-table.js +26 -26
  10. package/dist/components/ui/date-picker.js +24 -24
  11. package/dist/components/ui/gantt/components/Chart/Chart.js +1 -1
  12. package/dist/components/ui/multiple-selector.js +80 -79
  13. package/dist/components/ui/sidebar.js +1 -1
  14. package/dist/index.d.ts +2 -9
  15. package/dist/node_modules/hast-util-to-jsx-runtime/lib/index.js +1 -1
  16. package/dist/node_modules/react-is/index.js +1 -1
  17. package/dist/node_modules/recharts/es6/util/ReactUtils.js +1 -1
  18. package/dist/node_modules/style-to-object/cjs/index.js +1 -1
  19. package/dist/node_modules/unified/lib/index.js +1 -1
  20. package/dist/styles.css +1 -1
  21. package/dist/styles.v3.css +1 -1
  22. package/package.json +1 -1
  23. package/dist/dist/components/ui/checkbox.js +0 -32
  24. package/dist/dist/components/ui/scroll-area.js +0 -61
  25. package/dist/dist/components/ui/table.js +0 -87
  26. package/dist/dist/lib/utils.js +0 -9
  27. package/dist/dist/node_modules/@radix-ui/number/dist/index.js +0 -7
  28. package/dist/dist/node_modules/@radix-ui/primitive/dist/index.js +0 -10
  29. package/dist/dist/node_modules/@radix-ui/react-checkbox/dist/index.js +0 -136
  30. package/dist/dist/node_modules/@radix-ui/react-compose-refs/dist/index.js +0 -30
  31. package/dist/dist/node_modules/@radix-ui/react-context/dist/index.js +0 -56
  32. package/dist/dist/node_modules/@radix-ui/react-direction/dist/index.js +0 -11
  33. package/dist/dist/node_modules/@radix-ui/react-presence/dist/index.js +0 -72
  34. package/dist/dist/node_modules/@radix-ui/react-primitive/dist/index.js +0 -32
  35. package/dist/dist/node_modules/@radix-ui/react-scroll-area/dist/index.js +0 -534
  36. package/dist/dist/node_modules/@radix-ui/react-slot/dist/index.js +0 -50
  37. package/dist/dist/node_modules/@radix-ui/react-use-callback-ref/dist/index.js +0 -14
  38. package/dist/dist/node_modules/@radix-ui/react-use-controllable-state/dist/index.js +0 -33
  39. package/dist/dist/node_modules/@radix-ui/react-use-layout-effect/dist/index.js +0 -7
  40. package/dist/dist/node_modules/@radix-ui/react-use-previous/dist/index.js +0 -9
  41. package/dist/dist/node_modules/@radix-ui/react-use-size/dist/index.js +0 -28
  42. package/dist/dist/node_modules/clsx/dist/clsx.js +0 -18
  43. package/dist/dist/node_modules/lucide-react/dist/esm/Icon.js +0 -41
  44. package/dist/dist/node_modules/lucide-react/dist/esm/createLucideIcon.js +0 -28
  45. package/dist/dist/node_modules/lucide-react/dist/esm/defaultAttributes.js +0 -21
  46. package/dist/dist/node_modules/lucide-react/dist/esm/icons/check.js +0 -13
  47. package/dist/dist/node_modules/lucide-react/dist/esm/shared/src/utils.js +0 -20
  48. package/dist/dist/node_modules/tailwind-merge/dist/bundle-mjs.js +0 -2732
@@ -1,9 +0,0 @@
1
- "use client";
2
- import { clsx as e } from "../node_modules/clsx/dist/clsx.js";
3
- import { twMerge as o } from "../node_modules/tailwind-merge/dist/bundle-mjs.js";
4
- function i(...r) {
5
- return o(e(r));
6
- }
7
- export {
8
- i as cn
9
- };
@@ -1,7 +0,0 @@
1
- "use client";
2
- function n(t, [a, e]) {
3
- return Math.min(e, Math.max(a, t));
4
- }
5
- export {
6
- n as clamp
7
- };
@@ -1,10 +0,0 @@
1
- "use client";
2
- function u(n, t, { checkForDefaultPrevented: r = !0 } = {}) {
3
- return function(e) {
4
- if (n == null || n(e), r === !1 || !e.defaultPrevented)
5
- return t == null ? void 0 : t(e);
6
- };
7
- }
8
- export {
9
- u as composeEventHandlers
10
- };
@@ -1,136 +0,0 @@
1
- "use client";
2
- import * as n from "react";
3
- import { useComposedRefs as q } from "../../react-compose-refs/dist/index.js";
4
- import { createContextScope as L } from "../../react-context/dist/index.js";
5
- import { composeEventHandlers as w } from "../../primitive/dist/index.js";
6
- import { useControllableState as j } from "../../react-use-controllable-state/dist/index.js";
7
- import { usePrevious as z } from "../../react-use-previous/dist/index.js";
8
- import { useSize as N } from "../../react-use-size/dist/index.js";
9
- import { Presence as H } from "../../react-presence/dist/index.js";
10
- import { Primitive as P } from "../../react-primitive/dist/index.js";
11
- import { jsxs as K, jsx as b } from "react/jsx-runtime";
12
- var E = "Checkbox", [M, W] = L(E), [O, T] = M(E), g = n.forwardRef(
13
- (e, u) => {
14
- const {
15
- __scopeCheckbox: t,
16
- name: i,
17
- checked: f,
18
- defaultChecked: o,
19
- required: p,
20
- disabled: c,
21
- value: h = "on",
22
- onCheckedChange: k,
23
- form: d,
24
- ...v
25
- } = e, [a, C] = n.useState(null), D = q(u, (r) => C(r)), x = n.useRef(!1), R = a ? d || !!a.closest("form") : !0, [l = !1, y] = j({
26
- prop: f,
27
- defaultProp: o,
28
- onChange: k
29
- }), I = n.useRef(l);
30
- return n.useEffect(() => {
31
- const r = a == null ? void 0 : a.form;
32
- if (r) {
33
- const m = () => y(I.current);
34
- return r.addEventListener("reset", m), () => r.removeEventListener("reset", m);
35
- }
36
- }, [a, y]), /* @__PURE__ */ K(O, { scope: t, state: l, disabled: c, children: [
37
- /* @__PURE__ */ b(
38
- P.button,
39
- {
40
- type: "button",
41
- role: "checkbox",
42
- "aria-checked": s(l) ? "mixed" : l,
43
- "aria-required": p,
44
- "data-state": _(l),
45
- "data-disabled": c ? "" : void 0,
46
- disabled: c,
47
- value: h,
48
- ...v,
49
- ref: D,
50
- onKeyDown: w(e.onKeyDown, (r) => {
51
- r.key === "Enter" && r.preventDefault();
52
- }),
53
- onClick: w(e.onClick, (r) => {
54
- y((m) => s(m) ? !0 : !m), R && (x.current = r.isPropagationStopped(), x.current || r.stopPropagation());
55
- })
56
- }
57
- ),
58
- R && /* @__PURE__ */ b(
59
- X,
60
- {
61
- control: a,
62
- bubbles: !x.current,
63
- name: i,
64
- value: h,
65
- checked: l,
66
- required: p,
67
- disabled: c,
68
- form: d,
69
- style: { transform: "translateX(-100%)" },
70
- defaultChecked: s(o) ? !1 : o
71
- }
72
- )
73
- ] });
74
- }
75
- );
76
- g.displayName = E;
77
- var $ = "CheckboxIndicator", S = n.forwardRef(
78
- (e, u) => {
79
- const { __scopeCheckbox: t, forceMount: i, ...f } = e, o = T($, t);
80
- return /* @__PURE__ */ b(H, { present: i || s(o.state) || o.state === !0, children: /* @__PURE__ */ b(
81
- P.span,
82
- {
83
- "data-state": _(o.state),
84
- "data-disabled": o.disabled ? "" : void 0,
85
- ...f,
86
- ref: u,
87
- style: { pointerEvents: "none", ...e.style }
88
- }
89
- ) });
90
- }
91
- );
92
- S.displayName = $;
93
- var X = (e) => {
94
- const { control: u, checked: t, bubbles: i = !0, defaultChecked: f, ...o } = e, p = n.useRef(null), c = z(t), h = N(u);
95
- n.useEffect(() => {
96
- const d = p.current, v = window.HTMLInputElement.prototype, a = Object.getOwnPropertyDescriptor(v, "checked").set;
97
- if (c !== t && a) {
98
- const C = new Event("click", { bubbles: i });
99
- d.indeterminate = s(t), a.call(d, s(t) ? !1 : t), d.dispatchEvent(C);
100
- }
101
- }, [c, t, i]);
102
- const k = n.useRef(s(t) ? !1 : t);
103
- return /* @__PURE__ */ b(
104
- "input",
105
- {
106
- type: "checkbox",
107
- "aria-hidden": !0,
108
- defaultChecked: f ?? k.current,
109
- ...o,
110
- tabIndex: -1,
111
- ref: p,
112
- style: {
113
- ...e.style,
114
- ...h,
115
- position: "absolute",
116
- pointerEvents: "none",
117
- opacity: 0,
118
- margin: 0
119
- }
120
- }
121
- );
122
- };
123
- function s(e) {
124
- return e === "indeterminate";
125
- }
126
- function _(e) {
127
- return s(e) ? "indeterminate" : e ? "checked" : "unchecked";
128
- }
129
- var Y = g, ee = S;
130
- export {
131
- g as Checkbox,
132
- S as CheckboxIndicator,
133
- ee as Indicator,
134
- Y as Root,
135
- W as createCheckboxScope
136
- };
@@ -1,30 +0,0 @@
1
- "use client";
2
- import * as c from "react";
3
- function r(t, o) {
4
- if (typeof t == "function")
5
- return t(o);
6
- t != null && (t.current = o);
7
- }
8
- function s(...t) {
9
- return (o) => {
10
- let u = !1;
11
- const f = t.map((e) => {
12
- const n = r(e, o);
13
- return !u && typeof n == "function" && (u = !0), n;
14
- });
15
- if (u)
16
- return () => {
17
- for (let e = 0; e < f.length; e++) {
18
- const n = f[e];
19
- typeof n == "function" ? n() : r(t[e], null);
20
- }
21
- };
22
- };
23
- }
24
- function l(...t) {
25
- return c.useCallback(s(...t), t);
26
- }
27
- export {
28
- s as composeRefs,
29
- l as useComposedRefs
30
- };
@@ -1,56 +0,0 @@
1
- "use client";
2
- import * as s from "react";
3
- import { jsx as x } from "react/jsx-runtime";
4
- function S(o, u = []) {
5
- let n = [];
6
- function d(r, e) {
7
- const c = s.createContext(e), l = n.length;
8
- n = [...n, e];
9
- const m = (v) => {
10
- var i;
11
- const { scope: a, children: f, ...p } = v, _ = ((i = a == null ? void 0 : a[o]) == null ? void 0 : i[l]) || c, h = s.useMemo(() => p, Object.values(p));
12
- return /* @__PURE__ */ x(_.Provider, { value: h, children: f });
13
- };
14
- m.displayName = r + "Provider";
15
- function N(v, i) {
16
- var a;
17
- const f = ((a = i == null ? void 0 : i[o]) == null ? void 0 : a[l]) || c, p = s.useContext(f);
18
- if (p) return p;
19
- if (e !== void 0) return e;
20
- throw new Error(`\`${v}\` must be used within \`${r}\``);
21
- }
22
- return [m, N];
23
- }
24
- const t = () => {
25
- const r = n.map((e) => s.createContext(e));
26
- return function(e) {
27
- const c = (e == null ? void 0 : e[o]) || r;
28
- return s.useMemo(
29
- () => ({ [`__scope${o}`]: { ...e, [o]: c } }),
30
- [e, c]
31
- );
32
- };
33
- };
34
- return t.scopeName = o, [d, C(t, ...u)];
35
- }
36
- function C(...o) {
37
- const u = o[0];
38
- if (o.length === 1) return u;
39
- const n = () => {
40
- const d = o.map((t) => ({
41
- useScope: t(),
42
- scopeName: t.scopeName
43
- }));
44
- return function(t) {
45
- const r = d.reduce((e, { useScope: c, scopeName: l }) => {
46
- const m = c(t)[`__scope${l}`];
47
- return { ...e, ...m };
48
- }, {});
49
- return s.useMemo(() => ({ [`__scope${u.scopeName}`]: r }), [r]);
50
- };
51
- };
52
- return n.scopeName = u.scopeName, n;
53
- }
54
- export {
55
- S as createContextScope
56
- };
@@ -1,11 +0,0 @@
1
- "use client";
2
- import * as t from "react";
3
- import "react/jsx-runtime";
4
- var r = t.createContext(void 0);
5
- function i(e) {
6
- const o = t.useContext(r);
7
- return e || o || "ltr";
8
- }
9
- export {
10
- i as useDirection
11
- };
@@ -1,72 +0,0 @@
1
- "use client";
2
- import * as u from "react";
3
- import { useComposedRefs as M } from "../../react-compose-refs/dist/index.js";
4
- import { useLayoutEffect as N } from "../../react-use-layout-effect/dist/index.js";
5
- function y(n, e) {
6
- return u.useReducer((r, t) => e[r][t] ?? r, n);
7
- }
8
- var g = (n) => {
9
- const { present: e, children: r } = n, t = E(e), i = typeof r == "function" ? r({ present: t.isPresent }) : u.Children.only(r), c = M(t.ref, R(i));
10
- return typeof r == "function" || t.isPresent ? u.cloneElement(i, { ref: c }) : null;
11
- };
12
- g.displayName = "Presence";
13
- function E(n) {
14
- const [e, r] = u.useState(), t = u.useRef({}), i = u.useRef(n), c = u.useRef("none"), O = n ? "mounted" : "unmounted", [p, s] = y(O, {
15
- mounted: {
16
- UNMOUNT: "unmounted",
17
- ANIMATION_OUT: "unmountSuspended"
18
- },
19
- unmountSuspended: {
20
- MOUNT: "mounted",
21
- ANIMATION_END: "unmounted"
22
- },
23
- unmounted: {
24
- MOUNT: "mounted"
25
- }
26
- });
27
- return u.useEffect(() => {
28
- const o = f(t.current);
29
- c.current = p === "mounted" ? o : "none";
30
- }, [p]), N(() => {
31
- const o = t.current, d = i.current;
32
- if (d !== n) {
33
- const a = c.current, m = f(o);
34
- n ? s("MOUNT") : m === "none" || (o == null ? void 0 : o.display) === "none" ? s("UNMOUNT") : s(d && a !== m ? "ANIMATION_OUT" : "UNMOUNT"), i.current = n;
35
- }
36
- }, [n, s]), N(() => {
37
- if (e) {
38
- let o;
39
- const d = e.ownerDocument.defaultView ?? window, a = (l) => {
40
- const v = f(t.current).includes(l.animationName);
41
- if (l.target === e && v && (s("ANIMATION_END"), !i.current)) {
42
- const T = e.style.animationFillMode;
43
- e.style.animationFillMode = "forwards", o = d.setTimeout(() => {
44
- e.style.animationFillMode === "forwards" && (e.style.animationFillMode = T);
45
- });
46
- }
47
- }, m = (l) => {
48
- l.target === e && (c.current = f(t.current));
49
- };
50
- return e.addEventListener("animationstart", m), e.addEventListener("animationcancel", a), e.addEventListener("animationend", a), () => {
51
- d.clearTimeout(o), e.removeEventListener("animationstart", m), e.removeEventListener("animationcancel", a), e.removeEventListener("animationend", a);
52
- };
53
- } else
54
- s("ANIMATION_END");
55
- }, [e, s]), {
56
- isPresent: ["mounted", "unmountSuspended"].includes(p),
57
- ref: u.useCallback((o) => {
58
- o && (t.current = getComputedStyle(o)), r(o);
59
- }, [])
60
- };
61
- }
62
- function f(n) {
63
- return (n == null ? void 0 : n.animationName) || "none";
64
- }
65
- function R(n) {
66
- var e, r;
67
- let t = (e = Object.getOwnPropertyDescriptor(n.props, "ref")) == null ? void 0 : e.get, i = t && "isReactWarning" in t && t.isReactWarning;
68
- return i ? n.ref : (t = (r = Object.getOwnPropertyDescriptor(n, "ref")) == null ? void 0 : r.get, i = t && "isReactWarning" in t && t.isReactWarning, i ? n.props.ref : n.props.ref || n.ref);
69
- }
70
- export {
71
- g as Presence
72
- };
@@ -1,32 +0,0 @@
1
- "use client";
2
- import * as l from "react";
3
- import "react-dom";
4
- import { createSlot as p } from "../../react-slot/dist/index.js";
5
- import { jsx as u } from "react/jsx-runtime";
6
- var f = [
7
- "a",
8
- "button",
9
- "div",
10
- "form",
11
- "h2",
12
- "h3",
13
- "img",
14
- "input",
15
- "label",
16
- "li",
17
- "nav",
18
- "ol",
19
- "p",
20
- "span",
21
- "svg",
22
- "ul"
23
- ], w = f.reduce((o, r) => {
24
- const t = p(`Primitive.${r}`), i = l.forwardRef((e, a) => {
25
- const { asChild: m, ...n } = e, s = m ? t : r;
26
- return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ u(s, { ...n, ref: a });
27
- });
28
- return i.displayName = `Primitive.${r}`, { ...o, [r]: i };
29
- }, {});
30
- export {
31
- w as Primitive
32
- };