PromoCursed/node_modules/antd/lib/statistic/utils.d.ts
2024-08-20 23:25:37 +04:00

16 lines
658 B
TypeScript

import type * as React from 'react';
export type valueType = number | string;
export type countdownValueType = number | string;
export type Formatter = false | 'number' | 'countdown' | ((value: valueType, config?: FormatConfig) => React.ReactNode);
export interface FormatConfig {
formatter?: Formatter;
decimalSeparator?: string;
groupSeparator?: string;
precision?: number;
}
export interface CountdownFormatConfig extends FormatConfig {
format?: string;
}
export declare function formatTimeStr(duration: number, format: string): string;
export declare function formatCountdown(value: valueType, config: CountdownFormatConfig): string;