"use client" import { useTranslation, type Translations, } from "@/components/language-selector" import { Button } from "@/styles/base-nova/ui-rtl/button" import { Popover, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, } from "@/styles/base-nova/ui-rtl/popover" const translations: Translations = { en: { dir: "ltr", values: { title: "Dimensions", description: "Set the dimensions for the layer.", "inline-start": "Inline Start", left: "Left", top: "Top", bottom: "Bottom", right: "Right", "inline-end": "Inline End", }, }, ar: { dir: "rtl", values: { title: "الأبعاد", description: "تعيين الأبعاد للطبقة.", "inline-start": "بداية السطر", left: "يسار", top: "أعلى", bottom: "أسفل", right: "يمين", "inline-end": "نهاية السطر", }, }, he: { dir: "rtl", values: { title: "מימדים", description: "הגדר את המימדים לשכבה.", "inline-start": "תחילת השורה", left: "שמאל", top: "למעלה", bottom: "למטה", right: "ימין", "inline-end": "סוף השורה", }, }, } const physicalSides = ["left", "top", "bottom", "right"] as const const logicalSides = ["inline-start", "inline-end"] as const export function PopoverRtl() { const { dir, t } = useTranslation(translations, "ar") return (
{physicalSides.map((side) => ( }> {t[side]} {t.title} {t.description} ))}
{logicalSides.map((side) => ( }> {t[side]} {t.title} {t.description} ))}
) }