fix issue

pull/330/head
vapao 2021-03-31 23:15:45 +08:00
parent ae40c8581d
commit dd1cf0e81f
1 changed files with 6 additions and 2 deletions

View File

@ -4,7 +4,7 @@
* Released under the AGPL-3.0 License. * Released under the AGPL-3.0 License.
*/ */
import React, { useEffect, useState } from 'react'; import React, { useEffect, useState } from 'react';
import { Button, Card, List, Modal, Form, Input, Switch, Divider } from 'antd'; import { Button, Card, List, Modal, Form, Input, Switch, Divider, Typography } from 'antd';
import { DownSquareOutlined, PlusOutlined, UpSquareOutlined, SoundOutlined } from '@ant-design/icons'; import { DownSquareOutlined, PlusOutlined, UpSquareOutlined, SoundOutlined } from '@ant-design/icons';
import { http } from 'libs'; import { http } from 'libs';
import styles from './index.module.less'; import styles from './index.module.less';
@ -125,7 +125,11 @@ function NoticeIndex(props) {
</Modal> </Modal>
{notice ? ( {notice ? (
<Modal title={notice.title} visible={notice} footer={null} onCancel={handleRead}> <Modal title={notice.title} visible={notice} footer={null} onCancel={handleRead}>
{notice.content} <Typography>
{notice.content.split('\n').map((item, index) => (
<Typography.Paragraph key={index}>{item}</Typography.Paragraph>
))}
</Typography>
</Modal> </Modal>
) : null} ) : null}
</Card> </Card>