UNPKG

@joker.front/ui

Version:

Joker-UI | Official native UI component library for Joker Framework. Minimalist design with full-scene components, responsive layout & dynamic interactions. Access dev docs, API references & real-world case studies on official site.

28 lines (27 loc) 1.71 kB
import { ManipulateType } from "dayjs"; export declare const DEFAULT_FORMATS: Record<string, string>; export declare function parseAsFormatAndType(value: any, customFormat: string | undefined, type: string, rangeSeparator?: string): any; export declare function formatAsFormatAndType(value: any, customFormat: string | undefined, type: string): any; export type TimeMode = { hours: number; minutes: number; seconds: number; }; export declare function parseTime(time: string | TimeMode | undefined, format: string): TimeMode; export declare function compareTime(value1: string | TimeMode, value2: string | TimeMode, format: string): 0 | 1 | -1; export declare function validateTimeInRange(time: string | TimeMode, format: string, selectableRange: Array<(TimeMode | string)[] | string> | undefined): boolean; export declare function addDate(date: Date, val: number, type: ManipulateType): Date; export declare function subtractDate(date: Date, val: number, type: ManipulateType): Date; export declare function extractDateFormat(format: string): string; export declare function extractTimeFormat(format: string): string; export declare function getStartDateOfMonth(year: number, month: number): Date; export declare function getDayCountOfMonth(year: number, month: number): number; export declare function getDayCountOfYear(year: number): 366 | 365; export declare function getWeekNumber(date: Date): number; export declare function clearTime(date: Date): number; export declare function parseDate(val: string, format: string): Date; export declare function setTime(date: Date, time: string): Date; export type Shortcut = { text: string; onClick: (callBack: (val?: any) => void) => void; };