diff options
Diffstat (limited to 'app')
12 files changed, 57 insertions, 57 deletions
diff --git a/app/assets/javascripts/issue_show/components/app.vue b/app/assets/javascripts/issue_show/components/app.vue index efae112923d..eaaafd4c149 100644 --- a/app/assets/javascripts/issue_show/components/app.vue +++ b/app/assets/javascripts/issue_show/components/app.vue @@ -80,11 +80,11 @@ export default { type: Boolean, required: true, }, - markdownPreviewUrl: { + markdownPreviewPath: { type: String, required: true, }, - markdownDocs: { + markdownDocsPath: { type: String, required: true, }, @@ -96,7 +96,7 @@ export default { type: String, required: true, }, - projectsAutocompleteUrl: { + projectsAutocompletePath: { type: String, required: true, }, @@ -242,11 +242,11 @@ export default { :can-move="canMove" :can-destroy="canDestroy" :issuable-templates="issuableTemplates" - :markdown-docs="markdownDocs" - :markdown-preview-url="markdownPreviewUrl" + :markdown-docs-path="markdownDocsPath" + :markdown-preview-path="markdownPreviewPath" :project-path="projectPath" :project-namespace="projectNamespace" - :projects-autocomplete-url="projectsAutocompleteUrl" + :projects-autocomplete-path="projectsAutocompletePath" /> <div v-else> <title-component diff --git a/app/assets/javascripts/issue_show/components/fields/description.vue b/app/assets/javascripts/issue_show/components/fields/description.vue index 27b1b814f9a..dc902eefc5f 100644 --- a/app/assets/javascripts/issue_show/components/fields/description.vue +++ b/app/assets/javascripts/issue_show/components/fields/description.vue @@ -10,11 +10,11 @@ type: Object, required: true, }, - markdownPreviewUrl: { + markdownPreviewPath: { type: String, required: true, }, - markdownDocs: { + markdownDocsPath: { type: String, required: true, }, @@ -36,8 +36,8 @@ Description </label> <markdown-field - :markdown-preview-url="markdownPreviewUrl" - :markdown-docs="markdownDocs"> + :markdown-preview-path="markdownPreviewPath" + :markdown-docs-path="markdownDocsPath"> <textarea id="issue-description" class="note-textarea js-gfm-input js-autosize markdown-area" diff --git a/app/assets/javascripts/issue_show/components/fields/project_move.vue b/app/assets/javascripts/issue_show/components/fields/project_move.vue index 7bf2be8b28a..e514bebc5f6 100644 --- a/app/assets/javascripts/issue_show/components/fields/project_move.vue +++ b/app/assets/javascripts/issue_show/components/fields/project_move.vue @@ -10,7 +10,7 @@ type: Object, required: true, }, - projectsAutocompleteUrl: { + projectsAutocompletePath: { type: String, required: true, }, @@ -20,7 +20,7 @@ $moveDropdown.select2({ ajax: { - url: this.projectsAutocompleteUrl, + url: this.projectsAutocompletePath, quietMillis: 125, data(term, page, context) { return { diff --git a/app/assets/javascripts/issue_show/components/form.vue b/app/assets/javascripts/issue_show/components/form.vue index 76ec3dc9a5d..d9b53bc55cf 100644 --- a/app/assets/javascripts/issue_show/components/form.vue +++ b/app/assets/javascripts/issue_show/components/form.vue @@ -26,11 +26,11 @@ required: false, default: () => [], }, - markdownPreviewUrl: { + markdownPreviewPath: { type: String, required: true, }, - markdownDocs: { + markdownDocsPath: { type: String, required: true, }, @@ -42,7 +42,7 @@ type: String, required: true, }, - projectsAutocompleteUrl: { + projectsAutocompletePath: { type: String, required: true, }, @@ -89,14 +89,14 @@ </div> <description-field :form-state="formState" - :markdown-preview-url="markdownPreviewUrl" - :markdown-docs="markdownDocs" /> + :markdown-preview-path="markdownPreviewPath" + :markdown-docs-path="markdownDocsPath" /> <confidential-checkbox :form-state="formState" /> <project-move v-if="canMove" :form-state="formState" - :projects-autocomplete-url="projectsAutocompleteUrl" /> + :projects-autocomplete-path="projectsAutocompletePath" /> <edit-actions :form-state="formState" :can-destroy="canDestroy" /> diff --git a/app/assets/javascripts/issue_show/index.js b/app/assets/javascripts/issue_show/index.js index ad8cb6465e2..60b69b300fd 100644 --- a/app/assets/javascripts/issue_show/index.js +++ b/app/assets/javascripts/issue_show/index.js @@ -37,11 +37,11 @@ document.addEventListener('DOMContentLoaded', () => { initialDescriptionText: this.initialDescriptionText, issuableTemplates: this.issuableTemplates, isConfidential: this.isConfidential, - markdownPreviewUrl: this.markdownPreviewUrl, - markdownDocs: this.markdownDocs, + markdownPreviewPath: this.markdownPreviewPath, + markdownDocsPath: this.markdownDocsPath, projectPath: this.projectPath, projectNamespace: this.projectNamespace, - projectsAutocompleteUrl: this.projectsAutocompleteUrl, + projectsAutocompletePath: this.projectsAutocompletePath, updatedAt: this.updatedAt, updatedByName: this.updatedByName, updatedByPath: this.updatedByPath, diff --git a/app/assets/javascripts/notes/components/issue_comment_form.vue b/app/assets/javascripts/notes/components/issue_comment_form.vue index d80fc4bd373..7d69dbc807f 100644 --- a/app/assets/javascripts/notes/components/issue_comment_form.vue +++ b/app/assets/javascripts/notes/components/issue_comment_form.vue @@ -71,13 +71,13 @@ 'js-note-target-reopen': !this.isIssueOpen, }; }, - markdownDocsUrl() { - return this.getNotesData.markdownDocs; + markdownDocsPath() { + return this.getNotesData.markdownDocsPath; }, - quickActionsDocsUrl() { - return this.getNotesData.quickActionsDocs; + quickActionsDocsPath() { + return this.getNotesData.quickActionsDocsPath; }, - markdownPreviewUrl() { + markdownPreviewPath() { return this.getIssueData.preview_note_path; }, author() { @@ -231,9 +231,9 @@ <div class="flash-container error-alert timeline-content"></div> <confidentialIssue v-if="isConfidentialIssue" /> <markdown-field - :markdown-preview-url="markdownPreviewUrl" - :markdown-docs="markdownDocsUrl" - :quick-actions-docs="quickActionsDocsUrl" + :markdown-preview-path="markdownPreviewPath" + :markdown-docs-path="markdownDocsPath" + :quick-actions-docs-path="quickActionsDocsPath" :add-spacing-classes="false" :is-confidential-issue="isConfidentialIssue"> <textarea diff --git a/app/assets/javascripts/notes/components/issue_note_form.vue b/app/assets/javascripts/notes/components/issue_note_form.vue index e0c40f77b00..591008a0285 100644 --- a/app/assets/javascripts/notes/components/issue_note_form.vue +++ b/app/assets/javascripts/notes/components/issue_note_form.vue @@ -52,14 +52,14 @@ noteHash() { return `#note_${this.noteId}`; }, - markdownPreviewUrl() { + markdownPreviewPath() { return this.getIssueDataByProp('preview_note_path'); }, - markdownDocsUrl() { - return this.getNotesDataByProp('markdownDocs'); + markdownDocsPath() { + return this.getNotesDataByProp('markdownDocsPath'); }, - quickActionsDocsUrl() { - return !this.isEditing ? this.getNotesDataByProp('quickActionsDocs') : undefined; + quickActionsDocsPath() { + return !this.isEditing ? this.getNotesDataByProp('quickActionsDocsPath') : undefined; }, currentUserId() { return this.getUserDataByProp('id'); @@ -124,9 +124,9 @@ class="edit-note common-note-form js-quick-submit gfm-form"> <confidentialIssue v-if="isConfidentialIssue" /> <markdown-field - :markdown-preview-url="markdownPreviewUrl" - :markdown-docs="markdownDocsUrl" - :quick-actions-docs="quickActionsDocsUrl" + :markdown-preview-path="markdownPreviewPath" + :markdown-docs-path="markdownDocsPath" + :quick-actions-docs-path="quickActionsDocsPath" :add-spacing-classes="false"> <textarea id="note_note" diff --git a/app/assets/javascripts/notes/index.js b/app/assets/javascripts/notes/index.js index 7c90cf20019..e2ea37408cf 100644 --- a/app/assets/javascripts/notes/index.js +++ b/app/assets/javascripts/notes/index.js @@ -18,8 +18,8 @@ document.addEventListener('DOMContentLoaded', () => new Vue({ newSessionPath: notesDataset.newSessionPath, registerPath: notesDataset.registerPath, notesPath: notesDataset.notesPath, - markdownDocs: notesDataset.markdownDocs, - quickActionsDocs: notesDataset.quickActionsDocs, + markdownDocsPath: notesDataset.markdownDocsPath, + quickActionsDocsPath: notesDataset.quickActionsDocsPath, }, }; }, diff --git a/app/assets/javascripts/vue_shared/components/markdown/field.vue b/app/assets/javascripts/vue_shared/components/markdown/field.vue index 4e1d623647e..11eaeb89c4c 100644 --- a/app/assets/javascripts/vue_shared/components/markdown/field.vue +++ b/app/assets/javascripts/vue_shared/components/markdown/field.vue @@ -5,12 +5,12 @@ export default { props: { - markdownPreviewUrl: { + markdownPreviewPath: { type: String, required: false, default: '', }, - markdownDocs: { + markdownDocsPath: { type: String, required: true, }, @@ -19,7 +19,7 @@ required: false, default: true, }, - quickActionsDocs: { + quickActionsDocsPath: { type: String, required: false, }, @@ -52,7 +52,7 @@ } else { this.markdownPreviewLoading = true; this.$http.post( - this.markdownPreviewUrl, + this.markdownPreviewPath, { /* Can't use `$refs` as the component is technically in the parent component @@ -117,8 +117,8 @@ </i> </a> <markdown-toolbar - :markdown-docs="markdownDocs" - :quick-actions-docs="quickActionsDocs" + :markdown-docs-path="markdownDocsPath" + :quick-actions-docs-path="quickActionsDocsPath" /> </div> </div> diff --git a/app/assets/javascripts/vue_shared/components/markdown/toolbar.vue b/app/assets/javascripts/vue_shared/components/markdown/toolbar.vue index 13402f34c5b..65fe7bbd94e 100644 --- a/app/assets/javascripts/vue_shared/components/markdown/toolbar.vue +++ b/app/assets/javascripts/vue_shared/components/markdown/toolbar.vue @@ -1,11 +1,11 @@ <script> export default { props: { - markdownDocs: { + markdownDocsPath: { type: String, required: true, }, - quickActionsDocs: { + quickActionsDocsPath: { type: String, required: false, }, @@ -16,24 +16,24 @@ <template> <div class="comment-toolbar clearfix"> <div class="toolbar-text"> - <template v-if="!quickActionsDocs && markdownDocs"> + <template v-if="!quickActionsDocsPath && markdownDocsPath"> <a - :href="markdownDocs" + :href="markdownDocsPath" target="_blank" tabindex="-1"> Markdown is supported </a> </template> - <template v-if="quickActionsDocs && markdownDocs"> + <template v-if="quickActionsDocsPath && markdownDocsPath"> <a - :href="markdownDocs" + :href="markdownDocsPath" target="_blank" tabindex="-1"> Markdown </a> and <a - :href="quickActionsDocs" + :href="quickActionsDocsPath" target="_blank" tabindex="-1"> quick actions diff --git a/app/helpers/issuables_helper.rb b/app/helpers/issuables_helper.rb index 8c1a4767643..d3b6a9ff548 100644 --- a/app/helpers/issuables_helper.rb +++ b/app/helpers/issuables_helper.rb @@ -210,9 +210,9 @@ module IssuablesHelper canMove: current_user ? issuable.can_move?(current_user) : false, issuableRef: issuable.to_reference, isConfidential: issuable.confidential, - markdownPreviewUrl: preview_markdown_path(@project), - markdownDocs: help_page_path('user/markdown'), - projectsAutocompleteUrl: autocomplete_projects_path(project_id: @project.id), + markdownPreviewPath: preview_markdown_path(@project), + markdownDocsPath: help_page_path('user/markdown'), + projectsAutocompletePath: autocomplete_projects_path(project_id: @project.id), issuableTemplates: issuable_templates(issuable), projectPath: ref_project.path, projectNamespace: ref_project.namespace.full_path, diff --git a/app/views/projects/issues/_discussion.html.haml b/app/views/projects/issues/_discussion.html.haml index 50aae5388e9..3e63758a5e5 100644 --- a/app/views/projects/issues/_discussion.html.haml +++ b/app/views/projects/issues/_discussion.html.haml @@ -8,8 +8,8 @@ #js-vue-notes{ data: { discussions_path: discussions_namespace_project_issue_path(@project.namespace, @project, @issue, format: :json), register_path: "#{new_session_path(:user, redirect_to_referer: 'yes')}#register-pane", new_session_path: new_session_path(:user, redirect_to_referer: 'yes'), - markdown_docs: help_page_path('user/markdown'), - quick_actions_docs: help_page_path('user/project/quick_actions'), + markdown_docs_path: help_page_path('user/markdown'), + quick_actions_docs_path: help_page_path('user/project/quick_actions'), notes_path: notes_url, last_fetched_at: Time.now.to_i, issue_data: serialize_issuable(@issue), |