From 39937a3436452a0cb85e8d64287bb97983a1ac9a Mon Sep 17 00:00:00 2001 From: Nathan Panchout Date: Mon, 4 May 2026 16:17:56 +0200 Subject: [PATCH] =?UTF-8?q?=E2=99=BB=EF=B8=8F(frontend)=20adapt=20modals?= =?UTF-8?q?=20to=20ModalDefaultVariantProps?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit cunningham-react 4.3.0 splits Modal props per variant. Switch AlertModal and SideModal from the now-removed ModalProps alias to the more precise ModalDefaultVariantProps type so the modal wrappers keep type-checking against the new API. Signed-off-by: Nathan Panchout --- .../apps/impress/src/components/modal/SideModal.tsx | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/frontend/apps/impress/src/components/modal/SideModal.tsx b/src/frontend/apps/impress/src/components/modal/SideModal.tsx index 9e6047c12..93ca9e18a 100644 --- a/src/frontend/apps/impress/src/components/modal/SideModal.tsx +++ b/src/frontend/apps/impress/src/components/modal/SideModal.tsx @@ -1,5 +1,9 @@ -import { Modal, ModalSize } from '@gouvfr-lasuite/cunningham-react'; -import { ComponentPropsWithRef, PropsWithChildren } from 'react'; +import { + Modal, + ModalDefaultVariantProps, + ModalSize, +} from '@gouvfr-lasuite/cunningham-react'; +import { PropsWithChildren } from 'react'; import { createGlobalStyle } from 'styled-components'; interface SideModalStyleProps { @@ -35,7 +39,7 @@ const SideModalStyle = createGlobalStyle` } `; -type SideModalType = Omit, 'size'>; +type SideModalType = Omit; type SideModalProps = SideModalType & Partial;