mirror of
https://github.com/BoostIo/Boostnote
synced 2025-12-13 09:46:22 +00:00
Merge branch 'master' of https://github.com/BoostIO/Boostnote into spell_check
# Conflicts: # browser/components/CodeEditor.js # locales/fr.json # package.json
This commit is contained in:
@@ -36,7 +36,15 @@ const consts = {
|
||||
'Violet Eggplant'
|
||||
],
|
||||
THEMES: ['default'].concat(themes),
|
||||
SNIPPET_FILE: snippetFile
|
||||
SNIPPET_FILE: snippetFile,
|
||||
DEFAULT_EDITOR_FONT_FAMILY: [
|
||||
'Monaco',
|
||||
'Menlo',
|
||||
'Ubuntu Mono',
|
||||
'Consolas',
|
||||
'source-code-pro',
|
||||
'monospace'
|
||||
]
|
||||
}
|
||||
|
||||
module.exports = consts
|
||||
|
||||
9
browser/lib/normalizeEditorFontFamily.js
Normal file
9
browser/lib/normalizeEditorFontFamily.js
Normal file
@@ -0,0 +1,9 @@
|
||||
import consts from 'browser/lib/consts'
|
||||
import isString from 'lodash/isString'
|
||||
|
||||
export default function normalizeEditorFontFamily (fontFamily) {
|
||||
const defaultEditorFontFamily = consts.DEFAULT_EDITOR_FONT_FAMILY
|
||||
return isString(fontFamily) && fontFamily.length > 0
|
||||
? [fontFamily].concat(defaultEditorFontFamily).join(', ')
|
||||
: defaultEditorFontFamily.join(', ')
|
||||
}
|
||||
Reference in New Issue
Block a user