@deepnoid/ui 0.1.112 → 0.1.114

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 (122) hide show
  1. package/.turbo/turbo-build.log +181 -171
  2. package/dist/{chunk-46SXEYRN.mjs → chunk-2PZRTIRD.mjs} +1 -1
  3. package/dist/chunk-2VQM2ZBF.mjs +408 -0
  4. package/dist/{chunk-Q36C7WNH.mjs → chunk-4NVZMJGS.mjs} +1 -1
  5. package/dist/{chunk-HBEPQQOM.mjs → chunk-5AEN7QTL.mjs} +1 -1
  6. package/dist/{chunk-3I35VMMV.mjs → chunk-7VTZLHKM.mjs} +2 -2
  7. package/dist/{chunk-UOP7XLYB.mjs → chunk-7YCUFFKZ.mjs} +1 -1
  8. package/dist/{chunk-34DMXYCQ.mjs → chunk-AHBBUMPX.mjs} +2 -2
  9. package/dist/{chunk-KPNIWFLU.mjs → chunk-BFZ6OTVA.mjs} +2 -2
  10. package/dist/{chunk-7K463ANW.mjs → chunk-BKYNB52Z.mjs} +1 -1
  11. package/dist/{chunk-GAZ472ZU.mjs → chunk-CF7LIQF6.mjs} +54 -44
  12. package/dist/{chunk-XEEDMB5O.mjs → chunk-DDJ2EU3P.mjs} +39 -39
  13. package/dist/{chunk-J5K7RN5X.mjs → chunk-EDAREIAN.mjs} +1 -1
  14. package/dist/{chunk-33DLD2L6.mjs → chunk-FU4CDBVG.mjs} +1 -1
  15. package/dist/chunk-FWFEKWWD.mjs +18 -0
  16. package/dist/chunk-KIN2UK2C.mjs +132 -0
  17. package/dist/{chunk-XRYETYWI.mjs → chunk-L3WKBOWY.mjs} +1 -1
  18. package/dist/{chunk-EQWU2F5T.mjs → chunk-MLD6EZAE.mjs} +1 -1
  19. package/dist/{chunk-X67ELNP6.mjs → chunk-MTQGHQ7Z.mjs} +3 -3
  20. package/dist/{chunk-YCLB7ZNK.mjs → chunk-QREBEXKF.mjs} +1 -1
  21. package/dist/{chunk-2OK3VF75.mjs → chunk-TMHYS2DC.mjs} +4 -4
  22. package/dist/{chunk-GDKDD2MW.mjs → chunk-UNYKQTEP.mjs} +2 -2
  23. package/dist/{chunk-ANM4RNDF.mjs → chunk-VIXHPIIF.mjs} +3 -3
  24. package/dist/components/avatar/avatar.js +39 -39
  25. package/dist/components/avatar/avatar.mjs +2 -2
  26. package/dist/components/avatar/index.js +39 -39
  27. package/dist/components/avatar/index.mjs +2 -2
  28. package/dist/components/breadcrumb/breadcrumb.js +39 -39
  29. package/dist/components/breadcrumb/breadcrumb.mjs +5 -5
  30. package/dist/components/breadcrumb/index.js +39 -39
  31. package/dist/components/breadcrumb/index.mjs +5 -5
  32. package/dist/components/button/button.js +39 -39
  33. package/dist/components/button/button.mjs +3 -3
  34. package/dist/components/button/icon-button.js +39 -39
  35. package/dist/components/button/icon-button.mjs +3 -3
  36. package/dist/components/button/index.js +39 -39
  37. package/dist/components/button/index.mjs +4 -4
  38. package/dist/components/charts/barChart.js +54 -44
  39. package/dist/components/charts/barChart.mjs +1 -1
  40. package/dist/components/charts/circularProgress.d.mts +18 -33
  41. package/dist/components/charts/circularProgress.d.ts +18 -33
  42. package/dist/components/charts/circularProgress.js +56 -31
  43. package/dist/components/charts/circularProgress.mjs +1 -1
  44. package/dist/components/charts/index.js +110 -75
  45. package/dist/components/charts/index.mjs +2 -2
  46. package/dist/components/chip/chip.js +39 -39
  47. package/dist/components/chip/chip.mjs +3 -3
  48. package/dist/components/chip/index.js +39 -39
  49. package/dist/components/chip/index.mjs +3 -3
  50. package/dist/components/fileUpload/fileUpload.js +39 -39
  51. package/dist/components/fileUpload/fileUpload.mjs +6 -6
  52. package/dist/components/fileUpload/index.js +39 -39
  53. package/dist/components/fileUpload/index.mjs +6 -6
  54. package/dist/components/icon/Icon.d.mts +4 -4
  55. package/dist/components/icon/Icon.d.ts +4 -4
  56. package/dist/components/icon/Icon.js +39 -39
  57. package/dist/components/icon/Icon.mjs +2 -2
  58. package/dist/components/icon/index.js +39 -39
  59. package/dist/components/icon/index.mjs +2 -2
  60. package/dist/components/icon/template.d.mts +1 -1
  61. package/dist/components/icon/template.d.ts +1 -1
  62. package/dist/components/icon/template.js +39 -39
  63. package/dist/components/icon/template.mjs +1 -1
  64. package/dist/components/input/index.js +39 -39
  65. package/dist/components/input/index.mjs +3 -3
  66. package/dist/components/input/input.js +39 -39
  67. package/dist/components/input/input.mjs +3 -3
  68. package/dist/components/list/index.js +39 -39
  69. package/dist/components/list/index.mjs +4 -4
  70. package/dist/components/list/listItem.js +39 -39
  71. package/dist/components/list/listItem.mjs +4 -4
  72. package/dist/components/modal/index.js +39 -39
  73. package/dist/components/modal/index.mjs +5 -5
  74. package/dist/components/modal/modal.js +39 -39
  75. package/dist/components/modal/modal.mjs +5 -5
  76. package/dist/components/pagination/index.js +39 -39
  77. package/dist/components/pagination/index.mjs +4 -4
  78. package/dist/components/pagination/pagination.js +39 -39
  79. package/dist/components/pagination/pagination.mjs +4 -4
  80. package/dist/components/picker/datePicker.d.mts +244 -0
  81. package/dist/components/picker/datePicker.d.ts +244 -0
  82. package/dist/components/picker/datePicker.js +5452 -0
  83. package/dist/components/picker/datePicker.mjs +17 -0
  84. package/dist/components/picker/index.d.mts +1 -0
  85. package/dist/components/picker/index.d.ts +1 -0
  86. package/dist/components/picker/index.js +507 -107
  87. package/dist/components/picker/index.mjs +10 -5
  88. package/dist/components/picker/timePicker.js +39 -39
  89. package/dist/components/picker/timePicker.mjs +4 -4
  90. package/dist/components/picker/utils.d.mts +4 -0
  91. package/dist/components/picker/utils.d.ts +4 -0
  92. package/dist/components/picker/utils.js +42 -0
  93. package/dist/components/picker/utils.mjs +10 -0
  94. package/dist/components/select/index.js +39 -39
  95. package/dist/components/select/index.mjs +3 -3
  96. package/dist/components/select/select.js +39 -39
  97. package/dist/components/select/select.mjs +3 -3
  98. package/dist/components/table/index.js +39 -39
  99. package/dist/components/table/index.mjs +7 -7
  100. package/dist/components/table/table-body.js +39 -39
  101. package/dist/components/table/table-body.mjs +7 -7
  102. package/dist/components/table/table-head.js +39 -39
  103. package/dist/components/table/table-head.mjs +7 -7
  104. package/dist/components/table/table.js +39 -39
  105. package/dist/components/table/table.mjs +7 -7
  106. package/dist/components/toast/index.js +39 -39
  107. package/dist/components/toast/index.mjs +5 -5
  108. package/dist/components/toast/toast.js +39 -39
  109. package/dist/components/toast/toast.mjs +3 -3
  110. package/dist/components/toast/use-toast.js +39 -39
  111. package/dist/components/toast/use-toast.mjs +4 -4
  112. package/dist/components/tree/index.js +39 -39
  113. package/dist/components/tree/index.mjs +3 -3
  114. package/dist/components/tree/tree.js +39 -39
  115. package/dist/components/tree/tree.mjs +3 -3
  116. package/dist/index.d.mts +2 -1
  117. package/dist/index.d.ts +2 -1
  118. package/dist/index.js +690 -253
  119. package/dist/index.mjs +47 -42
  120. package/package.json +1 -1
  121. package/dist/chunk-ZWLRSZTC.mjs +0 -107
  122. /package/dist/{chunk-BG7VAVOX.mjs → chunk-ZG4WRZOU.mjs} +0 -0
