@faasjs/ant-design 0.0.3-beta.15 → 0.0.3-beta.16

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 CHANGED
@@ -43,33 +43,37 @@ 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
- - [ConfigProviderProps](#configproviderprops)
52
- - [DescriptionItemProps](#descriptionitemprops)
53
- - [DescriptionProps](#descriptionprops)
54
- - [DrawerProps](#drawerprops)
55
68
  - [ExtendDescriptionItemProps](#extenddescriptionitemprops)
56
- - [ExtendDescriptionTypeProps](#extenddescriptiontypeprops)
57
69
  - [ExtendFormItemProps](#extendformitemprops)
58
70
  - [ExtendFormTypeProps](#extendformtypeprops)
59
71
  - [ExtendTableItemProps](#extendtableitemprops)
60
72
  - [ExtendTableTypeProps](#extendtabletypeprops)
61
73
  - [ExtendTypes](#extendtypes)
62
- - [FaasItemProps](#faasitemprops)
63
74
  - [FaasItemType](#faasitemtype)
64
75
  - [FaasItemTypeValue](#faasitemtypevalue)
65
- - [FormItemProps](#formitemprops)
66
- - [FormProps](#formprops)
67
- - [LinkProps](#linkprops)
68
- - [ModalProps](#modalprops)
69
- - [RoutesProps](#routesprops)
70
- - [TableItemProps](#tableitemprops)
71
76
  - [TableProps](#tableprops)
72
- - [TitleProps](#titleprops)
73
77
  - [setDrawerProps](#setdrawerprops)
74
78
  - [setModalProps](#setmodalprops)
75
79
 
@@ -97,126 +101,21 @@ Form are based on [Ant Design's Form.Item component](https://ant.design/componen
97
101
 
98
102
  ## Type Aliases
99
103
 
100
- ### BaseItemProps
101
-
102
- Ƭ **BaseItemProps**: `Object`
103
-
104
- #### Type declaration
105
-
106
- | Name | Type |
107
- | :------ | :------ |
108
- | `id` | `string` |
109
- | `options?` | [`BaseOption`](#baseoption)[] |
110
- | `title?` | `string` |
111
-
112
- ___
113
-
114
104
  ### BaseOption
115
105
 
116
106
  Ƭ **BaseOption**: `string` \| `number` \| { `label`: `string` ; `value?`: `string` \| `number` }
117
107
 
118
108
  ___
119
109
 
120
- ### BlankProps
121
-
122
- Ƭ **BlankProps**: `Object`
123
-
124
- #### Type declaration
125
-
126
- | Name | Type |
127
- | :------ | :------ |
128
- | `text?` | `string` |
129
- | `value?` | `any` |
130
-
131
- ___
132
-
133
- ### ConfigProviderProps
134
-
135
- Ƭ **ConfigProviderProps**: `Object`
136
-
137
- #### Type declaration
138
-
139
- | Name | Type |
140
- | :------ | :------ |
141
- | `Blank?` | { `text?`: `string` } |
142
- | `Blank.text?` | `string` |
143
- | `Form?` | { `submit?`: { `text?`: `string` } } |
144
- | `Form.submit?` | { `text?`: `string` } |
145
- | `Form.submit.text?` | `string` |
146
- | `Link?` | { `style?`: `CSSProperties` ; `target?`: `string` } |
147
- | `Link.style?` | `CSSProperties` |
148
- | `Link.target?` | `string` |
149
- | `Title?` | { `separator?`: `string` ; `suffix?`: `string` } |
150
- | `Title.separator?` | `string` |
151
- | `Title.suffix?` | `string` |
152
- | `antd?` | `AntdConfigProviderProps` |
153
- | `common?` | { `add?`: `string` ; `all?`: `string` ; `blank?`: `string` ; `delete?`: `string` ; `pageNotFound?`: `string` ; `required?`: `string` ; `reset?`: `string` ; `search?`: `string` ; `submit?`: `string` } |
154
- | `common.add?` | `string` |
155
- | `common.all?` | `string` |
156
- | `common.blank?` | `string` |
157
- | `common.delete?` | `string` |
158
- | `common.pageNotFound?` | `string` |
159
- | `common.required?` | `string` |
160
- | `common.reset?` | `string` |
161
- | `common.search?` | `string` |
162
- | `common.submit?` | `string` |
163
- | `lang?` | `string` |
164
-
165
- ___
166
-
167
- ### DescriptionItemProps
168
-
169
- Ƭ **DescriptionItemProps**<`T`\>: { `children?`: `JSX.Element` ; `if?`: (`values`: `Record`<`string`, `any`\>) => `boolean` ; `render?`: (`value`: `T`, `values`: `any`) => `ReactNode` \| `JSX.Element` } & [`FaasItemProps`](#faasitemprops) & { `object?`: [`DescriptionItemProps`](#descriptionitemprops)[] }
170
-
171
- #### Type parameters
172
-
173
- | Name | Type |
174
- | :------ | :------ |
175
- | `T` | `any` |
176
-
177
- ___
178
-
179
- ### DescriptionProps
180
-
181
- Ƭ **DescriptionProps**<`T`, `ExtendItemProps`\>: { `dataSource?`: `T` ; `extendTypes?`: { `[key: string]`: [`ExtendDescriptionTypeProps`](#extenddescriptiontypeprops); } ; `faasData?`: `FaasDataWrapperProps`<`T`\> ; `items`: ([`DescriptionItemProps`](#descriptionitemprops) \| `ExtendItemProps`)[] ; `renderTitle?`: (`values`: `T`) => `ReactNode` \| `JSX.Element` } & `DescriptionsProps`
182
-
183
- #### Type parameters
184
-
185
- | Name | Type |
186
- | :------ | :------ |
187
- | `T` | `any` |
188
- | `ExtendItemProps` | `any` |
189
-
190
- ___
191
-
192
- ### DrawerProps
193
-
194
- Ƭ **DrawerProps**: `AntdDrawerProps` & { `children?`: `JSX.Element` \| `JSX.Element`[] }
195
-
196
- ___
197
-
198
110
  ### ExtendDescriptionItemProps
199
111
 
200
- Ƭ **ExtendDescriptionItemProps**: [`BaseItemProps`](#baseitemprops)
201
-
202
- ___
203
-
204
- ### ExtendDescriptionTypeProps
205
-
206
- Ƭ **ExtendDescriptionTypeProps**: `Object`
207
-
208
- #### Type declaration
209
-
210
- | Name | Type |
211
- | :------ | :------ |
212
- | `children?` | `JSX.Element` \| ``null`` |
213
- | `render?` | (`value`: `any`, `values`: `any`) => `ReactNode` \| `JSX.Element` |
112
+ Ƭ **ExtendDescriptionItemProps**: [`BaseItemProps`](interfaces/BaseItemProps.md)
214
113
 
215
114
  ___
216
115
 
217
116
  ### ExtendFormItemProps
218
117
 
219
- Ƭ **ExtendFormItemProps**: [`BaseItemProps`](#baseitemprops) & `AntdFormItemProps`
118
+ Ƭ **ExtendFormItemProps**: [`BaseItemProps`](interfaces/BaseItemProps.md) & `AntdFormItemProps`
220
119
 
221
120
  ___
222
121
 
@@ -234,7 +133,7 @@ ___
234
133
 
235
134
  ### ExtendTableItemProps
236
135
 
237
- Ƭ **ExtendTableItemProps**<`T`\>: [`BaseItemProps`](#baseitemprops) & `Omit`<`AntdTableColumnProps`<`T`\>, ``"children"``\>
136
+ Ƭ **ExtendTableItemProps**<`T`\>: [`BaseItemProps`](interfaces/BaseItemProps.md) & `Omit`<`AntdTableColumnProps`<`T`\>, ``"children"``\>
238
137
 
239
138
  #### Type parameters
240
139
 
@@ -252,7 +151,7 @@ ___
252
151
 
253
152
  | Name | Type |
254
153
  | :------ | :------ |
255
- | `children?` | `JSX.Element` \| ``null`` |
154
+ | `children?` | `JSX.Element` |
256
155
  | `render?` | (`value`: `any`, `values`: `any`, `index`: `number`) => `JSX.Element` \| `string` \| `number` \| `boolean` \| ``null`` |
257
156
 
258
157
  ___
@@ -267,12 +166,6 @@ ___
267
166
 
268
167
  ___
269
168
 
270
- ### FaasItemProps
271
-
272
- Ƭ **FaasItemProps**: [`BaseItemProps`](#baseitemprops) & { `type?`: [`FaasItemType`](#faasitemtype) }
273
-
274
- ___
275
-
276
169
  ### FaasItemType
277
170
 
278
171
  Ƭ **FaasItemType**: ``"string"`` \| ``"string[]"`` \| ``"number"`` \| ``"number[]"`` \| ``"boolean"`` \| ``"date"`` \| ``"time"`` \| ``"object"`` \| ``"object[]"``
@@ -301,83 +194,9 @@ FaasItemType's value type
301
194
 
302
195
  ___
303
196
 
304
- ### FormItemProps
305
-
306
- Ƭ **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"``\>
307
-
308
- #### Type parameters
309
-
310
- | Name | Type |
311
- | :------ | :------ |
312
- | `T` | `any` |
313
-
314
- ___
315
-
316
- ### FormProps
317
-
318
- Ƭ **FormProps**<`Values`, `ExtendItemProps`\>: { `beforeItems?`: `JSX.Element` \| `JSX.Element`[] ; `children?`: `ReactNode` ; `extendTypes?`: [`ExtendTypes`](#extendtypes) ; `footer?`: `JSX.Element` \| `JSX.Element`[] ; `initialValues?`: `Values` ; `items?`: ([`FormItemProps`](#formitemprops) \| `ExtendItemProps` \| `JSX.Element`)[] ; `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"``\>
319
-
320
- #### Type parameters
321
-
322
- | Name | Type |
323
- | :------ | :------ |
324
- | `Values` | extends `Record`<`string`, `any`\> = `any` |
325
- | `ExtendItemProps` | `any` |
326
-
327
- ___
328
-
329
- ### LinkProps
330
-
331
- Ƭ **LinkProps**: `Object`
332
-
333
- #### Type declaration
334
-
335
- | Name | Type |
336
- | :------ | :------ |
337
- | `button?` | `ButtonProps` |
338
- | `children?` | `ReactNode` |
339
- | `href` | `string` |
340
- | `style?` | `CSSProperties` |
341
- | `target?` | `string` |
342
- | `text?` | `string` \| `number` |
343
-
344
- ___
345
-
346
- ### ModalProps
347
-
348
- Ƭ **ModalProps**: `AntdModalProps` & { `children?`: `JSX.Element` \| `JSX.Element`[] \| `string` }
349
-
350
- ___
351
-
352
- ### RoutesProps
353
-
354
- Ƭ **RoutesProps**: `Object`
355
-
356
- #### Type declaration
357
-
358
- | Name | Type |
359
- | :------ | :------ |
360
- | `fallback?` | `JSX.Element` |
361
- | `notFound?` | `JSX.Element` |
362
- | `routes` | `RouteProps` & { `page?`: `LazyExoticComponent`<`ComponentType`<`any`\>\> }[] |
363
-
364
- ___
365
-
366
- ### TableItemProps
367
-
368
- Ƭ **TableItemProps**<`T`\>: { `children?`: `JSX.Element` \| ``null`` ; `object?`: [`TableItemProps`](#tableitemprops)[] ; `optionsType?`: ``"auto"`` } & [`FaasItemProps`](#faasitemprops) & `Omit`<`AntdTableColumnProps`<`T`\>, ``"children"``\>
369
-
370
- #### Type parameters
371
-
372
- | Name | Type |
373
- | :------ | :------ |
374
- | `T` | `any` |
375
-
376
- ___
377
-
378
197
  ### TableProps
379
198
 
380
- Ƭ **TableProps**<`T`, `ExtendTypes`\>: { `extendTypes?`: { `[key: string]`: [`ExtendTableTypeProps`](#extendtabletypeprops); } ; `faasData?`: `FaasDataWrapperProps`<`T`\> ; `items`: ([`TableItemProps`](#tableitemprops) \| `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`\>
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`\>
381
200
 
382
201
  #### Type parameters
383
202
 
@@ -388,26 +207,9 @@ ___
388
207
 
389
208
  ___
390
209
 
391
- ### TitleProps
392
-
393
- Ƭ **TitleProps**: `Object`
394
-
395
- #### Type declaration
396
-
397
- | Name | Type | Description |
398
- | :------ | :------ | :------ |
399
- | `children?` | `JSX.Element` | return children |
400
- | `h1?` | `boolean` \| { `className?`: `string` ; `style?`: `React.CSSProperties` } | return a h1 element |
401
- | `plain?` | `boolean` | return a pure text element |
402
- | `separator?` | `string` | ` - ` as default |
403
- | `suffix?` | `string` | - |
404
- | `title` | `string` \| `string`[] | - |
405
-
406
- ___
407
-
408
210
  ### setDrawerProps
409
211
 
410
- Ƭ **setDrawerProps**: (`changes`: `Partial`<[`DrawerProps`](#drawerprops)\>) => `void`
212
+ Ƭ **setDrawerProps**: (`changes`: `Partial`<[`DrawerProps`](interfaces/DrawerProps.md)\>) => `void`
411
213
 
412
214
  #### Type declaration
413
215
 
@@ -417,7 +219,7 @@ ___
417
219
 
418
220
  | Name | Type |
419
221
  | :------ | :------ |
420
- | `changes` | `Partial`<[`DrawerProps`](#drawerprops)\> |
222
+ | `changes` | `Partial`<[`DrawerProps`](interfaces/DrawerProps.md)\> |
421
223
 
422
224
  ##### Returns
423
225
 
@@ -427,7 +229,7 @@ ___
427
229
 
428
230
  ### setModalProps
429
231
 
430
- Ƭ **setModalProps**: (`changes`: `Partial`<[`ModalProps`](#modalprops)\>) => `void`
232
+ Ƭ **setModalProps**: (`changes`: `Partial`<[`ModalProps`](interfaces/ModalProps.md)\>) => `void`
431
233
 
432
234
  #### Type declaration
433
235
 
@@ -437,7 +239,7 @@ ___
437
239
 
438
240
  | Name | Type |
439
241
  | :------ | :------ |
440
- | `changes` | `Partial`<[`ModalProps`](#modalprops)\> |
242
+ | `changes` | `Partial`<[`ModalProps`](interfaces/ModalProps.md)\> |
441
243
 
442
244
  ##### Returns
443
245
 
@@ -447,7 +249,7 @@ ___
447
249
 
448
250
  ### ConfigContext
449
251
 
450
- • `Const` **ConfigContext**: `Context`<[`ConfigProviderProps`](#configproviderprops)\>
252
+ • `Const` **ConfigContext**: `Context`<[`ConfigProviderProps`](interfaces/ConfigProviderProps.md)\>
451
253
 
452
254
  ## Functions
453
255
 
@@ -461,7 +263,7 @@ If value is undefined or null, return text, otherwise return value.
461
263
 
462
264
  | Name | Type | Description |
463
265
  | :------ | :------ | :------ |
464
- | `options?` | [`BlankProps`](#blankprops) | {object} |
266
+ | `options?` | [`BlankProps`](interfaces/BlankProps.md) | {object} |
465
267
 
466
268
  #### Returns
467
269
 
@@ -495,7 +297,7 @@ Config for @faasjs/ant-design components.
495
297
  | :------ | :------ |
496
298
  | `«destructured»` | `Object` |
497
299
  | › `children` | `ReactNode` |
498
- | › `config` | [`ConfigProviderProps`](#configproviderprops) |
300
+ | › `config` | [`ConfigProviderProps`](interfaces/ConfigProviderProps.md) |
499
301
 
500
302
  #### Returns
501
303
 
@@ -517,7 +319,7 @@ ___
517
319
 
518
320
  | Name | Type |
519
321
  | :------ | :------ |
520
- | `props` | [`DescriptionProps`](#descriptionprops)<`T`, `any`\> |
322
+ | `props` | [`DescriptionProps`](interfaces/DescriptionProps.md)<`T`, `any`\> |
521
323
 
522
324
  #### Returns
523
325
 
@@ -545,7 +347,7 @@ https://ant.design/components/form/
545
347
 
546
348
  | Name | Type |
547
349
  | :------ | :------ |
548
- | `props` | [`FormProps`](#formprops)<`Values`, `any`\> |
350
+ | `props` | [`FormProps`](interfaces/FormProps.md)<`Values`, `any`\> |
549
351
 
550
352
  #### Returns
551
353
 
@@ -579,7 +381,7 @@ FormItem, can be used without Form.
579
381
 
580
382
  | Name | Type |
581
383
  | :------ | :------ |
582
- | `props` | [`FormItemProps`](#formitemprops)<`T`\> |
384
+ | `props` | [`FormItemProps`](interfaces/FormItemProps.md)<`T`\> |
583
385
 
584
386
  #### Returns
585
387
 
@@ -603,7 +405,7 @@ ___
603
405
 
604
406
  | Name | Type |
605
407
  | :------ | :------ |
606
- | `«destructured»` | [`LinkProps`](#linkprops) |
408
+ | `«destructured»` | [`LinkProps`](interfaces/LinkProps.md) |
607
409
 
608
410
  #### Returns
609
411
 
@@ -647,7 +449,7 @@ export function App () {
647
449
 
648
450
  | Name | Type |
649
451
  | :------ | :------ |
650
- | `props` | [`RoutesProps`](#routesprops) |
452
+ | `props` | [`RoutesProps`](interfaces/RoutesProps.md) |
651
453
 
652
454
  #### Returns
653
455
 
@@ -708,7 +510,7 @@ Return null by default.
708
510
 
709
511
  | Name | Type |
710
512
  | :------ | :------ |
711
- | `props` | [`TitleProps`](#titleprops) |
513
+ | `props` | [`TitleProps`](interfaces/TitleProps.md) |
712
514
 
713
515
  #### Returns
714
516
 
@@ -751,11 +553,11 @@ ___
751
553
 
752
554
  ### useConfigContext
753
555
 
754
- ▸ **useConfigContext**(): [`ConfigProviderProps`](#configproviderprops)
556
+ ▸ **useConfigContext**(): [`ConfigProviderProps`](interfaces/ConfigProviderProps.md)
755
557
 
756
558
  #### Returns
757
559
 
758
- [`ConfigProviderProps`](#configproviderprops)
560
+ [`ConfigProviderProps`](interfaces/ConfigProviderProps.md)
759
561
 
760
562
  ___
761
563
 
@@ -769,7 +571,7 @@ Hook style drawer.
769
571
 
770
572
  | Name | Type | Description |
771
573
  | :------ | :------ | :------ |
772
- | `init?` | [`DrawerProps`](#drawerprops) | initial props ```ts function Example() { const { drawer, setDrawerProps } = useDrawer() return <> <Button onClick={ () => setDrawerProps(prev => ({ open: !prev.open})) }> Toggle </Button> {drawer} </> } ``` |
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} </> } ``` |
773
575
 
774
576
  #### Returns
775
577
 
@@ -778,8 +580,8 @@ Hook style drawer.
778
580
  | Name | Type |
779
581
  | :------ | :------ |
780
582
  | `drawer` | `Element` |
781
- | `drawerProps` | [`DrawerProps`](#drawerprops) |
782
- | `setDrawerProps` | (`changes`: `Partial`<[`DrawerProps`](#drawerprops)\>) => `void` |
583
+ | `drawerProps` | [`DrawerProps`](interfaces/DrawerProps.md) |
584
+ | `setDrawerProps` | (`changes`: `Partial`<[`DrawerProps`](interfaces/DrawerProps.md)\>) => `void` |
783
585
 
784
586
  ___
785
587
 
@@ -793,7 +595,7 @@ Hook style modal.
793
595
 
794
596
  | Name | Type | Description |
795
597
  | :------ | :------ | :------ |
796
- | `init?` | [`ModalProps`](#modalprops) | initial props ```ts function Example() { const { modal, setModalProps } = useModal() return <> <Button onClick={() => setModalProps({ open: true })}>Open Modal</Button> {modal}</> } ``` |
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}</> } ``` |
797
599
 
798
600
  #### Returns
799
601
 
@@ -802,5 +604,5 @@ Hook style modal.
802
604
  | Name | Type |
803
605
  | :------ | :------ |
804
606
  | `modal` | `Element` |
805
- | `modalProps` | [`ModalProps`](#modalprops) |
806
- | `setModalProps` | (`changes`: `Partial`<[`ModalProps`](#modalprops)\>) => `void` |
607
+ | `modalProps` | [`ModalProps`](interfaces/ModalProps.md) |
608
+ | `setModalProps` | (`changes`: `Partial`<[`ModalProps`](interfaces/ModalProps.md)\>) => `void` |