mirror of
https://github.com/BoostIo/Boostnote
synced 2025-12-15 10:46:32 +00:00
Merge pull request #948 from wrhansen/master
Support for solarized dark and light themes
This commit is contained in:
@@ -10,6 +10,7 @@ const themes = fs.readdirSync(themePath)
|
|||||||
.map((themePath) => {
|
.map((themePath) => {
|
||||||
return themePath.substring(0, themePath.lastIndexOf('.'))
|
return themePath.substring(0, themePath.lastIndexOf('.'))
|
||||||
})
|
})
|
||||||
|
themes.splice(themes.indexOf('solarized'), 1, 'solarized dark', 'solarized light')
|
||||||
|
|
||||||
const consts = {
|
const consts = {
|
||||||
FOLDER_COLORS: [
|
FOLDER_COLORS: [
|
||||||
|
|||||||
@@ -61,7 +61,7 @@ class UiTab extends React.Component {
|
|||||||
const newCodemirrorTheme = this.refs.editorTheme.value
|
const newCodemirrorTheme = this.refs.editorTheme.value
|
||||||
|
|
||||||
if (newCodemirrorTheme !== codemirrorTheme) {
|
if (newCodemirrorTheme !== codemirrorTheme) {
|
||||||
checkHighLight.setAttribute('href', `../node_modules/codemirror/theme/${newCodemirrorTheme}.css`)
|
checkHighLight.setAttribute('href', `../node_modules/codemirror/theme/${newCodemirrorTheme.split(' ')[0]}.css`)
|
||||||
}
|
}
|
||||||
|
|
||||||
this.setState({ config: newConfig, codemirrorTheme: newCodemirrorTheme })
|
this.setState({ config: newConfig, codemirrorTheme: newCodemirrorTheme })
|
||||||
|
|||||||
Reference in New Issue
Block a user