UNPKG

@aimake/nanod

Version:

## 设计模式 NANO DESIGN 是面向于企业级中台化应用的解决方案。服务于 ToB 和 ToE 类型的单页应用,应用于各产品中从而产出了一套设计及前端规范。

51 lines (50 loc) 1.77 kB
import * as React from 'react'; import { Component } from 'react'; import { ConfigConsumerProps } from '../config-provider'; export interface ScrollNumberProps { prefixCls?: string; className?: string; count?: string | number | null; displayComponent?: React.ReactElement<any>; component?: string; onAnimated?: Function; style?: React.CSSProperties; title?: string | number | null; } export interface ScrollNumberState { animateStarted?: boolean; count?: string | number | null; } export default class ScrollNumber extends Component<ScrollNumberProps, ScrollNumberState> { static defaultProps: { count: null; onAnimated(): void; }; lastCount: any; constructor(props: ScrollNumberProps); getPositionByNum(num: number, i: number): number; componentWillReceiveProps(nextProps: ScrollNumberProps): void; renderNumberList(position: number): React.ReactElement<any>[]; renderCurrentNumber(prefixCls: string, num: number, i: number): React.DetailedReactHTMLElement<{ className: string; style: { transition: string | undefined; msTransform: string; WebkitTransform: string; transform: string; }; key: number; }, HTMLElement>; renderNumberElement(prefixCls: string): string | number | React.DetailedReactHTMLElement<{ className: string; style: { transition: string | undefined; msTransform: string; WebkitTransform: string; transform: string; }; key: number; }, HTMLElement>[] | null | undefined; renderScrollNumber: ({ getPrefixCls }: ConfigConsumerProps) => React.ReactElement<any>; render(): JSX.Element; }