fix: Estimate customize values

This commit is contained in:
Ahmed Bouhuolia
2024-10-07 17:20:45 +02:00
parent 682d40cbf8
commit d92b46aa7b
3 changed files with 4 additions and 5 deletions

View File

@@ -49,7 +49,7 @@ function EstimatePaperTemplateFormConnected() {
const { values } = useFormikContext<EstimateCustomizeValues>();
const { brandingState } = useElementCustomizeContext()
const mergedProps: EstimatePaperTemplateProps = { ...values, ...brandingState }
const mergedProps: EstimatePaperTemplateProps = { ...brandingState, ...values, }
return <EstimatePaperTemplate {...mergedProps} />;
}

View File

@@ -63,7 +63,7 @@ const withInvoicePreviewTemplateProps = <P extends object>(
const { values } = useFormikContext<InvoiceCustomizeFormValues>();
const { brandingState, } = useElementCustomizeContext();
const mergedProps: InvoicePaperTemplateProps = { ...brandingState, ...values }
const mergedProps: InvoicePaperTemplateProps = { ...brandingState, ...values };
return <Component {...(props as P)} {...mergedProps} />;
};