@@ -23,10 +23,11 @@ import Layout from '@uiw/react-layout';
23
23
const { Header , Footer , Sider , Content } = Layout;
24
24
// or
25
25
import Layout , { LayoutHeader , LayoutContent , LayoutSider , LayoutFooter } from ' @uiw/react-layout' ;
26
- Layout .Header = LayoutHeader
27
- Layout .Content = LayoutContent
28
- Layout .Sider = LayoutSider
29
- Layout .Footer = LayoutFooter
26
+
27
+ Layout .Header === LayoutHeader
28
+ Layout .Content === LayoutContent
29
+ Layout .Sider === LayoutSider
30
+ Layout .Footer === LayoutFooter
30
31
```
31
32
32
33
## Basic Usage
@@ -150,7 +151,55 @@ The layout wrapper, in which `Header` `Sider` `Content` `Footer` or `Layout` its
150
151
| hasSider | hasSider Whether contain Sider in children, don't have to assign it normally. Useful in ssr avoid style flickering | boolean | - |
151
152
<!-- | theme | Color theme of the sidebar | `light`、`dark` | `dark` | -->
152
153
153
- ## Layout.Sider
154
+ ## Header
155
+
156
+ ``` ts
157
+ import Layout , { LayoutHeader } from ' @uiw/react-layout' ;
158
+ Layout .Header === LayoutHeader
159
+ ```
160
+
161
+ ``` ts
162
+ import React from ' react' ;
163
+ export interface LayoutHeaderProps extends React .HTMLAttributes <HTMLElement > {
164
+ prefixCls? : string ;
165
+ children? : React .ReactNode ;
166
+ }
167
+ export declare const LayoutHeader: React .ForwardRefExoticComponent <LayoutHeaderProps & React .RefAttributes <HTMLElement >>;
168
+ ```
169
+
170
+ ## Content
171
+
172
+ ``` ts
173
+ import Layout , { LayoutContent } from ' @uiw/react-layout' ;
174
+ Layout .Content === LayoutContent
175
+ ```
176
+
177
+ ``` ts
178
+ import React from ' react' ;
179
+ export interface LayoutContentProps extends React .HTMLAttributes <HTMLElement > {
180
+ prefixCls? : string ;
181
+ children? : React .ReactNode ;
182
+ }
183
+ export declare const LayoutContent: React .ForwardRefExoticComponent <LayoutContentProps & React .RefAttributes <HTMLElement >>;
184
+ ```
185
+
186
+ ## Footer
187
+
188
+ ``` ts
189
+ import Layout , { LayoutFooter } from ' @uiw/react-layout' ;
190
+ Layout .Footer === LayoutFooter
191
+ ```
192
+
193
+ ``` ts
194
+ import React from ' react' ;
195
+ export interface LayoutFooterProps extends React .HTMLAttributes <HTMLElement > {
196
+ prefixCls? : string ;
197
+ children? : React .ReactNode ;
198
+ }
199
+ export declare const LayoutFooter: React .ForwardRefExoticComponent <LayoutFooterProps & React .RefAttributes <HTMLElement >>;
200
+ ```
201
+
202
+ ## Sider
154
203
155
204
| Property | Description | Type | Default |
156
205
| --------- | -------- | --------- | -------- |
@@ -160,6 +209,27 @@ The layout wrapper, in which `Header` `Sider` `Content` `Footer` or `Layout` its
160
209
| collapsedWidth | Width of the collapsed sidebar, by setting to 0 a special trigger will appear | boolean | ` 80 ` |
161
210
| width | Width of the sidebar | number/string | 200 |
162
211
212
+ ``` ts
213
+ import Layout , { LayoutSider } from ' @uiw/react-layout' ;
214
+ Layout .Sider === LayoutSider
215
+ ```
216
+
217
+ ``` ts
218
+ import React from ' react' ;
219
+ export declare function randomid(): string ;
220
+ export interface LayoutSiderProps extends React .HTMLAttributes <HTMLElement > {
221
+ prefixCls? : string ;
222
+ children? : React .ReactNode ;
223
+ /** Width of the sidebar */
224
+ width? : number | string ;
225
+ /** Width of the collapsed sidebar, by setting to 0 a special trigger will appear */
226
+ collapsedWidth? : number ;
227
+ /** To set the current status */
228
+ collapsed? : boolean ;
229
+ }
230
+ export declare const LayoutSider: React .ForwardRefExoticComponent <LayoutSiderProps & React .RefAttributes <HTMLDivElement >>;
231
+ ```
232
+
163
233
## Contributors
164
234
165
235
As always, thanks to our amazing contributors!
0 commit comments