Commit 160bbac6 authored by Kushal Pandya's avatar Kushal Pandya

Merge branch '283991-update-qa-selector-close-button' into 'master'

Add qa-selector to issue header

See merge request gitlab-org/gitlab!47851
parents 8b602bd9 eb2180d6
...@@ -87,6 +87,9 @@ export default { ...@@ -87,6 +87,9 @@ export default {
? sprintf(__('Reopen %{issueType}'), { issueType: this.issueType }) ? sprintf(__('Reopen %{issueType}'), { issueType: this.issueType })
: sprintf(__('Close %{issueType}'), { issueType: this.issueType }); : sprintf(__('Close %{issueType}'), { issueType: this.issueType });
}, },
qaSelector() {
return this.isClosed ? 'reopen_issue_button' : 'close_issue_button';
},
buttonVariant() { buttonVariant() {
return this.isClosed ? 'default' : 'warning'; return this.isClosed ? 'default' : 'warning';
}, },
...@@ -216,6 +219,7 @@ export default { ...@@ -216,6 +219,7 @@ export default {
v-if="showToggleIssueStateButton" v-if="showToggleIssueStateButton"
class="gl-display-none gl-display-sm-inline-flex!" class="gl-display-none gl-display-sm-inline-flex!"
category="secondary" category="secondary"
:data-qa-selector="qaSelector"
:loading="isUpdatingState" :loading="isUpdatingState"
:variant="buttonVariant" :variant="buttonVariant"
@click="toggleIssueState" @click="toggleIssueState"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment