From 6d54fe22d208518a5478180dac685a16a1fd3f0c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Rialland?= Date: Tue, 26 Apr 2022 16:07:28 +0200 Subject: [PATCH] Fix type --- site/source/components/conversation/RuleInput.tsx | 2 +- site/source/components/conversation/select/SelectTauxRisque.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/site/source/components/conversation/RuleInput.tsx b/site/source/components/conversation/RuleInput.tsx index 13a8eb568..c42f61acb 100644 --- a/site/source/components/conversation/RuleInput.tsx +++ b/site/source/components/conversation/RuleInput.tsx @@ -38,7 +38,7 @@ type Props = Omit< // implement this behavior currently // cf .https://github.com/betagouv/mon-entreprise/issues/1489#issuecomment-823058710 showDefaultDateValue?: boolean - onSubmit?: (source: string) => void + onSubmit?: (source?: string) => void inputType?: 'radio' | 'card' | 'toggle' | 'select' formatOptions?: Intl.NumberFormatOptions displayedUnit?: string diff --git a/site/source/components/conversation/select/SelectTauxRisque.tsx b/site/source/components/conversation/select/SelectTauxRisque.tsx index 9cad8c73b..f141a9473 100644 --- a/site/source/components/conversation/select/SelectTauxRisque.tsx +++ b/site/source/components/conversation/select/SelectTauxRisque.tsx @@ -137,7 +137,7 @@ interface ErrorT extends Error { } export default function SelectAtmp( - props: Parameters[0] + props: Omit[0], 'options'> ) { const [options, setOptions] = useState(null)