mobile landscape

This commit is contained in:
Josh Hawkins 2025-10-29 14:52:14 -05:00
parent 8ba659b36b
commit b3e158bd01

View File

@ -9,6 +9,7 @@ import { toast } from "sonner";
import { Trans, useTranslation } from "react-i18next"; import { Trans, useTranslation } from "react-i18next";
import { LuInfo } from "react-icons/lu"; import { LuInfo } from "react-icons/lu";
import { cn } from "@/lib/utils"; import { cn } from "@/lib/utils";
import { isMobile } from "react-device-detect";
type Props = { type Props = {
className?: string; className?: string;
@ -67,8 +68,20 @@ export default function AnnotationOffsetSlider({ className }: Props) {
}, [annotationOffset, camera, mutate, t]); }, [annotationOffset, camera, mutate, t]);
return ( return (
<div className={cn("flex flex-col gap-0.5 landscape:gap-3", className)}> <div
<div className="flex items-center gap-3 landscape:flex-col landscape:items-start landscape:gap-4"> className={cn(
"flex flex-col gap-0.5",
isMobile && "landscape:gap-3",
className,
)}
>
<div
className={cn(
"flex items-center gap-3",
isMobile &&
"landscape:flex-col landscape:items-start landscape:gap-4",
)}
>
<div className="flex flex-row gap-2 text-sm"> <div className="flex flex-row gap-2 text-sm">
{t("trackingDetails.annotationSettings.offset.label")}: {t("trackingDetails.annotationSettings.offset.label")}:
<span className="text-primary-variant">{annotationOffset}</span> <span className="text-primary-variant">{annotationOffset}</span>
@ -93,7 +106,12 @@ export default function AnnotationOffsetSlider({ className }: Props) {
</Button> </Button>
</div> </div>
</div> </div>
<div className="flex items-center gap-2 text-xs text-muted-foreground landscape:flex-col landscape:items-start"> <div
className={cn(
"flex items-center gap-2 text-xs text-muted-foreground",
isMobile && "landscape:flex-col landscape:items-start",
)}
>
<Trans ns="views/explore"> <Trans ns="views/explore">
trackingDetails.annotationSettings.offset.millisecondsToOffset trackingDetails.annotationSettings.offset.millisecondsToOffset
</Trans> </Trans>