@oneplatformdev/ui 0.0.1-beta.18 → 0.0.1-beta.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (39) hide show
  1. package/AlertDialog/AlertDialog.d.ts +0 -14
  2. package/AlertDialog/AlertDialog.mjs +60 -58
  3. package/Combobox/Combobox.mjs +60 -71
  4. package/Combobox/Combobox.types.d.ts +0 -7
  5. package/FormSelect/FormSelect.types.d.ts +1 -1
  6. package/Input/Input.d.ts +3 -5
  7. package/Input/Input.mjs +18 -58
  8. package/Input/Input.types.d.ts +2 -11
  9. package/Input/index.d.ts +0 -1
  10. package/Input/index.mjs +2 -5
  11. package/LazyLoader/LazyLoader.d.ts +0 -17
  12. package/LazyLoader/index.d.ts +1 -1
  13. package/LazyLoader/index.mjs +2 -3
  14. package/Search/index.d.ts +0 -1
  15. package/Search/index.mjs +2 -3
  16. package/Sidebar/Sidebar.d.ts +1 -1
  17. package/index.css +1 -1
  18. package/index.d.ts +0 -2
  19. package/index.mjs +293 -302
  20. package/package.json +6 -7
  21. package/Dropzone/Dropzone.d.ts +0 -22
  22. package/Dropzone/Dropzone.mjs +0 -136
  23. package/Dropzone/Dropzone.types.d.ts +0 -36
  24. package/Dropzone/DropzoneFilePreview.d.ts +0 -4
  25. package/Dropzone/DropzoneFilePreview.mjs +0 -9
  26. package/Dropzone/DropzoneUtils.d.ts +0 -4
  27. package/Dropzone/DropzoneUtils.mjs +0 -15
  28. package/Dropzone/index.d.ts +0 -2
  29. package/Dropzone/index.mjs +0 -7
  30. package/Dropzone/package.json +0 -7
  31. package/DropzoneFilePreview-Dhtv8F4u.js +0 -67
  32. package/FormDropzone/FormDropzone.d.ts +0 -4
  33. package/FormDropzone/FormDropzone.mjs +0 -26
  34. package/FormDropzone/FormDropzone.types.d.ts +0 -7
  35. package/FormDropzone/index.d.ts +0 -2
  36. package/FormDropzone/index.mjs +0 -4
  37. package/FormDropzone/package.json +0 -7
  38. package/Input/inputVariants.d.ts +0 -3
  39. package/Input/inputVariants.mjs +0 -18
@@ -6,10 +6,6 @@ import { FC, PropsWithChildren } from 'react';
6
6
  * @public
