@faasjs/ant-design 0.0.3-beta.2 → 0.0.3-beta.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +51 -314
- package/dist/index.d.ts +59 -100
- package/dist/index.js +177 -139
- package/dist/index.mjs +87 -48
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -43,48 +43,47 @@ Form are based on [Ant Design's Form.Item component](https://ant.design/componen
|
|
|
43
43
|
|
|
44
44
|
- [Form](modules/Form.md)
|
|
45
45
|
|
|
46
|
+
### Interfaces
|
|
47
|
+
|
|
48
|
+
- [BaseItemProps](interfaces/BaseItemProps.md)
|
|
49
|
+
- [BlankProps](interfaces/BlankProps.md)
|
|
50
|
+
- [ConfigProviderProps](interfaces/ConfigProviderProps.md)
|
|
51
|
+
- [DescriptionItemContentProps](interfaces/DescriptionItemContentProps.md)
|
|
52
|
+
- [DescriptionItemProps](interfaces/DescriptionItemProps.md)
|
|
53
|
+
- [DescriptionProps](interfaces/DescriptionProps.md)
|
|
54
|
+
- [DrawerProps](interfaces/DrawerProps.md)
|
|
55
|
+
- [ExtendDescriptionTypeProps](interfaces/ExtendDescriptionTypeProps.md)
|
|
56
|
+
- [FaasItemProps](interfaces/FaasItemProps.md)
|
|
57
|
+
- [FormItemProps](interfaces/FormItemProps.md)
|
|
58
|
+
- [FormProps](interfaces/FormProps.md)
|
|
59
|
+
- [LinkProps](interfaces/LinkProps.md)
|
|
60
|
+
- [ModalProps](interfaces/ModalProps.md)
|
|
61
|
+
- [RoutesProps](interfaces/RoutesProps.md)
|
|
62
|
+
- [TableItemProps](interfaces/TableItemProps.md)
|
|
63
|
+
- [TitleProps](interfaces/TitleProps.md)
|
|
64
|
+
|
|
46
65
|
### Type Aliases
|
|
47
66
|
|
|
48
|
-
- [BaseItemProps](#baseitemprops)
|
|
49
67
|
- [BaseOption](#baseoption)
|
|
50
|
-
- [BlankProps](#blankprops)
|
|
51
|
-
- [CalendarProps](#calendarprops)
|
|
52
|
-
- [ConfigProviderProps](#configproviderprops)
|
|
53
|
-
- [DatePickerProps](#datepickerprops)
|
|
54
|
-
- [DescriptionItemProps](#descriptionitemprops)
|
|
55
|
-
- [DescriptionProps](#descriptionprops)
|
|
56
|
-
- [DrawerProps](#drawerprops)
|
|
57
68
|
- [ExtendDescriptionItemProps](#extenddescriptionitemprops)
|
|
58
|
-
- [ExtendDescriptionTypeProps](#extenddescriptiontypeprops)
|
|
59
69
|
- [ExtendFormItemProps](#extendformitemprops)
|
|
60
70
|
- [ExtendFormTypeProps](#extendformtypeprops)
|
|
61
71
|
- [ExtendTableItemProps](#extendtableitemprops)
|
|
62
72
|
- [ExtendTableTypeProps](#extendtabletypeprops)
|
|
63
73
|
- [ExtendTypes](#extendtypes)
|
|
64
|
-
- [FaasItemProps](#faasitemprops)
|
|
65
74
|
- [FaasItemType](#faasitemtype)
|
|
66
75
|
- [FaasItemTypeValue](#faasitemtypevalue)
|
|
67
|
-
- [FormItemProps](#formitemprops)
|
|
68
|
-
- [FormProps](#formprops)
|
|
69
|
-
- [LinkProps](#linkprops)
|
|
70
|
-
- [ModalProps](#modalprops)
|
|
71
|
-
- [RoutesProps](#routesprops)
|
|
72
|
-
- [TableItemProps](#tableitemprops)
|
|
73
76
|
- [TableProps](#tableprops)
|
|
74
|
-
- [TimePickerProps](#timepickerprops)
|
|
75
|
-
- [TitleProps](#titleprops)
|
|
76
77
|
- [setDrawerProps](#setdrawerprops)
|
|
77
78
|
- [setModalProps](#setmodalprops)
|
|
78
79
|
|
|
79
80
|
### Variables
|
|
80
81
|
|
|
81
82
|
- [ConfigContext](#configcontext)
|
|
82
|
-
- [DatePicker](#datepicker)
|
|
83
83
|
|
|
84
84
|
### Functions
|
|
85
85
|
|
|
86
86
|
- [Blank](#blank)
|
|
87
|
-
- [Calendar](#calendar)
|
|
88
87
|
- [ConfigProvider](#configprovider)
|
|
89
88
|
- [Description](#description)
|
|
90
89
|
- [Form](#form)
|
|
@@ -93,7 +92,6 @@ Form are based on [Ant Design's Form.Item component](https://ant.design/componen
|
|
|
93
92
|
- [PageNotFound](#pagenotfound)
|
|
94
93
|
- [Routes](#routes)
|
|
95
94
|
- [Table](#table)
|
|
96
|
-
- [TimePicker](#timepicker)
|
|
97
95
|
- [Title](#title)
|
|
98
96
|
- [transferOptions](#transferoptions)
|
|
99
97
|
- [transferValue](#transfervalue)
|
|
@@ -103,138 +101,21 @@ Form are based on [Ant Design's Form.Item component](https://ant.design/componen
|
|
|
103
101
|
|
|
104
102
|
## Type Aliases
|
|
105
103
|
|
|
106
|
-
### BaseItemProps
|
|
107
|
-
|
|
108
|
-
Ƭ **BaseItemProps**: `Object`
|
|
109
|
-
|
|
110
|
-
#### Type declaration
|
|
111
|
-
|
|
112
|
-
| Name | Type |
|
|
113
|
-
| :------ | :------ |
|
|
114
|
-
| `id` | `string` |
|
|
115
|
-
| `options?` | [`BaseOption`](#baseoption)[] |
|
|
116
|
-
| `title?` | `string` |
|
|
117
|
-
|
|
118
|
-
___
|
|
119
|
-
|
|
120
104
|
### BaseOption
|
|
121
105
|
|
|
122
106
|
Ƭ **BaseOption**: `string` \| `number` \| { `label`: `string` ; `value?`: `string` \| `number` }
|
|
123
107
|
|
|
124
108
|
___
|
|
125
109
|
|
|
126
|
-
### BlankProps
|
|
127
|
-
|
|
128
|
-
Ƭ **BlankProps**: `Object`
|
|
129
|
-
|
|
130
|
-
#### Type declaration
|
|
131
|
-
|
|
132
|
-
| Name | Type |
|
|
133
|
-
| :------ | :------ |
|
|
134
|
-
| `text?` | `string` |
|
|
135
|
-
| `value?` | `any` |
|
|
136
|
-
|
|
137
|
-
___
|
|
138
|
-
|
|
139
|
-
### CalendarProps
|
|
140
|
-
|
|
141
|
-
Ƭ **CalendarProps**: `AntdProps`<`Dayjs`\>
|
|
142
|
-
|
|
143
|
-
___
|
|
144
|
-
|
|
145
|
-
### ConfigProviderProps
|
|
146
|
-
|
|
147
|
-
Ƭ **ConfigProviderProps**: `Object`
|
|
148
|
-
|
|
149
|
-
#### Type declaration
|
|
150
|
-
|
|
151
|
-
| Name | Type |
|
|
152
|
-
| :------ | :------ |
|
|
153
|
-
| `Blank?` | { `text?`: `string` } |
|
|
154
|
-
| `Blank.text?` | `string` |
|
|
155
|
-
| `Form?` | { `submit?`: { `text?`: `string` } } |
|
|
156
|
-
| `Form.submit?` | { `text?`: `string` } |
|
|
157
|
-
| `Form.submit.text?` | `string` |
|
|
158
|
-
| `Link?` | { `style?`: `CSSProperties` ; `target?`: `string` } |
|
|
159
|
-
| `Link.style?` | `CSSProperties` |
|
|
160
|
-
| `Link.target?` | `string` |
|
|
161
|
-
| `Title?` | { `separator?`: `string` ; `suffix?`: `string` } |
|
|
162
|
-
| `Title.separator?` | `string` |
|
|
163
|
-
| `Title.suffix?` | `string` |
|
|
164
|
-
| `antd?` | `AntdConfigProviderProps` |
|
|
165
|
-
| `common?` | { `add?`: `string` ; `all?`: `string` ; `blank?`: `string` ; `delete?`: `string` ; `pageNotFound?`: `string` ; `required?`: `string` ; `reset?`: `string` ; `search?`: `string` ; `submit?`: `string` } |
|
|
166
|
-
| `common.add?` | `string` |
|
|
167
|
-
| `common.all?` | `string` |
|
|
168
|
-
| `common.blank?` | `string` |
|
|
169
|
-
| `common.delete?` | `string` |
|
|
170
|
-
| `common.pageNotFound?` | `string` |
|
|
171
|
-
| `common.required?` | `string` |
|
|
172
|
-
| `common.reset?` | `string` |
|
|
173
|
-
| `common.search?` | `string` |
|
|
174
|
-
| `common.submit?` | `string` |
|
|
175
|
-
| `lang?` | `string` |
|
|
176
|
-
|
|
177
|
-
___
|
|
178
|
-
|
|
179
|
-
### DatePickerProps
|
|
180
|
-
|
|
181
|
-
Ƭ **DatePickerProps**: `PickerDateProps`<`Dayjs`\>
|
|
182
|
-
|
|
183
|
-
___
|
|
184
|
-
|
|
185
|
-
### DescriptionItemProps
|
|
186
|
-
|
|
187
|
-
Ƭ **DescriptionItemProps**<`T`\>: { `children?`: `JSX.Element` ; `if?`: (`values`: `Record`<`string`, `any`\>) => `boolean` ; `render?`: (`value`: `T`, `values`: `any`) => `ReactNode` \| `JSX.Element` } & [`FaasItemProps`](#faasitemprops) & { `object?`: [`DescriptionItemProps`](#descriptionitemprops)[] }
|
|
188
|
-
|
|
189
|
-
#### Type parameters
|
|
190
|
-
|
|
191
|
-
| Name | Type |
|
|
192
|
-
| :------ | :------ |
|
|
193
|
-
| `T` | `any` |
|
|
194
|
-
|
|
195
|
-
___
|
|
196
|
-
|
|
197
|
-
### DescriptionProps
|
|
198
|
-
|
|
199
|
-
Ƭ **DescriptionProps**<`T`, `ExtendItemProps`\>: { `dataSource?`: `T` ; `extendTypes?`: { `[key: string]`: [`ExtendDescriptionTypeProps`](#extenddescriptiontypeprops); } ; `faasData?`: `FaasDataWrapperProps`<`T`\> ; `items`: ([`DescriptionItemProps`](#descriptionitemprops) \| `ExtendItemProps`)[] ; `renderTitle?`: (`values`: `T`) => `ReactNode` \| `JSX.Element` } & `DescriptionsProps`
|
|
200
|
-
|
|
201
|
-
#### Type parameters
|
|
202
|
-
|
|
203
|
-
| Name | Type |
|
|
204
|
-
| :------ | :------ |
|
|
205
|
-
| `T` | `any` |
|
|
206
|
-
| `ExtendItemProps` | `any` |
|
|
207
|
-
|
|
208
|
-
___
|
|
209
|
-
|
|
210
|
-
### DrawerProps
|
|
211
|
-
|
|
212
|
-
Ƭ **DrawerProps**: `AntdDrawerProps` & { `children?`: `JSX.Element` \| `JSX.Element`[] }
|
|
213
|
-
|
|
214
|
-
___
|
|
215
|
-
|
|
216
110
|
### ExtendDescriptionItemProps
|
|
217
111
|
|
|
218
|
-
Ƭ **ExtendDescriptionItemProps**: [`BaseItemProps`](
|
|
219
|
-
|
|
220
|
-
___
|
|
221
|
-
|
|
222
|
-
### ExtendDescriptionTypeProps
|
|
223
|
-
|
|
224
|
-
Ƭ **ExtendDescriptionTypeProps**: `Object`
|
|
225
|
-
|
|
226
|
-
#### Type declaration
|
|
227
|
-
|
|
228
|
-
| Name | Type |
|
|
229
|
-
| :------ | :------ |
|
|
230
|
-
| `children?` | `JSX.Element` \| ``null`` |
|
|
231
|
-
| `render?` | (`value`: `any`, `values`: `any`) => `ReactNode` \| `JSX.Element` |
|
|
112
|
+
Ƭ **ExtendDescriptionItemProps**: [`BaseItemProps`](interfaces/BaseItemProps.md)
|
|
232
113
|
|
|
233
114
|
___
|
|
234
115
|
|
|
235
116
|
### ExtendFormItemProps
|
|
236
117
|
|
|
237
|
-
Ƭ **ExtendFormItemProps**: [`BaseItemProps`](
|
|
118
|
+
Ƭ **ExtendFormItemProps**: [`BaseItemProps`](interfaces/BaseItemProps.md) & `AntdFormItemProps`
|
|
238
119
|
|
|
239
120
|
___
|
|
240
121
|
|
|
@@ -252,7 +133,7 @@ ___
|
|
|
252
133
|
|
|
253
134
|
### ExtendTableItemProps
|
|
254
135
|
|
|
255
|
-
Ƭ **ExtendTableItemProps**<`T`\>: [`BaseItemProps`](
|
|
136
|
+
Ƭ **ExtendTableItemProps**<`T`\>: [`BaseItemProps`](interfaces/BaseItemProps.md) & `Omit`<`AntdTableColumnProps`<`T`\>, ``"children"``\>
|
|
256
137
|
|
|
257
138
|
#### Type parameters
|
|
258
139
|
|
|
@@ -270,7 +151,7 @@ ___
|
|
|
270
151
|
|
|
271
152
|
| Name | Type |
|
|
272
153
|
| :------ | :------ |
|
|
273
|
-
| `children?` | `JSX.Element`
|
|
154
|
+
| `children?` | `JSX.Element` |
|
|
274
155
|
| `render?` | (`value`: `any`, `values`: `any`, `index`: `number`) => `JSX.Element` \| `string` \| `number` \| `boolean` \| ``null`` |
|
|
275
156
|
|
|
276
157
|
___
|
|
@@ -285,12 +166,6 @@ ___
|
|
|
285
166
|
|
|
286
167
|
___
|
|
287
168
|
|
|
288
|
-
### FaasItemProps
|
|
289
|
-
|
|
290
|
-
Ƭ **FaasItemProps**: [`BaseItemProps`](#baseitemprops) & { `type?`: [`FaasItemType`](#faasitemtype) }
|
|
291
|
-
|
|
292
|
-
___
|
|
293
|
-
|
|
294
169
|
### FaasItemType
|
|
295
170
|
|
|
296
171
|
Ƭ **FaasItemType**: ``"string"`` \| ``"string[]"`` \| ``"number"`` \| ``"number[]"`` \| ``"boolean"`` \| ``"date"`` \| ``"time"`` \| ``"object"`` \| ``"object[]"``
|
|
@@ -319,83 +194,9 @@ FaasItemType's value type
|
|
|
319
194
|
|
|
320
195
|
___
|
|
321
196
|
|
|
322
|
-
### FormItemProps
|
|
323
|
-
|
|
324
|
-
Ƭ **FormItemProps**<`T`\>: { `children?`: `ReactNode` ; `extendTypes?`: [`ExtendTypes`](#extendtypes) ; `if?`: (`values`: `Record`<`string`, `any`\>) => `boolean` ; `label?`: `string` \| ``false`` ; `onValueChange?`: (`value`: `T`, `values`: `any`, `form`: `FormInstance`) => `void` ; `render?`: (`value?`: `T`) => `ReactNode` \| `JSX.Element` ; `rules?`: `RuleObject`[] } & `FormItemInputProps` & [`FaasItemProps`](#faasitemprops) & `Omit`<`AntdFormItemProps`<`T`\>, ``"children"``\>
|
|
325
|
-
|
|
326
|
-
#### Type parameters
|
|
327
|
-
|
|
328
|
-
| Name | Type |
|
|
329
|
-
| :------ | :------ |
|
|
330
|
-
| `T` | `any` |
|
|
331
|
-
|
|
332
|
-
___
|
|
333
|
-
|
|
334
|
-
### FormProps
|
|
335
|
-
|
|
336
|
-
Ƭ **FormProps**<`Values`, `ExtendItemProps`\>: { `beforeItems?`: `JSX.Element` \| `JSX.Element`[] ; `children?`: `ReactNode` ; `extendTypes?`: [`ExtendTypes`](#extendtypes) ; `footer?`: `JSX.Element` \| `JSX.Element`[] ; `initialValues?`: `Values` ; `items?`: ([`FormItemProps`](#formitemprops) \| `ExtendItemProps`)[] ; `onFinish?`: (`values`: `Values`, `submit?`: (`values`: `any`) => `Promise`<`any`\>) => `Promise`<`any`\> ; `submit?`: ``false`` \| { `text?`: `string` ; `to?`: { `action`: `string` ; `params?`: `Record`<`string`, `any`\> } } } & `Omit`<`AntdFormProps`<`Values`\>, ``"onFinish"`` \| ``"children"`` \| ``"initialValues"``\>
|
|
337
|
-
|
|
338
|
-
#### Type parameters
|
|
339
|
-
|
|
340
|
-
| Name | Type |
|
|
341
|
-
| :------ | :------ |
|
|
342
|
-
| `Values` | extends `Record`<`string`, `any`\> = `any` |
|
|
343
|
-
| `ExtendItemProps` | `any` |
|
|
344
|
-
|
|
345
|
-
___
|
|
346
|
-
|
|
347
|
-
### LinkProps
|
|
348
|
-
|
|
349
|
-
Ƭ **LinkProps**: `Object`
|
|
350
|
-
|
|
351
|
-
#### Type declaration
|
|
352
|
-
|
|
353
|
-
| Name | Type |
|
|
354
|
-
| :------ | :------ |
|
|
355
|
-
| `button?` | `ButtonProps` |
|
|
356
|
-
| `children?` | `ReactNode` |
|
|
357
|
-
| `href` | `string` |
|
|
358
|
-
| `style?` | `CSSProperties` |
|
|
359
|
-
| `target?` | `string` |
|
|
360
|
-
| `text?` | `string` \| `number` |
|
|
361
|
-
|
|
362
|
-
___
|
|
363
|
-
|
|
364
|
-
### ModalProps
|
|
365
|
-
|
|
366
|
-
Ƭ **ModalProps**: `AntdModalProps` & { `children?`: `JSX.Element` \| `JSX.Element`[] \| `string` }
|
|
367
|
-
|
|
368
|
-
___
|
|
369
|
-
|
|
370
|
-
### RoutesProps
|
|
371
|
-
|
|
372
|
-
Ƭ **RoutesProps**: `Object`
|
|
373
|
-
|
|
374
|
-
#### Type declaration
|
|
375
|
-
|
|
376
|
-
| Name | Type |
|
|
377
|
-
| :------ | :------ |
|
|
378
|
-
| `fallback?` | `JSX.Element` |
|
|
379
|
-
| `notFound?` | `JSX.Element` |
|
|
380
|
-
| `routes` | `RouteProps` & { `page?`: `LazyExoticComponent`<`ComponentType`<`any`\>\> }[] |
|
|
381
|
-
|
|
382
|
-
___
|
|
383
|
-
|
|
384
|
-
### TableItemProps
|
|
385
|
-
|
|
386
|
-
Ƭ **TableItemProps**<`T`\>: { `children?`: `JSX.Element` \| ``null`` ; `object?`: [`TableItemProps`](#tableitemprops)[] ; `optionsType?`: ``"auto"`` } & [`FaasItemProps`](#faasitemprops) & `Omit`<`AntdTableColumnProps`<`T`\>, ``"children"``\>
|
|
387
|
-
|
|
388
|
-
#### Type parameters
|
|
389
|
-
|
|
390
|
-
| Name | Type |
|
|
391
|
-
| :------ | :------ |
|
|
392
|
-
| `T` | `any` |
|
|
393
|
-
|
|
394
|
-
___
|
|
395
|
-
|
|
396
197
|
### TableProps
|
|
397
198
|
|
|
398
|
-
Ƭ **TableProps**<`T`, `ExtendTypes`\>: { `extendTypes?`: { `[key: string]`: [`ExtendTableTypeProps`](#extendtabletypeprops); } ; `faasData?`: `FaasDataWrapperProps`<`T`\> ; `items`: ([`TableItemProps`](
|
|
199
|
+
Ƭ **TableProps**<`T`, `ExtendTypes`\>: { `extendTypes?`: { `[key: string]`: [`ExtendTableTypeProps`](#extendtabletypeprops); } ; `faasData?`: `FaasDataWrapperProps`<`T`\> ; `items`: ([`TableItemProps`](interfaces/TableItemProps.md) \| `ExtendTypes` & [`ExtendTableItemProps`](#extendtableitemprops))[] ; `onChange?`: (`pagination`: `TablePaginationConfig`, `filters`: `Record`<`string`, `FilterValue` \| ``null``\>, `sorter`: `SorterResult`<`T`\> \| `SorterResult`<`T`\>[], `extra`: `TableCurrentDataSource`<`T`\>) => { `extra`: `TableCurrentDataSource`<`T`\> ; `filters`: `Record`<`string`, `FilterValue` \| ``null``\> ; `pagination`: `TablePaginationConfig` ; `sorter`: `SorterResult`<`T`\> \| `SorterResult`<`T`\>[] } } & `AntdTableProps`<`T`\>
|
|
399
200
|
|
|
400
201
|
#### Type parameters
|
|
401
202
|
|
|
@@ -406,33 +207,9 @@ ___
|
|
|
406
207
|
|
|
407
208
|
___
|
|
408
209
|
|
|
409
|
-
### TimePickerProps
|
|
410
|
-
|
|
411
|
-
Ƭ **TimePickerProps**: `Omit`<`PickerTimeProps`<`Dayjs`\>, ``"picker"``\>
|
|
412
|
-
|
|
413
|
-
___
|
|
414
|
-
|
|
415
|
-
### TitleProps
|
|
416
|
-
|
|
417
|
-
Ƭ **TitleProps**: `Object`
|
|
418
|
-
|
|
419
|
-
#### Type declaration
|
|
420
|
-
|
|
421
|
-
| Name | Type | Description |
|
|
422
|
-
| :------ | :------ | :------ |
|
|
423
|
-
| `children?` | `JSX.Element` | return children |
|
|
424
|
-
| `h1?` | `boolean` \| { `className?`: `string` ; `style?`: `React.CSSProperties` } | return a h1 element |
|
|
425
|
-
| `header?` | `PageHeaderProps` | return a PageHeader element |
|
|
426
|
-
| `plain?` | `boolean` | return a pure text element |
|
|
427
|
-
| `separator?` | `string` | ` - ` as default |
|
|
428
|
-
| `suffix?` | `string` | - |
|
|
429
|
-
| `title` | `string` \| `string`[] | - |
|
|
430
|
-
|
|
431
|
-
___
|
|
432
|
-
|
|
433
210
|
### setDrawerProps
|
|
434
211
|
|
|
435
|
-
Ƭ **setDrawerProps**: (`changes`: `Partial`<[`DrawerProps`](
|
|
212
|
+
Ƭ **setDrawerProps**: (`changes`: `Partial`<[`DrawerProps`](interfaces/DrawerProps.md)\>) => `void`
|
|
436
213
|
|
|
437
214
|
#### Type declaration
|
|
438
215
|
|
|
@@ -442,7 +219,7 @@ ___
|
|
|
442
219
|
|
|
443
220
|
| Name | Type |
|
|
444
221
|
| :------ | :------ |
|
|
445
|
-
| `changes` | `Partial`<[`DrawerProps`](
|
|
222
|
+
| `changes` | `Partial`<[`DrawerProps`](interfaces/DrawerProps.md)\> |
|
|
446
223
|
|
|
447
224
|
##### Returns
|
|
448
225
|
|
|
@@ -452,7 +229,7 @@ ___
|
|
|
452
229
|
|
|
453
230
|
### setModalProps
|
|
454
231
|
|
|
455
|
-
Ƭ **setModalProps**: (`changes`: `Partial`<[`ModalProps`](
|
|
232
|
+
Ƭ **setModalProps**: (`changes`: `Partial`<[`ModalProps`](interfaces/ModalProps.md)\>) => `void`
|
|
456
233
|
|
|
457
234
|
#### Type declaration
|
|
458
235
|
|
|
@@ -462,7 +239,7 @@ ___
|
|
|
462
239
|
|
|
463
240
|
| Name | Type |
|
|
464
241
|
| :------ | :------ |
|
|
465
|
-
| `changes` | `Partial`<[`ModalProps`](
|
|
242
|
+
| `changes` | `Partial`<[`ModalProps`](interfaces/ModalProps.md)\> |
|
|
466
243
|
|
|
467
244
|
##### Returns
|
|
468
245
|
|
|
@@ -472,13 +249,7 @@ ___
|
|
|
472
249
|
|
|
473
250
|
### ConfigContext
|
|
474
251
|
|
|
475
|
-
• `Const` **ConfigContext**: `Context`<[`ConfigProviderProps`](
|
|
476
|
-
|
|
477
|
-
___
|
|
478
|
-
|
|
479
|
-
### DatePicker
|
|
480
|
-
|
|
481
|
-
• `Const` **DatePicker**: `PickerComponentClass`<`Object`, `unknown`\> & {}
|
|
252
|
+
• `Const` **ConfigContext**: `Context`<[`ConfigProviderProps`](interfaces/ConfigProviderProps.md)\>
|
|
482
253
|
|
|
483
254
|
## Functions
|
|
484
255
|
|
|
@@ -492,7 +263,7 @@ If value is undefined or null, return text, otherwise return value.
|
|
|
492
263
|
|
|
493
264
|
| Name | Type | Description |
|
|
494
265
|
| :------ | :------ | :------ |
|
|
495
|
-
| `options?` | [`BlankProps`](
|
|
266
|
+
| `options?` | [`BlankProps`](interfaces/BlankProps.md) | {object} |
|
|
496
267
|
|
|
497
268
|
#### Returns
|
|
498
269
|
|
|
@@ -504,25 +275,9 @@ If value is undefined or null, return text, otherwise return value.
|
|
|
504
275
|
|
|
505
276
|
___
|
|
506
277
|
|
|
507
|
-
### Calendar
|
|
508
|
-
|
|
509
|
-
▸ **Calendar**(`props`): `Element`
|
|
510
|
-
|
|
511
|
-
#### Parameters
|
|
512
|
-
|
|
513
|
-
| Name | Type |
|
|
514
|
-
| :------ | :------ |
|
|
515
|
-
| `props` | `CalendarProps`<`Dayjs`\> |
|
|
516
|
-
|
|
517
|
-
#### Returns
|
|
518
|
-
|
|
519
|
-
`Element`
|
|
520
|
-
|
|
521
|
-
___
|
|
522
|
-
|
|
523
278
|
### ConfigProvider
|
|
524
279
|
|
|
525
|
-
▸ **ConfigProvider**(
|
|
280
|
+
▸ **ConfigProvider**(`«destructured»`): `Element`
|
|
526
281
|
|
|
527
282
|
Config for @faasjs/ant-design components.
|
|
528
283
|
|
|
@@ -540,9 +295,9 @@ Config for @faasjs/ant-design components.
|
|
|
540
295
|
|
|
541
296
|
| Name | Type |
|
|
542
297
|
| :------ | :------ |
|
|
543
|
-
|
|
|
544
|
-
| `
|
|
545
|
-
| `
|
|
298
|
+
| `«destructured»` | `Object` |
|
|
299
|
+
| › `children` | `ReactNode` |
|
|
300
|
+
| › `config` | [`ConfigProviderProps`](interfaces/ConfigProviderProps.md) |
|
|
546
301
|
|
|
547
302
|
#### Returns
|
|
548
303
|
|
|
@@ -564,7 +319,7 @@ ___
|
|
|
564
319
|
|
|
565
320
|
| Name | Type |
|
|
566
321
|
| :------ | :------ |
|
|
567
|
-
| `props` | [`DescriptionProps`](
|
|
322
|
+
| `props` | [`DescriptionProps`](interfaces/DescriptionProps.md)<`T`, `any`\> |
|
|
568
323
|
|
|
569
324
|
#### Returns
|
|
570
325
|
|
|
@@ -592,7 +347,7 @@ https://ant.design/components/form/
|
|
|
592
347
|
|
|
593
348
|
| Name | Type |
|
|
594
349
|
| :------ | :------ |
|
|
595
|
-
| `props` | [`FormProps`](
|
|
350
|
+
| `props` | [`FormProps`](interfaces/FormProps.md)<`Values`, `any`\> |
|
|
596
351
|
|
|
597
352
|
#### Returns
|
|
598
353
|
|
|
@@ -608,10 +363,10 @@ FormItem, can be used without Form.
|
|
|
608
363
|
|
|
609
364
|
```ts
|
|
610
365
|
// use inline type
|
|
611
|
-
<FormItem
|
|
366
|
+
<FormItem type='string' id='name' />
|
|
612
367
|
|
|
613
368
|
// use custom type
|
|
614
|
-
<FormItem
|
|
369
|
+
<FormItem id='password'>
|
|
615
370
|
<Input.Password />
|
|
616
371
|
</>
|
|
617
372
|
```
|
|
@@ -626,7 +381,7 @@ FormItem, can be used without Form.
|
|
|
626
381
|
|
|
627
382
|
| Name | Type |
|
|
628
383
|
| :------ | :------ |
|
|
629
|
-
| `props` | [`FormItemProps`](
|
|
384
|
+
| `props` | [`FormItemProps`](interfaces/FormItemProps.md)<`T`\> |
|
|
630
385
|
|
|
631
386
|
#### Returns
|
|
632
387
|
|
|
@@ -636,7 +391,7 @@ ___
|
|
|
636
391
|
|
|
637
392
|
### Link
|
|
638
393
|
|
|
639
|
-
▸ **Link**(
|
|
394
|
+
▸ **Link**(`«destructured»`): `Element`
|
|
640
395
|
|
|
641
396
|
```ts
|
|
642
397
|
// pure link
|
|
@@ -650,7 +405,7 @@ ___
|
|
|
650
405
|
|
|
651
406
|
| Name | Type |
|
|
652
407
|
| :------ | :------ |
|
|
653
|
-
|
|
|
408
|
+
| `«destructured»` | [`LinkProps`](interfaces/LinkProps.md) |
|
|
654
409
|
|
|
655
410
|
#### Returns
|
|
656
411
|
|
|
@@ -694,7 +449,7 @@ export function App () {
|
|
|
694
449
|
|
|
695
450
|
| Name | Type |
|
|
696
451
|
| :------ | :------ |
|
|
697
|
-
| `props` | [`RoutesProps`](
|
|
452
|
+
| `props` | [`RoutesProps`](interfaces/RoutesProps.md) |
|
|
698
453
|
|
|
699
454
|
#### Returns
|
|
700
455
|
|
|
@@ -731,24 +486,6 @@ https://ant.design/components/table/
|
|
|
731
486
|
|
|
732
487
|
___
|
|
733
488
|
|
|
734
|
-
### TimePicker
|
|
735
|
-
|
|
736
|
-
▸ **TimePicker**(`props`): `ReactElement`<`any`, `string` \| `JSXElementConstructor`<`any`\>\>
|
|
737
|
-
|
|
738
|
-
**NOTE**: Exotic components are not callable.
|
|
739
|
-
|
|
740
|
-
#### Parameters
|
|
741
|
-
|
|
742
|
-
| Name | Type |
|
|
743
|
-
| :------ | :------ |
|
|
744
|
-
| `props` | [`TimePickerProps`](#timepickerprops) & `RefAttributes`<`any`\> |
|
|
745
|
-
|
|
746
|
-
#### Returns
|
|
747
|
-
|
|
748
|
-
`ReactElement`<`any`, `string` \| `JSXElementConstructor`<`any`\>\>
|
|
749
|
-
|
|
750
|
-
___
|
|
751
|
-
|
|
752
489
|
### Title
|
|
753
490
|
|
|
754
491
|
▸ **Title**(`props`): `JSX.Element`
|
|
@@ -773,7 +510,7 @@ Return null by default.
|
|
|
773
510
|
|
|
774
511
|
| Name | Type |
|
|
775
512
|
| :------ | :------ |
|
|
776
|
-
| `props` | [`TitleProps`](
|
|
513
|
+
| `props` | [`TitleProps`](interfaces/TitleProps.md) |
|
|
777
514
|
|
|
778
515
|
#### Returns
|
|
779
516
|
|
|
@@ -816,11 +553,11 @@ ___
|
|
|
816
553
|
|
|
817
554
|
### useConfigContext
|
|
818
555
|
|
|
819
|
-
▸ **useConfigContext**(): [`ConfigProviderProps`](
|
|
556
|
+
▸ **useConfigContext**(): [`ConfigProviderProps`](interfaces/ConfigProviderProps.md)
|
|
820
557
|
|
|
821
558
|
#### Returns
|
|
822
559
|
|
|
823
|
-
[`ConfigProviderProps`](
|
|
560
|
+
[`ConfigProviderProps`](interfaces/ConfigProviderProps.md)
|
|
824
561
|
|
|
825
562
|
___
|
|
826
563
|
|
|
@@ -834,7 +571,7 @@ Hook style drawer.
|
|
|
834
571
|
|
|
835
572
|
| Name | Type | Description |
|
|
836
573
|
| :------ | :------ | :------ |
|
|
837
|
-
| `init?` | [`DrawerProps`](
|
|
574
|
+
| `init?` | [`DrawerProps`](interfaces/DrawerProps.md) | initial props ```ts function Example() { const { drawer, setDrawerProps } = useDrawer() return <> <Button onClick={ () => setDrawerProps(prev => ({ open: !prev.open})) }> Toggle </Button> {drawer} </> } ``` |
|
|
838
575
|
|
|
839
576
|
#### Returns
|
|
840
577
|
|
|
@@ -843,8 +580,8 @@ Hook style drawer.
|
|
|
843
580
|
| Name | Type |
|
|
844
581
|
| :------ | :------ |
|
|
845
582
|
| `drawer` | `Element` |
|
|
846
|
-
| `drawerProps` | [`DrawerProps`](
|
|
847
|
-
| `setDrawerProps` | (`changes`: `Partial`<[`DrawerProps`](
|
|
583
|
+
| `drawerProps` | [`DrawerProps`](interfaces/DrawerProps.md) |
|
|
584
|
+
| `setDrawerProps` | (`changes`: `Partial`<[`DrawerProps`](interfaces/DrawerProps.md)\>) => `void` |
|
|
848
585
|
|
|
849
586
|
___
|
|
850
587
|
|
|
@@ -858,7 +595,7 @@ Hook style modal.
|
|
|
858
595
|
|
|
859
596
|
| Name | Type | Description |
|
|
860
597
|
| :------ | :------ | :------ |
|
|
861
|
-
| `init?` | [`ModalProps`](
|
|
598
|
+
| `init?` | [`ModalProps`](interfaces/ModalProps.md) | initial props ```ts function Example() { const { modal, setModalProps } = useModal() return <> <Button onClick={() => setModalProps({ open: true })}>Open Modal</Button> {modal}</> } ``` |
|
|
862
599
|
|
|
863
600
|
#### Returns
|
|
864
601
|
|
|
@@ -867,5 +604,5 @@ Hook style modal.
|
|
|
867
604
|
| Name | Type |
|
|
868
605
|
| :------ | :------ |
|
|
869
606
|
| `modal` | `Element` |
|
|
870
|
-
| `modalProps` | [`ModalProps`](
|
|
871
|
-
| `setModalProps` | (`changes`: `Partial`<[`ModalProps`](
|
|
607
|
+
| `modalProps` | [`ModalProps`](interfaces/ModalProps.md) |
|
|
608
|
+
| `setModalProps` | (`changes`: `Partial`<[`ModalProps`](interfaces/ModalProps.md)\>) => `void` |
|