Requires Confirmation Threshold (#5825)

* WIP + react errors fixed

* Booking and Availability page treatment

* Update BookingPage.tsx

Co-authored-by: Bailey Pumfleet <[email protected]>
This commit is contained in:
Leo GiovanettiandBailey Pumfleet authored and GitHub committed 2022-12-05 12:12:14 +00:00
1 parent 58270fa653
commit 1cdcebac01
11 files changed
+228 -44

No files matched your search

+2 -2
View File
@@ -14,11 +14,11 @@ const Switch = (
fitToHeight?: boolean;
}
) => {
const { label, ...primitiveProps } = props;
const { label, fitToHeight, ...primitiveProps } = props;
const id = useId();
return (
<div className={classNames("flex h-auto w-auto flex-row items-center", props.fitToHeight && "h-fit")}>
<div className={classNames("flex h-auto w-auto flex-row items-center", fitToHeight && "h-fit")}>
<PrimitiveSwitch.Root
className={classNames(
props.checked ? "bg-gray-900" : "bg-gray-200",
@@ -95,7 +95,9 @@ export const EventTypeDescription = ({ eventType, className }: EventTypeDescript
{eventType.requiresConfirmation && (
<li className="hidden xl:block">
<Badge variant="gray" size="lg" StartIcon={Icon.FiClipboard}>
{t("requires_confirmation")}
{eventType.metadata?.requiresConfirmationThreshold
? t("may_require_confirmation")
: t("requires_confirmation")}
</Badge>
</li>
)}