lawgic-dev-kit 0.19.0 → 0.19.8
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/_virtual/index2.js +2 -3
- package/dist/_virtual/index3.js +3 -3
- package/dist/_virtual/index4.js +3 -5
- package/dist/_virtual/index5.js +5 -2
- package/dist/_virtual/index6.js +2 -2
- package/dist/_virtual/index7.js +2 -2
- package/dist/components/atoms/Button/Button.js +9 -8
- package/dist/components/atoms/FilterPill/FilterPill.d.ts +8 -0
- package/dist/components/atoms/FilterPill/FilterPill.js +158 -0
- package/dist/components/atoms/FilterPill/index.d.ts +1 -0
- package/dist/components/atoms/IconButton/IconButton.js +11 -10
- package/dist/components/atoms/ProgressBar/ProgressBar.js +3 -2
- package/dist/components/atoms/SectionButton/desktop/SectionButton.js +11 -10
- package/dist/components/atoms/SectionButton/mobile/SectionButton.js +13 -12
- package/dist/components/atoms/SidebarButton/SidebarButton.js +3 -2
- package/dist/components/atoms/Switch/Switch.js +3 -2
- package/dist/components/atoms/TextButton/TextButton.js +1 -0
- package/dist/components/atoms/TextInput/TextInput.js +3 -2
- package/dist/components/atoms/UncontrolledTextInput/UncontrolledTextInput.js +9 -8
- package/dist/components/atoms/index.d.ts +1 -0
- package/dist/components/molecules/AutocompleteInput/AutocompleteInput.js +1 -1
- package/dist/components/molecules/AutocompleteInput/AutocompleteInput.types.d.ts +1 -1
- package/dist/components/molecules/DateInput/DateInput.d.ts +2 -1
- package/dist/components/molecules/DateInput/DateInput.js +40 -29
- package/dist/components/molecules/FiltersMenu/FiltersMenu.d.ts +13 -0
- package/dist/components/molecules/FiltersMenu/FiltersMenu.js +49 -0
- package/dist/components/molecules/FiltersMenu/index.d.ts +1 -0
- package/dist/components/molecules/FloatingMenu/FloatingMenu.js +42 -34
- package/dist/components/molecules/FloatingMenu/FloatingMenu.types.d.ts +1 -0
- package/dist/components/molecules/PillsContainer/PillsContainer.d.ts +5 -2
- package/dist/components/molecules/PillsContainer/PillsContainer.js +29 -23
- package/dist/components/molecules/SideModal/SideModal.d.ts +4 -0
- package/dist/components/molecules/SideModal/SideModal.js +97 -0
- package/dist/components/molecules/SideModal/SideModal.types.d.ts +10 -0
- package/dist/components/molecules/SideModal/index.d.ts +1 -0
- package/dist/components/molecules/UncontrolledDateInput/UncontrolledDateInput.d.ts +2 -1
- package/dist/components/molecules/UncontrolledDateInput/UncontrolledDateInput.js +27 -25
- package/dist/components/molecules/index.d.ts +2 -0
- package/dist/hooks/index.d.ts +1 -0
- package/dist/hooks/useFilterToggler.d.ts +5 -0
- package/dist/hooks/useFilterToggler.js +56 -0
- package/dist/index.js +79 -71
- package/dist/lawgic-dev-kit.css +1 -1
- package/dist/lawgic-dev-kit.umd.js +54 -51
- package/dist/node_modules/@fortawesome/pro-regular-svg-icons/index.js +15 -5
- package/dist/node_modules/prop-types/index.js +1 -1
- package/dist/node_modules/prop-types/node_modules/react-is/index.js +1 -1
- package/dist/node_modules/toposort/index.js +1 -1
- package/dist/node_modules/yup/index.esm.js +3 -3
- package/dist/types/cycles.d.ts +103 -0
- package/dist/types/filters.d.ts +22 -0
- package/dist/utils/cycles.d.ts +2 -0
- package/package.json +1 -1
package/dist/_virtual/index2.js
CHANGED
package/dist/_virtual/index3.js
CHANGED
package/dist/_virtual/index4.js
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
var t = r();
|
|
4
|
-
const s = /* @__PURE__ */ o(t);
|
|
1
|
+
import { __require as r } from "../node_modules/tiny-case/index.js";
|
|
2
|
+
var a = r();
|
|
5
3
|
export {
|
|
6
|
-
|
|
4
|
+
a as t
|
|
7
5
|
};
|
package/dist/_virtual/index5.js
CHANGED
package/dist/_virtual/index6.js
CHANGED
package/dist/_virtual/index7.js
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { j as s } from "../../../_virtual/jsx-runtime.js";
|
|
2
|
-
import { resolveButtonClasses as
|
|
3
|
-
import { useTheme as
|
|
2
|
+
import { resolveButtonClasses as i } from "./Button.styles.js";
|
|
3
|
+
import { useTheme as d } from "../../../hooks/useTheme.js";
|
|
4
|
+
import "react";
|
|
4
5
|
import { FontAwesomeIcon as r } from "../../../node_modules/@fortawesome/react-fontawesome/index.es.js";
|
|
5
6
|
import { resolveIconClasses as m } from "../IconButton/IconButton.styles.js";
|
|
6
|
-
const
|
|
7
|
+
const v = ({
|
|
7
8
|
icon: e,
|
|
8
9
|
rightIcon: t,
|
|
9
10
|
color: l,
|
|
@@ -11,15 +12,15 @@ const h = ({
|
|
|
11
12
|
size: o = "base",
|
|
12
13
|
children: n,
|
|
13
14
|
className: c,
|
|
14
|
-
...
|
|
15
|
+
...p
|
|
15
16
|
}) => {
|
|
16
|
-
const { defaultColorScheme:
|
|
17
|
+
const { defaultColorScheme: u } = d(), f = l || u;
|
|
17
18
|
return /* @__PURE__ */ s.jsxs(
|
|
18
19
|
"button",
|
|
19
20
|
{
|
|
20
21
|
type: "button",
|
|
21
|
-
className:
|
|
22
|
-
...
|
|
22
|
+
className: i(a, f, o) + " " + c,
|
|
23
|
+
...p,
|
|
23
24
|
children: [
|
|
24
25
|
e && /* @__PURE__ */ s.jsx(r, { icon: e, className: m(o) }),
|
|
25
26
|
n,
|
|
@@ -35,5 +36,5 @@ const h = ({
|
|
|
35
36
|
);
|
|
36
37
|
};
|
|
37
38
|
export {
|
|
38
|
-
|
|
39
|
+
v as default
|
|
39
40
|
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Filter, FilterControl } from '../../../types/filters';
|
|
2
|
+
interface FilterPillProps<T> {
|
|
3
|
+
filter: Omit<Filter<T>, "fn">;
|
|
4
|
+
filterControl: FilterControl<T>;
|
|
5
|
+
translations?: Record<string, string>;
|
|
6
|
+
}
|
|
7
|
+
declare const FilterPill: <T>({ filter, filterControl, translations, }: FilterPillProps<T>) => React.ReactElement;
|
|
8
|
+
export default FilterPill;
|
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
import { j as a } from "../../../_virtual/jsx-runtime.js";
|
|
2
|
+
import { FontAwesomeIcon as D } from "../../../node_modules/@fortawesome/react-fontawesome/index.es.js";
|
|
3
|
+
import { faFilter as C, faX as I } from "../../../node_modules/@fortawesome/pro-regular-svg-icons/index.js";
|
|
4
|
+
import { useState as O } from "react";
|
|
5
|
+
import "../../../contexts/themeContext.js";
|
|
6
|
+
import "../../../_virtual/lodash.js";
|
|
7
|
+
import "react-hook-form";
|
|
8
|
+
import "../../../constants/countries.js";
|
|
9
|
+
import "../ImageProfileInput/ImageProfileInput.validators.js";
|
|
10
|
+
import $ from "../UncontrolledSelector/UncontrolledSelector.js";
|
|
11
|
+
import L from "../UncontrolledTextInput/UncontrolledTextInput.js";
|
|
12
|
+
import M from "../../molecules/FloatingMenu/FloatingMenu.js";
|
|
13
|
+
import "../../molecules/InformationContainer/InformationContainer.js";
|
|
14
|
+
import h from "../../molecules/UncontrolledDateInput/UncontrolledDateInput.js";
|
|
15
|
+
const G = ({
|
|
16
|
+
filter: e,
|
|
17
|
+
filterControl: g,
|
|
18
|
+
translations: j = {}
|
|
19
|
+
}) => {
|
|
20
|
+
var c, p, u, d, r, m, x, v, y, b;
|
|
21
|
+
const [k, l] = O(!0), { updateFilter: o, removeFilter: w } = g, S = !!(e != null && e.value), n = (t, s) => j[t] || s, N = (t, s = []) => {
|
|
22
|
+
const i = s.find((F) => F.value === t);
|
|
23
|
+
return i ? i.label : String(t);
|
|
24
|
+
};
|
|
25
|
+
return /* @__PURE__ */ a.jsx(
|
|
26
|
+
M,
|
|
27
|
+
{
|
|
28
|
+
open: k,
|
|
29
|
+
onClose: () => l(!1),
|
|
30
|
+
placement: "bottom",
|
|
31
|
+
className: "min-w-[400px]",
|
|
32
|
+
component: /* @__PURE__ */ a.jsxs("div", { children: [
|
|
33
|
+
/* @__PURE__ */ a.jsx("p", { children: n(e.key, e.label) }),
|
|
34
|
+
e.type === "date" ? /* @__PURE__ */ a.jsxs("div", { className: "flex flex-col gap-2", children: [
|
|
35
|
+
/* @__PURE__ */ a.jsx("div", { className: "scale-[0.8] origin-left -mr-[10%] w-[125%]! relative z-99", children: /* @__PURE__ */ a.jsx(
|
|
36
|
+
h,
|
|
37
|
+
{
|
|
38
|
+
currentDate: (c = e.value) != null && c.startDate ? new Date(e.value.startDate) : null,
|
|
39
|
+
maxDate: (p = e.value) != null && p.endDate ? new Date(e.value.endDate) : void 0,
|
|
40
|
+
futureDates: !0,
|
|
41
|
+
onDateChange: (t) => o({
|
|
42
|
+
key: e.key,
|
|
43
|
+
value: {
|
|
44
|
+
...e.value || {},
|
|
45
|
+
startDate: (t == null ? void 0 : t.toISOString()) || ""
|
|
46
|
+
},
|
|
47
|
+
label: e.label,
|
|
48
|
+
type: e.type
|
|
49
|
+
}),
|
|
50
|
+
label: "Fecha de inicio",
|
|
51
|
+
translatedKey: "start_date"
|
|
52
|
+
}
|
|
53
|
+
) }),
|
|
54
|
+
/* @__PURE__ */ a.jsx("div", { className: "scale-[0.8] origin-left -mr-[10%] w-[125%]! ", children: /* @__PURE__ */ a.jsx(
|
|
55
|
+
h,
|
|
56
|
+
{
|
|
57
|
+
currentDate: (u = e.value) != null && u.endDate ? new Date(e.value.endDate) : null,
|
|
58
|
+
minDate: (d = e.value) != null && d.startDate ? new Date(e.value.startDate) : void 0,
|
|
59
|
+
onDateChange: (t) => o({
|
|
60
|
+
key: e.key,
|
|
61
|
+
value: {
|
|
62
|
+
...e.value || {},
|
|
63
|
+
endDate: (t == null ? void 0 : t.toISOString()) || ""
|
|
64
|
+
},
|
|
65
|
+
label: e.label,
|
|
66
|
+
type: e.type
|
|
67
|
+
}),
|
|
68
|
+
label: "Fecha de fin",
|
|
69
|
+
futureDates: !0,
|
|
70
|
+
translatedKey: "end_date"
|
|
71
|
+
}
|
|
72
|
+
) })
|
|
73
|
+
] }) : e.type === "select" ? /* @__PURE__ */ a.jsx(
|
|
74
|
+
$,
|
|
75
|
+
{
|
|
76
|
+
className: "scale-[0.8] origin-left -mr-[10%] w-[125%]! p-0! m-0!",
|
|
77
|
+
value: e.value || "",
|
|
78
|
+
options: e.options || [],
|
|
79
|
+
label: "",
|
|
80
|
+
allowSearch: !0,
|
|
81
|
+
onChange: (t) => o({
|
|
82
|
+
key: e.key,
|
|
83
|
+
value: t,
|
|
84
|
+
label: e.label,
|
|
85
|
+
type: e.type
|
|
86
|
+
}),
|
|
87
|
+
placeholder: n(e.key, e.label)
|
|
88
|
+
}
|
|
89
|
+
) : /* @__PURE__ */ a.jsx(
|
|
90
|
+
L,
|
|
91
|
+
{
|
|
92
|
+
size: "sm",
|
|
93
|
+
name: e.key,
|
|
94
|
+
value: e.value,
|
|
95
|
+
onChange: (t) => o({
|
|
96
|
+
key: e.key,
|
|
97
|
+
value: t,
|
|
98
|
+
label: e.label,
|
|
99
|
+
type: e.type
|
|
100
|
+
}),
|
|
101
|
+
placeholder: n(e.key, e.label)
|
|
102
|
+
}
|
|
103
|
+
)
|
|
104
|
+
] }),
|
|
105
|
+
children: /* @__PURE__ */ a.jsxs(
|
|
106
|
+
"div",
|
|
107
|
+
{
|
|
108
|
+
className: `flex gap-[8px] items-center px-[12px] py-[8px] bg-blue-100 max-w-[400px] ${S && "border-1! border-blue-500!"} cursor-pointer transition ease-in-out rounded-full border border-transparent hover:border-blue-500`,
|
|
109
|
+
onClick: () => l(!0),
|
|
110
|
+
children: [
|
|
111
|
+
/* @__PURE__ */ a.jsxs("div", { className: "flex justify-between items-center gap-[6px] min-w-0", children: [
|
|
112
|
+
/* @__PURE__ */ a.jsx(
|
|
113
|
+
D,
|
|
114
|
+
{
|
|
115
|
+
icon: e.icon || C,
|
|
116
|
+
className: "text-[14px] text-blue-500"
|
|
117
|
+
}
|
|
118
|
+
),
|
|
119
|
+
/* @__PURE__ */ a.jsx(
|
|
120
|
+
"p",
|
|
121
|
+
{
|
|
122
|
+
className: "flex-1 min-w-0 text-[12px] font-semibold text-gray-800 truncate overflow-hidden whitespace-nowrap",
|
|
123
|
+
title: e.type === "date" ? `${((r = e.value) == null ? void 0 : r.startDate) || "..."} - ${((m = e.value) == null ? void 0 : m.endDate) || "..."}` : String(
|
|
124
|
+
e.value || n(e.key, e.label)
|
|
125
|
+
),
|
|
126
|
+
children: e.value && (e.type === "date" ? (x = e.value) != null && x.startDate || (v = e.value) != null && v.endDate : e.value) ? /* @__PURE__ */ a.jsxs(a.Fragment, { children: [
|
|
127
|
+
n(e.key, e.label),
|
|
128
|
+
":",
|
|
129
|
+
" ",
|
|
130
|
+
/* @__PURE__ */ a.jsx("span", { className: "text-gray-600 truncate overflow-hidden whitespace-nowrap", children: e.type === "date" ? `${(y = e.value) != null && y.startDate ? new Date(
|
|
131
|
+
e.value.startDate
|
|
132
|
+
).toLocaleDateString() : "..."} - ${(b = e.value) != null && b.endDate ? new Date(
|
|
133
|
+
e.value.endDate
|
|
134
|
+
).toLocaleDateString() : "..."}` : e.type === "select" ? N(
|
|
135
|
+
e.value,
|
|
136
|
+
e.options
|
|
137
|
+
) : String(e.value) })
|
|
138
|
+
] }) : n(e.key, e.label)
|
|
139
|
+
}
|
|
140
|
+
)
|
|
141
|
+
] }),
|
|
142
|
+
/* @__PURE__ */ a.jsx(
|
|
143
|
+
"div",
|
|
144
|
+
{
|
|
145
|
+
className: "flex justify-center items-center",
|
|
146
|
+
onClick: () => w({ key: e.key }),
|
|
147
|
+
children: /* @__PURE__ */ a.jsx(D, { icon: I, className: "text-[10px] text-gray-400" })
|
|
148
|
+
}
|
|
149
|
+
)
|
|
150
|
+
]
|
|
151
|
+
}
|
|
152
|
+
)
|
|
153
|
+
}
|
|
154
|
+
);
|
|
155
|
+
};
|
|
156
|
+
export {
|
|
157
|
+
G as default
|
|
158
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as FilterPill } from './FilterPill';
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import { j as s } from "../../../_virtual/jsx-runtime.js";
|
|
2
|
-
import { FontAwesomeIcon as
|
|
3
|
-
import { resolveIconButtonClasses as
|
|
2
|
+
import { FontAwesomeIcon as i } from "../../../node_modules/@fortawesome/react-fontawesome/index.es.js";
|
|
3
|
+
import { resolveIconButtonClasses as p, resolveIconClasses as d } from "./IconButton.styles.js";
|
|
4
4
|
import { useTheme as x } from "../../../hooks/useTheme.js";
|
|
5
|
-
|
|
5
|
+
import "react";
|
|
6
|
+
const v = ({
|
|
6
7
|
variant: t = "filled",
|
|
7
8
|
color: r,
|
|
8
9
|
size: o = "base",
|
|
9
|
-
shadow:
|
|
10
|
+
shadow: m = "none",
|
|
10
11
|
icon: e,
|
|
11
|
-
iconProps:
|
|
12
|
+
iconProps: n = {},
|
|
12
13
|
children: l,
|
|
13
14
|
className: a,
|
|
14
15
|
...c
|
|
@@ -18,12 +19,12 @@ const b = ({
|
|
|
18
19
|
"button",
|
|
19
20
|
{
|
|
20
21
|
...c,
|
|
21
|
-
className: `${
|
|
22
|
+
className: `${p(t, f, o, m)} ${a}`,
|
|
22
23
|
children: e ? /* @__PURE__ */ s.jsx(
|
|
23
|
-
|
|
24
|
+
i,
|
|
24
25
|
{
|
|
25
|
-
...
|
|
26
|
-
className:
|
|
26
|
+
...n,
|
|
27
|
+
className: d(o),
|
|
27
28
|
icon: e
|
|
28
29
|
}
|
|
29
30
|
) : l
|
|
@@ -31,5 +32,5 @@ const b = ({
|
|
|
31
32
|
);
|
|
32
33
|
};
|
|
33
34
|
export {
|
|
34
|
-
|
|
35
|
+
v as default
|
|
35
36
|
};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { j as e } from "../../../_virtual/jsx-runtime.js";
|
|
2
2
|
import { resolveProgressBarColors as c } from "./ProgressBar.styles.js";
|
|
3
3
|
import { useTheme as f } from "../../../hooks/useTheme.js";
|
|
4
|
-
|
|
4
|
+
import "react";
|
|
5
|
+
const g = ({
|
|
5
6
|
progress: r,
|
|
6
7
|
showPercentage: o = !1,
|
|
7
8
|
color: l,
|
|
@@ -24,5 +25,5 @@ const p = ({
|
|
|
24
25
|
] });
|
|
25
26
|
};
|
|
26
27
|
export {
|
|
27
|
-
|
|
28
|
+
g as default
|
|
28
29
|
};
|
|
@@ -1,16 +1,17 @@
|
|
|
1
|
-
import { j as
|
|
1
|
+
import { j as e } from "../../../../_virtual/jsx-runtime.js";
|
|
2
2
|
import { FontAwesomeIcon as u } from "../../../../node_modules/@fortawesome/react-fontawesome/index.es.js";
|
|
3
3
|
import { resolveSectionButtonClasses as $ } from "./SectionButton.styles.js";
|
|
4
4
|
import { resolveIconClasses as f } from "../../IconButton/IconButton.styles.js";
|
|
5
5
|
import { useTheme as d } from "../../../../hooks/useTheme.js";
|
|
6
|
-
|
|
6
|
+
import "react";
|
|
7
|
+
const w = ({
|
|
7
8
|
label: r,
|
|
8
9
|
href: a,
|
|
9
10
|
onClick: o,
|
|
10
11
|
active: p = !1,
|
|
11
12
|
disabled: s = !1,
|
|
12
13
|
className: m,
|
|
13
|
-
icon:
|
|
14
|
+
icon: t,
|
|
14
15
|
color: i
|
|
15
16
|
}) => {
|
|
16
17
|
const { defaultColorScheme: x } = d(), j = i || x, n = (c) => {
|
|
@@ -20,7 +21,7 @@ const g = ({
|
|
|
20
21
|
}
|
|
21
22
|
o == null || o(c);
|
|
22
23
|
}, l = `${$(p, j)} ${s ? "!text-gray-300 cursor-not-allowed !bg-transparent" : ""}`;
|
|
23
|
-
return a ? /* @__PURE__ */
|
|
24
|
+
return a ? /* @__PURE__ */ e.jsxs(
|
|
24
25
|
"a",
|
|
25
26
|
{
|
|
26
27
|
href: a,
|
|
@@ -28,27 +29,27 @@ const g = ({
|
|
|
28
29
|
onClick: n,
|
|
29
30
|
"aria-disabled": s,
|
|
30
31
|
children: [
|
|
31
|
-
|
|
32
|
+
t && /* @__PURE__ */ e.jsx(
|
|
32
33
|
u,
|
|
33
34
|
{
|
|
34
|
-
icon:
|
|
35
|
+
icon: t,
|
|
35
36
|
className: f()
|
|
36
37
|
}
|
|
37
38
|
),
|
|
38
39
|
r
|
|
39
40
|
]
|
|
40
41
|
}
|
|
41
|
-
) : /* @__PURE__ */
|
|
42
|
+
) : /* @__PURE__ */ e.jsxs(
|
|
42
43
|
"button",
|
|
43
44
|
{
|
|
44
45
|
className: `${l} ${m || ""}`,
|
|
45
46
|
onClick: n,
|
|
46
47
|
disabled: s,
|
|
47
48
|
children: [
|
|
48
|
-
|
|
49
|
+
t && /* @__PURE__ */ e.jsx(
|
|
49
50
|
u,
|
|
50
51
|
{
|
|
51
|
-
icon:
|
|
52
|
+
icon: t,
|
|
52
53
|
className: f()
|
|
53
54
|
}
|
|
54
55
|
),
|
|
@@ -58,5 +59,5 @@ const g = ({
|
|
|
58
59
|
);
|
|
59
60
|
};
|
|
60
61
|
export {
|
|
61
|
-
|
|
62
|
+
w as default
|
|
62
63
|
};
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { j as s } from "../../../../_virtual/jsx-runtime.js";
|
|
2
|
-
import { FontAwesomeIcon as
|
|
3
|
-
import { useTheme as
|
|
4
|
-
import
|
|
5
|
-
|
|
2
|
+
import { FontAwesomeIcon as u } from "../../../../node_modules/@fortawesome/react-fontawesome/index.es.js";
|
|
3
|
+
import { useTheme as h } from "../../../../hooks/useTheme.js";
|
|
4
|
+
import "react";
|
|
5
|
+
import { resolveSectionButtonClasses as j, resolveSectionButtonIconClasses as f } from "./MobileSectionButton.styles.js";
|
|
6
|
+
const v = ({
|
|
6
7
|
label: m,
|
|
7
8
|
href: n,
|
|
8
9
|
onClick: o,
|
|
@@ -10,15 +11,15 @@ const S = ({
|
|
|
10
11
|
disabled: e = !1,
|
|
11
12
|
className: l,
|
|
12
13
|
icon: t,
|
|
13
|
-
color:
|
|
14
|
+
color: p
|
|
14
15
|
}) => {
|
|
15
|
-
const { defaultColorScheme:
|
|
16
|
+
const { defaultColorScheme: d } = h(), a = p || d, c = (i) => {
|
|
16
17
|
if (e) {
|
|
17
|
-
|
|
18
|
+
i.preventDefault();
|
|
18
19
|
return;
|
|
19
20
|
}
|
|
20
|
-
o == null || o(
|
|
21
|
-
}, x = `${
|
|
21
|
+
o == null || o(i);
|
|
22
|
+
}, x = `${j(r, a)} ${e ? "!text-gray-300 cursor-not-allowed !bg-transparent" : ""}`;
|
|
22
23
|
return n ? /* @__PURE__ */ s.jsxs(
|
|
23
24
|
"a",
|
|
24
25
|
{
|
|
@@ -28,7 +29,7 @@ const S = ({
|
|
|
28
29
|
"aria-disabled": e,
|
|
29
30
|
children: [
|
|
30
31
|
t && /* @__PURE__ */ s.jsx("div", { className: f(r, a), children: /* @__PURE__ */ s.jsx(
|
|
31
|
-
|
|
32
|
+
u,
|
|
32
33
|
{
|
|
33
34
|
icon: t,
|
|
34
35
|
className: "size-16 max-h-16 max-w-16"
|
|
@@ -45,7 +46,7 @@ const S = ({
|
|
|
45
46
|
disabled: e,
|
|
46
47
|
children: [
|
|
47
48
|
t && /* @__PURE__ */ s.jsx("div", { className: f(r, a), children: /* @__PURE__ */ s.jsx(
|
|
48
|
-
|
|
49
|
+
u,
|
|
49
50
|
{
|
|
50
51
|
icon: t,
|
|
51
52
|
className: "size-16 max-h-16 max-w-16"
|
|
@@ -57,5 +58,5 @@ const S = ({
|
|
|
57
58
|
);
|
|
58
59
|
};
|
|
59
60
|
export {
|
|
60
|
-
|
|
61
|
+
v as default
|
|
61
62
|
};
|
|
@@ -2,7 +2,8 @@ import { j as t } from "../../../_virtual/jsx-runtime.js";
|
|
|
2
2
|
import { FontAwesomeIcon as f } from "../../../node_modules/@fortawesome/react-fontawesome/index.es.js";
|
|
3
3
|
import { resolveSidebarButtonColors as d } from "./SidebarButton.styles.js";
|
|
4
4
|
import { useTheme as h } from "../../../hooks/useTheme.js";
|
|
5
|
-
|
|
5
|
+
import "react";
|
|
6
|
+
const j = ({
|
|
6
7
|
active: o,
|
|
7
8
|
icon: l,
|
|
8
9
|
label: n,
|
|
@@ -58,5 +59,5 @@ const y = ({
|
|
|
58
59
|
);
|
|
59
60
|
};
|
|
60
61
|
export {
|
|
61
|
-
|
|
62
|
+
j as default
|
|
62
63
|
};
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { j as s } from "../../../_virtual/jsx-runtime.js";
|
|
2
2
|
import { useTheme as t } from "../../../hooks/useTheme.js";
|
|
3
|
-
|
|
3
|
+
import "react";
|
|
4
|
+
const i = ({ active: n, onClick: e }) => {
|
|
4
5
|
const { defaultColorScheme: o } = t();
|
|
5
6
|
return /* @__PURE__ */ s.jsxs(
|
|
6
7
|
"button",
|
|
@@ -29,5 +30,5 @@ const l = ({ active: n, onClick: e }) => {
|
|
|
29
30
|
);
|
|
30
31
|
};
|
|
31
32
|
export {
|
|
32
|
-
|
|
33
|
+
i as default
|
|
33
34
|
};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { j as o } from "../../../_virtual/jsx-runtime.js";
|
|
2
2
|
import { useController as w } from "react-hook-form";
|
|
3
3
|
import { useTheme as v } from "../../../hooks/useTheme.js";
|
|
4
|
-
|
|
4
|
+
import "react";
|
|
5
|
+
const S = ({
|
|
5
6
|
label: c,
|
|
6
7
|
control: x,
|
|
7
8
|
name: e,
|
|
@@ -94,5 +95,5 @@ const I = ({
|
|
|
94
95
|
);
|
|
95
96
|
};
|
|
96
97
|
export {
|
|
97
|
-
|
|
98
|
+
S as default
|
|
98
99
|
};
|
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
import { j as o } from "../../../_virtual/jsx-runtime.js";
|
|
2
2
|
import { useTheme as h } from "../../../hooks/useTheme.js";
|
|
3
|
-
|
|
3
|
+
import "react";
|
|
4
|
+
const w = ({
|
|
4
5
|
label: x,
|
|
5
6
|
onChange: p,
|
|
6
7
|
value: s,
|
|
7
8
|
name: t,
|
|
8
9
|
error: l,
|
|
9
|
-
placeholder:
|
|
10
|
-
className:
|
|
10
|
+
placeholder: i,
|
|
11
|
+
className: b = "",
|
|
11
12
|
disabled: e = !1,
|
|
12
13
|
disabledInput: n = !1,
|
|
13
|
-
size:
|
|
14
|
+
size: g = "base",
|
|
14
15
|
leftSide: a,
|
|
15
16
|
rightSide: c,
|
|
16
17
|
...d
|
|
@@ -30,11 +31,11 @@ const j = ({
|
|
|
30
31
|
error: "text-label",
|
|
31
32
|
gap: "gap-8"
|
|
32
33
|
}
|
|
33
|
-
}[
|
|
34
|
+
}[g];
|
|
34
35
|
return /* @__PURE__ */ o.jsxs(
|
|
35
36
|
"label",
|
|
36
37
|
{
|
|
37
|
-
className: `flex flex-col group select-none ${r.gap} ${e && "cursor-not-allowed"} ${
|
|
38
|
+
className: `flex flex-col group select-none ${r.gap} ${e && "cursor-not-allowed"} ${b}`,
|
|
38
39
|
htmlFor: t,
|
|
39
40
|
children: [
|
|
40
41
|
/* @__PURE__ */ o.jsx(
|
|
@@ -74,7 +75,7 @@ const j = ({
|
|
|
74
75
|
id: t,
|
|
75
76
|
name: t,
|
|
76
77
|
disabled: e,
|
|
77
|
-
placeholder:
|
|
78
|
+
placeholder: i,
|
|
78
79
|
value: s,
|
|
79
80
|
onChange: (f) => {
|
|
80
81
|
p(f.target.value);
|
|
@@ -92,5 +93,5 @@ const j = ({
|
|
|
92
93
|
);
|
|
93
94
|
};
|
|
94
95
|
export {
|
|
95
|
-
|
|
96
|
+
w as default
|
|
96
97
|
};
|
|
@@ -5,7 +5,7 @@ export interface AutocompleteInputProps {
|
|
|
5
5
|
onChange?: (value: string) => void;
|
|
6
6
|
onSelect?: (value: unknown) => void;
|
|
7
7
|
onKeyDown?: (e: React.KeyboardEvent<HTMLInputElement>) => void;
|
|
8
|
-
onOptionClick?: (
|
|
8
|
+
onOptionClick?: ({ label, value }: {
|
|
9
9
|
label: string;
|
|
10
10
|
value: unknown;
|
|
11
11
|
}) => void;
|
|
@@ -8,6 +8,7 @@ export type DateInputProps<T extends FieldValues = FieldValues> = {
|
|
|
8
8
|
translateKey?: string;
|
|
9
9
|
futureDates?: boolean;
|
|
10
10
|
pastDates?: boolean;
|
|
11
|
+
size?: "sm" | "base";
|
|
11
12
|
};
|
|
12
|
-
declare const DateInput: <T extends FieldValues = FieldValues>({ control, name, showTimeSelector, label, translateKey, placeholder, futureDates, pastDates }: DateInputProps<T>) => React.ReactElement;
|
|
13
|
+
declare const DateInput: <T extends FieldValues = FieldValues>({ control, name, showTimeSelector, label, translateKey, placeholder, futureDates, pastDates, size, }: DateInputProps<T>) => React.ReactElement;
|
|
13
14
|
export default DateInput;
|