yuyeon 0.0.39 → 0.0.41
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/yuyeon.js +1498 -1459
- package/dist/yuyeon.umd.cjs +4 -4
- package/lib/components/date-picker/YDateCalendar.mjs +12 -0
- package/lib/components/date-picker/YDateCalendar.mjs.map +1 -0
- package/lib/components/date-picker/YDatePicker.mjs +12 -0
- package/lib/components/date-picker/YDatePicker.mjs.map +1 -0
- package/lib/components/date-picker/index.mjs +2 -0
- package/lib/components/date-picker/index.mjs.map +1 -0
- package/lib/components/default-provider/YDefaultProvider.mjs +2 -0
- package/lib/components/default-provider/YDefaultProvider.mjs.map +1 -0
- package/lib/components/default-provider/index.mjs +2 -0
- package/lib/components/default-provider/index.mjs.map +1 -0
- package/lib/components/layer/YLayer.mjs +12 -3
- package/lib/components/layer/YLayer.mjs.map +1 -1
- package/lib/components/list/YList.mjs +6 -5
- package/lib/components/list/YList.mjs.map +1 -1
- package/lib/components/menu/YMenu.mjs +11 -2
- package/lib/components/menu/YMenu.mjs.map +1 -1
- package/lib/components/select/YSelect.mjs +35 -5
- package/lib/components/select/YSelect.mjs.map +1 -1
- package/lib/composables/date/index.mjs +2 -0
- package/lib/composables/date/index.mjs.map +1 -0
- package/lib/composables/date/types.mjs +2 -0
- package/lib/composables/date/types.mjs.map +1 -0
- package/lib/util/date/built-in.mjs +476 -0
- package/lib/util/date/built-in.mjs.map +1 -0
- package/lib/util/date/index.mjs +3 -0
- package/lib/util/date/index.mjs.map +1 -0
- package/lib/util/date/types.mjs +2 -0
- package/lib/util/date/types.mjs.map +1 -0
- package/package.json +1 -1
- package/types/components/dialog/YDialog.d.ts +4 -1
- package/types/components/layer/YLayer.d.ts +5 -2
- package/types/components/menu/YMenu.d.ts +6 -2
- package/types/components/select/YSelect.d.ts +3919 -0
- package/types/components/tooltip/YTooltip.d.ts +4 -1
|
@@ -0,0 +1,476 @@
|
|
|
1
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
2
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
3
|
+
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
4
|
+
const FIRST_DAY_INDEX = {
|
|
5
|
+
AD: 1,
|
|
6
|
+
AE: 6,
|
|
7
|
+
AF: 6,
|
|
8
|
+
AG: 0,
|
|
9
|
+
AI: 1,
|
|
10
|
+
AL: 1,
|
|
11
|
+
AM: 1,
|
|
12
|
+
AN: 1,
|
|
13
|
+
AR: 1,
|
|
14
|
+
AS: 0,
|
|
15
|
+
AT: 1,
|
|
16
|
+
AU: 1,
|
|
17
|
+
AX: 1,
|
|
18
|
+
AZ: 1,
|
|
19
|
+
BA: 1,
|
|
20
|
+
BD: 0,
|
|
21
|
+
BE: 1,
|
|
22
|
+
BG: 1,
|
|
23
|
+
BH: 6,
|
|
24
|
+
BM: 1,
|
|
25
|
+
BN: 1,
|
|
26
|
+
BR: 0,
|
|
27
|
+
BS: 0,
|
|
28
|
+
BT: 0,
|
|
29
|
+
BW: 0,
|
|
30
|
+
BY: 1,
|
|
31
|
+
BZ: 0,
|
|
32
|
+
CA: 0,
|
|
33
|
+
CH: 1,
|
|
34
|
+
CL: 1,
|
|
35
|
+
CM: 1,
|
|
36
|
+
CN: 1,
|
|
37
|
+
CO: 0,
|
|
38
|
+
CR: 1,
|
|
39
|
+
CY: 1,
|
|
40
|
+
CZ: 1,
|
|
41
|
+
DE: 1,
|
|
42
|
+
DJ: 6,
|
|
43
|
+
DK: 1,
|
|
44
|
+
DM: 0,
|
|
45
|
+
D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MZ: 0,
|
|
106
|
+
NI: 0,
|
|
107
|
+
NL: 1,
|
|
108
|
+
NO: 1,
|
|
109
|
+
NP: 0,
|
|
110
|
+
NZ: 1,
|
|
111
|
+
OM: 6,
|
|
112
|
+
PA: 0,
|
|
113
|
+
PE: 0,
|
|
114
|
+
PH: 0,
|
|
115
|
+
PK: 0,
|
|
116
|
+
PL: 1,
|
|
117
|
+
PR: 0,
|
|
118
|
+
PT: 0,
|
|
119
|
+
PY: 0,
|
|
120
|
+
QA: 6,
|
|
121
|
+
RE: 1,
|
|
122
|
+
RO: 1,
|
|
123
|
+
RS: 1,
|
|
124
|
+
RU: 1,
|
|
125
|
+
SA: 0,
|
|
126
|
+
SD: 6,
|
|
127
|
+
SE: 1,
|
|
128
|
+
SG: 0,
|
|
129
|
+
SI: 1,
|
|
130
|
+
SK: 1,
|
|
131
|
+
SM: 1,
|
|
132
|
+
SV: 0,
|
|
133
|
+
SY: 6,
|
|
134
|
+
TH: 0,
|
|
135
|
+
TJ: 1,
|
|
136
|
+
TM: 1,
|
|
137
|
+
TR: 1,
|
|
138
|
+
TT: 0,
|
|
139
|
+
TW: 0,
|
|
140
|
+
UA: 1,
|
|
141
|
+
UM: 0,
|
|
142
|
+
US: 0,
|
|
143
|
+
UY: 1,
|
|
144
|
+
UZ: 1,
|
|
145
|
+
VA: 1,
|
|
146
|
+
VE: 0,
|
|
147
|
+
VI: 0,
|
|
148
|
+
VN: 1,
|
|
149
|
+
WS: 0,
|
|
150
|
+
XK: 1,
|
|
151
|
+
YE: 0,
|
|
152
|
+
ZA: 0,
|
|
153
|
+
ZW: 0
|
|
154
|
+
};
|
|
155
|
+
export const ONE_DAY = 1000 * 60 * 60 * 24;
|
|
156
|
+
export const YYYY_MM_DD_REGEX = /^([12]\d{3}-([1-9]|0[1-9]|1[0-2])-([1-9]|0[1-9]|[12]\d|3[01]))$/;
|
|
157
|
+
export const FIRST_SUNDAY = new Date(1970, 0, 4);
|
|
158
|
+
export class DateUtil {
|
|
159
|
+
static date(value) {
|
|
160
|
+
if (value === null) return new Date();
|
|
161
|
+
if (value instanceof Date) {
|
|
162
|
+
return value;
|
|
163
|
+
}
|
|
164
|
+
let parsed;
|
|
165
|
+
if (typeof value === 'string') {
|
|
166
|
+
if (YYYY_MM_DD_REGEX.test(value)) {
|
|
167
|
+
return DateUtil.parseLocalDate(value);
|
|
168
|
+
} else {
|
|
169
|
+
parsed = Date.parse(value);
|
|
170
|
+
}
|
|
171
|
+
if (!isNaN(parsed)) {
|
|
172
|
+
return new Date(parsed);
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
return null;
|
|
176
|
+
}
|
|
177
|
+
static format(value, formatString, locale, formats) {
|
|
178
|
+
const neo = DateUtil.date(value) ?? new Date();
|
|
179
|
+
const formatFunction = formats?.[formatString];
|
|
180
|
+
if (typeof formatFunction === 'function') {
|
|
181
|
+
return formatFunction(neo, formatString, locale);
|
|
182
|
+
}
|
|
183
|
+
let options = {};
|
|
184
|
+
switch (formatString) {
|
|
185
|
+
case 'fullDateWithWeekday':
|
|
186
|
+
options = {
|
|
187
|
+
weekday: 'long',
|
|
188
|
+
day: 'numeric',
|
|
189
|
+
month: 'long',
|
|
190
|
+
year: 'numeric'
|
|
191
|
+
};
|
|
192
|
+
break;
|
|
193
|
+
case 'normalDateWithWeekday':
|
|
194
|
+
options = {
|
|
195
|
+
weekday: 'short',
|
|
196
|
+
day: 'numeric',
|
|
197
|
+
month: 'short'
|
|
198
|
+
};
|
|
199
|
+
break;
|
|
200
|
+
case 'keyboardDate':
|
|
201
|
+
options = {
|
|
202
|
+
day: '2-digit',
|
|
203
|
+
month: '2-digit',
|
|
204
|
+
year: 'numeric'
|
|
205
|
+
};
|
|
206
|
+
break;
|
|
207
|
+
case 'monthAndDate':
|
|
208
|
+
options = {
|
|
209
|
+
month: 'long',
|
|
210
|
+
day: 'numeric'
|
|
211
|
+
};
|
|
212
|
+
break;
|
|
213
|
+
case 'monthAndYear':
|
|
214
|
+
options = {
|
|
215
|
+
month: 'long',
|
|
216
|
+
year: 'numeric'
|
|
217
|
+
};
|
|
218
|
+
break;
|
|
219
|
+
case 'month':
|
|
220
|
+
options = {
|
|
221
|
+
month: 'long'
|
|
222
|
+
};
|
|
223
|
+
break;
|
|
224
|
+
case 'monthShort':
|
|
225
|
+
options = {
|
|
226
|
+
month: 'short'
|
|
227
|
+
};
|
|
228
|
+
break;
|
|
229
|
+
case 'dayOfMonth':
|
|
230
|
+
options = {
|
|
231
|
+
day: 'numeric'
|
|
232
|
+
};
|
|
233
|
+
break;
|
|
234
|
+
case 'shortDate':
|
|
235
|
+
options = {
|
|
236
|
+
year: '2-digit',
|
|
237
|
+
month: 'numeric',
|
|
238
|
+
day: 'numeric'
|
|
239
|
+
};
|
|
240
|
+
break;
|
|
241
|
+
case 'year':
|
|
242
|
+
options = {
|
|
243
|
+
year: 'numeric'
|
|
244
|
+
};
|
|
245
|
+
break;
|
|
246
|
+
default:
|
|
247
|
+
options = formatFunction ?? {
|
|
248
|
+
timeZone: 'UTC',
|
|
249
|
+
timeZoneName: 'short'
|
|
250
|
+
};
|
|
251
|
+
}
|
|
252
|
+
return new Intl.DateTimeFormat(locale, options).format(neo);
|
|
253
|
+
}
|
|
254
|
+
static parseLocalDate(value) {
|
|
255
|
+
const parts = value.split('-').map(Number);
|
|
256
|
+
return new Date(parts[0], parts[1] - 1, parts[2]);
|
|
257
|
+
}
|
|
258
|
+
static parseISO(value) {
|
|
259
|
+
const [year, month, day] = value.split('-').map(Number);
|
|
260
|
+
return new Date(year, month - 1, day);
|
|
261
|
+
}
|
|
262
|
+
static toISO(date) {
|
|
263
|
+
return date.toISOString().substring(0, 10);
|
|
264
|
+
}
|
|
265
|
+
static getWeekArray(date, locale) {
|
|
266
|
+
const weeks = [];
|
|
267
|
+
let currentWeek = [];
|
|
268
|
+
const firstDayOfMonth = DateUtil.startOfMonth(date);
|
|
269
|
+
const lastDayOfMonth = DateUtil.endOfMonth(date);
|
|
270
|
+
const firstDayWeekIndex = (firstDayOfMonth.getDay() - FIRST_DAY_INDEX[locale.slice(-2).toUpperCase()] + 7) % 7;
|
|
271
|
+
const lastDayWeekIndex = (lastDayOfMonth.getDay() - FIRST_DAY_INDEX[locale.slice(-2).toUpperCase()] + 7) % 7;
|
|
272
|
+
// prev month
|
|
273
|
+
for (let i = 0; i < firstDayWeekIndex; i++) {
|
|
274
|
+
const adjacentDay = new Date(firstDayOfMonth);
|
|
275
|
+
adjacentDay.setDate(adjacentDay.getDate() - (firstDayWeekIndex - i));
|
|
276
|
+
currentWeek.push(adjacentDay);
|
|
277
|
+
}
|
|
278
|
+
// this month
|
|
279
|
+
for (let i = 1; i <= lastDayOfMonth.getDate(); i++) {
|
|
280
|
+
currentWeek.push(new Date(date.getFullYear(), date.getMonth(), i));
|
|
281
|
+
// flush full week
|
|
282
|
+
if (currentWeek.length === 7) {
|
|
283
|
+
weeks.push(currentWeek);
|
|
284
|
+
currentWeek = [];
|
|
285
|
+
}
|
|
286
|
+
}
|
|
287
|
+
// next month
|
|
288
|
+
for (let i = 1; i < 7 - lastDayWeekIndex; i++) {
|
|
289
|
+
const adjacentDay = new Date(lastDayOfMonth);
|
|
290
|
+
adjacentDay.setDate(adjacentDay.getDate() + i);
|
|
291
|
+
currentWeek.push(adjacentDay);
|
|
292
|
+
}
|
|
293
|
+
if (currentWeek.length > 0) {
|
|
294
|
+
weeks.push(currentWeek);
|
|
295
|
+
}
|
|
296
|
+
return weeks;
|
|
297
|
+
}
|
|
298
|
+
static startOfMonth(date) {
|
|
299
|
+
return new Date(date.getFullYear(), date.getMonth(), 1);
|
|
300
|
+
}
|
|
301
|
+
static endOfMonth(date) {
|
|
302
|
+
return new Date(date.getFullYear(), date.getMonth() + 1, 0);
|
|
303
|
+
}
|
|
304
|
+
static startOfDay(date) {
|
|
305
|
+
return new Date(date.getFullYear(), date.getMonth(), date.getDate());
|
|
306
|
+
}
|
|
307
|
+
static startOfYear(date) {
|
|
308
|
+
return new Date(date.getFullYear(), 0, 1);
|
|
309
|
+
}
|
|
310
|
+
static endOfDay(date) {
|
|
311
|
+
return new Date(date.getFullYear(), date.getMonth(), date.getDate(), 23, 59, 59, 999);
|
|
312
|
+
}
|
|
313
|
+
static endOfYear(date) {
|
|
314
|
+
return new Date(date.getFullYear(), 11, 31);
|
|
315
|
+
}
|
|
316
|
+
static getMonth(date) {
|
|
317
|
+
return date.getMonth();
|
|
318
|
+
}
|
|
319
|
+
static getNextMonth(date) {
|
|
320
|
+
return new Date(date.getFullYear(), date.getMonth() + 1, 1);
|
|
321
|
+
}
|
|
322
|
+
static getWeekdays(locale) {
|
|
323
|
+
const sundayIndex = FIRST_DAY_INDEX[locale.slice(-2).toUpperCase()] ?? 0;
|
|
324
|
+
return [...Array(7).keys()].map(i => {
|
|
325
|
+
const weekday = new Date(FIRST_SUNDAY);
|
|
326
|
+
weekday.setDate(FIRST_SUNDAY.getDate() + sundayIndex + i);
|
|
327
|
+
return new Intl.DateTimeFormat(locale, {
|
|
328
|
+
weekday: 'narrow'
|
|
329
|
+
}).format(weekday);
|
|
330
|
+
});
|
|
331
|
+
}
|
|
332
|
+
static getYear(date) {
|
|
333
|
+
return date.getFullYear();
|
|
334
|
+
}
|
|
335
|
+
static isAfter(date, comparing) {
|
|
336
|
+
return date.getTime() > comparing.getTime();
|
|
337
|
+
}
|
|
338
|
+
static isBefore(date, comparing) {
|
|
339
|
+
return date.getTime() < comparing.getTime();
|
|
340
|
+
}
|
|
341
|
+
static isEqual(date, comparing) {
|
|
342
|
+
return date.getTime() === comparing.getTime();
|
|
343
|
+
}
|
|
344
|
+
static isSameDay(date, comparing) {
|
|
345
|
+
return date.getDate() === comparing.getDate() && date.getMonth() === comparing.getMonth() && date.getFullYear() === comparing.getFullYear();
|
|
346
|
+
}
|
|
347
|
+
static isSameMonth(date, comparing) {
|
|
348
|
+
return !!(date.getMonth() === comparing.getMonth() && date.getFullYear() && comparing.getFullYear());
|
|
349
|
+
}
|
|
350
|
+
static isValid(date) {
|
|
351
|
+
const d = new Date(date);
|
|
352
|
+
return d instanceof Date && !isNaN(d.getTime());
|
|
353
|
+
}
|
|
354
|
+
static isWithinRange(date, range) {
|
|
355
|
+
return DateUtil.isAfter(date, range[0]) && DateUtil.isBefore(date, range[1]);
|
|
356
|
+
}
|
|
357
|
+
static addDays(date, amount) {
|
|
358
|
+
const d = new Date(date);
|
|
359
|
+
d.setDate(d.getDate() + amount);
|
|
360
|
+
return d;
|
|
361
|
+
}
|
|
362
|
+
static addMonths(date, amount) {
|
|
363
|
+
const d = new Date(date);
|
|
364
|
+
d.setMonth(d.getMonth() + amount);
|
|
365
|
+
return d;
|
|
366
|
+
}
|
|
367
|
+
static getDiff(date, comparing, unit) {
|
|
368
|
+
const b = new Date(date);
|
|
369
|
+
const c = new Date(comparing);
|
|
370
|
+
if (unit === 'month') {
|
|
371
|
+
return b.getMonth() - c.getMonth() + (b.getFullYear() - c.getFullYear()) * 12;
|
|
372
|
+
}
|
|
373
|
+
return Math.floor(b.getTime() - c.getTime()) / ONE_DAY;
|
|
374
|
+
}
|
|
375
|
+
static setMonth(date, month) {
|
|
376
|
+
const d = new Date(date);
|
|
377
|
+
d.setMonth(month);
|
|
378
|
+
return d;
|
|
379
|
+
}
|
|
380
|
+
static setYear(date, year) {
|
|
381
|
+
const d = new Date(date);
|
|
382
|
+
d.setFullYear(year);
|
|
383
|
+
return d;
|
|
384
|
+
}
|
|
385
|
+
}
|
|
386
|
+
export class YuyeonDateAdapter {
|
|
387
|
+
constructor(locale) {
|
|
388
|
+
_defineProperty(this, "locale", 'ko-kr');
|
|
389
|
+
this.locale = locale;
|
|
390
|
+
}
|
|
391
|
+
getWeekArray(date) {
|
|
392
|
+
return DateUtil.getWeekArray(date, this.locale);
|
|
393
|
+
}
|
|
394
|
+
startOfMonth(date) {
|
|
395
|
+
return DateUtil.startOfMonth(date);
|
|
396
|
+
}
|
|
397
|
+
endOfMonth(date) {
|
|
398
|
+
return DateUtil.endOfMonth(date);
|
|
399
|
+
}
|
|
400
|
+
addDays(date, amount) {
|
|
401
|
+
return DateUtil.addDays(date, amount);
|
|
402
|
+
}
|
|
403
|
+
addMonths(date, amount) {
|
|
404
|
+
return DateUtil.addMonths(date, amount);
|
|
405
|
+
}
|
|
406
|
+
date(value) {
|
|
407
|
+
return DateUtil.date(value);
|
|
408
|
+
}
|
|
409
|
+
endOfDay(date) {
|
|
410
|
+
return DateUtil.endOfDay(date);
|
|
411
|
+
}
|
|
412
|
+
endOfYear(date) {
|
|
413
|
+
return DateUtil.endOfYear(date);
|
|
414
|
+
}
|
|
415
|
+
format(date, formatString) {
|
|
416
|
+
return DateUtil.format(date, formatString, this.locale, this.formats);
|
|
417
|
+
}
|
|
418
|
+
getDiff(date, comparing, unit) {
|
|
419
|
+
return DateUtil.getDiff(date, comparing, unit);
|
|
420
|
+
}
|
|
421
|
+
getMonth(date) {
|
|
422
|
+
return DateUtil.getMonth(date);
|
|
423
|
+
}
|
|
424
|
+
getNextMonth(date) {
|
|
425
|
+
return DateUtil.getNextMonth(date);
|
|
426
|
+
}
|
|
427
|
+
getWeekdays() {
|
|
428
|
+
return DateUtil.getWeekdays(this.locale);
|
|
429
|
+
}
|
|
430
|
+
getYear(date) {
|
|
431
|
+
return DateUtil.getYear(date);
|
|
432
|
+
}
|
|
433
|
+
isAfter(date, comparing) {
|
|
434
|
+
return DateUtil.isAfter(date, comparing);
|
|
435
|
+
}
|
|
436
|
+
isBefore(date, comparing) {
|
|
437
|
+
return DateUtil.isBefore(date, comparing);
|
|
438
|
+
}
|
|
439
|
+
isEqual(date, comparing) {
|
|
440
|
+
return DateUtil.isEqual(date, comparing);
|
|
441
|
+
}
|
|
442
|
+
isSameDay(date, comparing) {
|
|
443
|
+
return DateUtil.isSameDay(date, comparing);
|
|
444
|
+
}
|
|
445
|
+
isSameMonth(date, comparing) {
|
|
446
|
+
return DateUtil.isSameMonth(date, comparing);
|
|
447
|
+
}
|
|
448
|
+
isValid(date) {
|
|
449
|
+
return DateUtil.isValid(date);
|
|
450
|
+
}
|
|
451
|
+
isWithinRange(date, range) {
|
|
452
|
+
return DateUtil.isWithinRange(date, range);
|
|
453
|
+
}
|
|
454
|
+
parseISO(date) {
|
|
455
|
+
return DateUtil.parseISO(date);
|
|
456
|
+
}
|
|
457
|
+
setMonth(date, month) {
|
|
458
|
+
return DateUtil.setMonth(date, month);
|
|
459
|
+
}
|
|
460
|
+
setYear(date, year) {
|
|
461
|
+
return DateUtil.setYear(date, year);
|
|
462
|
+
}
|
|
463
|
+
startOfDay(date) {
|
|
464
|
+
return DateUtil.startOfDay(date);
|
|
465
|
+
}
|
|
466
|
+
startOfYear(date) {
|
|
467
|
+
return DateUtil.startOfYear(date);
|
|
468
|
+
}
|
|
469
|
+
toISO(date) {
|
|
470
|
+
return DateUtil.toISO(date);
|
|
471
|
+
}
|
|
472
|
+
toJsDate(date) {
|
|
473
|
+
return date;
|
|
474
|
+
}
|
|
475
|
+
}
|
|
476
|
+
//# sourceMappingURL=built-in.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"built-in.mjs","names":["FIRST_DAY_INDEX","AD","AE","AF","AG","AI","AL","AM","AN","AR","AS","AT","AU","AX","AZ","BA","BD","BE","BG","BH","BM","BN","BR","BS","BT","BW","BY","BZ","CA","CH","CL","CM","CN","CO","CR","CY","CZ","DE","DJ","DK","DM","DO","DZ","EC","EE","EG","ES","ET","FI","FJ","FO","FR","GB","GE","GF","GP","GR","GT","GU","HK","HN","HR","HU","ID","IE","IL","IN","IQ","IR","IS","IT","JM","JO","JP","KE","KG","KH","KR","KW","KZ","LA","LB","LI","LK","LT","LU","LV","LY","MC","MD","ME","MH","MK","MM","MN","MO","MQ","MT","MV","MX","MY","MZ","NI","NL","NO","NP","NZ","OM","PA","PE","PH","PK","PL","PR","PT","PY","QA","RE","RO","RS","RU","SA","SD","SE","SG","SI","SK","SM","SV","SY","TH","TJ","TM","TR","TT","TW","UA","UM","US","UY","UZ","VA","VE","VI","VN","WS","XK","YE","ZA","ZW","ONE_DAY","YYYY_MM_DD_REGEX","FIRST_SUNDAY","Date","DateUtil","date","value","parsed","test","parseLocalDate","parse","isNaN","format","formatString","locale","formats","neo","formatFunction","options","weekday","day","month","year","timeZone","timeZoneName","Intl","DateTimeFormat","parts","split","map","Number","parseISO","toISO","toISOString","substring","getWeekArray","weeks","currentWeek","firstDayOfMonth","startOfMonth","lastDayOfMonth","endOfMonth","firstDayWeekIndex","getDay","slice","toUpperCase","lastDayWeekIndex","i","adjacentDay","setDate","getDate","push","getFullYear","getMonth","length","startOfDay","startOfYear","endOfDay","endOfYear","getNextMonth","getWeekdays","sundayIndex","Array","keys","getYear","isAfter","comparing","getTime","isBefore","isEqual","isSameDay","isSameMonth","isValid","d","isWithinRange","range","addDays","amount","addMonths","setMonth","getDiff","unit","b","c","Math","floor","setYear","setFullYear","YuyeonDateAdapter","constructor","_defineProperty","toJsDate"],"sources":["../../../src/util/date/built-in.ts"],"sourcesContent":["import { DateAdapter, DateFormatOptions } from './types';\n\nconst FIRST_DAY_INDEX: Record<string, number> = {\n AD: 1,\n AE: 6,\n AF: 6,\n AG: 0,\n AI: 1,\n AL: 1,\n AM: 1,\n AN: 1,\n AR: 1,\n AS: 0,\n AT: 1,\n AU: 1,\n AX: 1,\n AZ: 1,\n BA: 1,\n BD: 0,\n BE: 1,\n BG: 1,\n BH: 6,\n BM: 1,\n BN: 1,\n BR: 0,\n BS: 0,\n BT: 0,\n BW: 0,\n BY: 1,\n BZ: 0,\n CA: 0,\n CH: 1,\n CL: 1,\n CM: 1,\n CN: 1,\n CO: 0,\n CR: 1,\n CY: 1,\n CZ: 1,\n DE: 1,\n DJ: 6,\n DK: 1,\n DM: 0,\n DO: 0,\n DZ: 6,\n EC: 1,\n EE: 1,\n EG: 6,\n ES: 1,\n ET: 0,\n FI: 1,\n FJ: 1,\n FO: 1,\n FR: 1,\n GB: 1,\n GE: 1,\n GF: 1,\n GP: 1,\n GR: 1,\n GT: 0,\n GU: 0,\n HK: 0,\n HN: 0,\n HR: 1,\n HU: 1,\n ID: 0,\n IE: 1,\n IL: 0,\n IN: 0,\n IQ: 6,\n IR: 6,\n IS: 1,\n IT: 1,\n JM: 0,\n JO: 6,\n JP: 0,\n KE: 0,\n KG: 1,\n KH: 0,\n KR: 0,\n KW: 6,\n KZ: 1,\n LA: 0,\n LB: 1,\n LI: 1,\n LK: 1,\n LT: 1,\n LU: 1,\n LV: 1,\n LY: 6,\n MC: 1,\n MD: 1,\n ME: 1,\n MH: 0,\n MK: 1,\n MM: 0,\n MN: 1,\n MO: 0,\n MQ: 1,\n MT: 0,\n MV: 5,\n MX: 0,\n MY: 1,\n MZ: 0,\n NI: 0,\n NL: 1,\n NO: 1,\n NP: 0,\n NZ: 1,\n OM: 6,\n PA: 0,\n PE: 0,\n PH: 0,\n PK: 0,\n PL: 1,\n PR: 0,\n PT: 0,\n PY: 0,\n QA: 6,\n RE: 1,\n RO: 1,\n RS: 1,\n RU: 1,\n SA: 0,\n SD: 6,\n SE: 1,\n SG: 0,\n SI: 1,\n SK: 1,\n SM: 1,\n SV: 0,\n SY: 6,\n TH: 0,\n TJ: 1,\n TM: 1,\n TR: 1,\n TT: 0,\n TW: 0,\n UA: 1,\n UM: 0,\n US: 0,\n UY: 1,\n UZ: 1,\n VA: 1,\n VE: 0,\n VI: 0,\n VN: 1,\n WS: 0,\n XK: 1,\n YE: 0,\n ZA: 0,\n ZW: 0,\n};\n\nexport const ONE_DAY = 1000 * 60 * 60 * 24;\nexport const YYYY_MM_DD_REGEX =\n /^([12]\\d{3}-([1-9]|0[1-9]|1[0-2])-([1-9]|0[1-9]|[12]\\d|3[01]))$/;\nexport const FIRST_SUNDAY = new Date(1970, 0, 4);\n\nexport class DateUtil {\n static date(value?: any): Date | null {\n if (value === null) return new Date();\n if (value instanceof Date) {\n return value;\n }\n let parsed;\n if (typeof value === 'string') {\n if (YYYY_MM_DD_REGEX.test(value)) {\n return DateUtil.parseLocalDate(value);\n } else {\n parsed = Date.parse(value);\n }\n\n if (!isNaN(parsed)) {\n return new Date(parsed);\n }\n }\n return null;\n }\n\n static format(\n value: Date,\n formatString: string,\n locale: string,\n formats?: Record<string, DateFormatOptions>,\n ): string {\n const neo = DateUtil.date(value) ?? new Date();\n const formatFunction = formats?.[formatString];\n\n if (typeof formatFunction === 'function') {\n return formatFunction(neo, formatString, locale);\n }\n\n let options: Intl.DateTimeFormatOptions = {};\n switch (formatString) {\n case 'fullDateWithWeekday':\n options = {\n weekday: 'long',\n day: 'numeric',\n month: 'long',\n year: 'numeric',\n };\n break;\n case 'normalDateWithWeekday':\n options = { weekday: 'short', day: 'numeric', month: 'short' };\n break;\n case 'keyboardDate':\n options = { day: '2-digit', month: '2-digit', year: 'numeric' };\n break;\n case 'monthAndDate':\n options = { month: 'long', day: 'numeric' };\n break;\n case 'monthAndYear':\n options = { month: 'long', year: 'numeric' };\n break;\n case 'month':\n options = { month: 'long' };\n break;\n case 'monthShort':\n options = { month: 'short' };\n break;\n case 'dayOfMonth':\n options = { day: 'numeric' };\n break;\n case 'shortDate':\n options = { year: '2-digit', month: 'numeric', day: 'numeric' };\n break;\n case 'year':\n options = { year: 'numeric' };\n break;\n default:\n options = formatFunction ?? { timeZone: 'UTC', timeZoneName: 'short' };\n }\n\n return new Intl.DateTimeFormat(locale, options).format(neo);\n }\n\n static parseLocalDate(value: string) {\n const parts = value.split('-').map(Number);\n return new Date(parts[0], parts[1] - 1, parts[2]);\n }\n\n static parseISO(value: string): Date {\n const [year, month, day] = value.split('-').map(Number);\n return new Date(year, month - 1, day);\n }\n\n static toISO(date: Date): string {\n return date.toISOString().substring(0, 10);\n }\n\n static getWeekArray(date: Date, locale: string) {\n const weeks = [];\n let currentWeek = [];\n const firstDayOfMonth = DateUtil.startOfMonth(date);\n const lastDayOfMonth = DateUtil.endOfMonth(date);\n const firstDayWeekIndex =\n (firstDayOfMonth.getDay() -\n FIRST_DAY_INDEX[locale.slice(-2).toUpperCase()] +\n 7) %\n 7;\n const lastDayWeekIndex =\n (lastDayOfMonth.getDay() -\n FIRST_DAY_INDEX[locale.slice(-2).toUpperCase()] +\n 7) %\n 7;\n // prev month\n for (let i = 0; i < firstDayWeekIndex; i++) {\n const adjacentDay = new Date(firstDayOfMonth);\n adjacentDay.setDate(adjacentDay.getDate() - (firstDayWeekIndex - i));\n currentWeek.push(adjacentDay);\n }\n // this month\n for (let i = 1; i <= lastDayOfMonth.getDate(); i++) {\n currentWeek.push(new Date(date.getFullYear(), date.getMonth(), i));\n // flush full week\n if (currentWeek.length === 7) {\n weeks.push(currentWeek);\n currentWeek = [];\n }\n }\n // next month\n for (let i = 1; i < 7 - lastDayWeekIndex; i++) {\n const adjacentDay = new Date(lastDayOfMonth);\n adjacentDay.setDate(adjacentDay.getDate() + i);\n currentWeek.push(adjacentDay);\n }\n\n if (currentWeek.length > 0) {\n weeks.push(currentWeek);\n }\n\n return weeks;\n }\n\n static startOfMonth(date: Date) {\n return new Date(date.getFullYear(), date.getMonth(), 1);\n }\n\n static endOfMonth(date: Date) {\n return new Date(date.getFullYear(), date.getMonth() + 1, 0);\n }\n\n static startOfDay(date: Date) {\n return new Date(date.getFullYear(), date.getMonth(), date.getDate());\n }\n\n static startOfYear(date: Date) {\n return new Date(date.getFullYear(), 0, 1);\n }\n\n static endOfDay(date: Date) {\n return new Date(\n date.getFullYear(),\n date.getMonth(),\n date.getDate(),\n 23,\n 59,\n 59,\n 999,\n );\n }\n\n static endOfYear(date: Date) {\n return new Date(date.getFullYear(), 11, 31);\n }\n\n static getMonth(date: Date): number {\n return date.getMonth();\n }\n\n static getNextMonth(date: Date) {\n return new Date(date.getFullYear(), date.getMonth() + 1, 1);\n }\n\n static getWeekdays(locale: string) {\n const sundayIndex = FIRST_DAY_INDEX[locale.slice(-2).toUpperCase()] ?? 0;\n return [...Array(7).keys()].map((i) => {\n const weekday = new Date(FIRST_SUNDAY);\n weekday.setDate(FIRST_SUNDAY.getDate() + sundayIndex + i);\n return new Intl.DateTimeFormat(locale, { weekday: 'narrow' }).format(\n weekday,\n );\n });\n }\n\n static getYear(date: Date) {\n return date.getFullYear();\n }\n\n static isAfter(date: Date, comparing: Date): boolean {\n return date.getTime() > comparing.getTime();\n }\n\n static isBefore(date: Date, comparing: Date): boolean {\n return date.getTime() < comparing.getTime();\n }\n\n static isEqual(date: Date, comparing: Date): boolean {\n return date.getTime() === comparing.getTime();\n }\n\n static isSameDay(date: Date, comparing: Date): boolean {\n return (\n date.getDate() === comparing.getDate() &&\n date.getMonth() === comparing.getMonth() &&\n date.getFullYear() === comparing.getFullYear()\n );\n }\n\n static isSameMonth(date: Date, comparing: Date): boolean {\n return !!(\n date.getMonth() === comparing.getMonth() &&\n date.getFullYear() &&\n comparing.getFullYear()\n );\n }\n\n static isValid(date: any): boolean {\n const d = new Date(date);\n return d instanceof Date && !isNaN(d.getTime());\n }\n\n static isWithinRange(date: Date, range: [Date, Date]): boolean {\n return (\n DateUtil.isAfter(date, range[0]) && DateUtil.isBefore(date, range[1])\n );\n }\n\n static addDays(date: Date, amount: number) {\n const d = new Date(date);\n d.setDate(d.getDate() + amount);\n return d;\n }\n\n static addMonths(date: Date, amount: number) {\n const d = new Date(date);\n d.setMonth(d.getMonth() + amount);\n return d;\n }\n\n static getDiff(\n date: Date,\n comparing: string | Date,\n unit?: 'month' | string,\n ): number {\n const b = new Date(date);\n const c = new Date(comparing);\n\n if (unit === 'month') {\n return (\n b.getMonth() - c.getMonth() + (b.getFullYear() - c.getFullYear()) * 12\n );\n }\n\n return Math.floor(b.getTime() - c.getTime()) / ONE_DAY;\n }\n\n static setMonth(date: Date, month: number) {\n const d = new Date(date);\n d.setMonth(month);\n return d;\n }\n\n static setYear(date: Date, year: number) {\n const d = new Date(date);\n d.setFullYear(year);\n return d;\n }\n}\n\nexport class YuyeonDateAdapter implements DateAdapter<Date> {\n public locale = 'ko-kr';\n\n public formats?: Record<string, DateFormatOptions>;\n\n constructor(locale: string) {\n this.locale = locale;\n }\n\n public getWeekArray(date: Date) {\n return DateUtil.getWeekArray(date, this.locale);\n }\n\n public startOfMonth(date: Date) {\n return DateUtil.startOfMonth(date);\n }\n\n public endOfMonth(date: Date) {\n return DateUtil.endOfMonth(date);\n }\n\n public addDays(date: Date, amount: number): Date {\n return DateUtil.addDays(date, amount);\n }\n\n public addMonths(date: Date, amount: number): Date {\n return DateUtil.addMonths(date, amount);\n }\n\n public date(value?: any): Date | null {\n return DateUtil.date(value);\n }\n\n public endOfDay(date: Date): Date {\n return DateUtil.endOfDay(date);\n }\n\n public endOfYear(date: Date): Date {\n return DateUtil.endOfYear(date);\n }\n\n public format(date: Date, formatString: string): string {\n return DateUtil.format(date, formatString, this.locale, this.formats);\n }\n\n public getDiff(date: Date, comparing: string | Date, unit?: string): number {\n return DateUtil.getDiff(date, comparing, unit);\n }\n\n public getMonth(date: Date): number {\n return DateUtil.getMonth(date);\n }\n\n public getNextMonth(date: Date): Date {\n return DateUtil.getNextMonth(date);\n }\n\n public getWeekdays(): string[] {\n return DateUtil.getWeekdays(this.locale);\n }\n\n public getYear(date: Date): number {\n return DateUtil.getYear(date);\n }\n\n public isAfter(date: Date, comparing: Date): boolean {\n return DateUtil.isAfter(date, comparing);\n }\n\n public isBefore(date: Date, comparing: Date): boolean {\n return DateUtil.isBefore(date, comparing);\n }\n\n public isEqual(date: Date, comparing: Date): boolean {\n return DateUtil.isEqual(date, comparing);\n }\n\n public isSameDay(date: Date, comparing: Date): boolean {\n return DateUtil.isSameDay(date, comparing);\n }\n\n public isSameMonth(date: Date, comparing: Date): boolean {\n return DateUtil.isSameMonth(date, comparing);\n }\n\n public isValid(date: any): boolean {\n return DateUtil.isValid(date);\n }\n\n public isWithinRange(date: Date, range: [Date, Date]): boolean {\n return DateUtil.isWithinRange(date, range);\n }\n\n public parseISO(date: string): Date {\n return DateUtil.parseISO(date);\n }\n\n public setMonth(date: Date, month: number): Date {\n return DateUtil.setMonth(date, month);\n }\n\n public setYear(date: Date, year: number): Date {\n return DateUtil.setYear(date, year);\n }\n\n public startOfDay(date: Date): Date {\n return DateUtil.startOfDay(date);\n }\n\n public startOfYear(date: Date): Date {\n return DateUtil.startOfYear(date);\n }\n\n public toISO(date: Date): string {\n return DateUtil.toISO(date);\n }\n\n public toJsDate(date: Date): Date {\n return date;\n }\n}\n"],"mappings":";;;AAEA,MAAMA,eAAuC,GAAG;EAC9CC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CAAC;EACLC,EAAE,EAAE,CA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AK,CAAC;EAC5C;EAEO5C,QAAQA,CAAC1B,IAAY,EAAQ;IAClC,OAAOD,QAAQ,CAAC2B,QAAQ,CAAC1B,IAAI,CAAC;EAChC;EAEO0E,QAAQA,CAAC1E,IAAU,EAAEgB,KAAa,EAAQ;IAC/C,OAAOjB,QAAQ,CAAC2E,QAAQ,CAAC1E,IAAI,EAAEgB,KAAK,CAAC;EACvC;EAEOiE,OAAOA,CAACjF,IAAU,EAAEiB,IAAY,EAAQ;IAC7C,OAAOlB,QAAQ,CAACkF,OAAO,CAACjF,IAAI,EAAEiB,IAAI,CAAC;EACrC;EAEOiC,UAAUA,CAAClD,IAAU,EAAQ;IAClC,OAAOD,QAAQ,CAACmD,UAAU,CAAClD,IAAI,CAAC;EAClC;EAEOmD,WAAWA,CAACnD,IAAU,EAAQ;IACnC,OAAOD,QAAQ,CAACoD,WAAW,CAACnD,IAAI,CAAC;EACnC;EAEO2B,KAAKA,CAAC3B,IAAU,EAAU;IAC/B,OAAOD,QAAQ,CAAC4B,KAAK,CAAC3B,IAAI,CAAC;EAC7B;EAEOsF,QAAQA,CAACtF,IAAU,EAAQ;IAChC,OAAOA,IAAI;EACb;AACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","names":["createDateAdapter"],"sources":["../../../src/util/date/index.ts"],"sourcesContent":["export * from './built-in';\n\nexport function createDateAdapter() {\n\n}\n"],"mappings":";AAEA,OAAO,SAASA,iBAAiBA,CAAA,EAAG,CAEpC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.mjs","names":[],"sources":["../../../src/util/date/types.ts"],"sourcesContent":["export interface DateAdapter<T = unknown> {\r\n date (value?: any): T | null\r\n format (date: T, formatString: string): string\r\n toJsDate (value: T): Date\r\n parseISO (date: string): T\r\n toISO (date: T): string\r\n\r\n startOfDay (date: T): T\r\n endOfDay (date: T): T\r\n startOfMonth (date: T): T\r\n endOfMonth (date: T): T\r\n startOfYear (date: T): T\r\n endOfYear (date: T): T\r\n\r\n isBefore (date: T, comparing: T): boolean\r\n isAfter (date: T, comparing: T): boolean\r\n isEqual (date: T, comparing: T): boolean\r\n isSameDay (date: T, comparing: T): boolean\r\n isSameMonth (date: T, comparing: T): boolean\r\n isValid (date: any): boolean\r\n isWithinRange (date: T, range: [T, T]): boolean\r\n\r\n addDays (date: T, amount: number): T\r\n addMonths (date: T, amount: number): T\r\n\r\n getYear (date: T): number\r\n setYear (date: T, year: number): T\r\n getDiff (date: T, comparing: T | string, unit?: string): number\r\n getWeekArray (date: T): T[][]\r\n getWeekdays (): string[]\r\n getMonth (date: T): number\r\n setMonth (date: T, month: number): T\r\n getNextMonth (date: T): T\r\n}\r\n\r\nexport type DateFormatOptions = Intl.DateTimeFormatOptions | ((date: Date, formatString: string, locale: string) => string);\r\n"],"mappings":""}
|
package/package.json
CHANGED
|
@@ -1786,7 +1786,10 @@ export declare const YDialog: import("vue").DefineComponent<{
|
|
|
1786
1786
|
transition: string | (import("vue").TransitionProps & {
|
|
1787
1787
|
is?: import("vue").Component | undefined;
|
|
1788
1788
|
});
|
|
1789
|
-
}, {
|
|
1789
|
+
}, import("vue").SlotsType<{
|
|
1790
|
+
base: any;
|
|
1791
|
+
default: any;
|
|
1792
|
+
}>> | undefined>;
|
|
1790
1793
|
classes: import("vue").ComputedRef<{
|
|
1791
1794
|
'y-dialog': boolean;
|
|
1792
1795
|
'y-dialog--maximized': boolean | undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { CSSProperties, PropType,
|
|
1
|
+
import type { CSSProperties, ComponentInternalInstance, PropType, SlotsType } from 'vue';
|
|
2
2
|
export declare const pressYLayerProps: <Defaults extends {
|
|
3
3
|
minWidth?: unknown;
|
|
4
4
|
width?: unknown;
|
|
@@ -2004,5 +2004,8 @@ export declare const YLayer: import("vue").DefineComponent<{
|
|
|
2004
2004
|
transition: string | (import("vue").TransitionProps & {
|
|
2005
2005
|
is?: import("vue").Component | undefined;
|
|
2006
2006
|
});
|
|
2007
|
-
}, {
|
|
2007
|
+
}, SlotsType<{
|
|
2008
|
+
base: any;
|
|
2009
|
+
default: any;
|
|
2010
|
+
}>>;
|
|
2008
2011
|
export type YLayer = InstanceType<typeof YLayer>;
|
|
@@ -198,7 +198,7 @@ export declare const YMenu: import("vue").DefineComponent<{
|
|
|
198
198
|
default: boolean;
|
|
199
199
|
};
|
|
200
200
|
}, {
|
|
201
|
-
|
|
201
|
+
layer$: import("vue").Ref<import("vue").DefineComponent<{
|
|
202
202
|
minWidth: PropType<string | number>;
|
|
203
203
|
width: PropType<string | number>;
|
|
204
204
|
maxWidth: PropType<string | number>;
|
|
@@ -1960,7 +1960,11 @@ export declare const YMenu: import("vue").DefineComponent<{
|
|
|
1960
1960
|
transition: string | (import("vue").TransitionProps & {
|
|
1961
1961
|
is?: import("vue").Component | undefined;
|
|
1962
1962
|
});
|
|
1963
|
-
}, {
|
|
1963
|
+
}, import("vue").SlotsType<{
|
|
1964
|
+
base: any;
|
|
1965
|
+
default: any;
|
|
1966
|
+
}>> | undefined>;
|
|
1967
|
+
baseEl: import("vue").ComputedRef<any>;
|
|
1964
1968
|
classes: import("vue").ComputedRef<{
|
|
1965
1969
|
'y-menu': boolean;
|
|
1966
1970
|
}>;
|