@@ -7,7 +7,7 @@ import {
7
7
  } from "./chunk-6PNKRBUT.mjs";
8
8
  import {
9
9
  Icon_default
10
- } from "./chunk-33DLD2L6.mjs";
10
+ } from "./chunk-FU4CDBVG.mjs";
11
11
  import {
12
12
  mapPropsVariants
13
13
  } from "./chunk-E3G5QXSH.mjs";
@@ -0,0 +1,408 @@
1
+ "use client";
2
+ import {
3
+ formatDateToString,
4
+ formatStringToDate
5
+ } from "./chunk-FWFEKWWD.mjs";
6
+ import {
7
+ Icon_default
8
+ } from "./chunk-FU4CDBVG.mjs";
9
+ import {
10
+ mapPropsVariants
11
+ } from "./chunk-E3G5QXSH.mjs";
12
+ import {
13
+ tv
14
+ } from "./chunk-CDXBML6O.mjs";
15
+ import {
16
+ clsx
17
+ } from "./chunk-27Y6K5NK.mjs";
18
+
19
+ // src/components/picker/datePicker.tsx
20
+ import React, { forwardRef, useCallback, useMemo, useState, useRef, useEffect } from "react";
21
+ import { createPortal } from "react-dom";
22
+ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
23
+ var DatePicker = forwardRef((originalProps, ref) => {
24
+ const [props, variantProps] = mapPropsVariants(originalProps, datePickerStyle.variantKeys);
25
+ const {
26
+ classNames,
27
+ label,
28
+ errorMessage,
29
+ value,
30
+ onChange,
31
+ size,
32
+ placeholder = "",
33
+ format = "YYYY-MM-DD",
34
+ highlightWeekend = true,
35
+ calendarColor = "primary",
36
+ locale = "default",
37
+ daysOfWeek = ["S", "M", "T", "W", "T", "F", "S"],
38
+ monthYearFormat = (year, month) => new Date(year, month).toLocaleString(locale, { year: "numeric", month: "2-digit" }),
39
+ ...inputProps
40
+ } = props;
41
+ const [selectedDate, setSelectedDate] = useState(value || "");
42
+ const [isPanelOpen, setIsPanelOpen] = useState(false);
43
+ const [currentDate, setCurrentDate] = useState(selectedDate ? new Date(selectedDate) : /* @__PURE__ */ new Date());
44
+ const inputWrapperRef = useRef(null);
45
+ const panelWrapperRef = useRef(null);
46
+ const [panelPos, setPanelPos] = useState({ top: -9999, left: -9999 });
47
+ const formatDate = (dateString) => {
48
+ if (!dateString) return "";
49
+ const [year, month, day] = dateString.split("-");
50
+ switch (format) {
51
+ case "MM/DD/YYYY":
52
+ return `${month}/${day}/${year}`;
53
+ case "DD/MM/YYYY":
54
+ return `${day}/${month}/${year}`;
55
+ default:
56
+ return dateString;
57
+ }
58
+ };
59
+ const displayValue = useMemo(() => {
60
+ return formatDate(selectedDate);
61
+ }, [selectedDate, format]);
62
+ const calculatePosition = useCallback(() => {
63
+ if (inputWrapperRef.current) {
64
+ const rect = inputWrapperRef.current.getBoundingClientRect();
65
+ setPanelPos({ top: rect.bottom + window.scrollY + 6, left: rect.left + window.scrollX });
66
+ }
67
+ }, []);
68
+ const handleFocusInput = () => {
69
+ calculatePosition();
70
+ setIsPanelOpen(true);
71
+ };
72
+ const handleInputBlur = () => {
73
+ setTimeout(() => setIsPanelOpen(false), 150);
74
+ };
75
+ const handleInputKeyDown = (e) => {
76
+ if (e.key === "Enter" || e.key === " ") {
77
+ e.preventDefault();
78
+ calculatePosition();
79
+ setIsPanelOpen((prev) => !prev);
80
+ } else if (e.key === "Escape") {
81
+ setIsPanelOpen(false);
82
+ }
83
+ };
84
+ const getCalendarDates = useCallback(() => {
85
+ const year = currentDate.getFullYear();
86
+ const month = currentDate.getMonth();
87
+ const firstDayOfMonth = new Date(year, month, 1).getDay();
88
+ const lastDateOfMonth = new Date(year, month + 1, 0).getDate();
89
+ const lastDateOfPrevMonth = new Date(year, month, 0).getDate();
90
+ let dates = [];
91
+ for (let i = firstDayOfMonth - 1; i >= 0; i--) {
92
+ dates.push({
93
+ date: lastDateOfPrevMonth - i,
94
+ currentMonth: false
95
+ });
96
+ }
97
+ for (let date = 1; date <= lastDateOfMonth; date++) {
98
+ dates.push({
99
+ date,
100
+ currentMonth: true
101
+ });
102
+ }
103
+ const remainingDays = 42 - dates.length;
104
+ for (let i = 1; i <= remainingDays; i++) {
105
+ dates.push({
106
+ date: i,
107
+ currentMonth: false
108
+ });
109
+ }
110
+ const weeks = [];
111
+ for (let i = 0; i < dates.length; i += 7) {
112
+ weeks.push(dates.slice(i, i + 7));
113
+ }
114
+ return weeks;
115
+ }, [currentDate]);
116
+ const handlePrevMonth = () => {
117
+ setCurrentDate(new Date(currentDate.getFullYear(), currentDate.getMonth() - 1));
118
+ };
119
+ const handleNextMonth = () => {
120
+ setCurrentDate(new Date(currentDate.getFullYear(), currentDate.getMonth() + 1));
121
+ };
122
+ const handleDateSelect = (date, isCurrentMonth) => {
123
+ if (!isCurrentMonth) return;
124
+ const selected = new Date(currentDate.getFullYear(), currentDate.getMonth(), date);
125
+ const formatted = formatDateToString(selected);
126
+ setSelectedDate(formatted);
127
+ onChange == null ? void 0 : onChange(formatted);
128
+ setIsPanelOpen(false);
129
+ };
130
+ const handleClearDate = () => {
131
+ setSelectedDate("");
132
+ onChange == null ? void 0 : onChange("");
133
+ };
134
+ const slots = useMemo(() => datePickerStyle({ ...variantProps }), [variantProps]);
135
+ const getDateTitleProps = useCallback(
136
+ (index) => {
137
+ return {
138
+ className: clsx(
139
+ "text-sm font-[500]",
140
+ highlightWeekend && index === 6 && "text-[#1E7EEE]",
141
+ highlightWeekend && index === 0 && "text-[#FF4684]"
142
+ )
143
+ };
144
+ },
145
+ [highlightWeekend]
146
+ );
147
+ const getDateProps = useCallback(
148
+ (dateObj) => {
149
+ const today = /* @__PURE__ */ new Date();
150
+ const isToday = today.getDate() === dateObj.date && today.getMonth() === currentDate.getMonth() && today.getFullYear() === currentDate.getFullYear();
151
+ const formatted = selectedDate ? formatStringToDate(selectedDate) : null;
152
+ const isSelected = formatted ? formatted.getDate() === dateObj.date && formatted.getMonth() === currentDate.getMonth() && formatted.getFullYear() === currentDate.getFullYear() : false;
153
+ const dayOfWeek = new Date(currentDate.getFullYear(), currentDate.getMonth(), dateObj.date).getDay();
154
+ return {
155
+ className: clsx(
156
+ "flex justify-center items-center h-[25px] text-sm rounded-full cursor-pointer hover:bg-neutral-light",
157
+ dateObj.currentMonth && isToday && "border border-foreground",
158
+ dateObj.currentMonth && isSelected && "!text-white border-none",
159
+ calendarColor === "primary" && dateObj.currentMonth && isSelected && "!border-primary-main bg-primary-main",
160
+ calendarColor === "secondary" && dateObj.currentMonth && isSelected && "!border-secondary-main bg-secondary-main",
161
+ highlightWeekend && dayOfWeek === 6 && "text-neutral-main",
162
+ highlightWeekend && dayOfWeek === 6 && isToday && "!border-neutral-light",
163
+ highlightWeekend && dayOfWeek === 0 && "text-danger-main",
164
+ highlightWeekend && dayOfWeek === 0 && isToday && "!border-danger-light",
165
+ !dateObj.currentMonth && "!text-neutral-main cursor-default hover:bg-transparent"
166
+ ),
167
+ onClick: () => handleDateSelect(dateObj.date, dateObj.currentMonth)
168
+ };
169
+ },
170
+ [selectedDate, currentDate, highlightWeekend, calendarColor]
171
+ );
172
+ const calendarDates = getCalendarDates();
173
+ useEffect(() => {
174
+ if (value !== void 0) {
175
+ setSelectedDate(value);
176
+ if (value) {
177
+ setCurrentDate(new Date(value));
178
+ }
179
+ }
180
+ }, [value]);
181
+ useEffect(() => {
182
+ if (selectedDate) {
183
+ setCurrentDate(new Date(selectedDate));
184
+ }
185
+ }, [selectedDate]);
186
+ return /* @__PURE__ */ jsxs(Fragment, { children: [
187
+ /* @__PURE__ */ jsxs("div", { className: slots.base({ class: classNames == null ? void 0 : classNames.base }), children: [
188
+ label && /* @__PURE__ */ jsx("label", { className: slots.label({ class: classNames == null ? void 0 : classNames.label }), children: label }),
189
+ /* @__PURE__ */ jsxs("div", { className: slots.wrapper({ class: classNames == null ? void 0 : classNames.wrapper }), children: [
190
+ /* @__PURE__ */ jsxs("div", { ref: inputWrapperRef, className: slots.inputWrapper({ class: classNames == null ? void 0 : classNames.inputWrapper }), children: [
191
+ /* @__PURE__ */ jsx(
192
+ "input",
193
+ {
194
+ ...inputProps,
195
+ ref,
196
+ className: slots.input({ class: classNames == null ? void 0 : classNames.input }),
197
+ type: "text",
198
+ value: displayValue,
199
+ placeholder,
200
+ readOnly: true,
201
+ onFocus: handleFocusInput,
202
+ onBlur: handleInputBlur,
203
+ onKeyDown: handleInputKeyDown
204
+ }
205
+ ),
206
+ /* @__PURE__ */ jsxs("div", { className: slots.icon({ class: classNames == null ? void 0 : classNames.icon }), children: [
207
+ displayValue && /* @__PURE__ */ jsx(
208
+ Icon_default,
209
+ {
210
+ name: "close",
211
+ className: "text-neutral-light hover:text-neutral-main mr-[5px] cursor-pointer",
212
+ onClick: (e) => {
213
+ e.stopPropagation();
214
+ handleClearDate();
215
+ }
216
+ }
217
+ ),
218
+ /* @__PURE__ */ jsx(
219
+ Icon_default,
220
+ {
221
+ name: "calendar",
222
+ className: "cursor-pointer",
223
+ fill: true,
224
+ onClick: () => {
225
+ calculatePosition();
226
+ setIsPanelOpen((v) => !v);
227
+ }
228
+ }
229
+ )
230
+ ] })
231
+ ] }),
232
+ errorMessage && /* @__PURE__ */ jsx("p", { className: clsx("error", slots.errorMessage({ class: classNames == null ? void 0 : classNames.errorMessage })), children: errorMessage })
233
+ ] })
234
+ ] }),
235
+ isPanelOpen && createPortal(
236
+ /* @__PURE__ */ jsxs(
237
+ "div",
238
+ {
239
+ ref: panelWrapperRef,
240
+ className: slots.optionsWrapper({ class: classNames == null ? void 0 : classNames.optionsWrapper }),
241
+ style: {
242
+ position: "absolute",
243
+ top: panelPos.top,
244
+ left: panelPos.left,
245
+ zIndex: 1e3
246
+ },
247
+ onMouseDown: (e) => e.preventDefault(),
248
+ children: [
249
+ /* @__PURE__ */ jsxs("div", { className: "calendar-header mb-4 flex items-center justify-between", children: [
250
+ /* @__PURE__ */ jsx(Icon_default, { name: "brace-left", size: "md", className: "cursor-pointer", onClick: handlePrevMonth }),
251
+ /* @__PURE__ */ jsx("span", { className: "text-h6 font-semibold", children: monthYearFormat(currentDate.getFullYear(), currentDate.getMonth()) }),
252
+ /* @__PURE__ */ jsx(Icon_default, { name: "brace-right", size: "md", className: "cursor-pointer", onClick: handleNextMonth })
253
+ ] }),
254
+ /* @__PURE__ */ jsx("div", { className: "grid grid-cols-7 gap-2 text-center", children: daysOfWeek.map((day, index) => /* @__PURE__ */ jsx("div", { ...getDateTitleProps(index), children: day }, `${day}-${index}`)) }),
255
+ /* @__PURE__ */ jsx("div", { className: "mt-2 grid grid-cols-7 gap-[5px] text-center", children: calendarDates.map((week, weekIndex) => {
256
+ const hasCurrentMonthDates = week.some((dateObj) => dateObj.currentMonth);
257
+ if (!hasCurrentMonthDates) return null;
258
+ return /* @__PURE__ */ jsx(React.Fragment, { children: week.map((dateObj, index) => {
259
+ return /* @__PURE__ */ jsx("div", { ...getDateProps(dateObj), children: dateObj.date }, index);
260
+ }) }, weekIndex);
261
+ }) })
262
+ ]
263
+ }
264
+ ),
265
+ document.body
266
+ )
267
+ ] });
268
+ });
269
+ DatePicker.displayName = "DatePicker";
270
+ var datePicker_default = DatePicker;
271
+ var datePickerStyle = tv({
272
+ slots: {
273
+ base: ["group/datepicker", "flex", "flex-col"],
274
+ label: ["flex", "items-center", "font-bold", "text-body-foreground", "min-w-[80px]"],
275
+ wrapper: ["flex", "flex-col"],
276
+ inputWrapper: [
277
+ "flex",
278
+ "items-center",
279
+ "justify-between",
280
+ "border",
281
+ "cursor-pointer",
282
+ "text-neutral-main",
283
+ "group-has-[p.error]/datepicker:border-danger-main",
284
+ "group-has-[p.error]/datepicker:bg-danger-soft",
285
+ "group-has-[p.error]/datepicker:text-danger-main",
286
+ "group-has-[p.error]/datepicker:hover:bg-danger-soft"
287
+ ],
288
+ input: [
289
+ "bg-transparent",
290
+ "w-full",
291
+ "outline-none",
292
+ "placeholder:text-neutral-main",
293
+ "text-body-foreground",
294
+ "group-has-[p.error]/datepicker:text-danger-main",
295
+ "group-has-[p.error]/datepicker:placeholder:text-danger-main",
296
+ "cursor-pointer"
297
+ ],
298
+ icon: [
299
+ "flex",
300
+ "items-center",
301
+ "select-none",
302
+ "text-body-foreground",
303
+ "group-has-[p.error]/datepicker:text-danger-main"
304
+ ],
305
+ optionsWrapper: [
306
+ "flex",
307
+ "flex-col",
308
+ "border",
309
+ "rounded-md",
310
+ "bg-body-background",
311
+ "shadow-lg",
312
+ "overflow-auto",
313
+ "w-[240px]",
314
+ "select-none",
315
+ "p-[10px]"
316
+ ],
317
+ errorMessage: ["text-danger-main", "text-sm"]
318
+ },
319
+ variants: {
320
+ color: {
321
+ primary: {
322
+ icon: ["text-primary-main"]
323
+ },
324
+ secondary: {
325
+ icon: ["text-secondary-main"]
326
+ }
327
+ },
328
+ size: {
329
+ sm: {
330
+ base: ["text-sm", "gap-[4px]"],
331
+ label: ["text-sm"],
332
+ wrapper: ["gap-[4px]"],
333
+ inputWrapper: ["w-[240px]", "h-[24px]", "rounded-sm", "px-[4px]"],
334
+ input: ["text-sm"],
335
+ icon: ["text-sm"],
336
+ errorMessage: ["text-sm"]
337
+ },
338
+ md: {
339
+ base: ["text-md", "gap-[6px]"],
340
+ label: ["text-md"],
341
+ wrapper: ["gap-[6px]"],
342
+ inputWrapper: ["w-[240px]", "h-[32px]", "rounded-md", "px-[6px]"],
343
+ input: ["text-md"],
344
+ icon: ["text-md"],
345
+ errorMessage: ["text-sm"]
346
+ },
347
+ lg: {
348
+ base: ["text-lg", "gap-[8px]"],
349
+ label: ["text-lg"],
350
+ wrapper: ["gap-[8px]"],
351
+ inputWrapper: ["w-[240px]", "h-[40px]", "rounded-lg", "px-[8px]"],
352
+ input: ["text-lg"],
353
+ icon: ["text-lg"],
354
+ errorMessage: ["text-md"]
355
+ },
356
+ xl: {
357
+ base: ["text-xl", "gap-[10px]"],
358
+ label: ["text-xl"],
359
+ wrapper: ["gap-[10px]"],
360
+ inputWrapper: ["w-[240px]", "h-[50px]", "rounded-lg", "px-[10px]"],
361
+ input: ["text-xl"],
362
+ icon: ["text-xl"],
363
+ errorMessage: ["text-md"]
364
+ }
365
+ },
366
+ full: {
367
+ true: {
368
+ base: ["w-full"],
369
+ wrapper: ["w-full"],
370
+ inputWrapper: ["w-full"]
371
+ }
372
+ },
373
+ disabled: {
374
+ true: {
375
+ base: ["pointer-events-none"],
376
+ label: ["text-neutral-light"],
377
+ inputWrapper: [
378
+ "bg-neutral-soft",
379
+ "border-neutral-light",
380
+ "group-has-[p.error]/datepicker:text-danger-light",
381
+ "group-has-[p.error]/datepicker:bg-danger-soft",
382
+ "group-has-[p.error]/datepicker:border-danger-light",
383
+ "cursor-not-allowed"
384
+ ],
385
+ input: [
386
+ "text-neutral-light",
387
+ "placeholder:text-neutral-light",
388
+ "group-has-[p.error]/datepicker:text-danger-light",
389
+ "group-has-[p.error]/datepicker:placeholder:text-danger-light",
390
+ "cursor-not-allowed"
391
+ ],
392
+ icon: ["text-neutral-light"],
393
+ errorMessage: ["text-danger-light"]
394
+ }
395
+ }
396
+ },
397
+ defaultVariants: {
398
+ color: "primary",
399
+ size: "md",
400
+ full: false,
401
+ disabled: false
402
+ }
403
+ });
404
+
405
+ export {
406
+ datePicker_default,
407
+ datePickerStyle
408
+ };
@@ -7,7 +7,7 @@ import {
7
7
  } from "./chunk-6PNKRBUT.mjs";
