1
1
mirror of https://github.com/Fabio286/antares.git synced 2025-06-05 21:59:22 +02:00

feat: option to toggle line wrap mode

This commit is contained in:
2020-12-24 15:33:51 +01:00
parent 3b4f1475df
commit d94b49febf
4 changed files with 43 additions and 3 deletions

View File

@ -35,7 +35,8 @@ export default {
computed: {
...mapGetters({
editorTheme: 'settings/getEditorTheme',
autoComplete: 'settings/getAutoComplete'
autoComplete: 'settings/getAutoComplete',
lineWrap: 'settings/getLineWrap'
}),
tables () {
return this.workspace
@ -100,6 +101,13 @@ export default {
enableLiveAutocompletion: this.autoComplete
});
}
},
lineWrap () {
if (this.editor) {
this.editor.setOptions({
wrap: this.lineWrap
});
}
}
},
mounted () {
@ -114,6 +122,7 @@ export default {
this.editor.setOptions({
enableBasicAutocompletion: true,
wrap: this.lineWrap,
enableSnippets: true,
enableLiveAutocompletion: this.autoComplete
});