mirror of https://github.com/openspug/spug
fix issues
parent
c98d30981d
commit
fdfa7d811c
|
@ -5,7 +5,7 @@
|
|||
*/
|
||||
import React from 'react';
|
||||
import styles from './index.module.css';
|
||||
import { Descriptions, Spin, Icon, notification } from "antd";
|
||||
import { Descriptions, Spin, Icon, Button, notification } from "antd";
|
||||
import { observer } from 'mobx-react'
|
||||
import { http, VERSION } from 'libs';
|
||||
|
||||
|
@ -34,7 +34,17 @@ class About extends React.Component {
|
|||
message: `发现新版本 ${res.version}`,
|
||||
icon: <Icon type="smile" theme="twoTone"/>,
|
||||
btn: <a target="_blank" rel="noopener noreferrer" href="https://spug.cc/docs/update-version/">如何升级?</a>,
|
||||
description: <pre style={{lineHeight: '30px'}}>{res.content}</pre>
|
||||
description: <pre style={{lineHeight: '30px'}}>{res.content}<br/>{res.extra}</pre>
|
||||
})
|
||||
} else if (res.extra) {
|
||||
notification.open({
|
||||
key: 'new_version',
|
||||
duration: 0,
|
||||
top: 88,
|
||||
message: `已是最新版本`,
|
||||
icon: <Icon type="smile" theme="twoTone"/>,
|
||||
btn: <Button type="link" onClick={() => notification.close('new_version')}>知道了</Button>,
|
||||
description: <pre style={{lineHeight: '30px'}}>{res.extra}</pre>
|
||||
})
|
||||
}
|
||||
})
|
||||
|
|
Loading…
Reference in New Issue