8
8
  import {
9
9
  Icon_default
10
- } from "./chunk-33DLD2L6.mjs";
10
+ } from "./chunk-FU4CDBVG.mjs";
11
11
  import {
12
12
  mapPropsVariants
13
13
  } from "./chunk-E3G5QXSH.mjs";
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  Icon_default
4
- } from "./chunk-33DLD2L6.mjs";
4
+ } from "./chunk-FU4CDBVG.mjs";
5
5
  import {
6
6
  tv
7
7
  } from "./chunk-CDXBML6O.mjs";
@@ -4,10 +4,10 @@ import {
4
4
  } from "./chunk-AF4I7ZQS.mjs";
5
5
  import {
6
6
  button_default
7
- } from "./chunk-Q36C7WNH.mjs";
7
+ } from "./chunk-4NVZMJGS.mjs";
8
8
  import {
9
9
  Icon_default
10
- } from "./chunk-33DLD2L6.mjs";
10
+ } from "./chunk-FU4CDBVG.mjs";
11
11
  import {
12
12
  mapPropsVariants
13
13
  } from "./chunk-E3G5QXSH.mjs";
@@ -4,7 +4,7 @@ import {
4
4
  } from "./chunk-Q364C3FI.mjs";
5
5
  import {
6
6
  Icon_default
7
- } from "./chunk-33DLD2L6.mjs";
7
+ } from "./chunk-FU4CDBVG.mjs";
8
8
  import {
9
9
  tv
10
10
  } from "./chunk-CDXBML6O.mjs";
