minishouyin/node_modules/antd/es/statistic/utils.d.ts

16 lines
671 B
TypeScript
Raw Permalink Normal View History

2025-11-12 11:35:57 +08:00
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 formatCounter(value: valueType, config: CountdownFormatConfig, down: boolean): string;