feat: don't update query params for booker atom (#20000)

* feat: Add `omitUpdatingParams` prop to Booker store for query param control

* remove console

* Update booking.tsx

* fix: type check failing

* undo changes

* feat: Expose `onBookerStateChange` callback to track `booker-store` updates

* add `onBookerStateChange` docs

* Update store.ts

* added `allowUpdatingUrlParams` for backwards compatibility
This commit is contained in:
Somay Chauhan authored and GitHub committed 2025-03-13 23:47:24 +05:30
1 parent f8aa2701b6
commit b1ebefb854
5 files changed
+141 -15

No files matched your search

@@ -101,6 +101,10 @@ export default function Bookings(props: { calUsername: string; calEmail: string
router.push(`/${data.data.uid}`);
}
}}
onBookerStateChange={(bookerState) => {
console.log("Booker state updated:", bookerState);
// You can perform any actions based on the updated state here
}}
metadata={{ CustomKey: "CustomValue" }}
duration={eventTypeDuration}
customClassNames={{
@@ -120,6 +124,8 @@ export default function Bookings(props: { calUsername: string; calEmail: string
? { isTeamEvent: true, teamId: teams?.[0]?.id || 0 }
: { username: props.calUsername })}
hostsLimit={3}
selectedDate={new Date("2025-03-25")}
allowUpdatingUrlParams={true}
/>
</>
)}