@@ -1,10 +1,10 @@
1
1
  "use client";
2
2
  import {
3
3
  select_default
4
- } from "./chunk-YCLB7ZNK.mjs";
4
+ } from "./chunk-QREBEXKF.mjs";
5
5
  import {
6
6
  Icon_default
7
- } from "./chunk-33DLD2L6.mjs";
7
+ } from "./chunk-FU4CDBVG.mjs";
8
8
  import {
9
9
  mapPropsVariants
10
10
  } from "./chunk-E3G5QXSH.mjs";
@@ -1,13 +1,13 @@
1
1
  "use client";
2
2
  import {
3
3
  Icon_default
4
- } from "./chunk-33DLD2L6.mjs";
4
+ } from "./chunk-FU4CDBVG.mjs";
5
5
  import {
6
6
  mapPropsVariants
7
7
  } from "./chunk-E3G5QXSH.mjs";
8
8
  import {
9
9
  avatar_default
10
- } from "./chunk-EQWU2F5T.mjs";
10
+ } from "./chunk-MLD6EZAE.mjs";
11
11
  import {
12
12
  tv
13
13
  } from "./chunk-CDXBML6O.mjs";
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import {
3
3
  Icon_default
4
- } from "./chunk-33DLD2L6.mjs";
4
+ } from "./chunk-FU4CDBVG.mjs";
5
5
  import {
6
6
  mapPropsVariants
7
7
  } from "./chunk-E3G5QXSH.mjs";
