From 828fcbe1d9ac09e04f81b63f76fe7a29bb01af77 Mon Sep 17 00:00:00 2001 From: "GitStart-Cal.com" <121884634+gitstart-calcom@users.noreply.github.com> Date: Thu, 2 Feb 2023 17:06:05 +0545 Subject: [PATCH 1/2] [CAL-713] /availability single - layout issues. Check spacing, margin, alignment with spec'd design (#6724) Co-authored-by: gitstart-calcom --- apps/web/pages/availability/[schedule].tsx | 48 ++++++++++--------- .../schedules/components/Schedule.tsx | 16 +++---- packages/features/shell/Shell.tsx | 7 ++- .../ui/components/form/select/components.tsx | 2 +- 4 files changed, 40 insertions(+), 33 deletions(-) diff --git a/apps/web/pages/availability/[schedule].tsx b/apps/web/pages/availability/[schedule].tsx index 84a4337bf7..a2c13c5f21 100644 --- a/apps/web/pages/availability/[schedule].tsx +++ b/apps/web/pages/availability/[schedule].tsx @@ -51,7 +51,7 @@ const DateOverride = ({ workingHours }: { workingHours: WorkingHours[] }) => { }); const { t } = useLocale(); return ( -
+

{t("date_overrides")}{" "} @@ -60,8 +60,8 @@ const DateOverride = ({ workingHours }: { workingHours: WorkingHours[] }) => {

-

{t("date_overrides_subtitle")}

-
+

{t("date_overrides_subtitle")}

+
yyyymmdd(field.ranges[0].start))} remove={remove} @@ -148,7 +148,7 @@ export default function Availability({ schedule }: { schedule: number }) { ) } CTA={ -
+
-
-
- {typeof me.data?.weekStart === "string" && ( - - )} + className="flex flex-col sm:mx-0 xl:flex-row xl:space-x-6"> +
+
+
+ {typeof me.data?.weekStart === "string" && ( + + )} +
+
+
+ {data?.workingHours && }
- {data?.workingHours && }
-
-
+
+
-
+

{t("something_doesnt_look_right")}

diff --git a/packages/features/schedules/components/Schedule.tsx b/packages/features/schedules/components/Schedule.tsx index 0050f9c934..8fa50cf52d 100644 --- a/packages/features/schedules/components/Schedule.tsx +++ b/packages/features/schedules/components/Schedule.tsx @@ -51,9 +51,9 @@ const ScheduleDay = ({ const watchDayRange = watch(name); return ( -
+
{/* Label & switch container */} -
+
@@ -77,7 +75,7 @@ const ScheduleDay = ({ {watchDayRange ? (
- {!!watchDayRange.length &&
{CopyButton}
} + {!!watchDayRange.length &&
{CopyButton}
}
) : ( @@ -142,7 +140,7 @@ const Schedule = < const { i18n } = useLocale(); return ( -
+
{/* First iterate for each day */} {weekdayNames(i18n.language, weekStart, "long").map((weekday, num) => { const weekdayIndex = (num + weekStart) % 7; @@ -179,7 +177,7 @@ export const DayRanges = ({
{fields.map((field, index: number) => ( -
+
} /> {index === 0 && (