@esic-lab/data-core-ui 0.0.24 → 0.0.26
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.css +0 -7
- package/dist/index.d.mts +97 -526
- package/dist/index.d.ts +97 -526
- package/dist/index.js +508 -557
- package/dist/index.mjs +488 -538
- package/package.json +2 -1
package/dist/index.d.mts
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
/// <reference path="../node_modules/dayjs/locale/index.d.ts" />
|
|
2
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
2
|
import react, { ReactNode } from 'react';
|
|
4
3
|
import { ColumnsType } from 'antd/es/table';
|
|
5
4
|
import { EventSourceInput } from '@fullcalendar/core';
|
|
5
|
+
import { InputNumberProps, SelectProps } from 'antd';
|
|
6
6
|
import { Color } from 'antd/es/color-picker';
|
|
7
|
-
import { SelectProps } from 'antd';
|
|
8
7
|
import { MessageInstance } from 'antd/es/message/interface';
|
|
9
8
|
import { ItemType } from 'antd/es/breadcrumb/Breadcrumb';
|
|
10
9
|
|
|
@@ -176,19 +175,17 @@ interface InputFieldProps {
|
|
|
176
175
|
value: string | undefined;
|
|
177
176
|
onChange: (value: string | undefined) => void;
|
|
178
177
|
placeholder?: string;
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
bottomText?: string;
|
|
178
|
+
label?: string;
|
|
179
|
+
required?: boolean;
|
|
182
180
|
disabled?: boolean;
|
|
183
|
-
|
|
184
|
-
errorMessage?: string;
|
|
181
|
+
error?: string;
|
|
185
182
|
addonBefore?: ReactNode;
|
|
186
183
|
addonAfter?: ReactNode;
|
|
187
184
|
defaultValue?: string;
|
|
188
185
|
className?: string;
|
|
189
186
|
onClear?: () => void;
|
|
190
187
|
}
|
|
191
|
-
declare function InputField({ value, onChange, placeholder,
|
|
188
|
+
declare function InputField({ value, onChange, placeholder, label, required, disabled, error, addonBefore, addonAfter, defaultValue, className, onClear }: InputFieldProps): react_jsx_runtime.JSX.Element;
|
|
192
189
|
|
|
193
190
|
interface TextAreaProps {
|
|
194
191
|
label?: string;
|
|
@@ -205,530 +202,115 @@ interface TextAreaProps {
|
|
|
205
202
|
}
|
|
206
203
|
declare function TextAreaInput({ label, height, placeholder, onChange, value, maxLength, resizable, showCount, required, error, disabled, }: TextAreaProps): react_jsx_runtime.JSX.Element;
|
|
207
204
|
|
|
205
|
+
interface InputFieldNumberProps {
|
|
206
|
+
value: number | string | null;
|
|
207
|
+
onChange: (value: number | string | null) => void;
|
|
208
|
+
placeholder?: string;
|
|
209
|
+
title?: string;
|
|
210
|
+
required?: boolean;
|
|
211
|
+
disabled?: boolean;
|
|
212
|
+
error?: string;
|
|
213
|
+
addonBefore?: React.ReactNode;
|
|
214
|
+
addonAfter?: React.ReactNode;
|
|
215
|
+
defaultValue?: number;
|
|
216
|
+
className?: string;
|
|
217
|
+
max?: number;
|
|
218
|
+
min?: number;
|
|
219
|
+
controls?: boolean | {
|
|
220
|
+
upIcon?: React.ReactNode;
|
|
221
|
+
downIcon?: React.ReactNode;
|
|
222
|
+
};
|
|
223
|
+
size?: "large" | "middle" | "small";
|
|
224
|
+
changeOnWheel?: boolean;
|
|
225
|
+
formatter?: InputNumberProps["formatter"];
|
|
226
|
+
parser?: InputNumberProps["parser"];
|
|
227
|
+
}
|
|
228
|
+
declare function InputFieldNumber({ value, onChange, placeholder, title, required, disabled, error, addonBefore, addonAfter, defaultValue, className, max, min, controls, size, changeOnWheel, formatter, parser, }: InputFieldNumberProps): react_jsx_runtime.JSX.Element;
|
|
229
|
+
|
|
208
230
|
interface ColorPickerProps {
|
|
209
231
|
value: string | null;
|
|
210
232
|
onChange?: (color: Color, hex: string) => void;
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
showError?: boolean;
|
|
215
|
-
errorMessage?: string;
|
|
233
|
+
required?: boolean;
|
|
234
|
+
label?: string;
|
|
235
|
+
error?: string;
|
|
216
236
|
disabled?: boolean;
|
|
217
237
|
allowClear?: boolean;
|
|
218
238
|
defaultFormat?: "hex" | "rgb" | "hsb";
|
|
219
239
|
className?: string;
|
|
220
240
|
placeholder?: string;
|
|
221
241
|
}
|
|
222
|
-
declare function ColorPickerBasic({ value, onChange,
|
|
223
|
-
|
|
224
|
-
declare function dayjs (date?: dayjs.ConfigType): dayjs.Dayjs
|
|
225
|
-
|
|
226
|
-
declare function dayjs (date?: dayjs.ConfigType, format?: dayjs.OptionType, strict?: boolean): dayjs.Dayjs
|
|
227
|
-
|
|
228
|
-
declare function dayjs (date?: dayjs.ConfigType, format?: dayjs.OptionType, locale?: string, strict?: boolean): dayjs.Dayjs
|
|
229
|
-
|
|
230
|
-
declare namespace dayjs {
|
|
231
|
-
interface ConfigTypeMap {
|
|
232
|
-
default: string | number | Date | Dayjs | null | undefined
|
|
233
|
-
}
|
|
234
|
-
|
|
235
|
-
export type ConfigType = ConfigTypeMap[keyof ConfigTypeMap]
|
|
236
|
-
|
|
237
|
-
export interface FormatObject { locale?: string, format?: string, utc?: boolean }
|
|
238
|
-
|
|
239
|
-
export type OptionType = FormatObject | string | string[]
|
|
240
|
-
|
|
241
|
-
export type UnitTypeShort = 'd' | 'D' | 'M' | 'y' | 'h' | 'm' | 's' | 'ms'
|
|
242
|
-
|
|
243
|
-
export type UnitTypeLong = 'millisecond' | 'second' | 'minute' | 'hour' | 'day' | 'month' | 'year' | 'date'
|
|
244
|
-
|
|
245
|
-
export type UnitTypeLongPlural = 'milliseconds' | 'seconds' | 'minutes' | 'hours' | 'days' | 'months' | 'years' | 'dates'
|
|
246
|
-
|
|
247
|
-
export type UnitType = UnitTypeLong | UnitTypeLongPlural | UnitTypeShort;
|
|
248
|
-
|
|
249
|
-
export type OpUnitType = UnitType | "week" | "weeks" | 'w';
|
|
250
|
-
export type QUnitType = UnitType | "quarter" | "quarters" | 'Q';
|
|
251
|
-
export type ManipulateType = Exclude<OpUnitType, 'date' | 'dates'>;
|
|
252
|
-
class Dayjs {
|
|
253
|
-
constructor (config?: ConfigType)
|
|
254
|
-
/**
|
|
255
|
-
* All Day.js objects are immutable. Still, `dayjs#clone` can create a clone of the current object if you need one.
|
|
256
|
-
* ```
|
|
257
|
-
* dayjs().clone()// => Dayjs
|
|
258
|
-
* dayjs(dayjs('2019-01-25')) // passing a Dayjs object to a constructor will also clone it
|
|
259
|
-
* ```
|
|
260
|
-
* Docs: https://day.js.org/docs/en/parse/dayjs-clone
|
|
261
|
-
*/
|
|
262
|
-
clone(): Dayjs
|
|
263
|
-
/**
|
|
264
|
-
* This returns a `boolean` indicating whether the Day.js object contains a valid date or not.
|
|
265
|
-
* ```
|
|
266
|
-
* dayjs().isValid()// => boolean
|
|
267
|
-
* ```
|
|
268
|
-
* Docs: https://day.js.org/docs/en/parse/is-valid
|
|
269
|
-
*/
|
|
270
|
-
isValid(): boolean
|
|
271
|
-
/**
|
|
272
|
-
* Get the year.
|
|
273
|
-
* ```
|
|
274
|
-
* dayjs().year()// => 2020
|
|
275
|
-
* ```
|
|
276
|
-
* Docs: https://day.js.org/docs/en/get-set/year
|
|
277
|
-
*/
|
|
278
|
-
year(): number
|
|
279
|
-
/**
|
|
280
|
-
* Set the year.
|
|
281
|
-
* ```
|
|
282
|
-
* dayjs().year(2000)// => Dayjs
|
|
283
|
-
* ```
|
|
284
|
-
* Docs: https://day.js.org/docs/en/get-set/year
|
|
285
|
-
*/
|
|
286
|
-
year(value: number): Dayjs
|
|
287
|
-
/**
|
|
288
|
-
* Get the month.
|
|
289
|
-
*
|
|
290
|
-
* Months are zero indexed, so January is month 0.
|
|
291
|
-
* ```
|
|
292
|
-
* dayjs().month()// => 0-11
|
|
293
|
-
* ```
|
|
294
|
-
* Docs: https://day.js.org/docs/en/get-set/month
|
|
295
|
-
*/
|
|
296
|
-
month(): number
|
|
297
|
-
/**
|
|
298
|
-
* Set the month.
|
|
299
|
-
*
|
|
300
|
-
* Months are zero indexed, so January is month 0.
|
|
301
|
-
*
|
|
302
|
-
* Accepts numbers from 0 to 11. If the range is exceeded, it will bubble up to the next year.
|
|
303
|
-
* ```
|
|
304
|
-
* dayjs().month(0)// => Dayjs
|
|
305
|
-
* ```
|
|
306
|
-
* Docs: https://day.js.org/docs/en/get-set/month
|
|
307
|
-
*/
|
|
308
|
-
month(value: number): Dayjs
|
|
309
|
-
/**
|
|
310
|
-
* Get the date of the month.
|
|
311
|
-
* ```
|
|
312
|
-
* dayjs().date()// => 1-31
|
|
313
|
-
* ```
|
|
314
|
-
* Docs: https://day.js.org/docs/en/get-set/date
|
|
315
|
-
*/
|
|
316
|
-
date(): number
|
|
317
|
-
/**
|
|
318
|
-
* Set the date of the month.
|
|
319
|
-
*
|
|
320
|
-
* Accepts numbers from 1 to 31. If the range is exceeded, it will bubble up to the next months.
|
|
321
|
-
* ```
|
|
322
|
-
* dayjs().date(1)// => Dayjs
|
|
323
|
-
* ```
|
|
324
|
-
* Docs: https://day.js.org/docs/en/get-set/date
|
|
325
|
-
*/
|
|
326
|
-
date(value: number): Dayjs
|
|
327
|
-
/**
|
|
328
|
-
* Get the day of the week.
|
|
329
|
-
*
|
|
330
|
-
* Returns numbers from 0 (Sunday) to 6 (Saturday).
|
|
331
|
-
* ```
|
|
332
|
-
* dayjs().day()// 0-6
|
|
333
|
-
* ```
|
|
334
|
-
* Docs: https://day.js.org/docs/en/get-set/day
|
|
335
|
-
*/
|
|
336
|
-
day(): 0 | 1 | 2 | 3 | 4 | 5 | 6
|
|
337
|
-
/**
|
|
338
|
-
* Set the day of the week.
|
|
339
|
-
*
|
|
340
|
-
* Accepts numbers from 0 (Sunday) to 6 (Saturday). If the range is exceeded, it will bubble up to next weeks.
|
|
341
|
-
* ```
|
|
342
|
-
* dayjs().day(0)// => Dayjs
|
|
343
|
-
* ```
|
|
344
|
-
* Docs: https://day.js.org/docs/en/get-set/day
|
|
345
|
-
*/
|
|
346
|
-
day(value: number): Dayjs
|
|
347
|
-
/**
|
|
348
|
-
* Get the hour.
|
|
349
|
-
* ```
|
|
350
|
-
* dayjs().hour()// => 0-23
|
|
351
|
-
* ```
|
|
352
|
-
* Docs: https://day.js.org/docs/en/get-set/hour
|
|
353
|
-
*/
|
|
354
|
-
hour(): number
|
|
355
|
-
/**
|
|
356
|
-
* Set the hour.
|
|
357
|
-
*
|
|
358
|
-
* Accepts numbers from 0 to 23. If the range is exceeded, it will bubble up to the next day.
|
|
359
|
-
* ```
|
|
360
|
-
* dayjs().hour(12)// => Dayjs
|
|
361
|
-
* ```
|
|
362
|
-
* Docs: https://day.js.org/docs/en/get-set/hour
|
|
363
|
-
*/
|
|
364
|
-
hour(value: number): Dayjs
|
|
365
|
-
/**
|
|
366
|
-
* Get the minutes.
|
|
367
|
-
* ```
|
|
368
|
-
* dayjs().minute()// => 0-59
|
|
369
|
-
* ```
|
|
370
|
-
* Docs: https://day.js.org/docs/en/get-set/minute
|
|
371
|
-
*/
|
|
372
|
-
minute(): number
|
|
373
|
-
/**
|
|
374
|
-
* Set the minutes.
|
|
375
|
-
*
|
|
376
|
-
* Accepts numbers from 0 to 59. If the range is exceeded, it will bubble up to the next hour.
|
|
377
|
-
* ```
|
|
378
|
-
* dayjs().minute(59)// => Dayjs
|
|
379
|
-
* ```
|
|
380
|
-
* Docs: https://day.js.org/docs/en/get-set/minute
|
|
381
|
-
*/
|
|
382
|
-
minute(value: number): Dayjs
|
|
383
|
-
/**
|
|
384
|
-
* Get the seconds.
|
|
385
|
-
* ```
|
|
386
|
-
* dayjs().second()// => 0-59
|
|
387
|
-
* ```
|
|
388
|
-
* Docs: https://day.js.org/docs/en/get-set/second
|
|
389
|
-
*/
|
|
390
|
-
second(): number
|
|
391
|
-
/**
|
|
392
|
-
* Set the seconds.
|
|
393
|
-
*
|
|
394
|
-
* Accepts numbers from 0 to 59. If the range is exceeded, it will bubble up to the next minutes.
|
|
395
|
-
* ```
|
|
396
|
-
* dayjs().second(1)// Dayjs
|
|
397
|
-
* ```
|
|
398
|
-
*/
|
|
399
|
-
second(value: number): Dayjs
|
|
400
|
-
/**
|
|
401
|
-
* Get the milliseconds.
|
|
402
|
-
* ```
|
|
403
|
-
* dayjs().millisecond()// => 0-999
|
|
404
|
-
* ```
|
|
405
|
-
* Docs: https://day.js.org/docs/en/get-set/millisecond
|
|
406
|
-
*/
|
|
407
|
-
millisecond(): number
|
|
408
|
-
/**
|
|
409
|
-
* Set the milliseconds.
|
|
410
|
-
*
|
|
411
|
-
* Accepts numbers from 0 to 999. If the range is exceeded, it will bubble up to the next seconds.
|
|
412
|
-
* ```
|
|
413
|
-
* dayjs().millisecond(1)// => Dayjs
|
|
414
|
-
* ```
|
|
415
|
-
* Docs: https://day.js.org/docs/en/get-set/millisecond
|
|
416
|
-
*/
|
|
417
|
-
millisecond(value: number): Dayjs
|
|
418
|
-
/**
|
|
419
|
-
* Generic setter, accepting unit as first argument, and value as second, returns a new instance with the applied changes.
|
|
420
|
-
*
|
|
421
|
-
* In general:
|
|
422
|
-
* ```
|
|
423
|
-
* dayjs().set(unit, value) === dayjs()[unit](value)
|
|
424
|
-
* ```
|
|
425
|
-
* Units are case insensitive, and support plural and short forms.
|
|
426
|
-
* ```
|
|
427
|
-
* dayjs().set('date', 1)
|
|
428
|
-
* dayjs().set('month', 3) // April
|
|
429
|
-
* dayjs().set('second', 30)
|
|
430
|
-
* ```
|
|
431
|
-
* Docs: https://day.js.org/docs/en/get-set/set
|
|
432
|
-
*/
|
|
433
|
-
set(unit: UnitType, value: number): Dayjs
|
|
434
|
-
/**
|
|
435
|
-
* String getter, returns the corresponding information getting from Day.js object.
|
|
436
|
-
*
|
|
437
|
-
* In general:
|
|
438
|
-
* ```
|
|
439
|
-
* dayjs().get(unit) === dayjs()[unit]()
|
|
440
|
-
* ```
|
|
441
|
-
* Units are case insensitive, and support plural and short forms.
|
|
442
|
-
* ```
|
|
443
|
-
* dayjs().get('year')
|
|
444
|
-
* dayjs().get('month') // start 0
|
|
445
|
-
* dayjs().get('date')
|
|
446
|
-
* ```
|
|
447
|
-
* Docs: https://day.js.org/docs/en/get-set/get
|
|
448
|
-
*/
|
|
449
|
-
get(unit: UnitType): number
|
|
450
|
-
/**
|
|
451
|
-
* Returns a cloned Day.js object with a specified amount of time added.
|
|
452
|
-
* ```
|
|
453
|
-
* dayjs().add(7, 'day')// => Dayjs
|
|
454
|
-
* ```
|
|
455
|
-
* Units are case insensitive, and support plural and short forms.
|
|
456
|
-
*
|
|
457
|
-
* Docs: https://day.js.org/docs/en/manipulate/add
|
|
458
|
-
*/
|
|
459
|
-
add(value: number, unit?: ManipulateType): Dayjs
|
|
460
|
-
/**
|
|
461
|
-
* Returns a cloned Day.js object with a specified amount of time subtracted.
|
|
462
|
-
* ```
|
|
463
|
-
* dayjs().subtract(7, 'year')// => Dayjs
|
|
464
|
-
* ```
|
|
465
|
-
* Units are case insensitive, and support plural and short forms.
|
|
466
|
-
*
|
|
467
|
-
* Docs: https://day.js.org/docs/en/manipulate/subtract
|
|
468
|
-
*/
|
|
469
|
-
subtract(value: number, unit?: ManipulateType): Dayjs
|
|
470
|
-
/**
|
|
471
|
-
* Returns a cloned Day.js object and set it to the start of a unit of time.
|
|
472
|
-
* ```
|
|
473
|
-
* dayjs().startOf('year')// => Dayjs
|
|
474
|
-
* ```
|
|
475
|
-
* Units are case insensitive, and support plural and short forms.
|
|
476
|
-
*
|
|
477
|
-
* Docs: https://day.js.org/docs/en/manipulate/start-of
|
|
478
|
-
*/
|
|
479
|
-
startOf(unit: OpUnitType): Dayjs
|
|
480
|
-
/**
|
|
481
|
-
* Returns a cloned Day.js object and set it to the end of a unit of time.
|
|
482
|
-
* ```
|
|
483
|
-
* dayjs().endOf('month')// => Dayjs
|
|
484
|
-
* ```
|
|
485
|
-
* Units are case insensitive, and support plural and short forms.
|
|
486
|
-
*
|
|
487
|
-
* Docs: https://day.js.org/docs/en/manipulate/end-of
|
|
488
|
-
*/
|
|
489
|
-
endOf(unit: OpUnitType): Dayjs
|
|
490
|
-
/**
|
|
491
|
-
* Get the formatted date according to the string of tokens passed in.
|
|
492
|
-
*
|
|
493
|
-
* To escape characters, wrap them in square brackets (e.g. [MM]).
|
|
494
|
-
* ```
|
|
495
|
-
* dayjs().format()// => current date in ISO8601, without fraction seconds e.g. '2020-04-02T08:02:17-05:00'
|
|
496
|
-
* dayjs('2019-01-25').format('[YYYYescape] YYYY-MM-DDTHH:mm:ssZ[Z]')// 'YYYYescape 2019-01-25T00:00:00-02:00Z'
|
|
497
|
-
* dayjs('2019-01-25').format('DD/MM/YYYY') // '25/01/2019'
|
|
498
|
-
* ```
|
|
499
|
-
* Docs: https://day.js.org/docs/en/display/format
|
|
500
|
-
*/
|
|
501
|
-
format(template?: string): string
|
|
502
|
-
/**
|
|
503
|
-
* This indicates the difference between two date-time in the specified unit.
|
|
504
|
-
*
|
|
505
|
-
* To get the difference in milliseconds, use `dayjs#diff`
|
|
506
|
-
* ```
|
|
507
|
-
* const date1 = dayjs('2019-01-25')
|
|
508
|
-
* const date2 = dayjs('2018-06-05')
|
|
509
|
-
* date1.diff(date2) // 20214000000 default milliseconds
|
|
510
|
-
* date1.diff() // milliseconds to current time
|
|
511
|
-
* ```
|
|
512
|
-
*
|
|
513
|
-
* To get the difference in another unit of measurement, pass that measurement as the second argument.
|
|
514
|
-
* ```
|
|
515
|
-
* const date1 = dayjs('2019-01-25')
|
|
516
|
-
* date1.diff('2018-06-05', 'month') // 7
|
|
517
|
-
* ```
|
|
518
|
-
* Units are case insensitive, and support plural and short forms.
|
|
519
|
-
*
|
|
520
|
-
* Docs: https://day.js.org/docs/en/display/difference
|
|
521
|
-
*/
|
|
522
|
-
diff(date?: ConfigType, unit?: QUnitType | OpUnitType, float?: boolean): number
|
|
523
|
-
/**
|
|
524
|
-
* This returns the number of **milliseconds** since the Unix Epoch of the Day.js object.
|
|
525
|
-
* ```
|
|
526
|
-
* dayjs('2019-01-25').valueOf() // 1548381600000
|
|
527
|
-
* +dayjs(1548381600000) // 1548381600000
|
|
528
|
-
* ```
|
|
529
|
-
* To get a Unix timestamp (the number of seconds since the epoch) from a Day.js object, you should use Unix Timestamp `dayjs#unix()`.
|
|
530
|
-
*
|
|
531
|
-
* Docs: https://day.js.org/docs/en/display/unix-timestamp-milliseconds
|
|
532
|
-
*/
|
|
533
|
-
valueOf(): number
|
|
534
|
-
/**
|
|
535
|
-
* This returns the Unix timestamp (the number of **seconds** since the Unix Epoch) of the Day.js object.
|
|
536
|
-
* ```
|
|
537
|
-
* dayjs('2019-01-25').unix() // 1548381600
|
|
538
|
-
* ```
|
|
539
|
-
* This value is floored to the nearest second, and does not include a milliseconds component.
|
|
540
|
-
*
|
|
541
|
-
* Docs: https://day.js.org/docs/en/display/unix-timestamp
|
|
542
|
-
*/
|
|
543
|
-
unix(): number
|
|
544
|
-
/**
|
|
545
|
-
* Get the number of days in the current month.
|
|
546
|
-
* ```
|
|
547
|
-
* dayjs('2019-01-25').daysInMonth() // 31
|
|
548
|
-
* ```
|
|
549
|
-
* Docs: https://day.js.org/docs/en/display/days-in-month
|
|
550
|
-
*/
|
|
551
|
-
daysInMonth(): number
|
|
552
|
-
/**
|
|
553
|
-
* To get a copy of the native `Date` object parsed from the Day.js object use `dayjs#toDate`.
|
|
554
|
-
* ```
|
|
555
|
-
* dayjs('2019-01-25').toDate()// => Date
|
|
556
|
-
* ```
|
|
557
|
-
*/
|
|
558
|
-
toDate(): Date
|
|
559
|
-
/**
|
|
560
|
-
* To serialize as an ISO 8601 string.
|
|
561
|
-
* ```
|
|
562
|
-
* dayjs('2019-01-25').toJSON() // '2019-01-25T02:00:00.000Z'
|
|
563
|
-
* ```
|
|
564
|
-
* Docs: https://day.js.org/docs/en/display/as-json
|
|
565
|
-
*/
|
|
566
|
-
toJSON(): string
|
|
567
|
-
/**
|
|
568
|
-
* To format as an ISO 8601 string.
|
|
569
|
-
* ```
|
|
570
|
-
* dayjs('2019-01-25').toISOString() // '2019-01-25T02:00:00.000Z'
|
|
571
|
-
* ```
|
|
572
|
-
* Docs: https://day.js.org/docs/en/display/as-iso-string
|
|
573
|
-
*/
|
|
574
|
-
toISOString(): string
|
|
575
|
-
/**
|
|
576
|
-
* Returns a string representation of the date.
|
|
577
|
-
* ```
|
|
578
|
-
* dayjs('2019-01-25').toString() // 'Fri, 25 Jan 2019 02:00:00 GMT'
|
|
579
|
-
* ```
|
|
580
|
-
* Docs: https://day.js.org/docs/en/display/as-string
|
|
581
|
-
*/
|
|
582
|
-
toString(): string
|
|
583
|
-
/**
|
|
584
|
-
* Get the UTC offset in minutes.
|
|
585
|
-
* ```
|
|
586
|
-
* dayjs().utcOffset()
|
|
587
|
-
* ```
|
|
588
|
-
* Docs: https://day.js.org/docs/en/manipulate/utc-offset
|
|
589
|
-
*/
|
|
590
|
-
utcOffset(): number
|
|
591
|
-
/**
|
|
592
|
-
* This indicates whether the Day.js object is before the other supplied date-time.
|
|
593
|
-
* ```
|
|
594
|
-
* dayjs().isBefore(dayjs('2011-01-01')) // default milliseconds
|
|
595
|
-
* ```
|
|
596
|
-
* If you want to limit the granularity to a unit other than milliseconds, pass it as the second parameter.
|
|
597
|
-
* ```
|
|
598
|
-
* dayjs().isBefore('2011-01-01', 'year')// => boolean
|
|
599
|
-
* ```
|
|
600
|
-
* Units are case insensitive, and support plural and short forms.
|
|
601
|
-
*
|
|
602
|
-
* Docs: https://day.js.org/docs/en/query/is-before
|
|
603
|
-
*/
|
|
604
|
-
isBefore(date?: ConfigType, unit?: OpUnitType): boolean
|
|
605
|
-
/**
|
|
606
|
-
* This indicates whether the Day.js object is the same as the other supplied date-time.
|
|
607
|
-
* ```
|
|
608
|
-
* dayjs().isSame(dayjs('2011-01-01')) // default milliseconds
|
|
609
|
-
* ```
|
|
610
|
-
* If you want to limit the granularity to a unit other than milliseconds, pass it as the second parameter.
|
|
611
|
-
* ```
|
|
612
|
-
* dayjs().isSame('2011-01-01', 'year')// => boolean
|
|
613
|
-
* ```
|
|
614
|
-
* Docs: https://day.js.org/docs/en/query/is-same
|
|
615
|
-
*/
|
|
616
|
-
isSame(date?: ConfigType, unit?: OpUnitType): boolean
|
|
617
|
-
/**
|
|
618
|
-
* This indicates whether the Day.js object is after the other supplied date-time.
|
|
619
|
-
* ```
|
|
620
|
-
* dayjs().isAfter(dayjs('2011-01-01')) // default milliseconds
|
|
621
|
-
* ```
|
|
622
|
-
* If you want to limit the granularity to a unit other than milliseconds, pass it as the second parameter.
|
|
623
|
-
* ```
|
|
624
|
-
* dayjs().isAfter('2011-01-01', 'year')// => boolean
|
|
625
|
-
* ```
|
|
626
|
-
* Units are case insensitive, and support plural and short forms.
|
|
627
|
-
*
|
|
628
|
-
* Docs: https://day.js.org/docs/en/query/is-after
|
|
629
|
-
*/
|
|
630
|
-
isAfter(date?: ConfigType, unit?: OpUnitType): boolean
|
|
631
|
-
|
|
632
|
-
locale(): string
|
|
633
|
-
|
|
634
|
-
locale(preset: string | ILocale, object?: Partial<ILocale>): Dayjs
|
|
635
|
-
}
|
|
636
|
-
|
|
637
|
-
export type PluginFunc<T = unknown> = (option: T, c: typeof Dayjs, d: typeof dayjs) => void
|
|
638
|
-
|
|
639
|
-
export function extend<T = unknown>(plugin: PluginFunc<T>, option?: T): Dayjs
|
|
640
|
-
|
|
641
|
-
export function locale(preset?: string | ILocale, object?: Partial<ILocale>, isLocal?: boolean): string
|
|
642
|
-
|
|
643
|
-
export function isDayjs(d: any): d is Dayjs
|
|
644
|
-
|
|
645
|
-
export function unix(t: number): Dayjs
|
|
646
|
-
|
|
647
|
-
const Ls : { [key: string] : ILocale }
|
|
648
|
-
}
|
|
649
|
-
|
|
650
|
-
type Dayjs$2 = dayjs.Dayjs;
|
|
242
|
+
declare function ColorPickerBasic({ value, onChange, required, label, error, disabled, allowClear, defaultFormat, className, placeholder }: ColorPickerProps): react_jsx_runtime.JSX.Element;
|
|
651
243
|
|
|
652
244
|
interface DatePickerBasicProps {
|
|
653
|
-
value:
|
|
654
|
-
onChange: (
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
showError?: boolean;
|
|
659
|
-
errorMessage?: string;
|
|
245
|
+
value: Date | null;
|
|
246
|
+
onChange: (date: Date | null) => void;
|
|
247
|
+
required?: boolean;
|
|
248
|
+
label?: string;
|
|
249
|
+
error?: string;
|
|
660
250
|
placeholder?: string;
|
|
661
251
|
disabled?: boolean;
|
|
662
|
-
defaultValue?:
|
|
252
|
+
defaultValue?: Date | null;
|
|
663
253
|
mode?: "time" | "date" | "month";
|
|
664
|
-
minDate?:
|
|
665
|
-
maxDate?:
|
|
666
|
-
disabledDate?: (currentDate:
|
|
254
|
+
minDate?: Date;
|
|
255
|
+
maxDate?: Date;
|
|
256
|
+
disabledDate?: (currentDate: Date) => boolean;
|
|
667
257
|
className?: string;
|
|
668
258
|
size?: "small" | "middle" | "large";
|
|
669
259
|
}
|
|
670
|
-
declare function DatePickerBasic({ value, onChange,
|
|
260
|
+
declare function DatePickerBasic({ value, onChange, required, label, error, placeholder, disabled, defaultValue, minDate, maxDate, disabledDate, className, size, }: DatePickerBasicProps): react_jsx_runtime.JSX.Element;
|
|
671
261
|
|
|
672
|
-
type Dayjs$1 = dayjs.Dayjs;
|
|
673
262
|
interface DatePickerRangePickerProps {
|
|
674
|
-
value: [
|
|
675
|
-
onChange: (val: [
|
|
263
|
+
value: [Date | null, Date | null] | null;
|
|
264
|
+
onChange: (val: [Date | null, Date | null] | null) => void;
|
|
676
265
|
placeholder?: [string, string];
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
showError?: boolean;
|
|
681
|
-
errorMessage?: string;
|
|
266
|
+
label?: string;
|
|
267
|
+
required?: boolean;
|
|
268
|
+
error?: string;
|
|
682
269
|
disabled?: boolean;
|
|
683
|
-
defaultValue?: [
|
|
270
|
+
defaultValue?: [Date, Date] | null;
|
|
684
271
|
mode?: "time" | "date" | "month";
|
|
685
|
-
minDate?:
|
|
686
|
-
maxDate?:
|
|
687
|
-
disabledDate?: (currentDate:
|
|
272
|
+
minDate?: Date | undefined;
|
|
273
|
+
maxDate?: Date | undefined;
|
|
274
|
+
disabledDate?: (currentDate: Date) => boolean;
|
|
688
275
|
size?: "small" | "middle" | "large";
|
|
689
276
|
className?: string;
|
|
690
277
|
onOpenChange?: (open: boolean) => void;
|
|
691
|
-
onCalendarChange?: (dates: [
|
|
278
|
+
onCalendarChange?: (dates: [Date | null, Date | null], dateStrings: [string, string], info: any) => void;
|
|
692
279
|
}
|
|
693
|
-
declare function DatePickerRangePicker({ value, onChange, placeholder,
|
|
280
|
+
declare function DatePickerRangePicker({ value, onChange, placeholder, label, required, error, disabled, minDate, maxDate, disabledDate, size, className, onOpenChange, onCalendarChange, }: DatePickerRangePickerProps): react_jsx_runtime.JSX.Element;
|
|
694
281
|
|
|
695
|
-
type Dayjs = dayjs.Dayjs;
|
|
696
282
|
interface TimePickerBasicProps {
|
|
697
|
-
value:
|
|
698
|
-
onChange: (time:
|
|
699
|
-
|
|
700
|
-
|
|
283
|
+
value: Date | null;
|
|
284
|
+
onChange: (time: Date | null) => void;
|
|
285
|
+
required?: boolean;
|
|
286
|
+
label?: string;
|
|
701
287
|
bottomText?: string;
|
|
702
288
|
showError?: boolean;
|
|
703
|
-
|
|
289
|
+
error?: string;
|
|
704
290
|
placeholder?: string;
|
|
705
291
|
disabled?: boolean;
|
|
706
292
|
className?: string;
|
|
707
293
|
}
|
|
708
|
-
declare function TimePickerBasic({ value, onChange,
|
|
294
|
+
declare function TimePickerBasic({ value, onChange, required, label, error, placeholder, disabled, className, }: TimePickerBasicProps): react_jsx_runtime.JSX.Element;
|
|
709
295
|
|
|
710
296
|
interface TimePickerRangePickerProps {
|
|
711
|
-
value: [
|
|
712
|
-
onChange: (val: [
|
|
297
|
+
value: [Date | null, Date | null] | null;
|
|
298
|
+
onChange: (val: [Date | null, Date | null] | null) => void;
|
|
713
299
|
placeholder?: [string, string];
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
showError?: boolean;
|
|
718
|
-
errorMessage?: string;
|
|
300
|
+
label?: string;
|
|
301
|
+
required?: boolean;
|
|
302
|
+
error?: string;
|
|
719
303
|
disabled?: boolean;
|
|
720
304
|
className?: string;
|
|
721
305
|
}
|
|
722
|
-
declare function TimePickerRangePicker({ value, onChange, placeholder,
|
|
306
|
+
declare function TimePickerRangePicker({ value, onChange, placeholder, label, required, error, disabled, className, }: TimePickerRangePickerProps): react_jsx_runtime.JSX.Element;
|
|
723
307
|
|
|
724
308
|
interface ColorPalettePickerBasicProps {
|
|
725
309
|
value: string | null;
|
|
726
310
|
onChange?: (color: Color, hex: string) => void;
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
showError?: boolean;
|
|
731
|
-
errorMessage?: string;
|
|
311
|
+
required?: boolean;
|
|
312
|
+
label?: string;
|
|
313
|
+
error?: string;
|
|
732
314
|
disabled?: boolean;
|
|
733
315
|
allowClear?: boolean;
|
|
734
316
|
defaultFormat?: "hex" | "rgb" | "hsb";
|
|
@@ -736,17 +318,15 @@ interface ColorPalettePickerBasicProps {
|
|
|
736
318
|
placeholder?: string;
|
|
737
319
|
onClear?: () => void;
|
|
738
320
|
}
|
|
739
|
-
declare function ColorPalettePickerBasic({ value, onChange,
|
|
321
|
+
declare function ColorPalettePickerBasic({ value, onChange, required, label, error, disabled, allowClear, defaultFormat, className, placeholder, onClear, }: ColorPalettePickerBasicProps): react_jsx_runtime.JSX.Element;
|
|
740
322
|
|
|
741
323
|
interface SelectFieldProps$1 {
|
|
742
324
|
value?: SelectProps["value"];
|
|
743
325
|
onChange: (value: SelectProps["value"]) => void;
|
|
744
326
|
placeholder?: string;
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
errorMessage?: string;
|
|
749
|
-
showError?: boolean;
|
|
327
|
+
label?: string;
|
|
328
|
+
required?: boolean;
|
|
329
|
+
error?: string;
|
|
750
330
|
disabled?: boolean;
|
|
751
331
|
defaultValue?: string;
|
|
752
332
|
options?: {
|
|
@@ -761,16 +341,15 @@ interface SelectFieldProps$1 {
|
|
|
761
341
|
className?: string;
|
|
762
342
|
onClear?: () => void;
|
|
763
343
|
}
|
|
764
|
-
declare function SelectField({ value, onChange, placeholder,
|
|
344
|
+
declare function SelectField({ value, onChange, placeholder, label, required, error, disabled, defaultValue, options, mode, prefix, prefixSize, handleSearch, className, onClear }: SelectFieldProps$1): react_jsx_runtime.JSX.Element;
|
|
765
345
|
|
|
766
346
|
interface SelectFieldProps {
|
|
767
347
|
value?: SelectProps["value"];
|
|
768
348
|
onChange: (value: SelectProps["value"]) => void;
|
|
769
349
|
placeholder?: string;
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
errorMessage?: string;
|
|
350
|
+
label?: string;
|
|
351
|
+
required?: boolean;
|
|
352
|
+
error?: string;
|
|
774
353
|
showError?: boolean;
|
|
775
354
|
disabled?: boolean;
|
|
776
355
|
defaultValue?: string;
|
|
@@ -788,18 +367,16 @@ interface SelectFieldProps {
|
|
|
788
367
|
prefixSize?: number;
|
|
789
368
|
className?: string;
|
|
790
369
|
}
|
|
791
|
-
declare function SelectFieldGroup({ value, onChange, placeholder,
|
|
370
|
+
declare function SelectFieldGroup({ value, onChange, placeholder, label, required, error, disabled, defaultValue, options, mode, prefix, prefixSize, handleSearch, className }: SelectFieldProps): react_jsx_runtime.JSX.Element;
|
|
792
371
|
|
|
793
372
|
interface SelectFieldStatusProps {
|
|
794
373
|
value: string | undefined;
|
|
795
374
|
onChange: (value: string | undefined) => void;
|
|
796
375
|
placeholder?: string;
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
bottomText?: string;
|
|
376
|
+
label?: string;
|
|
377
|
+
required?: boolean;
|
|
800
378
|
disabled?: boolean;
|
|
801
|
-
|
|
802
|
-
errorMessage?: string;
|
|
379
|
+
error?: string;
|
|
803
380
|
options?: {
|
|
804
381
|
label: ReactNode;
|
|
805
382
|
value: string | number | null;
|
|
@@ -807,18 +384,16 @@ interface SelectFieldStatusProps {
|
|
|
807
384
|
}[];
|
|
808
385
|
className?: string;
|
|
809
386
|
}
|
|
810
|
-
declare function SelectFieldStatus({ value, onChange, placeholder,
|
|
387
|
+
declare function SelectFieldStatus({ value, onChange, placeholder, label, required, disabled, error, options, className }: SelectFieldStatusProps): react_jsx_runtime.JSX.Element;
|
|
811
388
|
|
|
812
389
|
interface SelectFieldStatusReportProps {
|
|
813
390
|
value: string | undefined;
|
|
814
391
|
onChange: (value: string | undefined) => void;
|
|
815
392
|
placeholder?: string;
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
bottomText?: string;
|
|
393
|
+
label?: string;
|
|
394
|
+
required?: boolean;
|
|
819
395
|
disabled?: boolean;
|
|
820
|
-
|
|
821
|
-
errorMessage?: string;
|
|
396
|
+
error?: string;
|
|
822
397
|
className?: string;
|
|
823
398
|
options?: {
|
|
824
399
|
label: ReactNode;
|
|
@@ -826,43 +401,39 @@ interface SelectFieldStatusReportProps {
|
|
|
826
401
|
disabled?: boolean;
|
|
827
402
|
}[];
|
|
828
403
|
}
|
|
829
|
-
declare function SelectFieldStatusReport({ value, onChange, placeholder,
|
|
404
|
+
declare function SelectFieldStatusReport({ value, onChange, placeholder, label, required, disabled, error, className, options }: SelectFieldStatusReportProps): react_jsx_runtime.JSX.Element;
|
|
830
405
|
|
|
831
406
|
interface SelectFieldTagProps {
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
bottomText?: string | null;
|
|
407
|
+
label?: string | null;
|
|
408
|
+
required?: boolean;
|
|
835
409
|
placeholder?: string;
|
|
836
410
|
options?: {
|
|
837
411
|
label: ReactNode;
|
|
838
412
|
value: string | number | null;
|
|
839
413
|
disabled?: boolean;
|
|
840
414
|
}[];
|
|
841
|
-
|
|
842
|
-
errorMessage?: string;
|
|
415
|
+
error?: string;
|
|
843
416
|
value?: string[];
|
|
844
417
|
onChange?: (val: string[]) => void;
|
|
845
418
|
className?: string;
|
|
846
419
|
onClear?: () => void;
|
|
847
420
|
}
|
|
848
|
-
declare function SelectFieldTag({
|
|
421
|
+
declare function SelectFieldTag({ label, required, placeholder, options, error, value: controlledValue, className, onChange, onClear }: SelectFieldTagProps): react_jsx_runtime.JSX.Element;
|
|
849
422
|
|
|
850
423
|
interface OptionItem {
|
|
851
424
|
value: string;
|
|
852
425
|
label: string;
|
|
853
426
|
}
|
|
854
427
|
interface SelectCustomProps {
|
|
855
|
-
|
|
428
|
+
label?: string;
|
|
856
429
|
placeholder?: string;
|
|
857
430
|
options: OptionItem[];
|
|
858
|
-
|
|
431
|
+
required?: boolean;
|
|
859
432
|
onChange?: (valueList: string[]) => void;
|
|
860
|
-
|
|
861
|
-
showError?: boolean;
|
|
862
|
-
errorMessage?: string;
|
|
433
|
+
error?: string;
|
|
863
434
|
onClear?: () => void;
|
|
864
435
|
}
|
|
865
|
-
declare function SelectCustom({
|
|
436
|
+
declare function SelectCustom({ label, placeholder, options, required, onChange, error, onClear }: SelectCustomProps): react_jsx_runtime.JSX.Element;
|
|
866
437
|
|
|
867
438
|
interface SortFilterProps {
|
|
868
439
|
showYear?: boolean;
|
|
@@ -875,7 +446,7 @@ declare function SortFilter({ showYear, showQuarter, showMonth, onSortClick, onF
|
|
|
875
446
|
|
|
876
447
|
interface FileUploaderProps {
|
|
877
448
|
onUpload: (file: File) => Promise<void>;
|
|
878
|
-
onRemove?: () => Promise<void>;
|
|
449
|
+
onRemove?: (index: number) => Promise<void>;
|
|
879
450
|
onError?: (message: string) => void;
|
|
880
451
|
accept?: string[];
|
|
881
452
|
maxSize?: number;
|
|
@@ -938,4 +509,4 @@ interface KpiSectionProps {
|
|
|
938
509
|
}
|
|
939
510
|
declare function KpiSection({ type, onChangeKpiList }: KpiSectionProps): react_jsx_runtime.JSX.Element;
|
|
940
511
|
|
|
941
|
-
export { AntDataTable, Breadcrumbs, Calendar, Checkbox, CheckboxGroup, ColorPalettePickerBasic, ColorPickerBasic, DataTable, DatePickerBasic, DatePickerRangePicker, FileUploader, GhostButton, HeadingPage, InputField, KpiSection, Loader, MenuNavBar, type MenuNavBarProps, PrimaryButton, ProgressBar, Radio, RadioGroup, SecondaryButton, SelectCustom, SelectField, SelectFieldGroup, SelectFieldStatus, SelectFieldStatusReport, SelectFieldTag, Sidebar, SortFilter, Switch, TextAreaInput, TextInput, TimePickerBasic, TimePickerRangePicker, TopNavBar, messageError, messageInfo, messageLoading, messageSuccess, messageWarning, setMessageApi };
|
|
512
|
+
export { AntDataTable, Breadcrumbs, Calendar, Checkbox, CheckboxGroup, ColorPalettePickerBasic, ColorPickerBasic, DataTable, DatePickerBasic, DatePickerRangePicker, FileUploader, GhostButton, HeadingPage, InputField, InputFieldNumber, KpiSection, Loader, MenuNavBar, type MenuNavBarProps, PrimaryButton, ProgressBar, Radio, RadioGroup, SecondaryButton, SelectCustom, SelectField, SelectFieldGroup, SelectFieldStatus, SelectFieldStatusReport, SelectFieldTag, Sidebar, SortFilter, Switch, TextAreaInput, TextInput, TimePickerBasic, TimePickerRangePicker, TopNavBar, messageError, messageInfo, messageLoading, messageSuccess, messageWarning, setMessageApi };
|