From 5697de4429c5d94f25ce1bd14c84fb4266ea47a7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ra=C3=BAl=20G=C3=B3mez=20Morales?= Date: Tue, 8 Oct 2024 11:56:48 +0200 Subject: [PATCH] feat(editor): Add route for create / edit / share credentials (#11134) Co-authored-by: Csaba Tuncsik --- .../src/components/CredentialCard.vue | 8 +- .../editor-ui/src/routes/projects.routes.ts | 3 +- .../src/views/CredentialsView.test.ts | 189 +++++++++++------- .../editor-ui/src/views/CredentialsView.vue | 48 ++++- 4 files changed, 167 insertions(+), 81 deletions(-) diff --git a/packages/editor-ui/src/components/CredentialCard.vue b/packages/editor-ui/src/components/CredentialCard.vue index 958f236f1d..c39166f15a 100644 --- a/packages/editor-ui/src/components/CredentialCard.vue +++ b/packages/editor-ui/src/components/CredentialCard.vue @@ -21,6 +21,10 @@ const CREDENTIAL_LIST_ITEM_ACTIONS = { MOVE: 'move', }; +const emit = defineEmits<{ + click: [credentialId: string]; +}>(); + const props = withDefaults( defineProps<{ data: ICredentialsResponse; @@ -83,7 +87,7 @@ const formattedCreatedAtDate = computed(() => { }); function onClick() { - uiStore.openExistingCredential(props.data.id); + emit('click', props.data.id); } async function onAction(action: string) { @@ -131,7 +135,7 @@ function moveResource() {