diff options
3 files changed, 10 insertions, 11 deletions
diff --git a/app/assets/javascripts/notes/components/issue_comment_form.vue b/app/assets/javascripts/notes/components/issue_comment_form.vue index 715027c6fbc..2c05817ac88 100644 --- a/app/assets/javascripts/notes/components/issue_comment_form.vue +++ b/app/assets/javascripts/notes/components/issue_comment_form.vue @@ -266,9 +266,9 @@ <div class="error-alert"></div> <issue-warning - v-if="hasIssueWarning(getIssueData)" - :is-locked="isIssueLocked(getIssueData)" - :is-confidential="isIssueConfidential(getIssueData)" + v-if="hasWarning(getIssueData)" + :is-locked="isLocked(getIssueData)" + :is-confidential="isConfidential(getIssueData)" /> <markdown-field @@ -276,7 +276,6 @@ :markdown-docs-path="markdownDocsPath" :quick-actions-docs-path="quickActionsDocsPath" :add-spacing-classes="false" - :is-confidential-issue="isIssueConfidential(getIssueData)" ref="markdownField"> <textarea id="note-body" diff --git a/app/assets/javascripts/notes/components/issue_note_form.vue b/app/assets/javascripts/notes/components/issue_note_form.vue index f78289e68aa..e2539d6b89d 100644 --- a/app/assets/javascripts/notes/components/issue_note_form.vue +++ b/app/assets/javascripts/notes/components/issue_note_form.vue @@ -129,9 +129,9 @@ class="edit-note common-note-form js-quick-submit gfm-form"> <issue-warning - v-if="hasIssueWarning(getIssueData)" - :is-locked="isIssueLocked(getIssueData)" - :is-confidential="isIssueConfidential(getIssueData)" + v-if="hasWarning(getIssueData)" + :is-locked="isLocked(getIssueData)" + :is-confidential="isConfidential(getIssueData)" /> <markdown-field diff --git a/app/assets/javascripts/notes/mixins/issuable_state.js b/app/assets/javascripts/notes/mixins/issuable_state.js index a0b3d81d63b..97f3ea0d5de 100644 --- a/app/assets/javascripts/notes/mixins/issuable_state.js +++ b/app/assets/javascripts/notes/mixins/issuable_state.js @@ -1,15 +1,15 @@ export default { methods: { - isIssueConfidential(issue) { + isConfidential(issue) { return !!issue.confidential; }, - isIssueLocked(issue) { + isLocked(issue) { return !!issue.discussion_locked; }, - hasIssueWarning(issue) { - return this.isIssueConfidential(issue) || this.isIssueLocked(issue); + hasWarning(issue) { + return this.isConfidential(issue) || this.isLocked(issue); }, }, }; |