Browse Source

refactor(gui): Rename language property

renamed language property to lang to avoid conflict with global mixin

re #331

Signed-off-by: Pranav C <61551451+pranavxc@users.noreply.github.com>
pull/341/head
Pranav C 3 years ago
parent
commit
b84b43d33f
  1. 2
      packages/nc-gui/components/monaco/Monaco.vue
  2. 7
      packages/nc-gui/components/monaco/MonacoEditor.js
  3. 2
      packages/nc-gui/components/monaco/MonacoJsonEditor.js
  4. 2
      packages/nc-gui/components/monaco/MonacoJsonObjectEditor.js
  5. 2
      packages/nc-gui/components/monaco/MonacoSingleLineEditor.js
  6. 2
      packages/nc-gui/components/monaco/MonacoSqlEditor.vue
  7. 2
      packages/nc-gui/components/project/apiClientOld.vue
  8. 2
      packages/nc-gui/components/project/apiClientSwagger.vue
  9. 2
      packages/nc-gui/components/project/tableTabs/columnActions/jsonToColumn.vue
  10. 4
      packages/nc-gui/components/project/tableTabs/webhook/httpWebhook.vue
  11. 3
      packages/nc-gui/store/plugins.js

2
packages/nc-gui/components/monaco/Monaco.vue

@ -15,7 +15,7 @@
@selection="selectionFn" @selection="selectionFn"
theme="vs-dark" theme="vs-dark"
v-model="codeLocal" v-model="codeLocal"
language="sql" lang="sql"
:minimap="minimap" :minimap="minimap"
:readOnly="readOnly" :readOnly="readOnly"
> >

7
packages/nc-gui/components/monaco/MonacoEditor.js

@ -1,7 +1,6 @@
/* eslint-disable */ /* eslint-disable */
import assign from "nano-assign"; import assign from "nano-assign";
import sqlAutoCompletions from "./sqlAutoCompletions"; import sqlAutoCompletions from "./sqlAutoCompletions";
// import {ext} from "vee-validate/dist/rules.esm";
export default { export default {
@ -13,7 +12,7 @@ export default {
type: String, type: String,
default: "vs" default: "vs"
}, },
language: String, lang: String,
options: Object, options: Object,
readOnly: Boolean, readOnly: Boolean,
amdRequire: { amdRequire: {
@ -59,7 +58,7 @@ export default {
} }
}, },
language(newVal) { lang(newVal) {
if (this.editor) { if (this.editor) {
window.monaco.editor.setModelLanguage(this.editor.getModel(), newVal); window.monaco.editor.setModelLanguage(this.editor.getModel(), newVal);
} }
@ -110,7 +109,7 @@ export default {
{ {
value: this.value, value: this.value,
theme: this.theme, theme: this.theme,
language: this.language, language: this.lang,
// quickSuggestions: { other: true, comments: true, strings: true }, // quickSuggestions: { other: true, comments: true, strings: true },
automaticLayout: true, automaticLayout: true,
readOnly: false readOnly: false

2
packages/nc-gui/components/monaco/MonacoJsonEditor.js

@ -16,7 +16,7 @@ export default {
type: String, type: String,
default: "vs-dark" default: "vs-dark"
}, },
language: String, lang: String,
options: Object, options: Object,
readOnly: Boolean, readOnly: Boolean,
amdRequire: { amdRequire: {

2
packages/nc-gui/components/monaco/MonacoJsonObjectEditor.js

@ -15,7 +15,7 @@ export default {
type: String, type: String,
default: "vs-dark" default: "vs-dark"
}, },
language: String, lang: String,
options: Object, options: Object,
readOnly: Boolean, readOnly: Boolean,
amdRequire: { amdRequire: {

2
packages/nc-gui/components/monaco/MonacoSingleLineEditor.js

@ -16,7 +16,7 @@ export default {
type: String, type: String,
default: "vs" default: "vs"
}, },
language: String, lang: String,
options: Object, options: Object,
readOnly: Boolean, readOnly: Boolean,
amdRequire: { amdRequire: {

2
packages/nc-gui/components/monaco/MonacoSqlEditor.vue

@ -11,7 +11,7 @@
@selection="selectionFn" @selection="selectionFn"
theme="vs-dark" theme="vs-dark"
v-model="codeLocal" v-model="codeLocal"
language="sql" lang="sql"
:minimap="minimap" :minimap="minimap"
:readOnly="readOnly" :readOnly="readOnly"
:actions="actions" :actions="actions"

2
packages/nc-gui/components/project/apiClientOld.vue

@ -235,7 +235,7 @@
class="editor card" class="editor card"
theme="vs-dark" theme="vs-dark"
v-model="api.body" v-model="api.body"
language="json" lang="json"
:options="{validate:true,documentFormattingEdits:true,foldingRanges:true}" :options="{validate:true,documentFormattingEdits:true,foldingRanges:true}"
> >
</monaco-json-editor> </monaco-json-editor>

2
packages/nc-gui/components/project/apiClientSwagger.vue

@ -386,7 +386,7 @@
class="editor card" class="editor card"
theme="vs-dark" theme="vs-dark"
v-model="api.body" v-model="api.body"
language="json" lang="json"
:options="{validate:true,documentFormattingEdits:true,foldingRanges:true}" :options="{validate:true,documentFormattingEdits:true,foldingRanges:true}"
> >
</monaco-json-editor> </monaco-json-editor>

2
packages/nc-gui/components/project/tableTabs/columnActions/jsonToColumn.vue

@ -23,7 +23,7 @@
<monaco-json-editor <monaco-json-editor
:validate="false" :validate="false"
v-model="jsonContent" v-model="jsonContent"
language="json" style="height: 500px;width: 100%;min-width: 250px" lang="json" style="height: 500px;width: 100%;min-width: 250px"
></monaco-json-editor> ></monaco-json-editor>
</div> </div>
</div> </div>

4
packages/nc-gui/components/project/tableTabs/webhook/httpWebhook.vue

@ -50,7 +50,7 @@
class="editor card text-left" class="editor card text-left"
theme="vs-dark" theme="vs-dark"
v-model="api.body" v-model="api.body"
language="json" lang="json"
:options="{validate:true,documentFormattingEdits:true,foldingRanges:true}" :options="{validate:true,documentFormattingEdits:true,foldingRanges:true}"
> >
</monaco-json-editor> </monaco-json-editor>
@ -62,7 +62,7 @@
class="editor card text-left" class="editor card text-left"
theme="vs-dark" theme="vs-dark"
v-model="api.auth" v-model="api.auth"
language="json" lang="json"
:options="{validate:true,documentFormattingEdits:true,foldingRanges:true}" :options="{validate:true,documentFormattingEdits:true,foldingRanges:true}"
> >
</monaco-json-editor> </monaco-json-editor>

3
packages/nc-gui/store/plugins.js

@ -1,4 +1,3 @@
import settings from "@/components/settings";
export const state = () => ({}); export const state = () => ({});
@ -41,7 +40,7 @@ export const actions = {
settings settings
}) })
} catch (e) { } catch (e) {
console.log(e) // ignore
} }
} }
} }

Loading…
Cancel
Save