mirror of
https://github.com/ant-design/ant-design.git
synced 2024-11-28 21:19:37 +08:00
提供一个关闭功能,点击后 localStorage 存一下就不弹了
This commit is contained in:
parent
a04794261c
commit
2cf0577e4f
@ -94,6 +94,9 @@ class PicSearcher extends Component<PicSearcherProps, PicSearcherState> {
|
||||
fileList: [],
|
||||
icons: [],
|
||||
}));
|
||||
if (!localStorage.getItem('disableIconTip')) {
|
||||
localStorage.setItem('disableIconTip', 'true');
|
||||
}
|
||||
};
|
||||
|
||||
onCopied = (text: string) => {
|
||||
@ -111,7 +114,10 @@ class PicSearcher extends Component<PicSearcherProps, PicSearcherState> {
|
||||
const { modalVisible, icons, fileList, loading } = this.state;
|
||||
return (
|
||||
<div className="icon-pic-searcher">
|
||||
<Popover content={messages[`app.docs.components.icon.pic-searcher.intro`]} visible>
|
||||
<Popover
|
||||
content={messages[`app.docs.components.icon.pic-searcher.intro`]}
|
||||
visible={!localStorage.getItem('disableIconTip')}
|
||||
>
|
||||
<Icon type="camera" className="icon-pic-btn" onClick={this.toggleModal} />
|
||||
</Popover>
|
||||
<Modal
|
||||
|
Loading…
Reference in New Issue
Block a user