diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-12-22 18:14:10 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-12-22 18:14:10 +0300 |
commit | 60d2a60617c9251049fbd5708465d01d25179a98 (patch) | |
tree | d95e0dc1c2f29c9958cb80c0d3907f889f6ee6fd /app/assets/javascripts/blob | |
parent | 96891fec6dfa20a8342a3daa25935213cfddae22 (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_filepath.vue | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/app/assets/javascripts/blob/components/blob_header_filepath.vue b/app/assets/javascripts/blob/components/blob_header_filepath.vue index cb441a7e491..90d01358451 100644 --- a/app/assets/javascripts/blob/components/blob_header_filepath.vue +++ b/app/assets/javascripts/blob/components/blob_header_filepath.vue @@ -1,4 +1,5 @@ <script> +import { GlBadge } from '@gitlab/ui'; import { numberToHumanSize } from '~/lib/utils/number_utils'; import ClipboardButton from '~/vue_shared/components/clipboard_button.vue'; import FileIcon from '~/vue_shared/components/file_icon.vue'; @@ -7,6 +8,7 @@ export default { components: { FileIcon, ClipboardButton, + GlBadge, }, props: { blob: { @@ -21,6 +23,9 @@ export default { gfmCopyText() { return `\`${this.blob.path}\``; }, + showLfsBadge() { + return this.blob.storedExternally && this.blob.externalStorage === 'lfs'; + }, }, }; </script> @@ -37,8 +42,6 @@ export default { > </template> - <small class="mr-2">{{ blobSize }}</small> - <clipboard-button :text="blob.path" :gfm="gfmCopyText" @@ -46,5 +49,9 @@ export default { category="tertiary" css-class="btn-clipboard btn-transparent lh-100 position-static" /> + + <small class="mr-2">{{ blobSize }}</small> + + <gl-badge v-if="showLfsBadge">{{ __('LFS') }}</gl-badge> </div> </template> |