7
7
  * @see [Documentation](#)
8
8
  * @example
9
- * > Import:
10
- * ```tsx
11
- * import { AlertDialog } from '@oneplatformdev/ui/AlertDialog';
12
- * ```
13
9
  * > Simple example:
14
10
  * ```tsx
15
11
  * <AlertDialog
@@ -29,16 +25,6 @@ import { FC, PropsWithChildren } from 'react';
29
25
  * onConfirm={(event) => console.log(event, 'Confirm')}
30
26
  * />
31
27
  * ```
32
- * > Trigger example: Button with icon children
33
- * ```tsx
34
- * <AlertDialog
35
- * trigger={<Button variant="outline" size="icon"><PencilLine /></Button>}
36
- * title="Dialog title with icon trigger"
37
- * description="Description text..."
38
- * onCancel={(event) => console.log(event, 'Cancel')}
39
- * onConfirm={(event) => console.log(event, 'Confirm')}
40
- * />
41
- * ```
42
28
  *
43
29
  * > Full content example:
44
30
  * ```tsx
@@ -1,97 +1,99 @@
1
- import { jsxs as g, jsx as t } from "react/jsx-runtime";
2
- import { cloneElement as a, useId as j, Children as y } from "react";
3
- import { AlertDialogRoot as E, AlertDialogContent as u, AlertDialogTrigger as v, AlertDialogHeader as f, AlertDialogTitle as B, AlertDialogDescription as R, AlertDialogFooter as A, AlertDialogAction as D, AlertDialogCancel as k } from "./AlertDialogRoot.mjs";
4
- import { isValidReactElement as s } from "@oneplatformdev/utils";
5
- const F = (o) => {
6
- const { slotProps: e = {}, children: r } = o, i = e.trigger ?? {};
7
- return s(r, v) ? a(
1
+ import { jsxs as u, jsx as t } from "react/jsx-runtime";
2
+ import { cloneElement as a, useId as y, Children as E } from "react";
3
+ import { AlertDialogRoot as F, AlertDialogContent as h, AlertDialogTrigger as f, AlertDialogHeader as m, AlertDialogTitle as B, AlertDialogDescription as R, AlertDialogFooter as A, AlertDialogAction as C, AlertDialogCancel as k } from "./AlertDialogRoot.mjs";
4
+ import { Button as x } from "../Button/Button.mjs";
5
+ import "../Button/buttonVariants.mjs";
6
+ import { isValidReactElement as l } from "@oneplatformdev/utils";
7
+ const H = (n) => {
8
+ const { slotProps: e = {}, children: r } = n, o = e.trigger ?? {};
9
+ return l(r, f) ? a(
8
10
  r,
9
11
  {
10
12
  ...r.props || {},
11
- ...i
13
+ ...o
12
14
  }
13
- ) : /* @__PURE__ */ t(v, { asChild: !0, children: r });
14
- }, H = (o) => {
15
+ ) : l(r, x) ? /* @__PURE__ */ t(f, { asChild: !0, ...o, children: r }) : /* @__PURE__ */ t(f, { asChild: !0, children: /* @__PURE__ */ t(x, { variant: "outline", ...o, children: r }) });
16
+ }, I = (n) => {
15
17
  const {
16
18
  title: e = "",
17
19
  description: r = "",
18
- slotProps: i = {},
19
- children: l
20
- } = o, n = i.header ?? {}, d = i.title ?? {}, c = i.description ?? {};
21
- return l ? s(l, f) ? a(
22
- l,
23
- { ...l.props || {}, ...n }
24
- ) : /* @__PURE__ */ t(f, { ...n, children: l }) : /* @__PURE__ */ g(f, { children: [
25
- e && s(e, B) ? a(
20
+ slotProps: o = {},
21
+ children: c
22
+ } = n, i = o.header ?? {}, d = o.title ?? {}, s = o.description ?? {};
23
+ return c ? l(c, m) ? a(
24
+ c,
25
+ { ...c.props || {}, ...i }
26
+ ) : /* @__PURE__ */ t(m, { ...i, children: c }) : /* @__PURE__ */ u(m, { children: [
27
+ e && l(e, B) ? a(
26
28
  e,
27
29
  { ...e.props || {}, ...d }
28
30
  ) : /* @__PURE__ */ t(B, { ...d, children: e }),
29
- r && s(r, R) ? a(
31
+ r && l(r, R) ? a(
30
32
  r,
31
- { ...r.props || {}, ...c }
32
- ) : /* @__PURE__ */ t(R, { ...c, children: r })
33
+ { ...r.props || {}, ...s }
34
+ ) : /* @__PURE__ */ t(R, { ...s, children: r })
33
35
  ] });
34
- }, I = (o) => {
36
+ }, L = (n) => {
35
37
  const {
36
38
  slotProps: e = {},
37
39
  children: r,
38
- onCancel: i,
39
- onConfirm: l,
40
- cancelLabel: n = "Cancel",
40
+ onCancel: o,
41
+ onConfirm: c,
42
+ cancelLabel: i = "Cancel",
41
43
  actionLabel: d = "Continue",
42
- variant: c = "confirm"
43
- } = o, x = j(), m = e.footer ?? {}, T = e.cancelButton ?? {}, C = e.actionButton ?? {};
44
- return r ? s(r, A) ? a(
44
+ variant: s = "confirm"
45
+ } = n, T = y(), D = e.footer ?? {}, b = e.cancelButton ?? {}, P = e.actionButton ?? {};
46
+ return r ? l(r, A) ? a(
45
47
  r,
46
- { ...r.props || {}, ...m }
47
- ) : /* @__PURE__ */ t(A, { ...m, children: y.map(r, (p, b) => {
48
- if (!p || !s(p)) return;
49
- const h = p, P = a(h, { ...h.props || {}, key: h.key || `footer-${x}-action-${b}` });
50
- return s(p, D) || s(p, k) ? P : /* @__PURE__ */ t(D, { asChild: !0, children: P });
51
- }) }) : /* @__PURE__ */ g(A, { children: [
52
- c !== "alert" && /* @__PURE__ */ t(
48
+ { ...r.props || {}, ...D }
49
+ ) : /* @__PURE__ */ t(A, { ...D, children: E.map(r, (p, j) => {
50
+ if (!p || !l(p)) return;
51
+ const g = p, v = a(g, { ...g.props || {}, key: g.key || `footer-${T}-action-${j}` });
52
+ return l(p, C) || l(p, k) ? v : /* @__PURE__ */ t(C, { asChild: !0, children: v });
53
+ }) }) : /* @__PURE__ */ u(A, { children: [
54
+ s !== "alert" && /* @__PURE__ */ t(
53
55
  k,
54
56
  {
55
57
  variant: "ghost",
56
- onClick: i,
57
- ...T,
58
- children: n
58
+ onClick: o,
59
+ ...b,
60
+ children: i
59
61
  }
60
62
  ),
61
63
  /* @__PURE__ */ t(
62
- D,
64
+ C,
63
65
  {
64
- onClick: l,
65
- ...C,
66
- variant: C.variant || c === "destructive" ? "destructive" : "default",
66
+ onClick: c,
67
+ ...P,
68
+ variant: P.variant || s === "destructive" ? "destructive" : "default",
67
69
  children: d
68
70
  }
69
71
  )
70
72
  ] });
71
- }, w = (o) => {
73
+ }, J = (n) => {
72
74
  const {
73
75
  trigger: e,
74
76
  header: r,
75
- footer: i,
76
- slotProps: l = {},
77
- children: n,
77
+ footer: o,
78
+ slotProps: c = {},
79
+ children: i,
78
80
  ...d
79
- } = o, c = l.content ?? {};
80
- return /* @__PURE__ */ g(E, { ...d, children: [
81
- /* @__PURE__ */ t(F, { ...o, children: e }),
82
- n ? s(n, u) ? a(
83
- n,
81
+ } = n, s = c.content ?? {};
82
+ return /* @__PURE__ */ u(F, { ...d, children: [
83
+ /* @__PURE__ */ t(H, { ...n, children: e }),
84
+ i ? l(i, h) ? a(
85
+ i,
84
86
  {
85
- ...n.props || {},
86
- ...c
87
+ ...i.props || {},
88
+ ...s
87
89
  }
88
- ) : /* @__PURE__ */ t(u, { ...c, children: n }) : /* @__PURE__ */ g(u, { ...c, children: [
89
- /* @__PURE__ */ t(H, { ...o, children: r }),
90
- /* @__PURE__ */ t(I, { ...o, children: i })
90
+ ) : /* @__PURE__ */ t(h, { ...s, children: i }) : /* @__PURE__ */ u(h, { ...s, children: [
91
+ /* @__PURE__ */ t(I, { ...n, children: r }),
92
+ /* @__PURE__ */ t(L, { ...n, children: o })
91
93
  ] })
92
94
  ] });
93
95
  };
94
96
  export {
95
- w as AlertDialog,
96
- w as default
97
+ J as AlertDialog,
98
+ J as default
97
99
  };
@@ -1,120 +1,109 @@
1
1
  import { jsx as a, jsxs as t } from "react/jsx-runtime";
2
- import n, { useRef as U, useEffect as w, useCallback as _ } from "react";
3
- import { LoadingMask as B } from "../LoadingMask/LoadingMask.mjs";
4
- import { Popover as F, PopoverTrigger as G, PopoverContent as V } from "../Popover/Popover.mjs";
5
- import { Button as W } from "../Button/Button.mjs";
2
+ import n, { useEffect as E } from "react";
3
+ import { LoadingMask as I } from "../LoadingMask/LoadingMask.mjs";
4
+ import { Popover as U, PopoverTrigger as _, PopoverContent as B } from "../Popover/Popover.mjs";
5
+ import { Button as F } from "../Button/Button.mjs";
6
6
  import "../Button/buttonVariants.mjs";
7
- import { Command as X, CommandInput as q, CommandList as z, CommandEmpty as A, CommandGroup as H, CommandItem as J } from "../Command/Command.mjs";
8
- import { cn as x } from "@oneplatformdev/utils";
9
- import { useDebounceCallback as K } from "@oneplatformdev/hooks";
10
- import { X as Q, ChevronsUpDown as Y, Check as Z } from "lucide-react";
11
- const ie = (N) => {
12
- var y;
7
+ import { Command as G, CommandInput as M, CommandList as R, CommandEmpty as V, CommandGroup as W, CommandItem as X } from "../Command/Command.mjs";
8
+ import { cn as g } from "@oneplatformdev/utils";
9
+ import { useDebounceCallback as q } from "@oneplatformdev/hooks";
10
+ import { X as z, ChevronsUpDown as A, Check as H } from "lucide-react";
11
+ const te = (w) => {
12
+ var C;
13
13
  const {
14
14
  value: o,
15
- onChange: S,
16
- placeholder: k,
17
- disabled: L,
18
- searchLabel: O,
19
- fetchOptions: P,
15
+ onChange: y,
16
+ placeholder: x,
17
+ disabled: N,
18
+ searchLabel: S,
19
+ fetchOptions: L,
20
20
  options: r,
21
- emptyLabel: j = "No options",
22
- onMount: s
23
- } = N, c = U(!1), [l, p] = n.useState(!1), [D, h] = n.useState(""), [f, i] = n.useState([]), [d, b] = n.useState(), [v, C] = n.useState(!1);
24
- w(() => {
25
- r != null && r.length && i(r);
21
+ emptyLabel: O = "No options"
22
+ } = w, [l, d] = n.useState(!1), [P, m] = n.useState(""), [p, h] = n.useState([]), [s, u] = n.useState(), [f, b] = n.useState(!1);
23
+ E(() => {
24
+ r != null && r.length && h(r);
26
25
  }, [r]);
27
- const M = async () => {
28
- l || (g(), h(""));
29
- }, g = async (e) => {
30
- C(!0);
26
+ const j = async () => {
27
+ l || (v(), m(""));
28
+ }, v = async (e) => {
29
+ b(!0);
31
30
  try {
32
- const u = await P(e);
33
- i(u);
34
- } catch (u) {
35
- console.error("Unexpected error while get option:", u);
31
+ const i = await L(e);
32
+ h(i);
33
+ } catch (i) {
34
+ console.error("Unexpected error while get option:", i);
36
35
  } finally {
37
- C(!1);
36
+ b(!1);
38
37
  }
39
- }, T = K(g, 1e3), E = (e) => {
40
- h(e), T(e);
41
- }, m = (e) => {
42
- S(e.value), b(e);
43
- }, I = () => {
44
- m({ value: "", label: "" }), b(void 0);
45
- }, R = _(() => {
46
- if (!s) {
47
- c.current = !0;
48
- return;
49
- }
50
- s({ setOptions: i }).finally(() => {
51
- c.current = !0;
52
- });
53
- }, [s]);
54
- return w(() => (R(), () => {
55
- c.current = !1;
56
- }), []), /* @__PURE__ */ a("div", { className: "w-full", children: /* @__PURE__ */ t(
57
- F,
38
+ }, k = q(v, 1e3), D = (e) => {
39
+ m(e), k(e);
40
+ }, c = (e) => {
41
+ y(e.value), u(e);
42
+ }, T = () => {
43
+ c({ value: "", label: "" }), u(void 0);
44
+ };
45
+ return /* @__PURE__ */ a("div", { className: "w-full", children: /* @__PURE__ */ t(
46
+ U,
58
47
  {
59
48
  open: l,
60
49
  onOpenChange: (e) => {
61
- p(e), e && M();
50
+ d(e), e && j();
62
51
  },
63
52
  children: [
64
- /* @__PURE__ */ a(G, { asChild: !0, className: "border-border", children: /* @__PURE__ */ t(
65
- W,
53
+ /* @__PURE__ */ a(_, { asChild: !0, className: "border-border", children: /* @__PURE__ */ t(
54
+ F,
66
55
  {
67
56
  variant: "outline",
68
57
  role: "combobox",
69
58
  "aria-expanded": l,
70
- className: x(
59
+ className: g(
71
60
  "w-full justify-between font-normal text-sm border bg-input",
72
61
  l ? "border-2 border-sidebar-accent" : "border-border"
73
62
  ),
74
- disabled: L,
63
+ disabled: N,
75
64
  children: [
76
- /* @__PURE__ */ a("span", { className: "truncate max-w-[calc(100%-1.5rem)] overflow-hidden whitespace-nowrap", children: o ? ((y = f.find((e) => e.value === o)) == null ? void 0 : y.label) || (d == null ? void 0 : d.label) : /* @__PURE__ */ a("span", { className: "text-gray-400", children: k }) }),
65
+ /* @__PURE__ */ a("span", { className: "truncate max-w-[calc(100%-1.5rem)] overflow-hidden whitespace-nowrap", children: o ? ((C = p.find((e) => e.value === o)) == null ? void 0 : C.label) || (s == null ? void 0 : s.label) : /* @__PURE__ */ a("span", { className: "text-gray-400", children: x }) }),
77
66
  o ? /* @__PURE__ */ a(
78
- Q,
67
+ z,
79
68
  {
80
69
  className: "opacity-50 w-4 h-4 cursor-pointer hover:opacity-100",
81
70
  onClick: (e) => {
82
- e.stopPropagation(), I();
71
+ e.stopPropagation(), T();
83
72
  }
84
73
  }
85
- ) : /* @__PURE__ */ a(Y, { className: "opacity-50 w-4 h-4" })
74
+ ) : /* @__PURE__ */ a(A, { className: "opacity-50 w-4 h-4" })
86
75
  ]
87
76
  }
88
77
  ) }),
89
78
  /* @__PURE__ */ a(
90
- V,
79
+ B,
91
80
  {
92
81
  className: "w-[var(--radix-popper-anchor-width)] max-w-none p-0",
93
82
  align: "start",
94
- children: /* @__PURE__ */ t(X, { shouldFilter: !1, children: [
83
+ children: /* @__PURE__ */ t(G, { shouldFilter: !1, children: [
95
84
  /* @__PURE__ */ a(
96
- q,
85
+ M,
97
86
  {
98
- placeholder: O,
99
- value: D,
100
- onValueChange: E
87
+ placeholder: S,
88
+ value: P,
89
+ onValueChange: D
101
90
  }
102
91
  ),
103
- /* @__PURE__ */ t(z, { children: [
104
- !v && /* @__PURE__ */ a(A, { children: j }),
105
- /* @__PURE__ */ a(H, { children: v ? /* @__PURE__ */ a("div", { className: "flex justify-center", children: /* @__PURE__ */ a(B, {}) }) : f.map((e) => /* @__PURE__ */ t(
106
- J,
92
+ /* @__PURE__ */ t(R, { children: [
93
+ !f && /* @__PURE__ */ a(V, { children: O }),
94
+ /* @__PURE__ */ a(W, { children: f ? /* @__PURE__ */ a("div", { className: "flex justify-center", children: /* @__PURE__ */ a(I, {}) }) : p.map((e) => /* @__PURE__ */ t(
95
+ X,
107
96
  {
108
97
  value: e.value,
109
98
  onSelect: () => {
110
- o === e.value ? m({ value: "", label: "" }) : m(e), p(!1);
99
+ o === e.value ? c({ value: "", label: "" }) : c(e), d(!1);
111
100
  },
112
101
  children: [
113
102
  e.label,
114
103
  /* @__PURE__ */ a(
115
- Z,
104
+ H,
116
105
  {
117
- className: x(
106
+ className: g(
118
107
  "ml-auto",
119
108
  o === e.value ? "opacity-100" : "opacity-0"
120
109
  )
@@ -133,5 +122,5 @@ const ie = (N) => {
133
122
  ) });
134
123
  };
135
124
  export {
136
- ie as Combobox
125
+ te as Combobox
137
126
  };
@@ -1,12 +1,7 @@
1
- import { Dispatch, SetStateAction } from 'react';
2
-
3
1
  export interface ComboboxOption {
4
2
  value: string;
5
3
  label: string;
6
4
  }
7
- export interface ComboboxPropsOnMountParams {
8
- setOptions: Dispatch<SetStateAction<ComboboxOption[]>>;
9
- }
10
5
  export interface ComboboxProps {
11
6
  value: string;
12
7
  onChange: (value: string) => void;
@@ -17,6 +12,4 @@ export interface ComboboxProps {
17
12
  options?: ComboboxOption[];
18
13
  /** CommandEmpty label*/
19
14
  emptyLabel?: string;
20
- /** Callback for load data on start component */
21
- onMount?: (params: ComboboxPropsOnMountParams) => Promise<ComboboxOption[]>;
22
15
  }
@@ -3,5 +3,5 @@ import { FormRenderControlExtendProps } from '../Form';
3
3
  import { UseFormReturn } from 'react-hook-form';
4
4
  import { FieldValues } from 'react-hook-form/dist/types/fields';
5
5
 
6
- export interface FormSelectProps<Data extends FieldValues, Form extends UseFormReturn<Data>, ExtendOptionData> extends FormRenderControlExtendProps<Data, Form>, Omit<SelectProps<ExtendOptionData>, 'onChange'> {
6
+ export interface FormSelectProps<Data extends FieldValues, Form extends UseFormReturn<Data>, ExtendOptionData> extends FormRenderControlExtendProps<Data, Form>, SelectProps<ExtendOptionData> {
7
7
  }
package/Input/Input.d.ts CHANGED
@@ -1,6 +1,4 @@
1
1
  import { InputProps } from './Input.types';
2
- import { default as React } from 'react';
3
-
4
- export declare const BaseInput: React.ForwardRefExoticComponent<InputProps & React.RefAttributes<HTMLInputElement>>;
5
- export declare const PasswordInput: React.ForwardRefExoticComponent<InputProps & React.RefAttributes<HTMLInputElement>>;
6
- export declare const Input: React.ForwardRefExoticComponent<InputProps & React.RefAttributes<HTMLInputElement>>;
2
+ import * as React from "react";
3
+ declare const Input: React.ForwardRefExoticComponent<Omit<InputProps, "ref"> & React.RefAttributes<HTMLInputElement>>;
4
+ export { Input };
package/Input/Input.mjs CHANGED
@@ -1,61 +1,21 @@
1
- import { jsxs as c, jsx as s } from "react/jsx-runtime";
2
- import l, { useState as d } from "react";
3
- import { Eye as f, EyeOff as y } from "lucide-react";
4
- import { inputVariants as N } from "./inputVariants.mjs";
5
- import { cn as b } from "@oneplatformdev/utils";
6
- const p = l.forwardRef(
7
- (t, e) => {
8
- const {
9
- className: a,
10
- variant: r,
11
- type: o,
12
- slotProps: { input: n } = {},
13
- ...u
14
- } = t, { startAdornment: i } = n || {};
15
- return /* @__PURE__ */ c("div", { className: "relative", children: [
16
- !!i && /* @__PURE__ */ s("span", { className: "absolute left-[10px] top-1/2 -translate-y-1/2", children: i }),
17
- /* @__PURE__ */ s(
18
- "input",
19
- {
20
- type: o,
21
- className: b(
22
- N({ variant: r, className: a }),
23
- !!i && "pl-8"
24
- ),
25
- ref: e,
26
- ...u
27
- }
28
- )
29
- ] });
30
- }
1
+ import { jsx as i } from "react/jsx-runtime";
2
+ import * as n from "react";
3
+ import { cn as s } from "@oneplatformdev/utils";
4
+ const l = n.forwardRef(
5
+ ({ className: e, type: r, ...o }, t) => /* @__PURE__ */ i(
6
+ "input",
7
+ {
8
+ type: r,
9
+ className: s(
10
+ "flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",
11
+ e
12
+ ),
13
+ ref: t,
14
+ ...o
15
+ }
16
+ )
31
17
  );
32
- p.displayName = "Input";
33
- const m = l.forwardRef(
34
- (t, e) => {
35
- const [a, r] = d(!1), o = a ? "text" : "password", n = () => {
36
- r(!a);
37
- };
38
- return /* @__PURE__ */ c("div", { className: "relative", children: [
39
- /* @__PURE__ */ s(p, { ...t, type: o, className: "pr-8", ref: e }),
40
- /* @__PURE__ */ s(w, { isVisible: a, onClick: n })
41
- ] });
42
- }
43
- );
44
- m.displayName = "PasswordInput";
45
- const w = ({ isVisible: t, onClick: e }) => /* @__PURE__ */ s(
46
- "button",
47
- {
48
- type: "button",
49
- onClick: e,
50
- className: "absolute top-1/2 right-3 transform -translate-y-1/2",
51
- children: t ? /* @__PURE__ */ s(f, { size: 16 }) : /* @__PURE__ */ s(y, { size: 16 })
52
- }
53
- ), I = l.forwardRef(
54
- ({ type: t, ...e }, a) => t === "password" ? /* @__PURE__ */ s(m, { type: t, ...e, ref: a }) : /* @__PURE__ */ s(p, { type: t, ...e, ref: a })
55
- );
56
- I.displayName = "Input";
18
+ l.displayName = "Input";
57
19
  export {
58
- p as BaseInput,
59
- I as Input,
60
- m as PasswordInput
20
+ l as Input
61
21
  };
@@ -1,13 +1,4 @@
1
- import { inputVariants } from './inputVariants';
2
- import { VariantProps } from 'class-variance-authority';
3
- import { default as React, ReactNode } from 'react';
1
+ import { ComponentProps } from 'react';
4
2
 
5
- export interface InputSlotInputProps {
6
- startAdornment?: ReactNode;
7
- }
8
- export interface InputSlotProps {
9
- input?: InputSlotInputProps;
10
- }
11
- export interface InputProps extends React.InputHTMLAttributes<HTMLInputElement>, VariantProps<typeof inputVariants> {
12
- slotProps?: InputSlotProps;
3
+ export interface InputProps extends ComponentProps<'input'> {
13
4
  }
package/Input/index.d.ts CHANGED
@@ -1,3 +1,2 @@
1
1
  export * from './Input';
2
- export { Input as default } from './Input';
3
2
  export type * from './Input.types';
package/Input/index.mjs CHANGED
@@ -1,7 +1,4 @@
1
- import { BaseInput as u, Input as a, PasswordInput as n, Input as s } from "./Input.mjs";
1
+ import { Input as r } from "./Input.mjs";
2
2
  export {
3
- u as BaseInput,
4
- a as Input,
5
- n as PasswordInput,
6
- s as default
3
+ r as Input
7
4
  };
@@ -1,20 +1,3 @@
1
1
  import { default as React, JSX } from 'react';
2
2
 
3
- /**
4
- * Component lazy load component.
5
- * @public
6
- * @see [Documentation](#)
7
- * @example
8
- * ```tsx
9
- * import { lazy } from 'react';
10
- * import { LazyLoader } from '@oneplatformdev/ui/LazyLoader';
11
- *
12
- * const ModuleComponentViewLazy = LazyLoader(
13
- * lazy(() => import('path/to/module').then(module => ({
14
- * default: module.ModuleComponentView,
15
- * })),
16
- * ),
17
- * );
18
- * ```
19
- */
20
3
  export declare const LazyLoader: (Component: React.LazyExoticComponent<any>, showLoader?: boolean) => (props: any) => JSX.Element;
@@ -1 +1 @@
1
- export { LazyLoader as default, LazyLoader } from './LazyLoader';
1
+ export { LazyLoader } from './LazyLoader';
@@ -1,5 +1,4 @@
1
- import { LazyLoader as o, LazyLoader as r } from "./LazyLoader.mjs";
1
+ import { LazyLoader as a } from "./LazyLoader.mjs";
2
2
  export {
3
- o as LazyLoader,
4
- r as default
3
+ a as LazyLoader
5
4
  };
package/Search/index.d.ts CHANGED
@@ -1,3 +1,2 @@
1
1
  export * from './Search';
2
- export { Search as default } from './Search';
3
2
  export type * from './Search.types';
package/Search/index.mjs CHANGED
@@ -1,5 +1,4 @@
1
- import { Search as r, Search as c } from "./Search.mjs";
1
+ import { Search as o } from "./Search.mjs";
2
2
  export {
3
- r as Search,
4
- c as default
3
+ o as Search
5
4
  };
@@ -25,7 +25,7 @@ declare const Sidebar: React.ForwardRefExoticComponent<Omit<React.ClassAttribute
25
25
  declare const SidebarTrigger: React.ForwardRefExoticComponent<Omit<import('../Button').ButtonProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
26
26
  declare const SidebarRail: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
27
27
  declare const SidebarInset: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
28
- declare const SidebarInput: React.ForwardRefExoticComponent<Omit<import('../Input').InputProps & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
28
+ declare const SidebarInput: React.ForwardRefExoticComponent<Omit<Omit<import('../Input').InputProps, "ref"> & React.RefAttributes<HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
29
29
  declare const SidebarHeader: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
30
30
  declare const SidebarFooter: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
31
31
  declare const SidebarSeparator: React.ForwardRefExoticComponent<Omit<Omit<import('@radix-ui/react-separator').SeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;