feat: login page

This commit is contained in:
jialin
2024-06-03 09:06:41 +08:00
parent 69f354b278
commit d2212fe949
15 changed files with 147 additions and 23 deletions
+11 -4
View File
@@ -1,20 +1,27 @@
import { Button, Space } from 'antd';
type FormButtonsProps = {
onOk: () => void;
onCancel: () => void;
onOk?: () => void;
onCancel?: () => void;
cancelText?: string;
okText?: string;
htmlType?: 'submit' | 'button';
};
const FormButtons: React.FC<FormButtonsProps> = ({
onOk,
onCancel,
cancelText,
okText
okText,
htmlType = 'button'
}) => {
return (
<Space size={40} style={{ marginTop: '80px' }}>
<Button type="primary" onClick={onOk} style={{ width: '120px' }}>
<Button
type="primary"
onClick={onOk}
style={{ width: '120px' }}
htmlType={htmlType}
>
{okText || '保存'}
</Button>
<Button onClick={onCancel} style={{ width: '98px' }}>