Merged in fix/SW-2501-validation-trigger (pull request #1924)

fix(SW-2501): validation trigger

* fix(SW-2501): validation trigger

On enter details, when submitting we want to trigger the validation for
the details forms for each room. This will display error messages for
the form fields with errors if they are not already displayed, so the
user knows which fields has errors.


Approved-by: Tobias Johansson
This commit is contained in:
Niclas Edenvin
2025-05-02 13:59:23 +00:00
parent d49ecdae1f
commit fb44990777
5 changed files with 57 additions and 13 deletions

View File

@@ -87,6 +87,7 @@ export interface DetailsState {
setTotalPrice: (totalPrice: Price) => void
toggleSummaryOpen: () => void
updateSeachParamString: (searchParamString: string) => void
addPreSubmitCallback: (name: string, callback: () => void) => void
}
booking: SelectRateSearchParams
breakfastPackages: BreakfastPackages
@@ -98,6 +99,7 @@ export interface DetailsState {
searchParamString: string
totalPrice: Price
vat: number
preSubmitCallbacks: Record<string, () => void>
}
export type PersistedState = {