auto close brackets setting (#1110)
parent
899c2556cb
commit
7731b28203
|
@ -43,6 +43,7 @@ export type Config = {
|
|||
// Format: compatible with docker ignore
|
||||
spaceIgnore?: string;
|
||||
emoji?: EmojiConfig;
|
||||
autoCloseBrackets: string;
|
||||
|
||||
schema: SchemaConfig;
|
||||
|
||||
|
@ -64,6 +65,7 @@ export const defaultConfig: Config = {
|
|||
maximumAttachmentSize: 10, // MiB
|
||||
defaultLinkStyle: "wikilink", // wikilink [[]] or markdown []()
|
||||
actionButtons: [], // Actually defaults to defaultActionButtons
|
||||
autoCloseBrackets: "([{`",
|
||||
|
||||
schema: {
|
||||
config: {
|
||||
|
|
|
@ -100,7 +100,9 @@ export function createEditorState(
|
|||
addKeymap: true,
|
||||
}),
|
||||
extendedMarkdownLanguage.data.of({
|
||||
closeBrackets: { brackets: ["(", "{", "[", "`"] },
|
||||
closeBrackets: {
|
||||
brackets: client.config?.autoCloseBrackets.split(""),
|
||||
},
|
||||
}),
|
||||
syntaxHighlighting(customMarkdownStyle()),
|
||||
autocompletion({
|
||||
|
|
|
@ -58,6 +58,8 @@ shortcuts:
|
|||
|
||||
# Toggles between “smart” ‘quotes’ (left and right) and "simple" 'quotes' (good ol' ASCII)
|
||||
useSmartQuotes: true
|
||||
# Choose which characters to auto-close
|
||||
autoCloseBrackets: "([{`"
|
||||
|
||||
# Defines files to ignore in a format compatible with .gitignore
|
||||
spaceIgnore: |
|
||||
|
|
Loading…
Reference in New Issue