Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-11-16 12:09:18 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-11-16 12:09:18 +0300
commit14cb5b3d793c1f41c7d36e2e899d3e5e9eca148f (patch)
tree235f19919bf2a070c337f0336443fb05eacf52b2 /app/assets/javascripts/blob
parent0ab17699c88587c5872f9517b29be5f43224a8ea (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/assets/javascripts/blob')
-rw-r--r--app/assets/javascripts/blob/components/blob_header_default_actions.vue6
1 files changed, 5 insertions, 1 deletions
diff --git a/app/assets/javascripts/blob/components/blob_header_default_actions.vue b/app/assets/javascripts/blob/components/blob_header_default_actions.vue
index daade611651..6eddec31166 100644
--- a/app/assets/javascripts/blob/components/blob_header_default_actions.vue
+++ b/app/assets/javascripts/blob/components/blob_header_default_actions.vue
@@ -32,6 +32,7 @@ export default {
default: false,
},
},
+ inject: ['blobHash'],
computed: {
downloadUrl() {
return `${this.rawPath}?inline=false`;
@@ -39,6 +40,9 @@ export default {
copyDisabled() {
return this.activeViewer === RICH_BLOB_VIEWER;
},
+ getBlobHashTarget() {
+ return `[data-blob-hash="${this.blobHash}"]`;
+ },
},
BTN_COPY_CONTENTS_TITLE,
BTN_DOWNLOAD_TITLE,
@@ -53,7 +57,7 @@ export default {
:aria-label="$options.BTN_COPY_CONTENTS_TITLE"
:title="$options.BTN_COPY_CONTENTS_TITLE"
:disabled="copyDisabled"
- data-clipboard-target="#blob-code-content"
+ :data-clipboard-target="getBlobHashTarget"
data-testid="copyContentsButton"
icon="copy-to-clipboard"
category="primary"