fix: [CAL-2040] add spinner when bookerState is loading (#9873)

pull/10320/head^2
Afrie Irham 2023-07-25 01:20:42 +08:00 committed by GitHub
parent 0138fdd971
commit f168ec8df6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 1 deletions

View File

@ -158,6 +158,11 @@ const BookerComponent = ({
}; };
const shouldShowFormInDialog = shouldShowFormInDialogMap[layout]; const shouldShowFormInDialog = shouldShowFormInDialogMap[layout];
if (bookerState === "loading") {
return null;
}
return ( return (
<> <>
{event.data ? <BookingPageTagManager eventType={event.data} /> : null} {event.data ? <BookingPageTagManager eventType={event.data} /> : null}
@ -209,7 +214,7 @@ const BookerComponent = ({
<EventMeta /> <EventMeta />
{layout !== BookerLayouts.MONTH_VIEW && {layout !== BookerLayouts.MONTH_VIEW &&
!(layout === "mobile" && bookerState === "booking") && ( !(layout === "mobile" && bookerState === "booking") && (
<div className=" mt-auto px-5 py-3"> <div className="mt-auto px-5 py-3 ">
<DatePicker /> <DatePicker />
</div> </div>
)} )}