From b33d69c32a1d7aeae69a63f8bf9f4b4a00612fba Mon Sep 17 00:00:00 2001 From: Boubaker Khanfir Date: Mon, 3 Jun 2024 12:54:46 +0100 Subject: [PATCH] feat: Add a button from Portlet instance preview dialog - MEED-6924 - Meeds-io/MIPs#139 (#97) This change will add a button in Applications Drawer inside the illustration preview, to be able to add the application. --- .../components/Illustration.vue | 6 +++- .../components/IllustrationPreviewDialog.vue | 28 +++++++++++++++++-- .../content/common/ApplicationCard.vue | 8 ++++++ 3 files changed, 39 insertions(+), 3 deletions(-) diff --git a/layout-webapp/src/main/webapp/vue-app/common-illustration/components/Illustration.vue b/layout-webapp/src/main/webapp/vue-app/common-illustration/components/Illustration.vue index 008f4ba24..a6dc9941a 100644 --- a/layout-webapp/src/main/webapp/vue-app/common-illustration/components/Illustration.vue +++ b/layout-webapp/src/main/webapp/vue-app/common-illustration/components/Illustration.vue @@ -68,6 +68,10 @@ export default { type: String, default: () => '60', }, + previewAction: { + type: String, + default: null, + }, }, data: () => ({ hover: false, @@ -88,7 +92,7 @@ export default { }, methods: { openIllustration() { - this.$root.$emit('layout-illustration-preview', this.illustrationSrc); + this.$root.$emit('layout-illustration-preview', this.illustrationSrc, this.previewAction); }, }, }; diff --git a/layout-webapp/src/main/webapp/vue-app/common-illustration/components/IllustrationPreviewDialog.vue b/layout-webapp/src/main/webapp/vue-app/common-illustration/components/IllustrationPreviewDialog.vue index 338983a7e..bf1205bed 100644 --- a/layout-webapp/src/main/webapp/vue-app/common-illustration/components/IllustrationPreviewDialog.vue +++ b/layout-webapp/src/main/webapp/vue-app/common-illustration/components/IllustrationPreviewDialog.vue @@ -30,6 +30,14 @@ content-class="overflow-y-initial full-height full-width pa-5">