@@ -16,8 +16,8 @@ var BarChartComponent = forwardRef((originalProps, ref) => {
16
16
  const slots = useMemo(() => barChartStyle({ ...variantProps }), [variantProps]);
17
17
  const COLOR_MAP = {
18
18
  primary: "#C7E5FA",
19
- secondary: "#DEC1FA",
20
- warning: "#F9C967"
19
+ secondary: "#92DCB2",
20
+ warning: "#DEC1FA"
21
21
  };
22
22
  const [tickPositions, setTickPositions] = useState([]);
23
23
  const tickRef = useRef([]);
@@ -68,54 +68,64 @@ var BarChartComponent = forwardRef((originalProps, ref) => {
68
68
  }, [data]);
69
69
  return /* @__PURE__ */ jsxs("div", { ref, className: slots.base({ class: classNames == null ? void 0 : classNames.base }), children: [
70
70
  label && /* @__PURE__ */ jsx("p", { className: slots.label({ class: classNames == null ? void 0 : classNames.label }), children: label }),
71
- /* @__PURE__ */ jsx(ResponsiveContainer, { width: "100%", height: "100%", children: /* @__PURE__ */ jsxs(BarChart, { data, margin: { left: -30 }, barSize: 20, barGap: 10, children: [
72
- /* @__PURE__ */ jsx(
73
- CartesianGrid,
74
- {
75
- vertical: true,
76
- horizontal: false,
77
- strokeDasharray: "3 3",
78
- className: "stroke-neutral-light",
79
- verticalPoints: tickPositions
80
- }
81
- ),
82
- /* @__PURE__ */ jsx(
83
- XAxis,
84
- {
85
- dataKey: "name",
86
- axisLine: { stroke: "#DFE2E7", strokeWidth: 1 },
87
- tickLine: false,
88
- tick: CustomTick,
89
- padding: { left: 32, right: 32 }
90
- }
91
- ),
92
- /* @__PURE__ */ jsx(
93
- YAxis,
94
- {
95
- axisLine: { stroke: "#DFE2E7", strokeWidth: 1 },
96
- tickLine: false,
97
- tick: {
98
- fontSize: 12,
99
- fontWeight: 700,
100
- fill: "text-body-foreground",
101
- textAnchor: "middle",
102
- dx: -10
103
- },
104
- ticks: [0, 20, 40, 60, 80, 100],
105
- domain: [-6, 110]
106
- }
107
- ),
108
- /* @__PURE__ */ jsx(Bar, { dataKey: "avg", fill: COLOR_MAP.primary, width: 20, shape: CustomBarShape }),
109
- /* @__PURE__ */ jsx(Bar, { dataKey: "high", fill: COLOR_MAP.secondary, width: 20, shape: CustomBarShape }),
110
- /* @__PURE__ */ jsx(Bar, { dataKey: "low", fill: COLOR_MAP.warning, width: 20, shape: CustomBarShape })
111
- ] }) })
71
+ /* @__PURE__ */ jsx(ResponsiveContainer, { width: "100%", height: "100%", children: /* @__PURE__ */ jsxs(
72
+ BarChart,
73
+ {
74
+ data,
75
+ margin: { left: -30 },
76
+ barSize: 20,
77
+ barGap: 10,
78
+ className: "[&_.recharts-surface]:outline-none [&_.recharts-surface]:focus:outline-none",
79
+ children: [
80
+ /* @__PURE__ */ jsx(
81
+ CartesianGrid,
82
+ {
83
+ vertical: true,
84
+ horizontal: false,
85
+ strokeDasharray: "3 3",
86
+ className: "stroke-neutral-light",
87
+ verticalPoints: tickPositions
88
+ }
89
+ ),
90
+ /* @__PURE__ */ jsx(
91
+ XAxis,
92
+ {
93
+ dataKey: "name",
94
+ axisLine: { stroke: "#DFE2E7", strokeWidth: 1 },
95
+ tickLine: false,
96
+ tick: CustomTick,
97
+ padding: { left: 32, right: 32 }
98
+ }
99
+ ),
100
+ /* @__PURE__ */ jsx(
101
+ YAxis,
102
+ {
103
+ axisLine: { stroke: "#DFE2E7", strokeWidth: 1 },
104
+ tickLine: false,
105
+ tick: {
106
+ fontSize: 12,
107
+ fontWeight: 700,
108
+ fill: "text-body-foreground",
109
+ textAnchor: "middle",
110
+ dx: -10
111
+ },
112
+ ticks: [0, 20, 40, 60, 80, 100],
113
+ domain: [-6, 110]
114
+ }
115
+ ),
116
+ /* @__PURE__ */ jsx(Bar, { dataKey: "avg", fill: COLOR_MAP.primary, width: 20, shape: CustomBarShape }),
117
+ /* @__PURE__ */ jsx(Bar, { dataKey: "high", fill: COLOR_MAP.secondary, width: 20, shape: CustomBarShape }),
118
+ /* @__PURE__ */ jsx(Bar, { dataKey: "low", fill: COLOR_MAP.warning, width: 20, shape: CustomBarShape })
119
+ ]
120
+ }
121
+ ) })
112
122
  ] });
113
123
  });
114
124
  BarChartComponent.displayName = "barChart";
115
125
  var barChart_default = BarChartComponent;
116
126
  var barChartStyle = tv({
117
127
  slots: {
118
- base: ["flex", "flex-col", "gap-[10px]"],
128
+ base: ["flex", "flex-col", "gap-[10px]", "select-none"],
119
129
  label: ["text-md", "font-bold", "text-body-foreground"]
120
130
  },
121
131
  variants: {},