diff --git a/website/src/components/BrowserWindow.tsx b/website/src/components/BrowserWindow.tsx index bcf1549a2..0e4ec32f8 100644 --- a/website/src/components/BrowserWindow.tsx +++ b/website/src/components/BrowserWindow.tsx @@ -14,6 +14,7 @@ interface Props { minHeight?: number; url: string; style?: CSSProperties; + styleStr?: string; bodyStyle?: CSSProperties; shadow?: boolean; } @@ -23,7 +24,8 @@ export function BrowserWindow({ minHeight, style, bodyStyle, - shadow = true + shadow = true, + styleStr }: Props) { return (
- {props.mode === "single" && - selected && - dateLib.format(selected as Date, "EEEE, d MMMM yyyy")} + {props.mode === "single" && selected && ( + <> + {String(selected)} -{" "} + {dateLib.format(selected as Date, "EEEE, d MMMM yyyy")} + > + )} {props.mode === "multiple" && (selected as Date[] | undefined)?.map((date) => { return ( <> + {String(date)} -{" "} {dateLib.format(date, "EEEE, d MMMM yyyy")}
> @@ -607,12 +610,20 @@ export default function Playground() { {props.mode === "range" && isDateRange(selected) && ( <> From:{" "} - {selected.from && - dateLib.format(selected.from, "EEEE, d MMMM yyyy")} + {selected.from && ( + <> + {String(selected.from)} -{" "} + {dateLib.format(selected.from, "EEEE, d MMMM yyyy")} + > + )}
To: {" "} - {selected.to && - dateLib.format(selected.to, "EEEE, d MMMM yyyy")} + {selected.to && ( + <> + {String(selected.to)} -{" "} + {dateLib.format(selected.to, "EEEE, d MMMM yyyy")} + > + )} > )}