From da68243a91865732db46b9ae610a82eeec5c9bf2 Mon Sep 17 00:00:00 2001 From: Claire Nollet Date: Wed, 24 Jan 2024 19:21:30 +0100 Subject: [PATCH] feat: :children_crossing: better ux for forms in tiles --- apps/client/cypress/e2e/support/commands.ts | 2 ++ apps/client/src/components/ClusterForm.vue | 2 +- apps/client/src/components/QuotaForm.vue | 2 +- apps/client/src/components/RepoForm.vue | 6 +++--- apps/client/src/components/StageForm.vue | 2 +- apps/client/src/views/admin/ListClusters.vue | 19 ++++++++++++++++++- apps/client/src/views/admin/ListProjects.vue | 1 + apps/client/src/views/admin/ListQuotas.vue | 19 ++++++++++++++++++- apps/client/src/views/admin/ListStages.vue | 19 ++++++++++++++++++- apps/client/src/views/projects/DsoRepos.vue | 19 ++++++++++++++++++- .../src/views/projects/ManageEnvironments.vue | 19 ++++++++++++++++++- 11 files changed, 99 insertions(+), 11 deletions(-) diff --git a/apps/client/cypress/e2e/support/commands.ts b/apps/client/cypress/e2e/support/commands.ts index 1433020c9..050c4e033 100644 --- a/apps/client/cypress/e2e/support/commands.ts +++ b/apps/client/cypress/e2e/support/commands.ts @@ -235,6 +235,8 @@ Cypress.Commands.add('assertAddEnvironment', (project, environments, isDeepCheck .should('have.value', environment?.quota?.id) cy.get('#cluster-select') .should('have.value', environment?.cluster?.id) + cy.getByDataTestid('goBackBtn') + .click() } }) }) diff --git a/apps/client/src/components/ClusterForm.vue b/apps/client/src/components/ClusterForm.vue index 7102006d6..a54521306 100644 --- a/apps/client/src/components/ClusterForm.vue +++ b/apps/client/src/components/ClusterForm.vue @@ -374,7 +374,7 @@ watch(selectedContext, () => { /> { /> { emit('save', localRepo.value) } -const cancel = (event) => { - emit('cancel', event) +const cancel = () => { + emit('cancel') } @@ -171,7 +171,7 @@ const cancel = (event) => { class="flex space-x-10 mt-5" > { /> { class="flex { icon="ri-add-line" @click="showNewClusterForm()" /> +
+ +
{ />
{ :key="cluster.id" class="fr-mt-2v fr-mb-4w w-full" > -
+
{ { class="flex { icon="ri-add-line" @click="showNewQuotaForm()" /> +
+ +
{ />
{ :key="quota.id" class="fr-mt-2v fr-mb-4w w-full" > -
+
{ class="flex { icon="ri-add-line" @click="showNewStageForm()" /> +
+ +
{ />
{ :key="stage.id" class="fr-mt-2v fr-mb-4w w-full" > -
+
{ class="flex { icon="ri-add-line" @click="showNewRepoForm()" /> +
+ +
{ />
{ :key="repo.id" class="fr-mt-2v fr-mb-4w" > -
+
{ class="flex { icon="ri-add-line" @click="showNewEnvironmentForm()" /> +
+ +
{ />
{ :key="environment.id" class="fr-mt-2v fr-mb-4w" > -
+