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 4 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"
theme="vs-dark"
v-model="codeLocal"
language="sql"
lang="sql"
:minimap="minimap"
:readOnly="readOnly"
>

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

@ -23,7 +23,7 @@
<monaco-json-editor
:validate="false"
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>
</div>
</div>

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

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

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

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

Loading…
Cancel
Save