UNPKG

@jiaozhiye/qm-design-vue

Version:

A Component Library for Vue3.0

58 lines (57 loc) 4.03 kB
import type { AnyObject, IDict } from '../../_utils/types'; import type { IFormItem, IFetchFnMaker, IRecord } from './types'; export declare const getDate: (dateString: string | undefined, format: string) => Date | null; export declare const formatDate: (date: Date | null | undefined, format: string) => string; export declare const padDate: (input: string, options?: Record<'hour' | 'minute' | 'second', string>) => string; export declare const isEmptyValue: (value: unknown) => boolean; export declare const getSplitValue: (data: IRecord | null, path: string) => any; export declare const setEchoRecord: (row: IRecord, alias: any, echoAlias: any) => void; export declare const setEchoExtras: (row: IRecord, extras: any, echoExtras: any) => void; export declare const deepMapList: (list: any[], valueKey: string, textKey: string) => (IDict & { isLeaf?: boolean | undefined; })[]; export declare const deepFind: (arr: any[], mark: string) => any; export declare const deepFindValues: <T>(arr: T[], str: string, depth?: number) => T[]; export declare const deepGetPath: (arr: any[], value: string) => string[] | undefined; export declare const difference: <T extends AnyObject<any>>(object: T, base: T) => T; export declare const formatNumber: (value: string | number) => string; export declare const parserNumber: (value: string) => string; export declare const secretFormat: (value: string | number | undefined, type: string) => string; export declare const isValidLabel: (label: any) => boolean; export declare const getTitleFromNode: (vNode: any) => string; export declare const createShConfig: (data: any, fieldName: string, createFetch: IFetchFnMaker, multiple?: boolean) => { name?: string | undefined; getServerConfig?: import("./types").IFetchFn | undefined; createFetchApi?: ((url: string, type?: string | undefined) => import("./types").IFetchFn) | undefined; fieldsDefine?: import("./types").IFieldsDefine | undefined; filters?: IFormItem[] | undefined; table?: { fetch?: import("../../table/src/table/types").IFetch | undefined; columns?: import("../../table/src/table/types").IColumn[] | undefined; rowKey?: string | number | ((row: IRecord, index: number) => string | number) | undefined; webPagination?: boolean | undefined; paginationConfig?: Pick<import("../../table/src/table/types").IPaginationConfig, "pageSize" | "pageSizeOptions"> | undefined; } | undefined; tree?: { fetch?: (import("../../table/src/table/types").IFetch & import("./types").ITextValueKey) | undefined; tableParamsMap?: Record<string, string> | (() => Record<string, string>) | undefined; } | undefined; request?: import("./types").IRequest | undefined; echoRequest?: (import("./types").IRequest & { triggeredChange?: boolean | undefined; fieldAliasMap?: Record<string, string> | (() => Record<string, string>) | undefined; extraAliasMap?: Record<string, string> | (() => Record<string, string>) | undefined; }) | undefined; hideHeader?: boolean | undefined; columns?: import("../../table/src/table/types").IColumn[] | undefined; width?: string | number | undefined; initialValue?: import("./types").IFormData<string | number, string | number | (string | number)[] | undefined> | undefined; onlySelect?: boolean | undefined; autoQueryAssign?: boolean | undefined; closeRemoteMatch?: boolean | undefined; fieldAliasMap?: Record<string, string> | (() => Record<string, string>) | undefined; extraAliasMap?: Record<string, string> | (() => Record<string, string>) | undefined; filterAliasMap?: string[] | Record<string, (input: string) => string> | (() => string[] | Record<string, (input: string) => string>) | undefined; beforeOpen?: ((formData: import("./types").IFormData<string | number, string | number | (string | number)[] | undefined>) => boolean | void | Promise<void>) | undefined; closed?: ((rowData: Record<string, any>) => void) | undefined; };