Home / File/ resizable-rtl.tsx — ui Source File

resizable-rtl.tsx — ui Source File

Architecture documentation for resizable-rtl.tsx, a tsx file in the ui codebase. 3 imports, 0 dependents.

File tsx DocumentationAtlas SearchAPI 3 imports 1 functions

Entity Profile

Dependency Diagram

graph LR
  cf6b4240_6509_cfd3_5802_2d1e9f67e0d8["resizable-rtl.tsx"]
  1d141819_425e_b5fd_4c8e_32f7c6a42cf2["react"]
  cf6b4240_6509_cfd3_5802_2d1e9f67e0d8 --> 1d141819_425e_b5fd_4c8e_32f7c6a42cf2
  384f8686_de36_1fbc_6451_6f75224f7922["resizable"]
  cf6b4240_6509_cfd3_5802_2d1e9f67e0d8 --> 384f8686_de36_1fbc_6451_6f75224f7922
  2c1404ab_bf28_6225_f9a0_b9e29400c66c["language-selector"]
  cf6b4240_6509_cfd3_5802_2d1e9f67e0d8 --> 2c1404ab_bf28_6225_f9a0_b9e29400c66c
  style cf6b4240_6509_cfd3_5802_2d1e9f67e0d8 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

"use client"

import * as React from "react"
import {
  ResizableHandle,
  ResizablePanel,
  ResizablePanelGroup,
} from "@/examples/radix/ui-rtl/resizable"

import {
  useTranslation,
  type Translations,
} from "@/components/language-selector"

const translations: Translations = {
  en: {
    dir: "ltr",
    values: {
      one: "One",
      two: "Two",
      three: "Three",
    },
  },
  ar: {
    dir: "rtl",
    values: {
      one: "واحد",
      two: "اثنان",
      three: "ثلاثة",
    },
  },
  he: {
    dir: "rtl",
    values: {
      one: "אחד",
      two: "שניים",
      three: "שלושה",
    },
  },
}

export function ResizableRtl() {
  const { dir, t } = useTranslation(translations, "ar")

  return (
    <ResizablePanelGroup
      orientation="horizontal"
      className="max-w-sm rounded-lg border"
      dir={dir}
    >
      <ResizablePanel defaultSize="50%">
        <div className="flex h-[200px] items-center justify-center p-6">
          <span className="font-semibold">{t.one}</span>
        </div>
      </ResizablePanel>
      <ResizableHandle withHandle />
      <ResizablePanel defaultSize="50%">
        <ResizablePanelGroup orientation="vertical" dir={dir}>
          <ResizablePanel defaultSize="25%">
            <div className="flex h-full items-center justify-center p-6">
              <span className="font-semibold">{t.two}</span>
            </div>
          </ResizablePanel>
          <ResizableHandle withHandle />
          <ResizablePanel defaultSize="75%">
            <div className="flex h-full items-center justify-center p-6">
              <span className="font-semibold">{t.three}</span>
            </div>
          </ResizablePanel>
        </ResizablePanelGroup>
      </ResizablePanel>
    </ResizablePanelGroup>
  )
}

Subdomains

Functions

Dependencies

  • language-selector
  • react
  • resizable

Frequently Asked Questions

What does resizable-rtl.tsx do?
resizable-rtl.tsx is a source file in the ui codebase, written in tsx. It belongs to the DocumentationAtlas domain, SearchAPI subdomain.
What functions are defined in resizable-rtl.tsx?
resizable-rtl.tsx defines 1 function(s): ResizableRtl.
What does resizable-rtl.tsx depend on?
resizable-rtl.tsx imports 3 module(s): language-selector, react, resizable.
Where is resizable-rtl.tsx in the architecture?
resizable-rtl.tsx is located at apps/v4/examples/radix/resizable-rtl.tsx (domain: DocumentationAtlas, subdomain: SearchAPI, directory: apps/v4/examples/radix).

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free