@esic-lab/data-core-ui 0.0.37 → 0.0.38
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/index.d.mts +19 -1
- package/dist/index.d.ts +19 -1
- package/dist/index.js +649 -241
- package/dist/index.mjs +655 -225
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1,3 +1,351 @@
|
|
|
1
|
+
var __create = Object.create;
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __commonJS = (cb, mod) => function __require() {
|
|
8
|
+
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
19
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
20
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
21
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
22
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
23
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
24
|
+
mod
|
|
25
|
+
));
|
|
26
|
+
|
|
27
|
+
// node_modules/dayjs/dayjs.min.js
|
|
28
|
+
var require_dayjs_min = __commonJS({
|
|
29
|
+
"node_modules/dayjs/dayjs.min.js"(exports, module) {
|
|
30
|
+
"use strict";
|
|
31
|
+
!(function(t, e) {
|
|
32
|
+
"object" == typeof exports && "undefined" != typeof module ? module.exports = e() : "function" == typeof define && define.amd ? define(e) : (t = "undefined" != typeof globalThis ? globalThis : t || self).dayjs = e();
|
|
33
|
+
})(exports, (function() {
|
|
34
|
+
"use strict";
|
|
35
|
+
var t = 1e3, e = 6e4, n = 36e5, r = "millisecond", i = "second", s = "minute", u = "hour", a = "day", o = "week", c = "month", f = "quarter", h = "year", d = "date", l = "Invalid Date", $ = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, y = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, M = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(t2) {
|
|
36
|
+
var e2 = ["th", "st", "nd", "rd"], n2 = t2 % 100;
|
|
37
|
+
return "[" + t2 + (e2[(n2 - 20) % 10] || e2[n2] || e2[0]) + "]";
|
|
38
|
+
} }, m = function(t2, e2, n2) {
|
|
39
|
+
var r2 = String(t2);
|
|
40
|
+
return !r2 || r2.length >= e2 ? t2 : "" + Array(e2 + 1 - r2.length).join(n2) + t2;
|
|
41
|
+
}, v = { s: m, z: function(t2) {
|
|
42
|
+
var e2 = -t2.utcOffset(), n2 = Math.abs(e2), r2 = Math.floor(n2 / 60), i2 = n2 % 60;
|
|
43
|
+
return (e2 <= 0 ? "+" : "-") + m(r2, 2, "0") + ":" + m(i2, 2, "0");
|
|
44
|
+
}, m: function t2(e2, n2) {
|
|
45
|
+
if (e2.date() < n2.date()) return -t2(n2, e2);
|
|
46
|
+
var r2 = 12 * (n2.year() - e2.year()) + (n2.month() - e2.month()), i2 = e2.clone().add(r2, c), s2 = n2 - i2 < 0, u2 = e2.clone().add(r2 + (s2 ? -1 : 1), c);
|
|
47
|
+
return +(-(r2 + (n2 - i2) / (s2 ? i2 - u2 : u2 - i2)) || 0);
|
|
48
|
+
}, a: function(t2) {
|
|
49
|
+
return t2 < 0 ? Math.ceil(t2) || 0 : Math.floor(t2);
|
|
50
|
+
}, p: function(t2) {
|
|
51
|
+
return { M: c, y: h, w: o, d: a, D: d, h: u, m: s, s: i, ms: r, Q: f }[t2] || String(t2 || "").toLowerCase().replace(/s$/, "");
|
|
52
|
+
}, u: function(t2) {
|
|
53
|
+
return void 0 === t2;
|
|
54
|
+
} }, g = "en", D = {};
|
|
55
|
+
D[g] = M;
|
|
56
|
+
var p = "$isDayjsObject", S = function(t2) {
|
|
57
|
+
return t2 instanceof _ || !(!t2 || !t2[p]);
|
|
58
|
+
}, w = function t2(e2, n2, r2) {
|
|
59
|
+
var i2;
|
|
60
|
+
if (!e2) return g;
|
|
61
|
+
if ("string" == typeof e2) {
|
|
62
|
+
var s2 = e2.toLowerCase();
|
|
63
|
+
D[s2] && (i2 = s2), n2 && (D[s2] = n2, i2 = s2);
|
|
64
|
+
var u2 = e2.split("-");
|
|
65
|
+
if (!i2 && u2.length > 1) return t2(u2[0]);
|
|
66
|
+
} else {
|
|
67
|
+
var a2 = e2.name;
|
|
68
|
+
D[a2] = e2, i2 = a2;
|
|
69
|
+
}
|
|
70
|
+
return !r2 && i2 && (g = i2), i2 || !r2 && g;
|
|
71
|
+
}, O = function(t2, e2) {
|
|
72
|
+
if (S(t2)) return t2.clone();
|
|
73
|
+
var n2 = "object" == typeof e2 ? e2 : {};
|
|
74
|
+
return n2.date = t2, n2.args = arguments, new _(n2);
|
|
75
|
+
}, b = v;
|
|
76
|
+
b.l = w, b.i = S, b.w = function(t2, e2) {
|
|
77
|
+
return O(t2, { locale: e2.$L, utc: e2.$u, x: e2.$x, $offset: e2.$offset });
|
|
78
|
+
};
|
|
79
|
+
var _ = (function() {
|
|
80
|
+
function M2(t2) {
|
|
81
|
+
this.$L = w(t2.locale, null, true), this.parse(t2), this.$x = this.$x || t2.x || {}, this[p] = true;
|
|
82
|
+
}
|
|
83
|
+
var m2 = M2.prototype;
|
|
84
|
+
return m2.parse = function(t2) {
|
|
85
|
+
this.$d = (function(t3) {
|
|
86
|
+
var e2 = t3.date, n2 = t3.utc;
|
|
87
|
+
if (null === e2) return /* @__PURE__ */ new Date(NaN);
|
|
88
|
+
if (b.u(e2)) return /* @__PURE__ */ new Date();
|
|
89
|
+
if (e2 instanceof Date) return new Date(e2);
|
|
90
|
+
if ("string" == typeof e2 && !/Z$/i.test(e2)) {
|
|
91
|
+
var r2 = e2.match($);
|
|
92
|
+
if (r2) {
|
|
93
|
+
var i2 = r2[2] - 1 || 0, s2 = (r2[7] || "0").substring(0, 3);
|
|
94
|
+
return n2 ? new Date(Date.UTC(r2[1], i2, r2[3] || 1, r2[4] || 0, r2[5] || 0, r2[6] || 0, s2)) : new Date(r2[1], i2, r2[3] || 1, r2[4] || 0, r2[5] || 0, r2[6] || 0, s2);
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
return new Date(e2);
|
|
98
|
+
})(t2), this.init();
|
|
99
|
+
}, m2.init = function() {
|
|
100
|
+
var t2 = this.$d;
|
|
101
|
+
this.$y = t2.getFullYear(), this.$M = t2.getMonth(), this.$D = t2.getDate(), this.$W = t2.getDay(), this.$H = t2.getHours(), this.$m = t2.getMinutes(), this.$s = t2.getSeconds(), this.$ms = t2.getMilliseconds();
|
|
102
|
+
}, m2.$utils = function() {
|
|
103
|
+
return b;
|
|
104
|
+
}, m2.isValid = function() {
|
|
105
|
+
return !(this.$d.toString() === l);
|
|
106
|
+
}, m2.isSame = function(t2, e2) {
|
|
107
|
+
var n2 = O(t2);
|
|
108
|
+
return this.startOf(e2) <= n2 && n2 <= this.endOf(e2);
|
|
109
|
+
}, m2.isAfter = function(t2, e2) {
|
|
110
|
+
return O(t2) < this.startOf(e2);
|
|
111
|
+
}, m2.isBefore = function(t2, e2) {
|
|
112
|
+
return this.endOf(e2) < O(t2);
|
|
113
|
+
}, m2.$g = function(t2, e2, n2) {
|
|
114
|
+
return b.u(t2) ? this[e2] : this.set(n2, t2);
|
|
115
|
+
}, m2.unix = function() {
|
|
116
|
+
return Math.floor(this.valueOf() / 1e3);
|
|
117
|
+
}, m2.valueOf = function() {
|
|
118
|
+
return this.$d.getTime();
|
|
119
|
+
}, m2.startOf = function(t2, e2) {
|
|
120
|
+
var n2 = this, r2 = !!b.u(e2) || e2, f2 = b.p(t2), l2 = function(t3, e3) {
|
|
121
|
+
var i2 = b.w(n2.$u ? Date.UTC(n2.$y, e3, t3) : new Date(n2.$y, e3, t3), n2);
|
|
122
|
+
return r2 ? i2 : i2.endOf(a);
|
|
123
|
+
}, $2 = function(t3, e3) {
|
|
124
|
+
return b.w(n2.toDate()[t3].apply(n2.toDate("s"), (r2 ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(e3)), n2);
|
|
125
|
+
}, y2 = this.$W, M3 = this.$M, m3 = this.$D, v2 = "set" + (this.$u ? "UTC" : "");
|
|
126
|
+
switch (f2) {
|
|
127
|
+
case h:
|
|
128
|
+
return r2 ? l2(1, 0) : l2(31, 11);
|
|
129
|
+
case c:
|
|
130
|
+
return r2 ? l2(1, M3) : l2(0, M3 + 1);
|
|
131
|
+
case o:
|
|
132
|
+
var g2 = this.$locale().weekStart || 0, D2 = (y2 < g2 ? y2 + 7 : y2) - g2;
|
|
133
|
+
return l2(r2 ? m3 - D2 : m3 + (6 - D2), M3);
|
|
134
|
+
case a:
|
|
135
|
+
case d:
|
|
136
|
+
return $2(v2 + "Hours", 0);
|
|
137
|
+
case u:
|
|
138
|
+
return $2(v2 + "Minutes", 1);
|
|
139
|
+
case s:
|
|
140
|
+
return $2(v2 + "Seconds", 2);
|
|
141
|
+
case i:
|
|
142
|
+
return $2(v2 + "Milliseconds", 3);
|
|
143
|
+
default:
|
|
144
|
+
return this.clone();
|
|
145
|
+
}
|
|
146
|
+
}, m2.endOf = function(t2) {
|
|
147
|
+
return this.startOf(t2, false);
|
|
148
|
+
}, m2.$set = function(t2, e2) {
|
|
149
|
+
var n2, o2 = b.p(t2), f2 = "set" + (this.$u ? "UTC" : ""), l2 = (n2 = {}, n2[a] = f2 + "Date", n2[d] = f2 + "Date", n2[c] = f2 + "Month", n2[h] = f2 + "FullYear", n2[u] = f2 + "Hours", n2[s] = f2 + "Minutes", n2[i] = f2 + "Seconds", n2[r] = f2 + "Milliseconds", n2)[o2], $2 = o2 === a ? this.$D + (e2 - this.$W) : e2;
|
|
150
|
+
if (o2 === c || o2 === h) {
|
|
151
|
+
var y2 = this.clone().set(d, 1);
|
|
152
|
+
y2.$d[l2]($2), y2.init(), this.$d = y2.set(d, Math.min(this.$D, y2.daysInMonth())).$d;
|
|
153
|
+
} else l2 && this.$d[l2]($2);
|
|
154
|
+
return this.init(), this;
|
|
155
|
+
}, m2.set = function(t2, e2) {
|
|
156
|
+
return this.clone().$set(t2, e2);
|
|
157
|
+
}, m2.get = function(t2) {
|
|
158
|
+
return this[b.p(t2)]();
|
|
159
|
+
}, m2.add = function(r2, f2) {
|
|
160
|
+
var d2, l2 = this;
|
|
161
|
+
r2 = Number(r2);
|
|
162
|
+
var $2 = b.p(f2), y2 = function(t2) {
|
|
163
|
+
var e2 = O(l2);
|
|
164
|
+
return b.w(e2.date(e2.date() + Math.round(t2 * r2)), l2);
|
|
165
|
+
};
|
|
166
|
+
if ($2 === c) return this.set(c, this.$M + r2);
|
|
167
|
+
if ($2 === h) return this.set(h, this.$y + r2);
|
|
168
|
+
if ($2 === a) return y2(1);
|
|
169
|
+
if ($2 === o) return y2(7);
|
|
170
|
+
var M3 = (d2 = {}, d2[s] = e, d2[u] = n, d2[i] = t, d2)[$2] || 1, m3 = this.$d.getTime() + r2 * M3;
|
|
171
|
+
return b.w(m3, this);
|
|
172
|
+
}, m2.subtract = function(t2, e2) {
|
|
173
|
+
return this.add(-1 * t2, e2);
|
|
174
|
+
}, m2.format = function(t2) {
|
|
175
|
+
var e2 = this, n2 = this.$locale();
|
|
176
|
+
if (!this.isValid()) return n2.invalidDate || l;
|
|
177
|
+
var r2 = t2 || "YYYY-MM-DDTHH:mm:ssZ", i2 = b.z(this), s2 = this.$H, u2 = this.$m, a2 = this.$M, o2 = n2.weekdays, c2 = n2.months, f2 = n2.meridiem, h2 = function(t3, n3, i3, s3) {
|
|
178
|
+
return t3 && (t3[n3] || t3(e2, r2)) || i3[n3].slice(0, s3);
|
|
179
|
+
}, d2 = function(t3) {
|
|
180
|
+
return b.s(s2 % 12 || 12, t3, "0");
|
|
181
|
+
}, $2 = f2 || function(t3, e3, n3) {
|
|
182
|
+
var r3 = t3 < 12 ? "AM" : "PM";
|
|
183
|
+
return n3 ? r3.toLowerCase() : r3;
|
|
184
|
+
};
|
|
185
|
+
return r2.replace(y, (function(t3, r3) {
|
|
186
|
+
return r3 || (function(t4) {
|
|
187
|
+
switch (t4) {
|
|
188
|
+
case "YY":
|
|
189
|
+
return String(e2.$y).slice(-2);
|
|
190
|
+
case "YYYY":
|
|
191
|
+
return b.s(e2.$y, 4, "0");
|
|
192
|
+
case "M":
|
|
193
|
+
return a2 + 1;
|
|
194
|
+
case "MM":
|
|
195
|
+
return b.s(a2 + 1, 2, "0");
|
|
196
|
+
case "MMM":
|
|
197
|
+
return h2(n2.monthsShort, a2, c2, 3);
|
|
198
|
+
case "MMMM":
|
|
199
|
+
return h2(c2, a2);
|
|
200
|
+
case "D":
|
|
201
|
+
return e2.$D;
|
|
202
|
+
case "DD":
|
|
203
|
+
return b.s(e2.$D, 2, "0");
|
|
204
|
+
case "d":
|
|
205
|
+
return String(e2.$W);
|
|
206
|
+
case "dd":
|
|
207
|
+
return h2(n2.weekdaysMin, e2.$W, o2, 2);
|
|
208
|
+
case "ddd":
|
|
209
|
+
return h2(n2.weekdaysShort, e2.$W, o2, 3);
|
|
210
|
+
case "dddd":
|
|
211
|
+
return o2[e2.$W];
|
|
212
|
+
case "H":
|
|
213
|
+
return String(s2);
|
|
214
|
+
case "HH":
|
|
215
|
+
return b.s(s2, 2, "0");
|
|
216
|
+
case "h":
|
|
217
|
+
return d2(1);
|
|
218
|
+
case "hh":
|
|
219
|
+
return d2(2);
|
|
220
|
+
case "a":
|
|
221
|
+
return $2(s2, u2, true);
|
|
222
|
+
case "A":
|
|
223
|
+
return $2(s2, u2, false);
|
|
224
|
+
case "m":
|
|
225
|
+
return String(u2);
|
|
226
|
+
case "mm":
|
|
227
|
+
return b.s(u2, 2, "0");
|
|
228
|
+
case "s":
|
|
229
|
+
return String(e2.$s);
|
|
230
|
+
case "ss":
|
|
231
|
+
return b.s(e2.$s, 2, "0");
|
|
232
|
+
case "SSS":
|
|
233
|
+
return b.s(e2.$ms, 3, "0");
|
|
234
|
+
case "Z":
|
|
235
|
+
return i2;
|
|
236
|
+
}
|
|
237
|
+
return null;
|
|
238
|
+
})(t3) || i2.replace(":", "");
|
|
239
|
+
}));
|
|
240
|
+
}, m2.utcOffset = function() {
|
|
241
|
+
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
|
242
|
+
}, m2.diff = function(r2, d2, l2) {
|
|
243
|
+
var $2, y2 = this, M3 = b.p(d2), m3 = O(r2), v2 = (m3.utcOffset() - this.utcOffset()) * e, g2 = this - m3, D2 = function() {
|
|
244
|
+
return b.m(y2, m3);
|
|
245
|
+
};
|
|
246
|
+
switch (M3) {
|
|
247
|
+
case h:
|
|
248
|
+
$2 = D2() / 12;
|
|
249
|
+
break;
|
|
250
|
+
case c:
|
|
251
|
+
$2 = D2();
|
|
252
|
+
break;
|
|
253
|
+
case f:
|
|
254
|
+
$2 = D2() / 3;
|
|
255
|
+
break;
|
|
256
|
+
case o:
|
|
257
|
+
$2 = (g2 - v2) / 6048e5;
|
|
258
|
+
break;
|
|
259
|
+
case a:
|
|
260
|
+
$2 = (g2 - v2) / 864e5;
|
|
261
|
+
break;
|
|
262
|
+
case u:
|
|
263
|
+
$2 = g2 / n;
|
|
264
|
+
break;
|
|
265
|
+
case s:
|
|
266
|
+
$2 = g2 / e;
|
|
267
|
+
break;
|
|
268
|
+
case i:
|
|
269
|
+
$2 = g2 / t;
|
|
270
|
+
break;
|
|
271
|
+
default:
|
|
272
|
+
$2 = g2;
|
|
273
|
+
}
|
|
274
|
+
return l2 ? $2 : b.a($2);
|
|
275
|
+
}, m2.daysInMonth = function() {
|
|
276
|
+
return this.endOf(c).$D;
|
|
277
|
+
}, m2.$locale = function() {
|
|
278
|
+
return D[this.$L];
|
|
279
|
+
}, m2.locale = function(t2, e2) {
|
|
280
|
+
if (!t2) return this.$L;
|
|
281
|
+
var n2 = this.clone(), r2 = w(t2, e2, true);
|
|
282
|
+
return r2 && (n2.$L = r2), n2;
|
|
283
|
+
}, m2.clone = function() {
|
|
284
|
+
return b.w(this.$d, this);
|
|
285
|
+
}, m2.toDate = function() {
|
|
286
|
+
return new Date(this.valueOf());
|
|
287
|
+
}, m2.toJSON = function() {
|
|
288
|
+
return this.isValid() ? this.toISOString() : null;
|
|
289
|
+
}, m2.toISOString = function() {
|
|
290
|
+
return this.$d.toISOString();
|
|
291
|
+
}, m2.toString = function() {
|
|
292
|
+
return this.$d.toUTCString();
|
|
293
|
+
}, M2;
|
|
294
|
+
})(), k = _.prototype;
|
|
295
|
+
return O.prototype = k, [["$ms", r], ["$s", i], ["$m", s], ["$H", u], ["$W", a], ["$M", c], ["$y", h], ["$D", d]].forEach((function(t2) {
|
|
296
|
+
k[t2[1]] = function(e2) {
|
|
297
|
+
return this.$g(e2, t2[0], t2[1]);
|
|
298
|
+
};
|
|
299
|
+
})), O.extend = function(t2, e2) {
|
|
300
|
+
return t2.$i || (t2(e2, _, O), t2.$i = true), O;
|
|
301
|
+
}, O.locale = w, O.isDayjs = S, O.unix = function(t2) {
|
|
302
|
+
return O(1e3 * t2);
|
|
303
|
+
}, O.en = D[g], O.Ls = D, O.p = {}, O;
|
|
304
|
+
}));
|
|
305
|
+
}
|
|
306
|
+
});
|
|
307
|
+
|
|
308
|
+
// node_modules/dayjs/locale/th.js
|
|
309
|
+
var require_th = __commonJS({
|
|
310
|
+
"node_modules/dayjs/locale/th.js"(exports, module) {
|
|
311
|
+
"use strict";
|
|
312
|
+
!(function(_, e) {
|
|
313
|
+
"object" == typeof exports && "undefined" != typeof module ? module.exports = e(require_dayjs_min()) : "function" == typeof define && define.amd ? define(["dayjs"], e) : (_ = "undefined" != typeof globalThis ? globalThis : _ || self).dayjs_locale_th = e(_.dayjs);
|
|
314
|
+
})(exports, (function(_) {
|
|
315
|
+
"use strict";
|
|
316
|
+
function e(_2) {
|
|
317
|
+
return _2 && "object" == typeof _2 && "default" in _2 ? _2 : { default: _2 };
|
|
318
|
+
}
|
|
319
|
+
var t = e(_), d = { name: "th", weekdays: "\u0E2D\u0E32\u0E17\u0E34\u0E15\u0E22\u0E4C_\u0E08\u0E31\u0E19\u0E17\u0E23\u0E4C_\u0E2D\u0E31\u0E07\u0E04\u0E32\u0E23_\u0E1E\u0E38\u0E18_\u0E1E\u0E24\u0E2B\u0E31\u0E2A\u0E1A\u0E14\u0E35_\u0E28\u0E38\u0E01\u0E23\u0E4C_\u0E40\u0E2A\u0E32\u0E23\u0E4C".split("_"), weekdaysShort: "\u0E2D\u0E32\u0E17\u0E34\u0E15\u0E22\u0E4C_\u0E08\u0E31\u0E19\u0E17\u0E23\u0E4C_\u0E2D\u0E31\u0E07\u0E04\u0E32\u0E23_\u0E1E\u0E38\u0E18_\u0E1E\u0E24\u0E2B\u0E31\u0E2A_\u0E28\u0E38\u0E01\u0E23\u0E4C_\u0E40\u0E2A\u0E32\u0E23\u0E4C".split("_"), weekdaysMin: "\u0E2D\u0E32._\u0E08._\u0E2D._\u0E1E._\u0E1E\u0E24._\u0E28._\u0E2A.".split("_"), months: "\u0E21\u0E01\u0E23\u0E32\u0E04\u0E21_\u0E01\u0E38\u0E21\u0E20\u0E32\u0E1E\u0E31\u0E19\u0E18\u0E4C_\u0E21\u0E35\u0E19\u0E32\u0E04\u0E21_\u0E40\u0E21\u0E29\u0E32\u0E22\u0E19_\u0E1E\u0E24\u0E29\u0E20\u0E32\u0E04\u0E21_\u0E21\u0E34\u0E16\u0E38\u0E19\u0E32\u0E22\u0E19_\u0E01\u0E23\u0E01\u0E0E\u0E32\u0E04\u0E21_\u0E2A\u0E34\u0E07\u0E2B\u0E32\u0E04\u0E21_\u0E01\u0E31\u0E19\u0E22\u0E32\u0E22\u0E19_\u0E15\u0E38\u0E25\u0E32\u0E04\u0E21_\u0E1E\u0E24\u0E28\u0E08\u0E34\u0E01\u0E32\u0E22\u0E19_\u0E18\u0E31\u0E19\u0E27\u0E32\u0E04\u0E21".split("_"), monthsShort: "\u0E21.\u0E04._\u0E01.\u0E1E._\u0E21\u0E35.\u0E04._\u0E40\u0E21.\u0E22._\u0E1E.\u0E04._\u0E21\u0E34.\u0E22._\u0E01.\u0E04._\u0E2A.\u0E04._\u0E01.\u0E22._\u0E15.\u0E04._\u0E1E.\u0E22._\u0E18.\u0E04.".split("_"), formats: { LT: "H:mm", LTS: "H:mm:ss", L: "DD/MM/YYYY", LL: "D MMMM YYYY", LLL: "D MMMM YYYY \u0E40\u0E27\u0E25\u0E32 H:mm", LLLL: "\u0E27\u0E31\u0E19dddd\u0E17\u0E35\u0E48 D MMMM YYYY \u0E40\u0E27\u0E25\u0E32 H:mm" }, relativeTime: { future: "\u0E2D\u0E35\u0E01 %s", past: "%s\u0E17\u0E35\u0E48\u0E41\u0E25\u0E49\u0E27", s: "\u0E44\u0E21\u0E48\u0E01\u0E35\u0E48\u0E27\u0E34\u0E19\u0E32\u0E17\u0E35", m: "1 \u0E19\u0E32\u0E17\u0E35", mm: "%d \u0E19\u0E32\u0E17\u0E35", h: "1 \u0E0A\u0E31\u0E48\u0E27\u0E42\u0E21\u0E07", hh: "%d \u0E0A\u0E31\u0E48\u0E27\u0E42\u0E21\u0E07", d: "1 \u0E27\u0E31\u0E19", dd: "%d \u0E27\u0E31\u0E19", M: "1 \u0E40\u0E14\u0E37\u0E2D\u0E19", MM: "%d \u0E40\u0E14\u0E37\u0E2D\u0E19", y: "1 \u0E1B\u0E35", yy: "%d \u0E1B\u0E35" }, ordinal: function(_2) {
|
|
320
|
+
return _2 + ".";
|
|
321
|
+
} };
|
|
322
|
+
return t.default.locale(d, null, true), d;
|
|
323
|
+
}));
|
|
324
|
+
}
|
|
325
|
+
});
|
|
326
|
+
|
|
327
|
+
// node_modules/dayjs/plugin/buddhistEra.js
|
|
328
|
+
var require_buddhistEra = __commonJS({
|
|
329
|
+
"node_modules/dayjs/plugin/buddhistEra.js"(exports, module) {
|
|
330
|
+
"use strict";
|
|
331
|
+
!(function(t, e) {
|
|
332
|
+
"object" == typeof exports && "undefined" != typeof module ? module.exports = e() : "function" == typeof define && define.amd ? define(e) : (t = "undefined" != typeof globalThis ? globalThis : t || self).dayjs_plugin_buddhistEra = e();
|
|
333
|
+
})(exports, (function() {
|
|
334
|
+
"use strict";
|
|
335
|
+
return function(t, e) {
|
|
336
|
+
var n = e.prototype, i = n.format;
|
|
337
|
+
n.format = function(t2) {
|
|
338
|
+
var e2 = this, n2 = (t2 || "YYYY-MM-DDTHH:mm:ssZ").replace(/(\[[^\]]+])|BBBB|BB/g, (function(t3, n3) {
|
|
339
|
+
var i2, o = String(e2.$y + 543), f = "BB" === t3 ? [o.slice(-2), 2] : [o, 4];
|
|
340
|
+
return n3 || (i2 = e2.$utils()).s.apply(i2, f.concat(["0"]));
|
|
341
|
+
}));
|
|
342
|
+
return i.bind(this)(n2);
|
|
343
|
+
};
|
|
344
|
+
};
|
|
345
|
+
}));
|
|
346
|
+
}
|
|
347
|
+
});
|
|
348
|
+
|
|
1
349
|
// src/Button/PrimaryButton/PrimaryButton.tsx
|
|
2
350
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
351
|
function PrimaryButton({
|
|
@@ -879,24 +1227,48 @@ function InputFieldNumber({
|
|
|
879
1227
|
);
|
|
880
1228
|
}
|
|
881
1229
|
|
|
882
|
-
// src/
|
|
883
|
-
|
|
1230
|
+
// src/DatePicker/DatePickerBasic/DatePickerBasic.tsx
|
|
1231
|
+
var import_dayjs = __toESM(require_dayjs_min());
|
|
1232
|
+
var import_th2 = __toESM(require_th());
|
|
1233
|
+
var import_buddhistEra = __toESM(require_buddhistEra());
|
|
1234
|
+
import { ConfigProvider as ConfigProvider5, DatePicker } from "antd";
|
|
1235
|
+
import th from "antd/es/date-picker/locale/th_TH.js";
|
|
1236
|
+
import thTH from "antd/locale/th_TH.js";
|
|
1237
|
+
import { th as thFns } from "date-fns/locale";
|
|
1238
|
+
import { format } from "date-fns";
|
|
884
1239
|
import { jsx as jsx23, jsxs as jsxs19 } from "react/jsx-runtime";
|
|
885
|
-
|
|
1240
|
+
import_dayjs.default.extend(import_buddhistEra.default);
|
|
1241
|
+
function DatePickerBasic({
|
|
886
1242
|
value,
|
|
887
1243
|
onChange,
|
|
888
1244
|
required,
|
|
889
1245
|
label,
|
|
890
1246
|
error,
|
|
1247
|
+
placeholder = "\u0E01\u0E23\u0E38\u0E13\u0E32\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48",
|
|
891
1248
|
disabled,
|
|
892
|
-
|
|
893
|
-
|
|
1249
|
+
defaultValue,
|
|
1250
|
+
minDate,
|
|
1251
|
+
maxDate,
|
|
1252
|
+
disabledDate,
|
|
894
1253
|
className,
|
|
895
|
-
|
|
1254
|
+
size
|
|
896
1255
|
}) {
|
|
1256
|
+
const dateFormat = "DD/MM/YYYY";
|
|
1257
|
+
import_dayjs.default.locale("th_TH");
|
|
1258
|
+
const buddhistLocale = {
|
|
1259
|
+
...th,
|
|
1260
|
+
lang: {
|
|
1261
|
+
...th.lang,
|
|
1262
|
+
fieldDateFormat: "BBBB-MM-DD",
|
|
1263
|
+
fieldDateTimeFormat: "BBBB-MM-DD HH:mm:ss",
|
|
1264
|
+
yearFormat: "BBBB",
|
|
1265
|
+
cellYearFormat: "BBBB"
|
|
1266
|
+
}
|
|
1267
|
+
};
|
|
897
1268
|
return /* @__PURE__ */ jsx23(
|
|
898
1269
|
ConfigProvider5,
|
|
899
1270
|
{
|
|
1271
|
+
locale: thTH,
|
|
900
1272
|
theme: {
|
|
901
1273
|
token: {
|
|
902
1274
|
fontFamily: "Kanit",
|
|
@@ -910,6 +1282,63 @@ function ColorPickerBasic({
|
|
|
910
1282
|
required && /* @__PURE__ */ jsx23("span", { className: "text-red-500", children: "*" })
|
|
911
1283
|
] }),
|
|
912
1284
|
/* @__PURE__ */ jsx23(
|
|
1285
|
+
DatePicker,
|
|
1286
|
+
{
|
|
1287
|
+
className: `body-1 w-full ${className ?? ""}`,
|
|
1288
|
+
value,
|
|
1289
|
+
placeholder,
|
|
1290
|
+
onChange,
|
|
1291
|
+
allowClear: true,
|
|
1292
|
+
disabled,
|
|
1293
|
+
format: (date) => date ? format(date.toDate(), "dd/MM/yyyy", { locale: thFns }).replace(
|
|
1294
|
+
/\d{4}$/,
|
|
1295
|
+
(y) => String(parseInt(y) + 543)
|
|
1296
|
+
) : "",
|
|
1297
|
+
defaultValue,
|
|
1298
|
+
disabledDate: (d) => disabledDate ? disabledDate(d.toDate()) : false,
|
|
1299
|
+
minDate: minDate ? (0, import_dayjs.default)(minDate) : void 0,
|
|
1300
|
+
maxDate: maxDate ? (0, import_dayjs.default)(maxDate) : void 0,
|
|
1301
|
+
size,
|
|
1302
|
+
locale: buddhistLocale
|
|
1303
|
+
}
|
|
1304
|
+
),
|
|
1305
|
+
error && /* @__PURE__ */ jsx23("p", { className: "text-red-500 caption-1", children: error })
|
|
1306
|
+
] })
|
|
1307
|
+
}
|
|
1308
|
+
);
|
|
1309
|
+
}
|
|
1310
|
+
|
|
1311
|
+
// src/ColorPicker/ColorPickerBasic/ColorPicker.tsx
|
|
1312
|
+
import { ConfigProvider as ConfigProvider6, ColorPicker } from "antd";
|
|
1313
|
+
import { jsx as jsx24, jsxs as jsxs20 } from "react/jsx-runtime";
|
|
1314
|
+
function ColorPickerBasic({
|
|
1315
|
+
value,
|
|
1316
|
+
onChange,
|
|
1317
|
+
required,
|
|
1318
|
+
label,
|
|
1319
|
+
error,
|
|
1320
|
+
disabled,
|
|
1321
|
+
allowClear,
|
|
1322
|
+
defaultFormat,
|
|
1323
|
+
className,
|
|
1324
|
+
placeholder = "\u0E01\u0E23\u0E38\u0E13\u0E32\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E2A\u0E35"
|
|
1325
|
+
}) {
|
|
1326
|
+
return /* @__PURE__ */ jsx24(
|
|
1327
|
+
ConfigProvider6,
|
|
1328
|
+
{
|
|
1329
|
+
theme: {
|
|
1330
|
+
token: {
|
|
1331
|
+
fontFamily: "Kanit",
|
|
1332
|
+
fontSize: 16
|
|
1333
|
+
}
|
|
1334
|
+
},
|
|
1335
|
+
children: /* @__PURE__ */ jsxs20("div", { className: "container-input", children: [
|
|
1336
|
+
/* @__PURE__ */ jsxs20("div", { children: [
|
|
1337
|
+
/* @__PURE__ */ jsx24("span", { className: "body-1", children: label }),
|
|
1338
|
+
" ",
|
|
1339
|
+
required && /* @__PURE__ */ jsx24("span", { className: "text-red-500", children: "*" })
|
|
1340
|
+
] }),
|
|
1341
|
+
/* @__PURE__ */ jsx24(
|
|
913
1342
|
ColorPicker,
|
|
914
1343
|
{
|
|
915
1344
|
defaultFormat,
|
|
@@ -921,9 +1350,9 @@ function ColorPickerBasic({
|
|
|
921
1350
|
showText: (color) => {
|
|
922
1351
|
const hex = color.toHexString();
|
|
923
1352
|
if (!value) {
|
|
924
|
-
return /* @__PURE__ */
|
|
1353
|
+
return /* @__PURE__ */ jsx24("span", { children: placeholder });
|
|
925
1354
|
}
|
|
926
|
-
return /* @__PURE__ */
|
|
1355
|
+
return /* @__PURE__ */ jsxs20("span", { children: [
|
|
927
1356
|
"(",
|
|
928
1357
|
hex,
|
|
929
1358
|
")"
|
|
@@ -932,14 +1361,14 @@ function ColorPickerBasic({
|
|
|
932
1361
|
disabled
|
|
933
1362
|
}
|
|
934
1363
|
),
|
|
935
|
-
error && /* @__PURE__ */
|
|
1364
|
+
error && /* @__PURE__ */ jsx24("p", { className: "text-red-500 caption-1", children: error })
|
|
936
1365
|
] })
|
|
937
1366
|
}
|
|
938
1367
|
);
|
|
939
1368
|
}
|
|
940
1369
|
|
|
941
1370
|
// src/ColorPicker/ColorPalettePickerBasic/ColorPalettePickerBasic.tsx
|
|
942
|
-
import { ConfigProvider as
|
|
1371
|
+
import { ConfigProvider as ConfigProvider7, ColorPicker as ColorPicker2, theme } from "antd";
|
|
943
1372
|
|
|
944
1373
|
// node_modules/@babel/runtime/helpers/esm/typeof.js
|
|
945
1374
|
function _typeof(o) {
|
|
@@ -1641,7 +2070,7 @@ var greyDark = ["#151515", "#1f1f1f", "#2d2d2d", "#393939", "#494949", "#5a5a5a"
|
|
|
1641
2070
|
greyDark.primary = greyDark[5];
|
|
1642
2071
|
|
|
1643
2072
|
// src/ColorPicker/ColorPalettePickerBasic/ColorPalettePickerBasic.tsx
|
|
1644
|
-
import { jsx as
|
|
2073
|
+
import { jsx as jsx25, jsxs as jsxs21 } from "react/jsx-runtime";
|
|
1645
2074
|
function genPresets(presets = presetPalettes) {
|
|
1646
2075
|
return Object.entries(presets).map(([label, colors]) => ({
|
|
1647
2076
|
label,
|
|
@@ -1668,8 +2097,8 @@ function ColorPalettePickerBasic({
|
|
|
1668
2097
|
red,
|
|
1669
2098
|
green
|
|
1670
2099
|
});
|
|
1671
|
-
return /* @__PURE__ */
|
|
1672
|
-
|
|
2100
|
+
return /* @__PURE__ */ jsx25(
|
|
2101
|
+
ConfigProvider7,
|
|
1673
2102
|
{
|
|
1674
2103
|
theme: {
|
|
1675
2104
|
token: {
|
|
@@ -1677,13 +2106,13 @@ function ColorPalettePickerBasic({
|
|
|
1677
2106
|
fontSize: 16
|
|
1678
2107
|
}
|
|
1679
2108
|
},
|
|
1680
|
-
children: /* @__PURE__ */
|
|
1681
|
-
/* @__PURE__ */
|
|
1682
|
-
/* @__PURE__ */
|
|
2109
|
+
children: /* @__PURE__ */ jsxs21("div", { className: "container-input", children: [
|
|
2110
|
+
/* @__PURE__ */ jsxs21("div", { children: [
|
|
2111
|
+
/* @__PURE__ */ jsx25("span", { className: "body-1", children: label }),
|
|
1683
2112
|
" ",
|
|
1684
|
-
required && /* @__PURE__ */
|
|
2113
|
+
required && /* @__PURE__ */ jsx25("span", { className: "text-red-500", children: "*" })
|
|
1685
2114
|
] }),
|
|
1686
|
-
/* @__PURE__ */
|
|
2115
|
+
/* @__PURE__ */ jsx25(
|
|
1687
2116
|
ColorPicker2,
|
|
1688
2117
|
{
|
|
1689
2118
|
defaultFormat,
|
|
@@ -1696,9 +2125,9 @@ function ColorPalettePickerBasic({
|
|
|
1696
2125
|
showText: (color) => {
|
|
1697
2126
|
const hex = color.toHexString();
|
|
1698
2127
|
if (!value) {
|
|
1699
|
-
return /* @__PURE__ */
|
|
2128
|
+
return /* @__PURE__ */ jsx25("span", { children: placeholder });
|
|
1700
2129
|
}
|
|
1701
|
-
return /* @__PURE__ */
|
|
2130
|
+
return /* @__PURE__ */ jsxs21("span", { children: [
|
|
1702
2131
|
"(",
|
|
1703
2132
|
hex,
|
|
1704
2133
|
")"
|
|
@@ -1708,15 +2137,15 @@ function ColorPalettePickerBasic({
|
|
|
1708
2137
|
onClear
|
|
1709
2138
|
}
|
|
1710
2139
|
),
|
|
1711
|
-
error && /* @__PURE__ */
|
|
2140
|
+
error && /* @__PURE__ */ jsx25("p", { className: "text-red-500 caption-1", children: error })
|
|
1712
2141
|
] })
|
|
1713
2142
|
}
|
|
1714
2143
|
);
|
|
1715
2144
|
}
|
|
1716
2145
|
|
|
1717
2146
|
// src/Select/SelectField/SelectField.tsx
|
|
1718
|
-
import { Select, ConfigProvider as
|
|
1719
|
-
import { jsx as
|
|
2147
|
+
import { Select, ConfigProvider as ConfigProvider8 } from "antd";
|
|
2148
|
+
import { jsx as jsx26, jsxs as jsxs22 } from "react/jsx-runtime";
|
|
1720
2149
|
function SelectField({
|
|
1721
2150
|
value,
|
|
1722
2151
|
onChange,
|
|
@@ -1734,8 +2163,8 @@ function SelectField({
|
|
|
1734
2163
|
className,
|
|
1735
2164
|
onClear
|
|
1736
2165
|
}) {
|
|
1737
|
-
return /* @__PURE__ */
|
|
1738
|
-
|
|
2166
|
+
return /* @__PURE__ */ jsx26(
|
|
2167
|
+
ConfigProvider8,
|
|
1739
2168
|
{
|
|
1740
2169
|
theme: {
|
|
1741
2170
|
token: {
|
|
@@ -1743,13 +2172,13 @@ function SelectField({
|
|
|
1743
2172
|
fontSize: 16
|
|
1744
2173
|
}
|
|
1745
2174
|
},
|
|
1746
|
-
children: /* @__PURE__ */
|
|
1747
|
-
/* @__PURE__ */
|
|
1748
|
-
/* @__PURE__ */
|
|
2175
|
+
children: /* @__PURE__ */ jsxs22("div", { className: "container-input", children: [
|
|
2176
|
+
/* @__PURE__ */ jsxs22("div", { children: [
|
|
2177
|
+
/* @__PURE__ */ jsx26("span", { className: "body-1", children: label }),
|
|
1749
2178
|
" ",
|
|
1750
|
-
required && /* @__PURE__ */
|
|
2179
|
+
required && /* @__PURE__ */ jsx26("span", { className: "text-red-500", children: "*" })
|
|
1751
2180
|
] }),
|
|
1752
|
-
/* @__PURE__ */
|
|
2181
|
+
/* @__PURE__ */ jsx26(
|
|
1753
2182
|
Select,
|
|
1754
2183
|
{
|
|
1755
2184
|
showSearch: true,
|
|
@@ -1764,7 +2193,7 @@ function SelectField({
|
|
|
1764
2193
|
options,
|
|
1765
2194
|
mode,
|
|
1766
2195
|
onSearch: handleSearch,
|
|
1767
|
-
prefix: prefix ? /* @__PURE__ */
|
|
2196
|
+
prefix: prefix ? /* @__PURE__ */ jsx26(
|
|
1768
2197
|
"span",
|
|
1769
2198
|
{
|
|
1770
2199
|
style: {
|
|
@@ -1781,15 +2210,15 @@ function SelectField({
|
|
|
1781
2210
|
onClear
|
|
1782
2211
|
}
|
|
1783
2212
|
),
|
|
1784
|
-
error && /* @__PURE__ */
|
|
2213
|
+
error && /* @__PURE__ */ jsx26("p", { className: "text-red-500 caption-1", children: error })
|
|
1785
2214
|
] })
|
|
1786
2215
|
}
|
|
1787
2216
|
);
|
|
1788
2217
|
}
|
|
1789
2218
|
|
|
1790
2219
|
// src/Select/SelectFieldGroup/SelectFieldGroup.tsx
|
|
1791
|
-
import { Select as Select2, ConfigProvider as
|
|
1792
|
-
import { jsx as
|
|
2220
|
+
import { Select as Select2, ConfigProvider as ConfigProvider9 } from "antd";
|
|
2221
|
+
import { jsx as jsx27, jsxs as jsxs23 } from "react/jsx-runtime";
|
|
1793
2222
|
function SelectFieldGroup({
|
|
1794
2223
|
value,
|
|
1795
2224
|
onChange,
|
|
@@ -1806,21 +2235,21 @@ function SelectFieldGroup({
|
|
|
1806
2235
|
handleSearch,
|
|
1807
2236
|
className
|
|
1808
2237
|
}) {
|
|
1809
|
-
return /* @__PURE__ */
|
|
1810
|
-
|
|
2238
|
+
return /* @__PURE__ */ jsx27(
|
|
2239
|
+
ConfigProvider9,
|
|
1811
2240
|
{
|
|
1812
2241
|
theme: {
|
|
1813
2242
|
token: {
|
|
1814
2243
|
fontFamily: "Kanit"
|
|
1815
2244
|
}
|
|
1816
2245
|
},
|
|
1817
|
-
children: /* @__PURE__ */
|
|
1818
|
-
/* @__PURE__ */
|
|
1819
|
-
/* @__PURE__ */
|
|
2246
|
+
children: /* @__PURE__ */ jsxs23("div", { className: "container-input", children: [
|
|
2247
|
+
/* @__PURE__ */ jsxs23("div", { children: [
|
|
2248
|
+
/* @__PURE__ */ jsx27("span", { className: "body-1", children: label }),
|
|
1820
2249
|
" ",
|
|
1821
|
-
required && /* @__PURE__ */
|
|
2250
|
+
required && /* @__PURE__ */ jsx27("span", { className: "text-red-500", children: "*" })
|
|
1822
2251
|
] }),
|
|
1823
|
-
/* @__PURE__ */
|
|
2252
|
+
/* @__PURE__ */ jsx27(
|
|
1824
2253
|
Select2,
|
|
1825
2254
|
{
|
|
1826
2255
|
showSearch: true,
|
|
@@ -1835,7 +2264,7 @@ function SelectFieldGroup({
|
|
|
1835
2264
|
options,
|
|
1836
2265
|
mode,
|
|
1837
2266
|
onSearch: handleSearch,
|
|
1838
|
-
prefix: prefix ? /* @__PURE__ */
|
|
2267
|
+
prefix: prefix ? /* @__PURE__ */ jsx27(
|
|
1839
2268
|
"span",
|
|
1840
2269
|
{
|
|
1841
2270
|
style: {
|
|
@@ -1851,14 +2280,14 @@ function SelectFieldGroup({
|
|
|
1851
2280
|
allowClear: true
|
|
1852
2281
|
}
|
|
1853
2282
|
),
|
|
1854
|
-
error && /* @__PURE__ */
|
|
2283
|
+
error && /* @__PURE__ */ jsx27("p", { className: "text-red-500 caption-1", children: error })
|
|
1855
2284
|
] })
|
|
1856
2285
|
}
|
|
1857
2286
|
);
|
|
1858
2287
|
}
|
|
1859
2288
|
|
|
1860
2289
|
// src/Select/SelectFieldStatus/SelectFieldStatus.tsx
|
|
1861
|
-
import { Select as Select3, ConfigProvider as
|
|
2290
|
+
import { Select as Select3, ConfigProvider as ConfigProvider10 } from "antd";
|
|
1862
2291
|
|
|
1863
2292
|
// src/Select/SelectFieldStatus/StatusMockup.ts
|
|
1864
2293
|
var status = [
|
|
@@ -1871,7 +2300,7 @@ var status = [
|
|
|
1871
2300
|
|
|
1872
2301
|
// src/Select/SelectFieldStatus/SelectFieldStatus.tsx
|
|
1873
2302
|
import { DownOutlined } from "@ant-design/icons";
|
|
1874
|
-
import { jsx as
|
|
2303
|
+
import { jsx as jsx28, jsxs as jsxs24 } from "react/jsx-runtime";
|
|
1875
2304
|
function SelectFieldStatus({
|
|
1876
2305
|
value,
|
|
1877
2306
|
onChange,
|
|
@@ -1884,8 +2313,8 @@ function SelectFieldStatus({
|
|
|
1884
2313
|
className
|
|
1885
2314
|
}) {
|
|
1886
2315
|
const selectedItem = status.find((s) => s.value === value);
|
|
1887
|
-
return /* @__PURE__ */
|
|
1888
|
-
|
|
2316
|
+
return /* @__PURE__ */ jsx28(
|
|
2317
|
+
ConfigProvider10,
|
|
1889
2318
|
{
|
|
1890
2319
|
theme: {
|
|
1891
2320
|
components: {
|
|
@@ -1900,17 +2329,17 @@ function SelectFieldStatus({
|
|
|
1900
2329
|
fontFamily: "Kanit"
|
|
1901
2330
|
}
|
|
1902
2331
|
},
|
|
1903
|
-
children: /* @__PURE__ */
|
|
1904
|
-
/* @__PURE__ */
|
|
1905
|
-
/* @__PURE__ */
|
|
2332
|
+
children: /* @__PURE__ */ jsxs24("div", { className: "container-input", children: [
|
|
2333
|
+
/* @__PURE__ */ jsxs24("div", { children: [
|
|
2334
|
+
/* @__PURE__ */ jsx28("span", { className: "body-1", children: label }),
|
|
1906
2335
|
" ",
|
|
1907
|
-
required && /* @__PURE__ */
|
|
2336
|
+
required && /* @__PURE__ */ jsx28("span", { className: "text-red-500", children: "*" })
|
|
1908
2337
|
] }),
|
|
1909
|
-
/* @__PURE__ */
|
|
2338
|
+
/* @__PURE__ */ jsx28(
|
|
1910
2339
|
Select3,
|
|
1911
2340
|
{
|
|
1912
2341
|
disabled,
|
|
1913
|
-
suffixIcon: /* @__PURE__ */
|
|
2342
|
+
suffixIcon: /* @__PURE__ */ jsx28(DownOutlined, { style: { color: value ? "#fff" : "#D9D9D9" } }),
|
|
1914
2343
|
value,
|
|
1915
2344
|
onChange,
|
|
1916
2345
|
className: `body-3 custom-select flex justify-center w-full ${className ?? ""}`,
|
|
@@ -1921,14 +2350,14 @@ function SelectFieldStatus({
|
|
|
1921
2350
|
showSearch: true
|
|
1922
2351
|
}
|
|
1923
2352
|
),
|
|
1924
|
-
error && /* @__PURE__ */
|
|
2353
|
+
error && /* @__PURE__ */ jsx28("p", { className: "text-red-500 caption-1", children: error })
|
|
1925
2354
|
] })
|
|
1926
2355
|
}
|
|
1927
2356
|
);
|
|
1928
2357
|
}
|
|
1929
2358
|
|
|
1930
2359
|
// src/Select/SelectFieldStatusReport/SelectFieldStatusReport.tsx
|
|
1931
|
-
import { Select as Select4, ConfigProvider as
|
|
2360
|
+
import { Select as Select4, ConfigProvider as ConfigProvider11 } from "antd";
|
|
1932
2361
|
|
|
1933
2362
|
// src/Select/SelectFieldStatusReport/StatusReportMockup.ts
|
|
1934
2363
|
var status2 = [
|
|
@@ -1938,7 +2367,7 @@ var status2 = [
|
|
|
1938
2367
|
|
|
1939
2368
|
// src/Select/SelectFieldStatusReport/SelectFieldStatusReport.tsx
|
|
1940
2369
|
import { DownOutlined as DownOutlined2 } from "@ant-design/icons";
|
|
1941
|
-
import { jsx as
|
|
2370
|
+
import { jsx as jsx29, jsxs as jsxs25 } from "react/jsx-runtime";
|
|
1942
2371
|
function SelectFieldStatusReport({
|
|
1943
2372
|
value,
|
|
1944
2373
|
onChange,
|
|
@@ -1951,8 +2380,8 @@ function SelectFieldStatusReport({
|
|
|
1951
2380
|
options
|
|
1952
2381
|
}) {
|
|
1953
2382
|
const selectedItem = status2.find((s) => s.value === value);
|
|
1954
|
-
return /* @__PURE__ */
|
|
1955
|
-
|
|
2383
|
+
return /* @__PURE__ */ jsx29(
|
|
2384
|
+
ConfigProvider11,
|
|
1956
2385
|
{
|
|
1957
2386
|
theme: {
|
|
1958
2387
|
components: {
|
|
@@ -1967,17 +2396,17 @@ function SelectFieldStatusReport({
|
|
|
1967
2396
|
fontFamily: "Kanit"
|
|
1968
2397
|
}
|
|
1969
2398
|
},
|
|
1970
|
-
children: /* @__PURE__ */
|
|
1971
|
-
/* @__PURE__ */
|
|
1972
|
-
/* @__PURE__ */
|
|
2399
|
+
children: /* @__PURE__ */ jsxs25("div", { className: "container-input", children: [
|
|
2400
|
+
/* @__PURE__ */ jsxs25("div", { children: [
|
|
2401
|
+
/* @__PURE__ */ jsx29("span", { className: "body-1", children: label }),
|
|
1973
2402
|
" ",
|
|
1974
|
-
required && /* @__PURE__ */
|
|
2403
|
+
required && /* @__PURE__ */ jsx29("span", { className: "text-red-500", children: "*" })
|
|
1975
2404
|
] }),
|
|
1976
|
-
/* @__PURE__ */
|
|
2405
|
+
/* @__PURE__ */ jsx29(
|
|
1977
2406
|
Select4,
|
|
1978
2407
|
{
|
|
1979
2408
|
disabled,
|
|
1980
|
-
suffixIcon: /* @__PURE__ */
|
|
2409
|
+
suffixIcon: /* @__PURE__ */ jsx29(DownOutlined2, { style: { color: value ? "#fff" : "#D9D9D9" } }),
|
|
1981
2410
|
value,
|
|
1982
2411
|
onChange,
|
|
1983
2412
|
className: `body-3 custom-select flex justify-center w-full ${className ?? ""}`,
|
|
@@ -1988,16 +2417,16 @@ function SelectFieldStatusReport({
|
|
|
1988
2417
|
showSearch: true
|
|
1989
2418
|
}
|
|
1990
2419
|
),
|
|
1991
|
-
error && /* @__PURE__ */
|
|
2420
|
+
error && /* @__PURE__ */ jsx29("p", { className: "text-red-500 caption-1", children: error })
|
|
1992
2421
|
] })
|
|
1993
2422
|
}
|
|
1994
2423
|
);
|
|
1995
2424
|
}
|
|
1996
2425
|
|
|
1997
2426
|
// src/Select/SelectFieldTag/SelectFieldTag.tsx
|
|
1998
|
-
import { Select as Select5, ConfigProvider as
|
|
2427
|
+
import { Select as Select5, ConfigProvider as ConfigProvider12 } from "antd";
|
|
1999
2428
|
import { useState as useState6 } from "react";
|
|
2000
|
-
import { jsx as
|
|
2429
|
+
import { jsx as jsx30, jsxs as jsxs26 } from "react/jsx-runtime";
|
|
2001
2430
|
function SelectFieldTag({
|
|
2002
2431
|
label,
|
|
2003
2432
|
required,
|
|
@@ -2030,21 +2459,21 @@ function SelectFieldTag({
|
|
|
2030
2459
|
}
|
|
2031
2460
|
onChange?.([]);
|
|
2032
2461
|
};
|
|
2033
|
-
return /* @__PURE__ */
|
|
2034
|
-
|
|
2462
|
+
return /* @__PURE__ */ jsx30(
|
|
2463
|
+
ConfigProvider12,
|
|
2035
2464
|
{
|
|
2036
2465
|
theme: {
|
|
2037
2466
|
token: {
|
|
2038
2467
|
fontFamily: "Kanit"
|
|
2039
2468
|
}
|
|
2040
2469
|
},
|
|
2041
|
-
children: /* @__PURE__ */
|
|
2042
|
-
/* @__PURE__ */
|
|
2043
|
-
/* @__PURE__ */
|
|
2470
|
+
children: /* @__PURE__ */ jsxs26("div", { className: "container-input", children: [
|
|
2471
|
+
/* @__PURE__ */ jsxs26("div", { children: [
|
|
2472
|
+
/* @__PURE__ */ jsx30("span", { className: "body-1", children: label }),
|
|
2044
2473
|
" ",
|
|
2045
|
-
required && /* @__PURE__ */
|
|
2474
|
+
required && /* @__PURE__ */ jsx30("span", { className: "text-red-500", children: "*" })
|
|
2046
2475
|
] }),
|
|
2047
|
-
/* @__PURE__ */
|
|
2476
|
+
/* @__PURE__ */ jsx30(
|
|
2048
2477
|
Select5,
|
|
2049
2478
|
{
|
|
2050
2479
|
mode: "tags",
|
|
@@ -2063,7 +2492,7 @@ function SelectFieldTag({
|
|
|
2063
2492
|
onClear
|
|
2064
2493
|
}
|
|
2065
2494
|
),
|
|
2066
|
-
error && /* @__PURE__ */
|
|
2495
|
+
error && /* @__PURE__ */ jsx30("p", { className: "text-red-500 caption-1", children: error })
|
|
2067
2496
|
] })
|
|
2068
2497
|
}
|
|
2069
2498
|
);
|
|
@@ -2071,9 +2500,9 @@ function SelectFieldTag({
|
|
|
2071
2500
|
|
|
2072
2501
|
// src/Select/SelectCustom/SelectCustom.tsx
|
|
2073
2502
|
import { IconTrash } from "@tabler/icons-react";
|
|
2074
|
-
import { Select as Select6, ConfigProvider as
|
|
2503
|
+
import { Select as Select6, ConfigProvider as ConfigProvider13 } from "antd";
|
|
2075
2504
|
import { useState as useState7 } from "react";
|
|
2076
|
-
import { jsx as
|
|
2505
|
+
import { jsx as jsx31, jsxs as jsxs27 } from "react/jsx-runtime";
|
|
2077
2506
|
function SelectCustom({
|
|
2078
2507
|
label = "\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E42\u0E04\u0E23\u0E07\u0E01\u0E32\u0E23",
|
|
2079
2508
|
placeholder = "\u0E01\u0E23\u0E38\u0E13\u0E32\u0E40\u0E25\u0E37\u0E2D\u0E01",
|
|
@@ -2102,8 +2531,8 @@ function SelectCustom({
|
|
|
2102
2531
|
});
|
|
2103
2532
|
};
|
|
2104
2533
|
const filteredOptions = options.filter((opt) => !valueList.includes(opt.value)).map((opt) => ({ value: opt.value, label: opt.label }));
|
|
2105
|
-
return /* @__PURE__ */
|
|
2106
|
-
|
|
2534
|
+
return /* @__PURE__ */ jsx31(
|
|
2535
|
+
ConfigProvider13,
|
|
2107
2536
|
{
|
|
2108
2537
|
theme: {
|
|
2109
2538
|
token: {
|
|
@@ -2111,13 +2540,13 @@ function SelectCustom({
|
|
|
2111
2540
|
fontSize: 16
|
|
2112
2541
|
}
|
|
2113
2542
|
},
|
|
2114
|
-
children: /* @__PURE__ */
|
|
2115
|
-
/* @__PURE__ */
|
|
2116
|
-
/* @__PURE__ */
|
|
2543
|
+
children: /* @__PURE__ */ jsxs27("div", { className: "container-input", children: [
|
|
2544
|
+
/* @__PURE__ */ jsxs27("div", { children: [
|
|
2545
|
+
/* @__PURE__ */ jsx31("span", { className: "body-1", children: label }),
|
|
2117
2546
|
" ",
|
|
2118
|
-
required && /* @__PURE__ */
|
|
2547
|
+
required && /* @__PURE__ */ jsx31("span", { className: "text-red-500", children: "*" })
|
|
2119
2548
|
] }),
|
|
2120
|
-
/* @__PURE__ */
|
|
2549
|
+
/* @__PURE__ */ jsx31(
|
|
2121
2550
|
Select6,
|
|
2122
2551
|
{
|
|
2123
2552
|
value,
|
|
@@ -2128,16 +2557,16 @@ function SelectCustom({
|
|
|
2128
2557
|
onClear
|
|
2129
2558
|
}
|
|
2130
2559
|
),
|
|
2131
|
-
error && /* @__PURE__ */
|
|
2132
|
-
/* @__PURE__ */
|
|
2133
|
-
/* @__PURE__ */
|
|
2134
|
-
/* @__PURE__ */
|
|
2560
|
+
error && /* @__PURE__ */ jsx31("p", { className: "text-red-500 caption-1", children: error }),
|
|
2561
|
+
/* @__PURE__ */ jsx31("div", { className: "w-full p-[2px] overflow-y-auto", children: valueList.map((v, index) => /* @__PURE__ */ jsxs27("div", { className: "flex justify-between items-center py-[2px] body-1", children: [
|
|
2562
|
+
/* @__PURE__ */ jsxs27("div", { className: "flex flex-row gap-[8px]", children: [
|
|
2563
|
+
/* @__PURE__ */ jsxs27("p", { children: [
|
|
2135
2564
|
index + 1,
|
|
2136
2565
|
"."
|
|
2137
2566
|
] }),
|
|
2138
|
-
/* @__PURE__ */
|
|
2567
|
+
/* @__PURE__ */ jsx31("p", { children: v })
|
|
2139
2568
|
] }),
|
|
2140
|
-
/* @__PURE__ */
|
|
2569
|
+
/* @__PURE__ */ jsx31(IconTrash, { className: "cursor-pointer", onClick: () => handleDelete(v) })
|
|
2141
2570
|
] }, index)) })
|
|
2142
2571
|
] })
|
|
2143
2572
|
}
|
|
@@ -2145,7 +2574,7 @@ function SelectCustom({
|
|
|
2145
2574
|
}
|
|
2146
2575
|
|
|
2147
2576
|
// src/SortFilter/SortFilter.tsx
|
|
2148
|
-
import { ConfigProvider as
|
|
2577
|
+
import { ConfigProvider as ConfigProvider14 } from "antd";
|
|
2149
2578
|
import { CalendarOutlined } from "@ant-design/icons";
|
|
2150
2579
|
|
|
2151
2580
|
// src/SortFilter/DataMockSortFilter.ts
|
|
@@ -2178,7 +2607,7 @@ var quarters = [
|
|
|
2178
2607
|
// src/SortFilter/SortFilter.tsx
|
|
2179
2608
|
import { useState as useState8 } from "react";
|
|
2180
2609
|
import { IconSortDescending as IconSortDescending2, IconFilter } from "@tabler/icons-react";
|
|
2181
|
-
import { jsx as
|
|
2610
|
+
import { jsx as jsx32, jsxs as jsxs28 } from "react/jsx-runtime";
|
|
2182
2611
|
function SortFilter({
|
|
2183
2612
|
showYear = true,
|
|
2184
2613
|
showQuarter = true,
|
|
@@ -2189,20 +2618,20 @@ function SortFilter({
|
|
|
2189
2618
|
const [yearValue, setYearValue] = useState8();
|
|
2190
2619
|
const [monthValue, setMonthValue] = useState8();
|
|
2191
2620
|
const [quarterValue, setQuartersValue] = useState8();
|
|
2192
|
-
return /* @__PURE__ */
|
|
2193
|
-
|
|
2621
|
+
return /* @__PURE__ */ jsx32(
|
|
2622
|
+
ConfigProvider14,
|
|
2194
2623
|
{
|
|
2195
2624
|
theme: {
|
|
2196
2625
|
token: {
|
|
2197
2626
|
fontFamily: "Kanit"
|
|
2198
2627
|
}
|
|
2199
2628
|
},
|
|
2200
|
-
children: /* @__PURE__ */
|
|
2201
|
-
/* @__PURE__ */
|
|
2202
|
-
showYear && /* @__PURE__ */
|
|
2629
|
+
children: /* @__PURE__ */ jsxs28("div", { className: "w-full flex items-center justify-between", children: [
|
|
2630
|
+
/* @__PURE__ */ jsxs28("div", { className: "w-full flex gap-[10px]", children: [
|
|
2631
|
+
showYear && /* @__PURE__ */ jsx32("div", { className: "w-[200px]", children: /* @__PURE__ */ jsx32(
|
|
2203
2632
|
SelectField,
|
|
2204
2633
|
{
|
|
2205
|
-
prefix: /* @__PURE__ */
|
|
2634
|
+
prefix: /* @__PURE__ */ jsx32(CalendarOutlined, {}),
|
|
2206
2635
|
onChange: setYearValue,
|
|
2207
2636
|
options: years.map((s) => ({
|
|
2208
2637
|
value: s.value,
|
|
@@ -2212,10 +2641,10 @@ function SortFilter({
|
|
|
2212
2641
|
value: yearValue
|
|
2213
2642
|
}
|
|
2214
2643
|
) }),
|
|
2215
|
-
showMonth && /* @__PURE__ */
|
|
2644
|
+
showMonth && /* @__PURE__ */ jsx32("div", { className: "w-[200px]", children: /* @__PURE__ */ jsx32(
|
|
2216
2645
|
SelectField,
|
|
2217
2646
|
{
|
|
2218
|
-
prefix: /* @__PURE__ */
|
|
2647
|
+
prefix: /* @__PURE__ */ jsx32(CalendarOutlined, {}),
|
|
2219
2648
|
onChange: setMonthValue,
|
|
2220
2649
|
options: months.map((s) => ({
|
|
2221
2650
|
value: s.value,
|
|
@@ -2225,10 +2654,10 @@ function SortFilter({
|
|
|
2225
2654
|
placeholder: "\u0E01\u0E23\u0E38\u0E13\u0E32\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E40\u0E14\u0E37\u0E2D\u0E19"
|
|
2226
2655
|
}
|
|
2227
2656
|
) }),
|
|
2228
|
-
showQuarter && /* @__PURE__ */
|
|
2657
|
+
showQuarter && /* @__PURE__ */ jsx32("div", { className: "w-[200px]", children: /* @__PURE__ */ jsx32(
|
|
2229
2658
|
SelectField,
|
|
2230
2659
|
{
|
|
2231
|
-
prefix: /* @__PURE__ */
|
|
2660
|
+
prefix: /* @__PURE__ */ jsx32(CalendarOutlined, {}),
|
|
2232
2661
|
onChange: setQuartersValue,
|
|
2233
2662
|
options: quarters.map((s) => ({
|
|
2234
2663
|
value: s.value,
|
|
@@ -2239,8 +2668,8 @@ function SortFilter({
|
|
|
2239
2668
|
}
|
|
2240
2669
|
) })
|
|
2241
2670
|
] }),
|
|
2242
|
-
/* @__PURE__ */
|
|
2243
|
-
/* @__PURE__ */
|
|
2671
|
+
/* @__PURE__ */ jsxs28("div", { className: "flex gap-[10px]", children: [
|
|
2672
|
+
/* @__PURE__ */ jsx32(
|
|
2244
2673
|
IconSortDescending2,
|
|
2245
2674
|
{
|
|
2246
2675
|
size: 24,
|
|
@@ -2248,7 +2677,7 @@ function SortFilter({
|
|
|
2248
2677
|
onClick: onSortClick
|
|
2249
2678
|
}
|
|
2250
2679
|
),
|
|
2251
|
-
/* @__PURE__ */
|
|
2680
|
+
/* @__PURE__ */ jsx32(
|
|
2252
2681
|
IconFilter,
|
|
2253
2682
|
{
|
|
2254
2683
|
size: 24,
|
|
@@ -2265,7 +2694,7 @@ function SortFilter({
|
|
|
2265
2694
|
// src/Upload/FileUploader/FileUploader.tsx
|
|
2266
2695
|
import { IconPaperclip, IconUpload, IconTrash as IconTrash2 } from "@tabler/icons-react";
|
|
2267
2696
|
import { useRef as useRef2, useState as useState9 } from "react";
|
|
2268
|
-
import { Fragment as Fragment5, jsx as
|
|
2697
|
+
import { Fragment as Fragment5, jsx as jsx33, jsxs as jsxs29 } from "react/jsx-runtime";
|
|
2269
2698
|
function FileUploader({
|
|
2270
2699
|
onUpload,
|
|
2271
2700
|
onError,
|
|
@@ -2336,10 +2765,10 @@ function FileUploader({
|
|
|
2336
2765
|
}
|
|
2337
2766
|
if (inputRef.current) inputRef.current.value = "";
|
|
2338
2767
|
};
|
|
2339
|
-
return /* @__PURE__ */
|
|
2340
|
-
label && /* @__PURE__ */
|
|
2341
|
-
/* @__PURE__ */
|
|
2342
|
-
mode === "upload" ? /* @__PURE__ */
|
|
2768
|
+
return /* @__PURE__ */ jsxs29("div", { className: "w-full", children: [
|
|
2769
|
+
label && /* @__PURE__ */ jsx33("p", { className: "body-1", children: label }),
|
|
2770
|
+
/* @__PURE__ */ jsxs29("div", { children: [
|
|
2771
|
+
mode === "upload" ? /* @__PURE__ */ jsx33(
|
|
2343
2772
|
"button",
|
|
2344
2773
|
{
|
|
2345
2774
|
type: "button",
|
|
@@ -2347,15 +2776,15 @@ function FileUploader({
|
|
|
2347
2776
|
className: `h-[34px] flex justify-center items-center gap-2 w-full rounded-[2px] border border-gray-200 body-1
|
|
2348
2777
|
${disabled ? "cursor-not-allowed text-gray-400 bg-gray-100" : "cursor-pointer hover:text-primary-400 hover:border-primary-200 duration-300"}`,
|
|
2349
2778
|
disabled: disabled ? disabled : uploading,
|
|
2350
|
-
children: uploading ? /* @__PURE__ */
|
|
2351
|
-
/* @__PURE__ */
|
|
2779
|
+
children: uploading ? /* @__PURE__ */ jsxs29(Fragment5, { children: [
|
|
2780
|
+
/* @__PURE__ */ jsx33(Loader, { size: 15 }),
|
|
2352
2781
|
" \u0E01\u0E33\u0E25\u0E31\u0E07\u0E2D\u0E31\u0E1B\u0E42\u0E2B\u0E25\u0E14"
|
|
2353
|
-
] }) : /* @__PURE__ */
|
|
2354
|
-
/* @__PURE__ */
|
|
2782
|
+
] }) : /* @__PURE__ */ jsxs29(Fragment5, { children: [
|
|
2783
|
+
/* @__PURE__ */ jsx33(IconUpload, { size: 15, className: "text-gray-400" }),
|
|
2355
2784
|
" \u0E41\u0E19\u0E1A\u0E44\u0E1F\u0E25\u0E4C"
|
|
2356
2785
|
] })
|
|
2357
2786
|
}
|
|
2358
|
-
) : /* @__PURE__ */
|
|
2787
|
+
) : /* @__PURE__ */ jsx33(
|
|
2359
2788
|
"div",
|
|
2360
2789
|
{
|
|
2361
2790
|
className: `min-w-[400px] min-h-[120px] flex justify-center items-center border-2 border-dashed rounded-md p-4 transition-colors body-1
|
|
@@ -2369,17 +2798,17 @@ function FileUploader({
|
|
|
2369
2798
|
},
|
|
2370
2799
|
onDragLeave: () => setDragActive(false),
|
|
2371
2800
|
onDrop: handleDrop,
|
|
2372
|
-
children: uploading ? /* @__PURE__ */
|
|
2373
|
-
/* @__PURE__ */
|
|
2801
|
+
children: uploading ? /* @__PURE__ */ jsxs29("div", { className: "flex justify-center items-center gap-2", children: [
|
|
2802
|
+
/* @__PURE__ */ jsx33(Loader, { size: 15 }),
|
|
2374
2803
|
" \u0E01\u0E33\u0E25\u0E31\u0E07\u0E2D\u0E31\u0E1B\u0E42\u0E2B\u0E25\u0E14"
|
|
2375
|
-
] }) : /* @__PURE__ */
|
|
2376
|
-
/* @__PURE__ */
|
|
2377
|
-
/* @__PURE__ */
|
|
2378
|
-
/* @__PURE__ */
|
|
2804
|
+
] }) : /* @__PURE__ */ jsxs29("div", { className: "flex flex-col items-center gap-2", children: [
|
|
2805
|
+
/* @__PURE__ */ jsx33(IconUpload, { size: 20 }),
|
|
2806
|
+
/* @__PURE__ */ jsx33("span", { className: "body-1", children: "\u0E04\u0E25\u0E34\u0E01\u0E2B\u0E23\u0E37\u0E2D\u0E25\u0E32\u0E01\u0E44\u0E1F\u0E25\u0E4C\u0E21\u0E32\u0E17\u0E35\u0E48\u0E1A\u0E23\u0E34\u0E40\u0E27\u0E13\u0E19\u0E35\u0E49\u0E40\u0E1E\u0E37\u0E48\u0E2D\u0E2D\u0E31\u0E1B\u0E42\u0E2B\u0E25\u0E14" }),
|
|
2807
|
+
/* @__PURE__ */ jsx33("span", { className: "text-gray-400 body-3", children: "\u0E23\u0E2D\u0E07\u0E23\u0E31\u0E1A\u0E01\u0E32\u0E23\u0E2D\u0E31\u0E1B\u0E42\u0E2B\u0E25\u0E14\u0E41\u0E1A\u0E1A\u0E40\u0E14\u0E35\u0E48\u0E22\u0E27\u0E2B\u0E23\u0E37\u0E2D\u0E2B\u0E25\u0E32\u0E22\u0E44\u0E1F\u0E25\u0E4C" })
|
|
2379
2808
|
] })
|
|
2380
2809
|
}
|
|
2381
2810
|
),
|
|
2382
|
-
/* @__PURE__ */
|
|
2811
|
+
/* @__PURE__ */ jsx33(
|
|
2383
2812
|
"input",
|
|
2384
2813
|
{
|
|
2385
2814
|
type: "file",
|
|
@@ -2392,13 +2821,13 @@ function FileUploader({
|
|
|
2392
2821
|
}
|
|
2393
2822
|
)
|
|
2394
2823
|
] }),
|
|
2395
|
-
description && /* @__PURE__ */
|
|
2396
|
-
/* @__PURE__ */
|
|
2397
|
-
/* @__PURE__ */
|
|
2398
|
-
/* @__PURE__ */
|
|
2399
|
-
/* @__PURE__ */
|
|
2824
|
+
description && /* @__PURE__ */ jsx33("p", { className: "text-gray-400 body-4", children: description }),
|
|
2825
|
+
/* @__PURE__ */ jsx33("div", { className: "mt-[8px]", children: fileList.length !== 0 && fileList.map((file, index) => /* @__PURE__ */ jsxs29("div", { className: "flex items-center gap-2 rounded-[4px] px-[8px] py-[4px] body-1", children: [
|
|
2826
|
+
/* @__PURE__ */ jsxs29("div", { className: "flex items-center gap-2 w-[75%] overflow-hidden", children: [
|
|
2827
|
+
/* @__PURE__ */ jsx33("div", { className: "w-[15px] h-[15px]", children: /* @__PURE__ */ jsx33(IconPaperclip, { size: 15 }) }),
|
|
2828
|
+
/* @__PURE__ */ jsx33("span", { className: "truncate", children: file.name })
|
|
2400
2829
|
] }),
|
|
2401
|
-
/* @__PURE__ */
|
|
2830
|
+
/* @__PURE__ */ jsx33(
|
|
2402
2831
|
IconTrash2,
|
|
2403
2832
|
{
|
|
2404
2833
|
size: 20,
|
|
@@ -2432,9 +2861,9 @@ function messageLoading(content, duration) {
|
|
|
2432
2861
|
}
|
|
2433
2862
|
|
|
2434
2863
|
// src/Breadcrumb/Breadcrumb.tsx
|
|
2435
|
-
import { ConfigProvider as
|
|
2864
|
+
import { ConfigProvider as ConfigProvider15 } from "antd";
|
|
2436
2865
|
import { Breadcrumb } from "antd";
|
|
2437
|
-
import { jsx as
|
|
2866
|
+
import { jsx as jsx34 } from "react/jsx-runtime";
|
|
2438
2867
|
function Breadcrumbs({
|
|
2439
2868
|
items,
|
|
2440
2869
|
separator,
|
|
@@ -2442,15 +2871,15 @@ function Breadcrumbs({
|
|
|
2442
2871
|
classname,
|
|
2443
2872
|
params
|
|
2444
2873
|
}) {
|
|
2445
|
-
return /* @__PURE__ */
|
|
2446
|
-
|
|
2874
|
+
return /* @__PURE__ */ jsx34(
|
|
2875
|
+
ConfigProvider15,
|
|
2447
2876
|
{
|
|
2448
2877
|
theme: {
|
|
2449
2878
|
token: {
|
|
2450
2879
|
fontFamily: "Kanit"
|
|
2451
2880
|
}
|
|
2452
2881
|
},
|
|
2453
|
-
children: /* @__PURE__ */
|
|
2882
|
+
children: /* @__PURE__ */ jsx34(
|
|
2454
2883
|
Breadcrumb,
|
|
2455
2884
|
{
|
|
2456
2885
|
items,
|
|
@@ -2465,8 +2894,8 @@ function Breadcrumbs({
|
|
|
2465
2894
|
}
|
|
2466
2895
|
|
|
2467
2896
|
// src/HeadingPage/HeadingPage.tsx
|
|
2468
|
-
import { ConfigProvider as
|
|
2469
|
-
import { jsx as
|
|
2897
|
+
import { ConfigProvider as ConfigProvider16 } from "antd";
|
|
2898
|
+
import { jsx as jsx35, jsxs as jsxs30 } from "react/jsx-runtime";
|
|
2470
2899
|
function HeadingPage({ Heading }) {
|
|
2471
2900
|
const today = (/* @__PURE__ */ new Date()).toLocaleDateString("th-TH", {
|
|
2472
2901
|
weekday: "long",
|
|
@@ -2474,17 +2903,17 @@ function HeadingPage({ Heading }) {
|
|
|
2474
2903
|
month: "long",
|
|
2475
2904
|
year: "numeric"
|
|
2476
2905
|
});
|
|
2477
|
-
return /* @__PURE__ */
|
|
2478
|
-
|
|
2906
|
+
return /* @__PURE__ */ jsx35(
|
|
2907
|
+
ConfigProvider16,
|
|
2479
2908
|
{
|
|
2480
2909
|
theme: {
|
|
2481
2910
|
token: {
|
|
2482
2911
|
fontFamily: "Kanit"
|
|
2483
2912
|
}
|
|
2484
2913
|
},
|
|
2485
|
-
children: /* @__PURE__ */
|
|
2486
|
-
/* @__PURE__ */
|
|
2487
|
-
/* @__PURE__ */
|
|
2914
|
+
children: /* @__PURE__ */ jsxs30("div", { className: "flex flex-col gap-[10px] px-[20px] py-[10px]", children: [
|
|
2915
|
+
/* @__PURE__ */ jsx35("p", { className: "headline-5", children: Heading }),
|
|
2916
|
+
/* @__PURE__ */ jsxs30("p", { className: "body-1", children: [
|
|
2488
2917
|
" \u0E27\u0E31\u0E19\u0E19\u0E35\u0E49 ",
|
|
2489
2918
|
today
|
|
2490
2919
|
] })
|
|
@@ -2494,9 +2923,9 @@ function HeadingPage({ Heading }) {
|
|
|
2494
2923
|
}
|
|
2495
2924
|
|
|
2496
2925
|
// src/Progress/ProgressBar.tsx
|
|
2497
|
-
import { ConfigProvider as
|
|
2926
|
+
import { ConfigProvider as ConfigProvider17, Progress } from "antd";
|
|
2498
2927
|
import { useEffect as useEffect2, useRef as useRef3, useState as useState10 } from "react";
|
|
2499
|
-
import { jsx as
|
|
2928
|
+
import { jsx as jsx36, jsxs as jsxs31 } from "react/jsx-runtime";
|
|
2500
2929
|
function ProgressBar({
|
|
2501
2930
|
percent = 0,
|
|
2502
2931
|
size = "default",
|
|
@@ -2527,16 +2956,16 @@ function ProgressBar({
|
|
|
2527
2956
|
observer.observe(inner);
|
|
2528
2957
|
return () => observer.disconnect();
|
|
2529
2958
|
}, []);
|
|
2530
|
-
return /* @__PURE__ */
|
|
2531
|
-
|
|
2959
|
+
return /* @__PURE__ */ jsx36(
|
|
2960
|
+
ConfigProvider17,
|
|
2532
2961
|
{
|
|
2533
2962
|
theme: {
|
|
2534
2963
|
token: {
|
|
2535
2964
|
fontFamily: "Kanit"
|
|
2536
2965
|
}
|
|
2537
2966
|
},
|
|
2538
|
-
children: /* @__PURE__ */
|
|
2539
|
-
/* @__PURE__ */
|
|
2967
|
+
children: /* @__PURE__ */ jsxs31("div", { className: "relative w-full", ref: progressRef, children: [
|
|
2968
|
+
/* @__PURE__ */ jsx36(
|
|
2540
2969
|
Progress,
|
|
2541
2970
|
{
|
|
2542
2971
|
className: "w-full",
|
|
@@ -2552,7 +2981,7 @@ function ProgressBar({
|
|
|
2552
2981
|
strokeColor
|
|
2553
2982
|
}
|
|
2554
2983
|
),
|
|
2555
|
-
barWidth > 0 && isCheckPoints && type !== "circle" && checkpoints.map((cp) => /* @__PURE__ */
|
|
2984
|
+
barWidth > 0 && isCheckPoints && type !== "circle" && checkpoints.map((cp) => /* @__PURE__ */ jsx36(
|
|
2556
2985
|
"div",
|
|
2557
2986
|
{
|
|
2558
2987
|
className: "checkpoint absolute top-0",
|
|
@@ -2574,7 +3003,7 @@ function ProgressBar({
|
|
|
2574
3003
|
}
|
|
2575
3004
|
|
|
2576
3005
|
// src/KpiSection/KpiSection.tsx
|
|
2577
|
-
import { ConfigProvider as
|
|
3006
|
+
import { ConfigProvider as ConfigProvider18, message } from "antd";
|
|
2578
3007
|
import { useEffect as useEffect3, useState as useState12 } from "react";
|
|
2579
3008
|
|
|
2580
3009
|
// src/KpiSection/hooks/useGetKpiSection.ts
|
|
@@ -2725,7 +3154,7 @@ function useGetKpiSection() {
|
|
|
2725
3154
|
|
|
2726
3155
|
// src/KpiSection/KpiSection.tsx
|
|
2727
3156
|
import { IconCheck as IconCheck2, IconCirclePlus, IconPencil, IconTrash as IconTrash3, IconX as IconX2 } from "@tabler/icons-react";
|
|
2728
|
-
import { Fragment as Fragment6, jsx as
|
|
3157
|
+
import { Fragment as Fragment6, jsx as jsx37, jsxs as jsxs32 } from "react/jsx-runtime";
|
|
2729
3158
|
function KpiSection({ type, onChangeKpiList }) {
|
|
2730
3159
|
const {
|
|
2731
3160
|
handleAddKpi,
|
|
@@ -2755,8 +3184,8 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2755
3184
|
onChangeKpiList(kpiList);
|
|
2756
3185
|
}
|
|
2757
3186
|
}, [kpiList]);
|
|
2758
|
-
return /* @__PURE__ */
|
|
2759
|
-
|
|
3187
|
+
return /* @__PURE__ */ jsx37(
|
|
3188
|
+
ConfigProvider18,
|
|
2760
3189
|
{
|
|
2761
3190
|
theme: {
|
|
2762
3191
|
token: {
|
|
@@ -2764,11 +3193,11 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2764
3193
|
fontSize: 16
|
|
2765
3194
|
}
|
|
2766
3195
|
},
|
|
2767
|
-
children: /* @__PURE__ */
|
|
3196
|
+
children: /* @__PURE__ */ jsxs32("div", { className: "container-input", children: [
|
|
2768
3197
|
messageContainer,
|
|
2769
|
-
type === "number" && /* @__PURE__ */
|
|
2770
|
-
/* @__PURE__ */
|
|
2771
|
-
/* @__PURE__ */
|
|
3198
|
+
type === "number" && /* @__PURE__ */ jsxs32("div", { className: "space-y-4", children: [
|
|
3199
|
+
/* @__PURE__ */ jsxs32("div", { className: "grid grid-cols-[1fr_200px_200px_50px] w-full gap-[24px] items-start", children: [
|
|
3200
|
+
/* @__PURE__ */ jsx37(
|
|
2772
3201
|
InputField,
|
|
2773
3202
|
{
|
|
2774
3203
|
value: nameKpi,
|
|
@@ -2780,7 +3209,7 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2780
3209
|
error: errors.nameKpi
|
|
2781
3210
|
}
|
|
2782
3211
|
),
|
|
2783
|
-
/* @__PURE__ */
|
|
3212
|
+
/* @__PURE__ */ jsx37(
|
|
2784
3213
|
InputField,
|
|
2785
3214
|
{
|
|
2786
3215
|
value: kpiValue,
|
|
@@ -2804,7 +3233,7 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2804
3233
|
error: errors.kpiValue
|
|
2805
3234
|
}
|
|
2806
3235
|
),
|
|
2807
|
-
/* @__PURE__ */
|
|
3236
|
+
/* @__PURE__ */ jsx37(
|
|
2808
3237
|
InputField,
|
|
2809
3238
|
{
|
|
2810
3239
|
value: unitValue,
|
|
@@ -2816,7 +3245,7 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2816
3245
|
error: errors.unitValue
|
|
2817
3246
|
}
|
|
2818
3247
|
),
|
|
2819
|
-
/* @__PURE__ */
|
|
3248
|
+
/* @__PURE__ */ jsx37("div", { className: `flex justify-end mt-[28px]`, children: /* @__PURE__ */ jsx37(
|
|
2820
3249
|
IconCirclePlus,
|
|
2821
3250
|
{
|
|
2822
3251
|
className: "w-[40px] h-[40px] cursor-pointer hover:scale-110 transition",
|
|
@@ -2825,17 +3254,17 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2825
3254
|
}
|
|
2826
3255
|
) })
|
|
2827
3256
|
] }),
|
|
2828
|
-
/* @__PURE__ */
|
|
3257
|
+
/* @__PURE__ */ jsx37("div", { children: kpiList.map((kpi, index) => /* @__PURE__ */ jsxs32(
|
|
2829
3258
|
"div",
|
|
2830
3259
|
{
|
|
2831
3260
|
className: "grid grid-cols-[30px_1fr_100px_120px_80px] items-start py-2 body-1 gap-[8px]",
|
|
2832
3261
|
children: [
|
|
2833
|
-
/* @__PURE__ */
|
|
3262
|
+
/* @__PURE__ */ jsxs32("p", { className: `body-1 ${kpi.isEditing ? "mt-[12px]" : ""}`, children: [
|
|
2834
3263
|
index + 1,
|
|
2835
3264
|
"."
|
|
2836
3265
|
] }),
|
|
2837
|
-
kpi.isEditing ? /* @__PURE__ */
|
|
2838
|
-
/* @__PURE__ */
|
|
3266
|
+
kpi.isEditing ? /* @__PURE__ */ jsxs32(Fragment6, { children: [
|
|
3267
|
+
/* @__PURE__ */ jsx37(
|
|
2839
3268
|
InputField,
|
|
2840
3269
|
{
|
|
2841
3270
|
value: kpi.name,
|
|
@@ -2845,7 +3274,7 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2845
3274
|
error: itemErrors[kpi.id]?.name
|
|
2846
3275
|
}
|
|
2847
3276
|
),
|
|
2848
|
-
/* @__PURE__ */
|
|
3277
|
+
/* @__PURE__ */ jsx37(
|
|
2849
3278
|
InputField,
|
|
2850
3279
|
{
|
|
2851
3280
|
value: kpi.value?.toString(),
|
|
@@ -2870,7 +3299,7 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2870
3299
|
error: itemErrors[kpi.id]?.value
|
|
2871
3300
|
}
|
|
2872
3301
|
),
|
|
2873
|
-
/* @__PURE__ */
|
|
3302
|
+
/* @__PURE__ */ jsx37(
|
|
2874
3303
|
InputField,
|
|
2875
3304
|
{
|
|
2876
3305
|
value: kpi.unit,
|
|
@@ -2880,29 +3309,29 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2880
3309
|
error: itemErrors[kpi.id]?.unit
|
|
2881
3310
|
}
|
|
2882
3311
|
),
|
|
2883
|
-
/* @__PURE__ */
|
|
3312
|
+
/* @__PURE__ */ jsxs32(
|
|
2884
3313
|
"div",
|
|
2885
3314
|
{
|
|
2886
3315
|
className: `flex gap-2 justify-end self-center ${!!itemErrors[kpi.id]?.value || !!itemErrors[kpi.id]?.unit || !!itemErrors[kpi.id]?.name ? "mt-[-12px]" : ""}`,
|
|
2887
3316
|
children: [
|
|
2888
|
-
/* @__PURE__ */
|
|
3317
|
+
/* @__PURE__ */ jsx37(
|
|
2889
3318
|
IconCheck2,
|
|
2890
3319
|
{
|
|
2891
3320
|
className: "w-[30px] h-[30px] cursor-pointer",
|
|
2892
3321
|
onClick: () => handleSave(kpi.id, type)
|
|
2893
3322
|
}
|
|
2894
3323
|
),
|
|
2895
|
-
/* @__PURE__ */
|
|
3324
|
+
/* @__PURE__ */ jsx37(IconX2, { className: "w-[30px] h-[30px] cursor-pointer", onClick: () => handleCancel(kpi.id) })
|
|
2896
3325
|
]
|
|
2897
3326
|
}
|
|
2898
3327
|
)
|
|
2899
|
-
] }) : /* @__PURE__ */
|
|
2900
|
-
/* @__PURE__ */
|
|
2901
|
-
/* @__PURE__ */
|
|
2902
|
-
/* @__PURE__ */
|
|
2903
|
-
/* @__PURE__ */
|
|
2904
|
-
/* @__PURE__ */
|
|
2905
|
-
/* @__PURE__ */
|
|
3328
|
+
] }) : /* @__PURE__ */ jsxs32(Fragment6, { children: [
|
|
3329
|
+
/* @__PURE__ */ jsx37("p", { className: "body-1", children: kpi.name }),
|
|
3330
|
+
/* @__PURE__ */ jsx37("p", { className: "body-1", children: kpi.value }),
|
|
3331
|
+
/* @__PURE__ */ jsx37("p", { className: "body-1", children: kpi.unit }),
|
|
3332
|
+
/* @__PURE__ */ jsxs32("div", { className: "flex gap-3 justify-end", children: [
|
|
3333
|
+
/* @__PURE__ */ jsx37(IconPencil, { className: "w-[30px] h-[30px] cursor-pointer", onClick: () => handleEdit(kpi.id) }),
|
|
3334
|
+
/* @__PURE__ */ jsx37(IconTrash3, { className: "w-[30px] h-[30px] cursor-pointer", onClick: () => handleDelete(kpi.id) })
|
|
2906
3335
|
] })
|
|
2907
3336
|
] })
|
|
2908
3337
|
]
|
|
@@ -2910,9 +3339,9 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2910
3339
|
kpi.id
|
|
2911
3340
|
)) })
|
|
2912
3341
|
] }),
|
|
2913
|
-
type === "text" && /* @__PURE__ */
|
|
2914
|
-
/* @__PURE__ */
|
|
2915
|
-
/* @__PURE__ */
|
|
3342
|
+
type === "text" && /* @__PURE__ */ jsxs32("div", { className: "space-y-4", children: [
|
|
3343
|
+
/* @__PURE__ */ jsxs32("div", { className: "grid grid-cols-[1fr_50px] w-full gap-[24px] items-start", children: [
|
|
3344
|
+
/* @__PURE__ */ jsx37(
|
|
2916
3345
|
InputField,
|
|
2917
3346
|
{
|
|
2918
3347
|
value: nameKpi,
|
|
@@ -2924,7 +3353,7 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2924
3353
|
error: errors.nameKpi
|
|
2925
3354
|
}
|
|
2926
3355
|
),
|
|
2927
|
-
/* @__PURE__ */
|
|
3356
|
+
/* @__PURE__ */ jsx37("div", { className: `flex justify-end mt-[28px]`, children: /* @__PURE__ */ jsx37(
|
|
2928
3357
|
IconCirclePlus,
|
|
2929
3358
|
{
|
|
2930
3359
|
className: "w-[40px] h-[40px] cursor-pointer hover:scale-110 transition",
|
|
@@ -2933,13 +3362,13 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2933
3362
|
}
|
|
2934
3363
|
) })
|
|
2935
3364
|
] }),
|
|
2936
|
-
/* @__PURE__ */
|
|
2937
|
-
/* @__PURE__ */
|
|
3365
|
+
/* @__PURE__ */ jsx37("div", { children: kpiList.map((kpi, index) => /* @__PURE__ */ jsxs32("div", { className: "grid grid-cols-[30px_1fr_80px] items-start py-2 body-1 gap-[8px]", children: [
|
|
3366
|
+
/* @__PURE__ */ jsxs32("p", { className: `body-1 ${kpi.isEditing ? "mt-[12px]" : ""}`, children: [
|
|
2938
3367
|
index + 1,
|
|
2939
3368
|
"."
|
|
2940
3369
|
] }),
|
|
2941
|
-
kpi.isEditing ? /* @__PURE__ */
|
|
2942
|
-
/* @__PURE__ */
|
|
3370
|
+
kpi.isEditing ? /* @__PURE__ */ jsxs32(Fragment6, { children: [
|
|
3371
|
+
/* @__PURE__ */ jsx37(
|
|
2943
3372
|
InputField,
|
|
2944
3373
|
{
|
|
2945
3374
|
value: kpi.name,
|
|
@@ -2949,27 +3378,27 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2949
3378
|
error: itemErrors[kpi.id]?.name
|
|
2950
3379
|
}
|
|
2951
3380
|
),
|
|
2952
|
-
/* @__PURE__ */
|
|
3381
|
+
/* @__PURE__ */ jsxs32(
|
|
2953
3382
|
"div",
|
|
2954
3383
|
{
|
|
2955
3384
|
className: `flex gap-2 justify-end self-center ${!!itemErrors[kpi.id]?.name ? "mt-[-12px]" : ""}`,
|
|
2956
3385
|
children: [
|
|
2957
|
-
/* @__PURE__ */
|
|
3386
|
+
/* @__PURE__ */ jsx37(
|
|
2958
3387
|
IconCheck2,
|
|
2959
3388
|
{
|
|
2960
3389
|
className: "w-[30px] h-[30px] cursor-pointer",
|
|
2961
3390
|
onClick: () => handleSave(kpi.id, type)
|
|
2962
3391
|
}
|
|
2963
3392
|
),
|
|
2964
|
-
/* @__PURE__ */
|
|
3393
|
+
/* @__PURE__ */ jsx37(IconX2, { className: "w-[30px] h-[30px] cursor-pointer", onClick: () => handleCancel(kpi.id) })
|
|
2965
3394
|
]
|
|
2966
3395
|
}
|
|
2967
3396
|
)
|
|
2968
|
-
] }) : /* @__PURE__ */
|
|
2969
|
-
/* @__PURE__ */
|
|
2970
|
-
/* @__PURE__ */
|
|
2971
|
-
/* @__PURE__ */
|
|
2972
|
-
/* @__PURE__ */
|
|
3397
|
+
] }) : /* @__PURE__ */ jsxs32(Fragment6, { children: [
|
|
3398
|
+
/* @__PURE__ */ jsx37("p", { className: "body-1", children: kpi.name }),
|
|
3399
|
+
/* @__PURE__ */ jsxs32("div", { className: "flex gap-3 justify-end", children: [
|
|
3400
|
+
/* @__PURE__ */ jsx37(IconPencil, { className: "w-[30px] h-[30px] cursor-pointer", onClick: () => handleEdit(kpi.id) }),
|
|
3401
|
+
/* @__PURE__ */ jsx37(IconTrash3, { className: "w-[30px] h-[30px] cursor-pointer", onClick: () => handleDelete(kpi.id) })
|
|
2973
3402
|
] })
|
|
2974
3403
|
] })
|
|
2975
3404
|
] }, kpi.id)) })
|
|
@@ -2981,16 +3410,16 @@ function KpiSection({ type, onChangeKpiList }) {
|
|
|
2981
3410
|
|
|
2982
3411
|
// src/Modal/Modal/Modal.tsx
|
|
2983
3412
|
import { Modal } from "antd";
|
|
2984
|
-
import { jsx as
|
|
3413
|
+
import { jsx as jsx38 } from "react/jsx-runtime";
|
|
2985
3414
|
function AntDModal({ children, isOpen, width, onCancel }) {
|
|
2986
|
-
return /* @__PURE__ */
|
|
3415
|
+
return /* @__PURE__ */ jsx38("div", { children: /* @__PURE__ */ jsx38(Modal, { open: isOpen, onCancel, width, centered: true, footer: null, children: /* @__PURE__ */ jsx38("div", { children }) }) });
|
|
2987
3416
|
}
|
|
2988
3417
|
|
|
2989
3418
|
// src/Indicator/Indicator/Indicator.tsx
|
|
2990
3419
|
import { IconCheck as IconCheck3, IconCirclePlus as IconCirclePlus2, IconPencil as IconPencil2, IconTrash as IconTrash4, IconX as IconX3 } from "@tabler/icons-react";
|
|
2991
3420
|
import { useState as useState13 } from "react";
|
|
2992
3421
|
import { Input as Input4 } from "antd";
|
|
2993
|
-
import { Fragment as Fragment7, jsx as
|
|
3422
|
+
import { Fragment as Fragment7, jsx as jsx39, jsxs as jsxs33 } from "react/jsx-runtime";
|
|
2994
3423
|
function Indicator({
|
|
2995
3424
|
option = [
|
|
2996
3425
|
{ value: "TEXT", label: "\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21" },
|
|
@@ -3072,14 +3501,14 @@ function Indicator({
|
|
|
3072
3501
|
}));
|
|
3073
3502
|
console.log(cacheEditData);
|
|
3074
3503
|
};
|
|
3075
|
-
return /* @__PURE__ */
|
|
3076
|
-
/* @__PURE__ */
|
|
3504
|
+
return /* @__PURE__ */ jsxs33("div", { className: "w-full", children: [
|
|
3505
|
+
/* @__PURE__ */ jsxs33(
|
|
3077
3506
|
"div",
|
|
3078
3507
|
{
|
|
3079
3508
|
className: `space-x-2 grid ${valueSwitch === "TEXT" ? `grid-cols-[140px_1fr_50px]` : `grid-cols-[140px_1fr_200px_200px_50px]`} items-start`,
|
|
3080
3509
|
children: [
|
|
3081
|
-
/* @__PURE__ */
|
|
3082
|
-
/* @__PURE__ */
|
|
3510
|
+
/* @__PURE__ */ jsx39(SwitchSelect, { option, onClick: handleClick, value: valueSwitch, label: "\u0E1B\u0E23\u0E30\u0E40\u0E20\u0E17", required: true }),
|
|
3511
|
+
/* @__PURE__ */ jsx39(
|
|
3083
3512
|
InputField,
|
|
3084
3513
|
{
|
|
3085
3514
|
label: `\u0E0A\u0E37\u0E48\u0E2D\u0E15\u0E31\u0E27\u0E0A\u0E35\u0E49\u0E27\u0E31\u0E14${type === "OUTPUT" ? "\u0E1C\u0E25\u0E1C\u0E25\u0E34\u0E15" : "\u0E1C\u0E25\u0E25\u0E31\u0E1E\u0E18\u0E4C"}`,
|
|
@@ -3090,8 +3519,8 @@ function Indicator({
|
|
|
3090
3519
|
required: true
|
|
3091
3520
|
}
|
|
3092
3521
|
),
|
|
3093
|
-
valueSwitch === "NUMBER" && /* @__PURE__ */
|
|
3094
|
-
/* @__PURE__ */
|
|
3522
|
+
valueSwitch === "NUMBER" && /* @__PURE__ */ jsxs33(Fragment7, { children: [
|
|
3523
|
+
/* @__PURE__ */ jsx39(
|
|
3095
3524
|
InputFieldNumber,
|
|
3096
3525
|
{
|
|
3097
3526
|
label: `\u0E04\u0E48\u0E32\u0E40\u0E1B\u0E49\u0E32\u0E2B\u0E21\u0E32\u0E22${type === "OUTPUT" ? "\u0E1C\u0E25\u0E1C\u0E25\u0E34\u0E15" : "\u0E1C\u0E25\u0E25\u0E31\u0E1E\u0E18\u0E4C"}`,
|
|
@@ -3102,7 +3531,7 @@ function Indicator({
|
|
|
3102
3531
|
required: true
|
|
3103
3532
|
}
|
|
3104
3533
|
),
|
|
3105
|
-
/* @__PURE__ */
|
|
3534
|
+
/* @__PURE__ */ jsx39(
|
|
3106
3535
|
InputField,
|
|
3107
3536
|
{
|
|
3108
3537
|
label: `\u0E2B\u0E19\u0E48\u0E27\u0E22`,
|
|
@@ -3114,17 +3543,17 @@ function Indicator({
|
|
|
3114
3543
|
}
|
|
3115
3544
|
)
|
|
3116
3545
|
] }),
|
|
3117
|
-
/* @__PURE__ */
|
|
3546
|
+
/* @__PURE__ */ jsx39(IconCirclePlus2, { onClick: handleAddIndicator, className: "mt-7 cursor-pointer", size: 32 })
|
|
3118
3547
|
]
|
|
3119
3548
|
}
|
|
3120
3549
|
),
|
|
3121
|
-
/* @__PURE__ */
|
|
3550
|
+
/* @__PURE__ */ jsx39(Fragment7, { children: arrayData.map((item, index) => /* @__PURE__ */ jsxs33(
|
|
3122
3551
|
"div",
|
|
3123
3552
|
{
|
|
3124
3553
|
className: `space-y-4 grid ${item.inputType === "TEXT" ? `grid-cols-[140px_1fr_50px_50px]` : `grid-cols-[140px_1fr_200px_150px_50px_50px]`} items-start`,
|
|
3125
3554
|
children: [
|
|
3126
|
-
/* @__PURE__ */
|
|
3127
|
-
index === editIndex ? /* @__PURE__ */
|
|
3555
|
+
/* @__PURE__ */ jsx39("div", { className: "body-1 mt-2", children: item.inputType === "TEXT" ? "\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21" : "\u0E15\u0E31\u0E27\u0E40\u0E25\u0E02" }),
|
|
3556
|
+
index === editIndex ? /* @__PURE__ */ jsx39(
|
|
3128
3557
|
Input4,
|
|
3129
3558
|
{
|
|
3130
3559
|
className: "body-1 mt-2",
|
|
@@ -3133,9 +3562,9 @@ function Indicator({
|
|
|
3133
3562
|
name: "textValue",
|
|
3134
3563
|
onChange: (e) => handleChangeEditCashData(e)
|
|
3135
3564
|
}
|
|
3136
|
-
) : /* @__PURE__ */
|
|
3137
|
-
item.inputType === "NUMBER" && /* @__PURE__ */
|
|
3138
|
-
index === editIndex ? /* @__PURE__ */
|
|
3565
|
+
) : /* @__PURE__ */ jsx39("div", { className: "body-1 mt-2", children: item.textValue }),
|
|
3566
|
+
item.inputType === "NUMBER" && /* @__PURE__ */ jsxs33(Fragment7, { children: [
|
|
3567
|
+
index === editIndex ? /* @__PURE__ */ jsx39(
|
|
3139
3568
|
Input4,
|
|
3140
3569
|
{
|
|
3141
3570
|
className: "body-1 mt-2",
|
|
@@ -3144,8 +3573,8 @@ function Indicator({
|
|
|
3144
3573
|
name: "numberValue",
|
|
3145
3574
|
onChange: (e) => handleChangeEditCashData(e)
|
|
3146
3575
|
}
|
|
3147
|
-
) : /* @__PURE__ */
|
|
3148
|
-
index === editIndex ? /* @__PURE__ */
|
|
3576
|
+
) : /* @__PURE__ */ jsx39("div", { className: "body-1 mt-2", children: item.numberValue }),
|
|
3577
|
+
index === editIndex ? /* @__PURE__ */ jsx39(
|
|
3149
3578
|
Input4,
|
|
3150
3579
|
{
|
|
3151
3580
|
className: "body-1 mt-2",
|
|
@@ -3154,19 +3583,19 @@ function Indicator({
|
|
|
3154
3583
|
name: "unit",
|
|
3155
3584
|
onChange: (e) => handleChangeEditCashData(e)
|
|
3156
3585
|
}
|
|
3157
|
-
) : /* @__PURE__ */
|
|
3586
|
+
) : /* @__PURE__ */ jsx39("div", { className: "body-1 mt-2", children: item.unit })
|
|
3158
3587
|
] }),
|
|
3159
|
-
/* @__PURE__ */
|
|
3160
|
-
/* @__PURE__ */
|
|
3588
|
+
/* @__PURE__ */ jsx39("div", { className: "body-1 mt-2 flex", children: editIndex !== null ? editIndex === index ? /* @__PURE__ */ jsxs33("div", { className: "flex", children: [
|
|
3589
|
+
/* @__PURE__ */ jsx39(
|
|
3161
3590
|
IconCheck3,
|
|
3162
3591
|
{
|
|
3163
3592
|
className: "cursor-pointer text-green-600",
|
|
3164
3593
|
onClick: () => handleConfirmEditIndicator(index)
|
|
3165
3594
|
}
|
|
3166
3595
|
),
|
|
3167
|
-
/* @__PURE__ */
|
|
3168
|
-
] }) : void 0 : /* @__PURE__ */
|
|
3169
|
-
/* @__PURE__ */
|
|
3596
|
+
/* @__PURE__ */ jsx39(IconX3, { className: "cursor-pointer text-red-600", onClick: handleCancelEditIndicator })
|
|
3597
|
+
] }) : void 0 : /* @__PURE__ */ jsx39(IconPencil2, { className: "cursor-pointer", onClick: () => handleEditIndicator(index) }) }),
|
|
3598
|
+
/* @__PURE__ */ jsx39("div", { className: "body-1 mt-2 cursor-pointer", children: /* @__PURE__ */ jsx39(IconTrash4, { onClick: () => handleDeleteIndicator(index) }) })
|
|
3170
3599
|
]
|
|
3171
3600
|
}
|
|
3172
3601
|
)) })
|
|
@@ -3176,7 +3605,7 @@ function Indicator({
|
|
|
3176
3605
|
// src/FilterPopUp/FilterPopUp.tsx
|
|
3177
3606
|
import { IconCheck as IconCheck4, IconFilter as IconFilter2, IconTrash as IconTrash5 } from "@tabler/icons-react";
|
|
3178
3607
|
import { useState as useState14 } from "react";
|
|
3179
|
-
import { jsx as
|
|
3608
|
+
import { jsx as jsx40, jsxs as jsxs34 } from "react/jsx-runtime";
|
|
3180
3609
|
var FilterPopUp = (filter) => {
|
|
3181
3610
|
const [isAction, setIsAction] = useState14(true);
|
|
3182
3611
|
const [filterArray, setFilterArray] = useState14([""]);
|
|
@@ -3186,20 +3615,20 @@ var FilterPopUp = (filter) => {
|
|
|
3186
3615
|
const handleSubmitFilter = () => {
|
|
3187
3616
|
filter.handleSearch(filterArray);
|
|
3188
3617
|
};
|
|
3189
|
-
return /* @__PURE__ */
|
|
3190
|
-
/* @__PURE__ */
|
|
3191
|
-
/* @__PURE__ */
|
|
3618
|
+
return /* @__PURE__ */ jsxs34("div", { className: "relative", children: [
|
|
3619
|
+
/* @__PURE__ */ jsxs34("button", { className: "flex px-2 py-1 rounded-lg border-1", onClick: () => setIsAction(!isAction), children: [
|
|
3620
|
+
/* @__PURE__ */ jsx40(IconFilter2, {}),
|
|
3192
3621
|
"filter"
|
|
3193
3622
|
] }),
|
|
3194
|
-
isAction ? /* @__PURE__ */
|
|
3195
|
-
/* @__PURE__ */
|
|
3196
|
-
/* @__PURE__ */
|
|
3197
|
-
/* @__PURE__ */
|
|
3198
|
-
/* @__PURE__ */
|
|
3623
|
+
isAction ? /* @__PURE__ */ jsxs34("div", { className: "absolute bg-white p-5 rounded-lg shadow-2xl w-[600px]", children: [
|
|
3624
|
+
/* @__PURE__ */ jsxs34("div", { className: "flex justify-end", children: [
|
|
3625
|
+
/* @__PURE__ */ jsxs34("div", { className: "flex justify-end text-nowrap gap-2", children: [
|
|
3626
|
+
/* @__PURE__ */ jsx40(GhostButton, { title: "\u0E43\u0E0A\u0E49\u0E1F\u0E34\u0E25\u0E40\u0E15\u0E2D\u0E23\u0E4C", onClick: handleSubmitFilter, iconLeft: /* @__PURE__ */ jsx40(IconCheck4, {}) }),
|
|
3627
|
+
/* @__PURE__ */ jsx40(GhostButton, { title: "\u0E25\u0E49\u0E32\u0E07\u0E17\u0E31\u0E49\u0E07\u0E2B\u0E21\u0E14", onClick: handleClearFilter, iconLeft: /* @__PURE__ */ jsx40(IconTrash5, {}) })
|
|
3199
3628
|
] }),
|
|
3200
3629
|
""
|
|
3201
3630
|
] }),
|
|
3202
|
-
/* @__PURE__ */
|
|
3631
|
+
/* @__PURE__ */ jsx40(
|
|
3203
3632
|
SelectCustom,
|
|
3204
3633
|
{
|
|
3205
3634
|
options: filter.selectionFilter,
|
|
@@ -3220,6 +3649,7 @@ export {
|
|
|
3220
3649
|
ColorPalettePickerBasic,
|
|
3221
3650
|
ColorPickerBasic,
|
|
3222
3651
|
DataTable,
|
|
3652
|
+
DatePickerBasic,
|
|
3223
3653
|
FileUploader,
|
|
3224
3654
|
FilterPopUp,
|
|
3225
3655
|
GhostButton,
|