diff --git a/assets/translations/en-us.yaml b/assets/translations/en-us.yaml index 448fd1c1d8..72defbea95 100644 --- a/assets/translations/en-us.yaml +++ b/assets/translations/en-us.yaml @@ -174,6 +174,15 @@ containerResourceLimit: requestsCpu: CPU Reservation requestsMemory: Memory Reservation +cruResource: + previewYaml: Preview Yaml + cancel: Cancelling will destroy your changes. + back: Going back will destroy your changes. + confirmYaml: "No, Review Yaml" + backToForm: Go Back To Form + confirmCancel: "Yes, Cancel" + confirmBack: "Yes, Go Back" + footer: docs: Docs download: Download CLI diff --git a/components/CruResource.vue b/components/CruResource.vue index 314b1645b1..c90bc1764b 100644 --- a/components/CruResource.vue +++ b/components/CruResource.vue @@ -40,7 +40,7 @@ export default { return { isCancelModal: false, showAsForm: true, - resourceYaml: '', + resourceYaml: '' }; }, methods: { @@ -48,12 +48,17 @@ export default { if (isCancel) { // this.$modal.show('cancel') pass translation options this.isCancelModal = true; + } else { + this.isCancelModal = false; } this.$modal.show('cancel-modal'); }, confirmCancel(isCancel) { + this.$modal.hide('cancel-modal'); + if (isCancel) { + this.isCancelModal = false; this.$router.replace({ name: this.doneRoute, params: { resource: this.resource.type } @@ -78,157 +83,152 @@ export default { - - - - - - - - - {{ t(subtype.bannerAbbrv) }} - {{ subtype.bannerAbbrv.slice(0, 1).toUpperCase() }} - - - {{ subtype.id.slice(0, 1).toUpperCase() }} - - - - - - - - - {{ subtype.label }} - - - - - {{ subtype.description }} - - - - - - - - - - - - - - - - - - - - Preview Yaml - - + + + + - + + + + + {{ t(subtype.bannerAbbrv) }} + {{ subtype.bannerAbbrv.slice(0, 1).toUpperCase() }} + + + {{ subtype.id.slice(0, 1).toUpperCase() }} + + + + + + + + + {{ subtype.label }} + + + + + {{ subtype.description }} + + + + + + + + + + + + + + + - - - - - - - - - - - + + + + + + + + + + - - - + + + + + + + - - - - - - - - + + + + + + + + + + + + + + - Go Back To Form + - Cancelling will destroy your changes. + - Going back will destroy your changes. + @@ -236,6 +236,33 @@ export default {
- Cancelling will destroy your changes. +
- Going back will destroy your changes. +