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>2023-10-19 15:57:54 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-10-19 15:57:54 +0300
commit419c53ec62de6e97a517abd5fdd4cbde3a942a34 (patch)
tree1f43a548b46bca8a5fb8fe0c31cef1883d49c5b6 /app/assets/javascripts/vue_shared/components/blob_viewers
parent1da20d9135b3ad9e75e65b028bffc921aaf8deb7 (diff)
Add latest changes from gitlab-org/gitlab@16-5-stable-eev16.5.0-rc42
Diffstat (limited to 'app/assets/javascripts/vue_shared/components/blob_viewers')
-rw-r--r--app/assets/javascripts/vue_shared/components/blob_viewers/rich_viewer.vue12
1 files changed, 7 insertions, 5 deletions
diff --git a/app/assets/javascripts/vue_shared/components/blob_viewers/rich_viewer.vue b/app/assets/javascripts/vue_shared/components/blob_viewers/rich_viewer.vue
index 27bdcc69120..b52752d7e2f 100644
--- a/app/assets/javascripts/vue_shared/components/blob_viewers/rich_viewer.vue
+++ b/app/assets/javascripts/vue_shared/components/blob_viewers/rich_viewer.vue
@@ -41,7 +41,6 @@ export default {
mounted() {
this.renderRemainingMarkup();
handleBlobRichViewer(this.$refs.content, this.type);
- handleLocationHash();
},
methods: {
optimizeMarkupRendering() {
@@ -76,8 +75,7 @@ export default {
* */
if (!this.isMarkup || !this.remainingContent.length) {
- this.$emit(CONTENT_LOADED_EVENT);
- this.isLoading = false;
+ this.onContentLoaded();
return;
}
@@ -89,11 +87,15 @@ export default {
setTimeout(() => {
fileContent.append(...content);
if (nextChunkEnd < this.remainingContent.length) return;
- this.$emit(CONTENT_LOADED_EVENT);
- this.isLoading = false;
+ this.onContentLoaded();
}, i);
}
},
+ onContentLoaded() {
+ this.$emit(CONTENT_LOADED_EVENT);
+ handleLocationHash();
+ this.isLoading = false;
+ },
},
safeHtmlConfig: {
ADD_TAGS: ['gl-emoji', 'copy-code'],