1 |
|
2 |
|
3 | import * as React from 'react';
|
4 | import CommonProps from '../util';
|
5 |
|
6 | interface HTMLAttributesWeak extends React.HTMLAttributes<HTMLElement> {
|
7 | title?: any;
|
8 | onClick?: any;
|
9 | }
|
10 |
|
11 | export interface ItemProps extends HTMLAttributesWeak, CommonProps {
|
12 | |
13 |
|
14 |
|
15 | status?: 'wait' | 'process' | 'finish';
|
16 |
|
17 | |
18 |
|
19 |
|
20 | title?: React.ReactNode;
|
21 |
|
22 | |
23 |
|
24 |
|
25 | icon?: string;
|
26 |
|
27 | |
28 |
|
29 |
|
30 | content?: React.ReactNode;
|
31 |
|
32 | |
33 |
|
34 |
|
35 | itemRender?: (index: number, status: string) => React.ReactNode;
|
36 |
|
37 | |
38 |
|
39 |
|
40 | percent?: number;
|
41 |
|
42 | |
43 |
|
44 |
|
45 | disabled?: boolean;
|
46 |
|
47 | |
48 |
|
49 |
|
50 | onClick?: (index: number) => void;
|
51 |
|
52 | |
53 |
|
54 |
|
55 | className?: string;
|
56 | }
|
57 |
|
58 | export class Item extends React.Component<ItemProps, any> {}
|
59 | export interface StepProps extends React.HTMLAttributes<HTMLElement>, CommonProps {
|
60 | |
61 |
|
62 |
|
63 | current?: number;
|
64 |
|
65 | |
66 |
|
67 |
|
68 | direction?: 'hoz' | 'ver';
|
69 | |
70 |
|
71 |
|
72 | stretch?: boolean;
|
73 | |
74 |
|
75 |
|
76 | labelPlacement?: 'hoz' | 'ver';
|
77 |
|
78 | |
79 |
|
80 |
|
81 | shape?: 'circle' | 'arrow' | 'dot';
|
82 |
|
83 | |
84 |
|
85 |
|
86 | readOnly?: boolean;
|
87 |
|
88 | |
89 |
|
90 |
|
91 | animation?: boolean;
|
92 |
|
93 | |
94 |
|
95 |
|
96 | className?: string;
|
97 |
|
98 | |
99 |
|
100 |
|
101 | itemRender?: (index: number, status: string) => React.ReactNode;
|
102 | }
|
103 |
|
104 | export default class Step extends React.Component<StepProps, any> {
|
105 | static Item: typeof Item;
|
106 | }
|