From b00636595bc9282c2bc427de274dd3be7e7abd4c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9s=20De=20Freitas?= <6485562+adefreitas@users.noreply.github.com> Date: Tue, 17 Mar 2026 13:45:55 +0000 Subject: [PATCH 1/3] feat: dont render close button if no close handler is passed --- src/modules/integration-picker/IntegrationPicker.tsx | 2 +- .../components/successCardFooter.tsx | 10 ++++++---- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/modules/integration-picker/IntegrationPicker.tsx b/src/modules/integration-picker/IntegrationPicker.tsx index 1b9e899..802840c 100644 --- a/src/modules/integration-picker/IntegrationPicker.tsx +++ b/src/modules/integration-picker/IntegrationPicker.tsx @@ -94,7 +94,7 @@ export const IntegrationPicker: React.FC = ({ footer={ connectionState.success ? ( onClose?.()} + onClose={onClose} showFooterLinks={showFooterLinks} /> ) : ( diff --git a/src/modules/integration-picker/components/successCardFooter.tsx b/src/modules/integration-picker/components/successCardFooter.tsx index 1c7e5ac..1ea758e 100644 --- a/src/modules/integration-picker/components/successCardFooter.tsx +++ b/src/modules/integration-picker/components/successCardFooter.tsx @@ -9,7 +9,7 @@ import { } from '@stackone/malachite'; interface CardFooterProps { - onClose: () => void; + onClose?: () => void; showFooterLinks?: boolean; } @@ -20,9 +20,11 @@ const SuccessCardFooter: React.FC = ({ showFooterLinks = true, - + {onClose && ( + + )} From 42dd7eff4f336e370a3ecc58bd2a2d4bc32cf7a2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9s=20De=20Freitas?= <6485562+adefreitas@users.noreply.github.com> Date: Tue, 17 Mar 2026 13:52:36 +0000 Subject: [PATCH 2/3] fix: lint --- src/modules/integration-picker/IntegrationPicker.tsx | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/modules/integration-picker/IntegrationPicker.tsx b/src/modules/integration-picker/IntegrationPicker.tsx index 802840c..3beef05 100644 --- a/src/modules/integration-picker/IntegrationPicker.tsx +++ b/src/modules/integration-picker/IntegrationPicker.tsx @@ -93,10 +93,7 @@ export const IntegrationPicker: React.FC = ({ glassFooter footer={ connectionState.success ? ( - + ) : ( Date: Tue, 17 Mar 2026 13:55:36 +0000 Subject: [PATCH 3/3] fix: skip footer if no links or close action --- .../components/successCardFooter.tsx | 33 +++++++++++++------ 1 file changed, 23 insertions(+), 10 deletions(-) diff --git a/src/modules/integration-picker/components/successCardFooter.tsx b/src/modules/integration-picker/components/successCardFooter.tsx index 1ea758e..f36ece7 100644 --- a/src/modules/integration-picker/components/successCardFooter.tsx +++ b/src/modules/integration-picker/components/successCardFooter.tsx @@ -14,20 +14,33 @@ interface CardFooterProps { } const SuccessCardFooter: React.FC = ({ showFooterLinks = true, onClose }) => { + const hasFooterLinks = showFooterLinks; + const hasClose = Boolean(onClose); + + if (!hasFooterLinks && !hasClose) { + return null; + } + return ( - - {showFooterLinks && } - - - - {onClose && ( + + {hasFooterLinks && } + {hasClose && ( + + + - )} - - - + + + + )} ); };