fix:reset and save the devIconOptions

This commit is contained in:
KazooTTT 2023-04-10 20:04:16 +08:00
parent ea121e45dc
commit ecb040a906

View File

@ -31,7 +31,7 @@ const defaultSettings = {
font: 'font-Anek',
theme: 'background',
customIcon: '',
platform: 'hashnode'
platform: 'hashnode'
};
const devIconsUrl = "https://raw.githubusercontent.com/devicons/devicon/master/devicon.json"
@ -54,7 +54,10 @@ class Editor extends React.Component {
})
}
handleReset = () => {
this.setState(defaultSettings);
this.setState({
...defaultSettings,
devIconOptions: this.state.devIconOptions,
});
};
getRandomTheme = (theme, Pattern) => {