Scheduling infrastructure for absolutely everyone.
Fixed listing formatting and save for custom inputs (#5795)
Leo Giovanettief3ad36c2c76
diff --git a/apps/web/components/eventtype/CustomInputTypeForm.tsx b/apps/web/components/eventtype/CustomInputTypeForm.tsxindex 08a2b3fd5d9..07510bcaa15 100644--- a/apps/web/components/eventtype/CustomInputTypeForm.tsx+++ b/apps/web/components/eventtype/CustomInputTypeForm.tsx@@ -40,7 +40,7 @@ const CustomInputTypeForm: FC<Props> = (props) => {};return (- <form onSubmit={handleSubmit(props.onSubmit)} className="flex flex-col space-y-4">+ <form className="flex flex-col space-y-4"><div><label htmlFor="type" className="block text-sm font-medium text-gray-700">{t("input_type")}@@ -111,7 +111,9 @@ const CustomInputTypeForm: FC<Props> = (props) => {<Button onClick={onCancel} type="button" color="secondary" className="ltr:mr-2">{t("cancel")}</Button>- <Button type="submit">{t("save")}</Button>+ <Button onClick={handleSubmit(props.onSubmit)} form="custom-input">+ {t("save")}+ </Button></div></form>);diff --git a/apps/web/components/eventtype/EventAdvancedTab.tsx b/apps/web/components/eventtype/EventAdvancedTab.tsxindex c5405451f50..6a885e354eb 100644--- a/apps/web/components/eventtype/EventAdvancedTab.tsx+++ b/apps/web/components/eventtype/EventAdvancedTab.tsx@@ -132,7 +132,7 @@ export const EventAdvancedTab = ({ eventType, team }: Pick<EventTypeSetupInferedformMethods.setValue("customInputs", []);}}}>- <ul className="my-4">+ <ul className="my-4 rounded-md border">{customInputs.map((customInput: EventTypeCustomInput, idx: number) => (<CustomInputItemkey={idx}@@ -156,7 +156,7 @@ export const EventAdvancedTab = ({ eventType, team }: Pick<EventTypeSetupInferedsetSelectedCustomInput(undefined);setSelectedCustomInputModalOpen(true);}}>- Add an input+ {t("add_input")}</Button>)}</SettingsToggle>diff --git a/apps/web/pages/booking/[uid].tsx b/apps/web/pages/booking/[uid].tsxindex b2f1b572111..8a883b17d55 100644--- a/apps/web/pages/booking/[uid].tsx+++ b/apps/web/pages/booking/[uid].tsx@@ -411,7 +411,7 @@ export default function Success(props: SuccessProps) {{(bookingInfo?.user || bookingInfo?.attendees) && (<><div className="font-medium">{t("who")}</div>- <div className="col-span-2 mb-6 last:mb-0">+ <div className="col-span-2 last:mb-0"><>{bookingInfo?.user && (<div className="mb-3">@@ -458,8 +458,8 @@ export default function Success(props: SuccessProps) {<>{customInput !== "" && (<>- <div className="mt-2 pr-3 font-medium">{key}</div>- <div className="col-span-2 mt-2 mb-2">+ <div className="col-span-3 mt-8 border-t pt-8 pr-3 font-medium">{key}</div>+ <div className="col-span-3 mt-2 mb-2">{typeof customInput === "boolean" ? (<p>{customInput ? "true" : "false"}</p>) : (diff --git a/packages/ui/v2/modules/event-types/CustomInputItem.tsx b/packages/ui/v2/modules/event-types/CustomInputItem.tsxindex 08808f8e8bb..6ad2b6b1b9c 100644--- a/packages/ui/v2/modules/event-types/CustomInputItem.tsx+++ b/packages/ui/v2/modules/event-types/CustomInputItem.tsx@@ -13,7 +13,7 @@ type Props = {function CustomInputItem({ required, deleteOnClick, editOnClick, type, question }: Props) {const { t } = useLocale();return (- <li className="border-1 flex border border-gray-200 bg-white px-6 py-4 first:rounded-t-md last:rounded-b-md only:rounded-md">+ <li className="flex rounded-b-md border-t border-gray-200 bg-white px-6 py-4 first:rounded-t-md first:border-0"><div className="flex flex-col"><div className="flex items-center"><span className="pr-2 text-sm font-semibold leading-none text-black">{question}</span>