Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 | 66x | import { Col, Row } from 'antd';
import React, { ReactElement } from 'react';
export interface MasterDetailVerticalLayoutProps {
headerOnClick?: () => void;
header: ReactElement;
content: ReactElement;
headerClassName?: string;
contentClassName?: string;
}
const MasterDetailVerticalLayout = (props: MasterDetailVerticalLayoutProps): ReactElement => {
const {
header, headerOnClick, content,
headerClassName, contentClassName,
} = props;
return (
<div className='md-vertical-layout'>
<Row>
<Col
onClick={headerOnClick}
className={`md-layout-header ${headerClassName ?? ""}`}
span={24}
>
{header}
</Col>
</Row>
<Row>
<Col
className={`md-layout-content ${contentClassName ?? ""}`}
span={24}
>
{content}
</Col>
</Row>
</div>
);
};
export default MasterDetailVerticalLayout;
|