diff options
Diffstat (limited to 'app/assets/javascripts/clusters')
3 files changed, 18 insertions, 17 deletions
diff --git a/app/assets/javascripts/clusters/agents/components/show.vue b/app/assets/javascripts/clusters/agents/components/show.vue index 5c672d288c5..afbba9d1f7c 100644 --- a/app/assets/javascripts/clusters/agents/components/show.vue +++ b/app/assets/javascripts/clusters/agents/components/show.vue @@ -128,6 +128,7 @@ export default { </p> <gl-tabs> + <slot name="ee-security-tab"></slot> <gl-tab> <template #title> <span data-testid="cluster-agent-token-count"> diff --git a/app/assets/javascripts/clusters/agents/index.js b/app/assets/javascripts/clusters/agents/index.js index bcb5b271203..426d8d83847 100644 --- a/app/assets/javascripts/clusters/agents/index.js +++ b/app/assets/javascripts/clusters/agents/index.js @@ -1,7 +1,7 @@ import Vue from 'vue'; import VueApollo from 'vue-apollo'; import createDefaultClient from '~/lib/graphql'; -import AgentShowPage from './components/show.vue'; +import AgentShowPage from 'ee_else_ce/clusters/agents/components/show.vue'; Vue.use(VueApollo); diff --git a/app/assets/javascripts/clusters/components/remove_cluster_confirmation.vue b/app/assets/javascripts/clusters/components/remove_cluster_confirmation.vue index 0da7be4040f..98db620e3ab 100644 --- a/app/assets/javascripts/clusters/components/remove_cluster_confirmation.vue +++ b/app/assets/javascripts/clusters/components/remove_cluster_confirmation.vue @@ -1,8 +1,7 @@ <script> -import { GlModal, GlButton, GlFormInput } from '@gitlab/ui'; -import { escape } from 'lodash'; +import { GlModal, GlButton, GlFormInput, GlSprintf } from '@gitlab/ui'; import csrf from '~/lib/utils/csrf'; -import { s__, sprintf } from '~/locale'; +import { s__ } from '~/locale'; import SplitButton from '~/vue_shared/components/split_button.vue'; const splitButtonActionItems = [ @@ -29,6 +28,7 @@ export default { GlModal, GlButton, GlFormInput, + GlSprintf, }, props: { clusterPath: { @@ -67,17 +67,11 @@ export default { : s__('ClusterIntegration|You are about to remove your cluster integration.'); }, confirmationTextLabel() { - return sprintf( - this.confirmCleanup - ? s__( - 'ClusterIntegration|To remove your integration and resources, type %{clusterName} to confirm:', - ) - : s__('ClusterIntegration|To remove your integration, type %{clusterName} to confirm:'), - { - clusterName: `<code>${escape(this.clusterName)}</code>`, - }, - false, - ); + return this.confirmCleanup + ? s__( + 'ClusterIntegration|To remove your integration and resources, type %{clusterName} to confirm:', + ) + : s__('ClusterIntegration|To remove your integration, type %{clusterName} to confirm:'); }, canSubmit() { return this.enteredClusterName === this.clusterName; @@ -140,7 +134,13 @@ export default { <!-- eslint-enable @gitlab/vue-require-i18n-strings --> </ul> </div> - <strong v-html="confirmationTextLabel /* eslint-disable-line vue/no-v-html */"></strong> + <strong> + <gl-sprintf :message="confirmationTextLabel"> + <template #clusterName> + <code>{{ clusterName }}</code> + </template> + </gl-sprintf> + </strong> <form ref="form" :action="clusterPath" method="post" class="gl-mb-5"> <input ref="method" type="hidden" name="_method" value="delete" /> <input :value="csrfToken" type="hidden" name="authenticity_token" /> @@ -159,7 +159,7 @@ export default { ) }}</span> <template #modal-footer> - <gl-button variant="secondary" @click="handleCancel">{{ s__('Cancel') }}</gl-button> + <gl-button variant="secondary" @click="handleCancel">{{ __('Cancel') }}</gl-button> <template v-if="confirmCleanup"> <gl-button :disabled="!canSubmit" |