diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-06-20 13:43:29 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-06-20 13:43:29 +0300 |
commit | 3b1af5cc7ed2666ff18b718ce5d30fa5a2756674 (patch) | |
tree | 3bc4a40e0ee51ec27eabf917c537033c0c5b14d4 /app/assets/javascripts/pages/shared/wikis/components | |
parent | 9bba14be3f2c211bf79e15769cd9b77bc73a13bc (diff) |
Add latest changes from gitlab-org/gitlab@16-1-stable-eev16.1.0-rc42
Diffstat (limited to 'app/assets/javascripts/pages/shared/wikis/components')
-rw-r--r-- | app/assets/javascripts/pages/shared/wikis/components/wiki_form.vue | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/app/assets/javascripts/pages/shared/wikis/components/wiki_form.vue b/app/assets/javascripts/pages/shared/wikis/components/wiki_form.vue index 3b38d715ea5..4f68c7984e8 100644 --- a/app/assets/javascripts/pages/shared/wikis/components/wiki_form.vue +++ b/app/assets/javascripts/pages/shared/wikis/components/wiki_form.vue @@ -107,7 +107,7 @@ export default { MarkdownEditor, }, mixins: [trackingMixin], - inject: ['formatOptions', 'pageInfo'], + inject: ['formatOptions', 'pageInfo', 'drawioUrl'], data() { return { editingMode: 'source', @@ -183,6 +183,9 @@ export default { disableSubmitButton() { return this.noContent || !this.title; }, + drawioEnabled() { + return typeof this.drawioUrl === 'string' && this.drawioUrl.length > 0; + }, }, mounted() { if (!this.commitMessage) this.updateCommitMessage(); @@ -356,7 +359,7 @@ export default { :autofocus="pageInfo.persisted" :enable-autocomplete="true" :autocomplete-data-sources="autocompleteDataSources" - :drawio-enabled="true" + :drawio-enabled="drawioEnabled" @contentEditor="notifyContentEditorActive" @markdownField="notifyContentEditorInactive" @keydown.ctrl.enter="submitFormShortcut" |