feat: App Layout 统一使用 Tailwind CSS

perf/export-docx
Jimmy Liow 1 year ago
parent 8b44f5ce5c
commit 52fcb20dbf

@ -65,10 +65,6 @@ function App() {
defaultPath = splitPath[1] defaultPath = splitPath[1]
} }
const {
token: { colorBgContainer },
} = theme.useToken()
const [antdLng, setAntdLng] = useState(enLocale); const [antdLng, setAntdLng] = useState(enLocale);
useEffect(() => { useEffect(() => {
setAntdLng(i18n.language === 'en' ? enLocale : zhLocale); setAntdLng(i18n.language === 'en' ? enLocale : zhLocale);
@ -104,9 +100,7 @@ function App() {
</Modal> </Modal>
<Layout <Layout
style={{ className='min-h-screen'>
minHeight: '100vh',
}}>
<Header className='sticky top-0 z-10 w-full'> <Header className='sticky top-0 z-10 w-full'>
<Row gutter={{ md: 24 }} justify='end' align='middle'> <Row gutter={{ md: 24 }} justify='end' align='middle'>
<Col span={16}> <Col span={16}>
@ -136,9 +130,9 @@ function App() {
/> />
</Col> </Col>
<Col span={4}> <Col span={4}>
<Title level={3} style={{ color: 'white', marginBottom: '0', display: 'flex', justifyContent: 'end' }}> <h3 className='text-white mb-0 flex justify-end'>
{currentUser?.travelAgencyName} {currentUser?.travelAgencyName}
</Title> </h3>
</Col> </Col>
<Col span={2}> <Col span={2}>
<Dropdown <Dropdown
@ -168,13 +162,7 @@ function App() {
</Col> </Col>
</Row> </Row>
</Header> </Header>
<Content <Content className='p-6 m-0 min-h-72 bg-white'>
style={{
padding: 24,
margin: 0,
minHeight: 280,
background: colorBgContainer,
}}>
{needToLogin ? <>login...</> : <Outlet />} {needToLogin ? <>login...</> : <Outlet />}
</Content> </Content>
<Footer>China Highlights International Travel Service Co., LTD, Version: {BUILD_VERSION}</Footer> <Footer>China Highlights International Travel Service Co., LTD, Version: {BUILD_VERSION}</Footer>

Loading…
Cancel
Save