Skip to content

Scheduling infrastructure for absolutely everyone.

feat: add ARIA labels to time format and layout toggle controls (#27760)

Ahmad Yasser3052cf515779
diff --git a/packages/features/bookings/components/Header.tsx b/packages/features/bookings/components/Header.tsx
index 2d8c203b003..4373fcd38d1 100644
--- a/packages/features/bookings/components/Header.tsx
+++ b/packages/features/bookings/components/Header.tsx
@@ -234,7 +234,14 @@ const LayoutToggle = ({
// the layout can be toggled via props in the booker atom
if (isPlatform) return null;
- return <ToggleGroup onValueChange={onLayoutToggle} defaultValue={layout} options={layoutOptions} />;
+ return (
+ <ToggleGroup
+ onValueChange={onLayoutToggle}
+ defaultValue={layout}
+ aria-label={t("layout")}
+ options={layoutOptions}
+ />
+ );
};
const LayoutToggleWithData = ({
diff --git a/packages/features/bookings/components/TimeFormatToggle.tsx b/packages/features/bookings/components/TimeFormatToggle.tsx
index 04c00113d09..787bfd05831 100644
--- a/packages/features/bookings/components/TimeFormatToggle.tsx
+++ b/packages/features/bookings/components/TimeFormatToggle.tsx
@@ -17,6 +17,7 @@ export const TimeFormatToggle = ({ customClassName }: { customClassName?: string
}}
defaultValue={timeFormat}
value={timeFormat}
+ aria-label={t("time_format")}
options={[
{ value: TimeFormat.TWELVE_HOUR, label: t("12_hour_short") },
{ value: TimeFormat.TWENTY_FOUR_HOUR, label: t("24_hour_short") },