laif-ds 0.2.74 → 0.2.76
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/CHANGELOG.md +446 -0
- package/dist/agent-docs/adoption-report.json +615 -0
- package/dist/agent-docs/components/Accordion.md +46 -16
- package/dist/agent-docs/components/Alert.md +90 -95
- package/dist/agent-docs/components/AlertDialog.md +132 -126
- package/dist/agent-docs/components/AppEditor.md +90 -90
- package/dist/agent-docs/components/AppRadioGroup.md +18 -18
- package/dist/agent-docs/components/AppSidebar.md +129 -122
- package/dist/agent-docs/components/AppStepper.md +81 -77
- package/dist/agent-docs/components/AspectRatio.md +70 -62
- package/dist/agent-docs/components/AudioVisualizer.md +5 -5
- package/dist/agent-docs/components/Avatar.md +112 -113
- package/dist/agent-docs/components/Badge.md +123 -118
- package/dist/agent-docs/components/Breadcrumb.md +8 -1
- package/dist/agent-docs/components/Button.md +131 -129
- package/dist/agent-docs/components/Card.md +172 -147
- package/dist/agent-docs/components/Carousel.md +148 -129
- package/dist/agent-docs/components/Chat.md +121 -109
- package/dist/agent-docs/components/ChatMessage.md +72 -61
- package/dist/agent-docs/components/Checkbox.md +150 -135
- package/dist/agent-docs/components/CircularProgress.md +53 -49
- package/dist/agent-docs/components/CodeHighlighter.md +4 -4
- package/dist/agent-docs/components/Collapsible.md +114 -95
- package/dist/agent-docs/components/Command.md +141 -142
- package/dist/agent-docs/components/Confirmer.md +182 -175
- package/dist/agent-docs/components/ContextMenu.md +196 -191
- package/dist/agent-docs/components/DataCrossTable.md +114 -94
- package/dist/agent-docs/components/DataTable.md +32 -24
- package/dist/agent-docs/components/Dialog.md +130 -125
- package/dist/agent-docs/components/Drawer.md +141 -127
- package/dist/agent-docs/components/FilePreviewer.md +138 -139
- package/dist/agent-docs/components/FileUploader.md +149 -129
- package/dist/agent-docs/components/Form.md +3 -1
- package/dist/agent-docs/components/FormComposer.md +163 -137
- package/dist/agent-docs/components/GanttChart.md +125 -122
- package/dist/agent-docs/components/HoverCard.md +1 -1
- package/dist/agent-docs/components/Icon.md +98 -99
- package/dist/agent-docs/components/Input.md +173 -138
- package/dist/agent-docs/components/InputOtp.md +6 -1
- package/dist/agent-docs/components/InputSelector.md +94 -97
- package/dist/agent-docs/components/InterruptPrompt.md +4 -4
- package/dist/agent-docs/components/MarkdownRenderer.md +5 -2
- package/dist/agent-docs/components/Menubar.md +60 -57
- package/dist/agent-docs/components/MessageInput.md +134 -131
- package/dist/agent-docs/components/MessageList.md +110 -96
- package/dist/agent-docs/components/MultipleSelector.md +147 -146
- package/dist/agent-docs/components/NavigationMenu.md +6 -2
- package/dist/agent-docs/components/Popover.md +112 -103
- package/dist/agent-docs/components/PromptSuggestions.md +5 -5
- package/dist/agent-docs/components/RadioGroup.md +97 -90
- package/dist/agent-docs/components/Resizable.md +4 -1
- package/dist/agent-docs/components/ResizePrompt.md +12 -13
- package/dist/agent-docs/components/ScrollArea.md +6 -2
- package/dist/agent-docs/components/SecurePdfViewer.md +10 -6
- package/dist/agent-docs/components/Select.md +131 -132
- package/dist/agent-docs/components/Sheet.md +8 -1
- package/dist/agent-docs/components/ShikiHighlighter.md +5 -5
- package/dist/agent-docs/components/Sidebar.md +94 -85
- package/dist/agent-docs/components/Slider.md +62 -58
- package/dist/agent-docs/components/Sonner.md +1 -0
- package/dist/agent-docs/components/Spinner.md +14 -14
- package/dist/agent-docs/components/Stepper.md +93 -67
- package/dist/agent-docs/components/Switch.md +41 -42
- package/dist/agent-docs/components/TableSkeleton.md +8 -8
- package/dist/agent-docs/components/Tabs.md +106 -86
- package/dist/agent-docs/components/TextArea.md +51 -52
- package/dist/agent-docs/components/ThemeSwitcher.md +72 -69
- package/dist/agent-docs/components/Toaster.md +1 -0
- package/dist/agent-docs/components/Tooltip.md +102 -91
- package/dist/agent-docs/components/Typo.md +68 -65
- package/dist/agent-docs/components/WeeklyCalendar.md +63 -64
- package/dist/agent-docs/components-list.md +1 -0
- package/dist/agent-docs/manifest.json +5981 -0
- package/dist/agent-docs/truncated-cell.md +342 -0
- package/dist/components/editor/editor-hooks/use-update-toolbar.js +6 -6
- package/dist/components/editor/plugins/actions/counter-character-plugin.js +6 -6
- package/dist/components/editor/plugins/toolbar/font-format-toolbar-plugin.js +18 -18
- package/dist/components/editor/plugins/toolbar/history-toolbar-plugin.js +10 -10
- package/dist/components/editor/plugins/toolbar/toolbar-plugin.js +9 -9
- package/dist/components/ui/app-checkbox.js +1 -1
- package/dist/components/ui/app-dialog.js +70 -64
- package/dist/components/ui/app-editor.js +51 -51
- package/dist/components/ui/app-form.js +81 -81
- package/dist/components/ui/app-multiple-select-dropdown.js +36 -36
- package/dist/components/ui/app-select.js +109 -104
- package/dist/components/ui/app-sidebar.js +41 -41
- package/dist/components/ui/app-stepper.js +1 -1
- package/dist/components/ui/app-time-picker.js +18 -18
- package/dist/components/ui/app-tooltip.js +1 -1
- package/dist/components/ui/async-select.js +5 -5
- package/dist/components/ui/audio-visualizer.js +61 -58
- package/dist/components/ui/card.js +1 -1
- package/dist/components/ui/carousel.js +2 -2
- package/dist/components/ui/chart.js +1 -1
- package/dist/components/ui/chat-message.js +8 -8
- package/dist/components/ui/chat.js +86 -88
- package/dist/components/ui/command.js +2 -2
- package/dist/components/ui/copy-button.js +4 -4
- package/dist/components/ui/date-picker.js +20 -20
- package/dist/components/ui/file-preview/index.js +13 -13
- package/dist/components/ui/file-previewer.js +12 -11
- package/dist/components/ui/file-uploader.js +86 -78
- package/dist/components/ui/form.js +2 -2
- package/dist/components/ui/gantt/components/Chart/Bars/Bars.js +56 -56
- package/dist/components/ui/gantt/components/Chart/Bars/BarsRow/BarItem/BarItem.js +12 -12
- package/dist/components/ui/gantt/components/Chart/Bars/BarsRow/BarsItems/BarItems.js +1 -1
- package/dist/components/ui/gantt/components/Chart/Bars/BarsRow/BarsRow.js +4 -4
- package/dist/components/ui/gantt/components/Chart/Bars/BarsRow/RepeteadBars/RepeteadBars.js +2 -2
- package/dist/components/ui/gantt/components/Chart/Chart.js +23 -23
- package/dist/components/ui/gantt/components/Chart/Scale/Scale.js +1 -1
- package/dist/components/ui/gantt/components/Chart/Tree/Tree.js +34 -34
- package/dist/components/ui/gantt/components/Controls/Controls.js +5 -5
- package/dist/components/ui/gantt/components/Gantt/Gantt.js +4 -4
- package/dist/components/ui/gantt/hooks/useGanttCalculate.js +25 -18
- package/dist/components/ui/input-selector.js +1 -1
- package/dist/components/ui/input.js +23 -23
- package/dist/components/ui/kanban.js +8 -9
- package/dist/components/ui/markdown-renderer.js +41 -35
- package/dist/components/ui/message-input.js +45 -44
- package/dist/components/ui/multiple-selector.js +91 -82
- package/dist/components/ui/secure-pdf-viewer.js +19 -7
- package/dist/components/ui/sidebar.js +1 -1
- package/dist/components/ui/slider.js +1 -1
- package/dist/components/ui/spinner.js +4 -4
- package/dist/components/ui/stepper.js +157 -138
- package/dist/components/ui/tables/data-cross-table/data-cross-table-buttons.js +29 -29
- package/dist/components/ui/tables/data-cross-table/data-cross-table.js +258 -246
- package/dist/components/ui/tables/data-table/components/data-table-advanced-filter.js +4 -1
- package/dist/components/ui/tables/data-table/components/data-table-body.js +211 -367
- package/dist/components/ui/tables/data-table/components/data-table-filter-inputs.js +114 -112
- package/dist/components/ui/tables/data-table/components/data-table-filters.js +116 -96
- package/dist/components/ui/tables/data-table/components/data-table-header.js +211 -0
- package/dist/components/ui/tables/data-table/components/data-table-searchbar.js +8 -8
- package/dist/components/ui/tables/data-table/components/data-table-skeleton-rows.js +33 -0
- package/dist/components/ui/tables/data-table/data-table.js +258 -250
- package/dist/components/ui/tables/data-table/data-table.service.js +112 -97
- package/dist/components/ui/tables/data-table/data-table.utils.js +25 -15
- package/dist/components/ui/textarea.js +2 -2
- package/dist/components/ui/theme-switcher.js +1 -1
- package/dist/components/ui/toggle-group.js +2 -2
- package/dist/components/ui/truncated-cell.js +100 -0
- package/dist/components/ui/weekly-calendar/appointment-card.js +16 -16
- package/dist/components/ui/weekly-calendar/calendar-context.js +6 -6
- package/dist/components/ui/weekly-calendar/calendar-header.js +12 -12
- package/dist/components/ui/weekly-calendar/day-column.js +16 -16
- package/dist/components/ui/weekly-calendar/time-column.js +4 -4
- package/dist/components/ui/weekly-calendar/weekly-calendar.js +4 -4
- package/dist/hooks/use-audio-recording.js +1 -1
- package/dist/hooks/use-auto-scroll.js +18 -18
- package/dist/hooks/use-autosize-textarea.js +12 -13
- package/dist/index.d.ts +100 -45
- package/dist/index.js +362 -360
- package/dist/lib/utils.js +6 -6
- package/dist/styles.v3.css +1 -1
- package/package.json +14 -4
|
@@ -1,177 +1,179 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsx as
|
|
3
|
-
import { AppSelect as
|
|
2
|
+
import { jsx as a, jsxs as k } from "react/jsx-runtime";
|
|
3
|
+
import { AppSelect as $ } from "../../../app-select.js";
|
|
4
4
|
import { DatePicker as w } from "../../../date-picker.js";
|
|
5
|
-
import { Input as
|
|
6
|
-
import { cn as
|
|
7
|
-
function
|
|
5
|
+
import { Input as b } from "../../../input.js";
|
|
6
|
+
import { cn as g } from "../../../../../lib/utils.js";
|
|
7
|
+
function G({
|
|
8
8
|
columnType: x,
|
|
9
|
-
value:
|
|
10
|
-
onChange:
|
|
11
|
-
operator:
|
|
12
|
-
listOptions:
|
|
9
|
+
value: t,
|
|
10
|
+
onChange: c,
|
|
11
|
+
operator: f,
|
|
12
|
+
listOptions: D = [],
|
|
13
13
|
placeholder: C,
|
|
14
|
-
size:
|
|
15
|
-
className:
|
|
16
|
-
hasError:
|
|
17
|
-
disabled:
|
|
18
|
-
i18n:
|
|
14
|
+
size: o = "sm",
|
|
15
|
+
className: p,
|
|
16
|
+
hasError: V = !1,
|
|
17
|
+
disabled: l = !1,
|
|
18
|
+
i18n: s
|
|
19
19
|
}) {
|
|
20
|
-
const
|
|
21
|
-
if (
|
|
20
|
+
const m = C || s?.filters.value || "Value", T = V ? "border-red-500" : "", S = V ? "border-red-500" : "";
|
|
21
|
+
if (f === "eq_null" || f === "n_eq_null" || f === "checked" || f === "unchecked")
|
|
22
22
|
return null;
|
|
23
23
|
switch (x) {
|
|
24
24
|
case "string":
|
|
25
|
-
return /* @__PURE__ */
|
|
26
|
-
|
|
25
|
+
return /* @__PURE__ */ a(
|
|
26
|
+
b,
|
|
27
27
|
{
|
|
28
|
-
size:
|
|
29
|
-
placeholder:
|
|
30
|
-
className:
|
|
31
|
-
value:
|
|
32
|
-
disabled:
|
|
33
|
-
onChange: (
|
|
28
|
+
size: o,
|
|
29
|
+
placeholder: m,
|
|
30
|
+
className: g(p, T),
|
|
31
|
+
value: t != null ? String(t) : "",
|
|
32
|
+
disabled: l,
|
|
33
|
+
onChange: (r) => c(r.target.value)
|
|
34
34
|
}
|
|
35
35
|
);
|
|
36
36
|
case "number":
|
|
37
|
-
return /* @__PURE__ */
|
|
38
|
-
|
|
37
|
+
return /* @__PURE__ */ a(
|
|
38
|
+
b,
|
|
39
39
|
{
|
|
40
|
-
size:
|
|
40
|
+
size: o,
|
|
41
41
|
type: "number",
|
|
42
|
-
placeholder:
|
|
43
|
-
className:
|
|
44
|
-
value:
|
|
45
|
-
disabled:
|
|
46
|
-
onChange: (
|
|
42
|
+
placeholder: m,
|
|
43
|
+
className: g(p, T),
|
|
44
|
+
value: t != null ? String(t) : "",
|
|
45
|
+
disabled: l,
|
|
46
|
+
onChange: (r) => c(Number(r.target.value))
|
|
47
47
|
}
|
|
48
48
|
);
|
|
49
49
|
case "boolean":
|
|
50
|
-
return /* @__PURE__ */
|
|
51
|
-
|
|
50
|
+
return /* @__PURE__ */ a(
|
|
51
|
+
$,
|
|
52
52
|
{
|
|
53
53
|
isSingleSelectClearable: !0,
|
|
54
|
-
size:
|
|
55
|
-
placeholder:
|
|
56
|
-
className:
|
|
54
|
+
size: o,
|
|
55
|
+
placeholder: m,
|
|
56
|
+
className: g(p, S),
|
|
57
57
|
options: [
|
|
58
|
-
{ value: "true", label:
|
|
59
|
-
{ value: "false", label:
|
|
58
|
+
{ value: "true", label: s?.booleanOperators.true || "True" },
|
|
59
|
+
{ value: "false", label: s?.booleanOperators.false || "False" }
|
|
60
60
|
],
|
|
61
|
-
value:
|
|
62
|
-
disabled:
|
|
63
|
-
onValueChange: (
|
|
64
|
-
|
|
61
|
+
value: t === !0 ? "true" : t === !1 ? "false" : void 0,
|
|
62
|
+
disabled: l,
|
|
63
|
+
onValueChange: (r) => {
|
|
64
|
+
c(r === "true" ? !0 : r === "false" ? !1 : void 0);
|
|
65
65
|
}
|
|
66
66
|
},
|
|
67
|
-
`boolean-${
|
|
67
|
+
`boolean-${t}`
|
|
68
68
|
);
|
|
69
69
|
case "list_single_select":
|
|
70
|
-
return /* @__PURE__ */
|
|
71
|
-
|
|
70
|
+
return /* @__PURE__ */ a(
|
|
71
|
+
$,
|
|
72
72
|
{
|
|
73
73
|
searchable: !0,
|
|
74
74
|
isSingleSelectClearable: !0,
|
|
75
|
-
size:
|
|
76
|
-
placeholder:
|
|
77
|
-
className:
|
|
78
|
-
options:
|
|
79
|
-
value: Array.isArray(
|
|
80
|
-
disabled:
|
|
81
|
-
onValueChange:
|
|
75
|
+
size: o,
|
|
76
|
+
placeholder: s?.filters.searchPlaceholder || m,
|
|
77
|
+
className: g(p, S),
|
|
78
|
+
options: D,
|
|
79
|
+
value: Array.isArray(t) || typeof t == "boolean" ? void 0 : t,
|
|
80
|
+
disabled: l,
|
|
81
|
+
onValueChange: c
|
|
82
82
|
}
|
|
83
83
|
);
|
|
84
84
|
case "list_multi_select":
|
|
85
|
-
return /* @__PURE__ */
|
|
86
|
-
|
|
85
|
+
return /* @__PURE__ */ a(
|
|
86
|
+
$,
|
|
87
87
|
{
|
|
88
88
|
multiple: !0,
|
|
89
89
|
searchable: !0,
|
|
90
|
-
size:
|
|
91
|
-
placeholder:
|
|
92
|
-
className:
|
|
93
|
-
options:
|
|
94
|
-
value: Array.isArray(
|
|
95
|
-
disabled:
|
|
96
|
-
onValueChange:
|
|
90
|
+
size: o,
|
|
91
|
+
placeholder: s?.filters.searchPlaceholder || m,
|
|
92
|
+
className: g(p, S),
|
|
93
|
+
options: D,
|
|
94
|
+
value: Array.isArray(t) ? t : [],
|
|
95
|
+
disabled: l,
|
|
96
|
+
onValueChange: c
|
|
97
97
|
}
|
|
98
98
|
);
|
|
99
|
-
case "date":
|
|
100
|
-
const
|
|
101
|
-
const
|
|
102
|
-
|
|
103
|
-
},
|
|
104
|
-
return /* @__PURE__ */
|
|
99
|
+
case "date": {
|
|
100
|
+
const r = (i) => {
|
|
101
|
+
const e = i ? `${i.getFullYear()}-${(i.getMonth() + 1).toString().padStart(2, "0")}-${i.getDate().toString().padStart(2, "0")}` : void 0;
|
|
102
|
+
c(e);
|
|
103
|
+
}, n = t && typeof t == "string" ? new Date(t) : void 0;
|
|
104
|
+
return /* @__PURE__ */ a(
|
|
105
105
|
w,
|
|
106
106
|
{
|
|
107
|
-
value:
|
|
108
|
-
onChange:
|
|
109
|
-
placeholder:
|
|
107
|
+
value: n,
|
|
108
|
+
onChange: r,
|
|
109
|
+
placeholder: s?.filters.selectDate || "Select date",
|
|
110
110
|
buttonVariant: "outline",
|
|
111
|
-
size:
|
|
111
|
+
size: o,
|
|
112
112
|
dateFormat: "dd/MM/yyyy",
|
|
113
|
-
disabled:
|
|
113
|
+
disabled: l
|
|
114
114
|
}
|
|
115
115
|
);
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
116
|
+
}
|
|
117
|
+
case "datetime": {
|
|
118
|
+
const r = (e, h) => {
|
|
119
|
+
let u;
|
|
120
|
+
if (e) {
|
|
121
|
+
const y = h || "00:00", [M, F] = y.split(":"), d = new Date(e);
|
|
122
|
+
d.setHours(parseInt(M, 10), parseInt(F, 10), 0, 0);
|
|
123
|
+
const I = d.getFullYear(), N = (d.getMonth() + 1).toString().padStart(2, "0"), _ = d.getDate().toString().padStart(2, "0"), P = d.getHours().toString().padStart(2, "0"), A = d.getMinutes().toString().padStart(2, "0"), H = d.getSeconds().toString().padStart(2, "0");
|
|
124
|
+
u = `${I}-${N}-${_}T${P}:${A}:${H}.000000`;
|
|
124
125
|
}
|
|
125
|
-
|
|
126
|
-
},
|
|
127
|
-
if (
|
|
128
|
-
const
|
|
129
|
-
if (
|
|
130
|
-
const [
|
|
131
|
-
return new Date(
|
|
126
|
+
c(u);
|
|
127
|
+
}, n = t && typeof t == "string" ? (() => {
|
|
128
|
+
if (t.includes("T")) {
|
|
129
|
+
const e = t.split("T")[0];
|
|
130
|
+
if (e.match(/^\d{4}-\d{2}-\d{2}$/)) {
|
|
131
|
+
const [h, u, y] = e.split("-").map(Number);
|
|
132
|
+
return new Date(h, u - 1, y);
|
|
132
133
|
}
|
|
133
134
|
}
|
|
134
|
-
return new Date(
|
|
135
|
-
})() : void 0,
|
|
136
|
-
if (typeof
|
|
137
|
-
const
|
|
138
|
-
if (
|
|
139
|
-
const
|
|
140
|
-
if (
|
|
141
|
-
return
|
|
135
|
+
return new Date(t);
|
|
136
|
+
})() : void 0, i = n ? (() => {
|
|
137
|
+
if (typeof t == "string" && t.includes("T")) {
|
|
138
|
+
const e = t.split("T")[1];
|
|
139
|
+
if (e) {
|
|
140
|
+
const u = e.split(".")[0].replace("Z", "");
|
|
141
|
+
if (u.match(/^\d{2}:\d{2}(:\d{2})?$/))
|
|
142
|
+
return u.substring(0, 5);
|
|
142
143
|
}
|
|
143
144
|
}
|
|
144
|
-
return `${
|
|
145
|
+
return `${n.getHours().toString().padStart(2, "0")}:${n.getMinutes().toString().padStart(2, "0")}`;
|
|
145
146
|
})() : "00:00";
|
|
146
|
-
return /* @__PURE__ */
|
|
147
|
-
/* @__PURE__ */
|
|
147
|
+
return /* @__PURE__ */ k("div", { className: "flex flex-row gap-2", children: [
|
|
148
|
+
/* @__PURE__ */ a(
|
|
148
149
|
w,
|
|
149
150
|
{
|
|
150
|
-
value:
|
|
151
|
-
onChange: (
|
|
152
|
-
placeholder:
|
|
151
|
+
value: n,
|
|
152
|
+
onChange: (e) => r(e, i),
|
|
153
|
+
placeholder: s?.filters.selectDate || "Select date",
|
|
153
154
|
buttonVariant: "outline",
|
|
154
|
-
size:
|
|
155
|
+
size: o,
|
|
155
156
|
dateFormat: "dd/MM/yyyy",
|
|
156
|
-
disabled:
|
|
157
|
+
disabled: l
|
|
157
158
|
}
|
|
158
159
|
),
|
|
159
|
-
/* @__PURE__ */
|
|
160
|
-
|
|
160
|
+
/* @__PURE__ */ a(
|
|
161
|
+
b,
|
|
161
162
|
{
|
|
162
163
|
type: "time",
|
|
163
|
-
size:
|
|
164
|
-
value:
|
|
165
|
-
onChange: (
|
|
164
|
+
size: o,
|
|
165
|
+
value: i,
|
|
166
|
+
onChange: (e) => r(n, e.target.value),
|
|
166
167
|
className: "text-sm",
|
|
167
|
-
disabled: !
|
|
168
|
+
disabled: !n || l
|
|
168
169
|
}
|
|
169
170
|
)
|
|
170
171
|
] });
|
|
172
|
+
}
|
|
171
173
|
default:
|
|
172
|
-
return /* @__PURE__ */
|
|
174
|
+
return /* @__PURE__ */ a("div", { className: "text-muted-foreground text-sm", children: s?.filters.filterNotSupported || "Filter not supported" });
|
|
173
175
|
}
|
|
174
176
|
}
|
|
175
177
|
export {
|
|
176
|
-
|
|
178
|
+
G as FilterValueInput
|
|
177
179
|
};
|