import React, { useState } from 'react';
import { VtxConstructionSiteModal, VtxThemeProvider } from '@vtx/modals';
import { Button, Space } from 'antd';

const App = () => {
    const [visible, setVisible] = useState(false);
    const [theme, setTheme] = useState('light');
    const showModal = theme => {
        setVisible(true);
        setTheme(theme);
    };
    const handleCancel = () => {
        setVisible(false);
    };
    return (
        <VtxThemeProvider value={{ theme }}>
            <Space>
                <Button type="primary" onClick={() => showModal('light')}>
                    基本模态框
                </Button>
                <Button type="primary" onClick={() => showModal('dark')}>
                    深色的建筑模态框
                </Button>
                <VtxConstructionSiteModal
                    id="0aa3898cd7a14ed9a1cea84a9e4f075c"
                    title="分类小区"
                    subTitle=""
                    onCancel={handleCancel}
                    visible={visible}
                    width={1520}
                />
            </Space>
        </VtxThemeProvider>
    );
};
export default () => <App />;
//# sourceMappingURL=index.jsx.map
