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:
Diffstat (limited to 'app/assets/javascripts')
-rw-r--r--app/assets/javascripts/registry/explorer/utils.js11
-rw-r--r--app/assets/javascripts/vue_merge_request_widget/mr_widget_options.vue5
2 files changed, 14 insertions, 2 deletions
diff --git a/app/assets/javascripts/registry/explorer/utils.js b/app/assets/javascripts/registry/explorer/utils.js
index 2c89d508c31..a48da51caae 100644
--- a/app/assets/javascripts/registry/explorer/utils.js
+++ b/app/assets/javascripts/registry/explorer/utils.js
@@ -1,3 +1,5 @@
+import { joinPaths } from '~/lib/utils/url_utility';
+
export const pathGenerator = (imageDetails, ending = '?format=json') => {
// this method is a temporary workaround, to be removed with graphql implementation
// https://gitlab.com/gitlab-org/gitlab/-/issues/276432
@@ -12,5 +14,12 @@ export const pathGenerator = (imageDetails, ending = '?format=json') => {
return acc;
}, [])
.join('/');
- return `/${basePath}/registry/repository/${imageDetails.id}/tags${ending}`;
+
+ return joinPaths(
+ window.gon.relative_url_root,
+ `/${basePath}`,
+ '/registry/repository/',
+ `${imageDetails.id}`,
+ `tags${ending}`,
+ );
};
diff --git a/app/assets/javascripts/vue_merge_request_widget/mr_widget_options.vue b/app/assets/javascripts/vue_merge_request_widget/mr_widget_options.vue
index 190d790f584..e7f0977778e 100644
--- a/app/assets/javascripts/vue_merge_request_widget/mr_widget_options.vue
+++ b/app/assets/javascripts/vue_merge_request_widget/mr_widget_options.vue
@@ -202,6 +202,9 @@ export default {
shouldShowAccessibilityReport() {
return this.mr.accessibilityReportPath;
},
+ formattedHumanAccess() {
+ return (this.mr.humanAccess || '').toLowerCase();
+ },
},
watch: {
state(newVal, oldVal) {
@@ -439,7 +442,7 @@ export default {
class="mr-widget-workflow"
:pipeline-path="mr.mergeRequestAddCiConfigPath"
:pipeline-svg-path="mr.pipelinesEmptySvgPath"
- :human-access="mr.humanAccess.toLowerCase()"
+ :human-access="formattedHumanAccess"
:user-callouts-path="mr.userCalloutsPath"
:user-callout-feature-id="mr.suggestPipelineFeatureId"
@dismiss="dismissSuggestPipelines"