Home / File/ spinner-empty.tsx — ui Source File

spinner-empty.tsx — ui Source File

Architecture documentation for spinner-empty.tsx, a tsx file in the ui codebase. 4 imports, 1 dependents.

File tsx Internationalization Dictionary 4 imports 1 dependents 1 functions

Entity Profile

Dependency Diagram

graph LR
  20b17ba4_a066_67db_7876_8ae83b9109ff["spinner-empty.tsx"]
  43bb9fc1_6eab_13df_a99b_981eb13b9ec1["button"]
  20b17ba4_a066_67db_7876_8ae83b9109ff --> 43bb9fc1_6eab_13df_a99b_981eb13b9ec1
  49420061_5812_6802_3c39_964bf3930555["empty"]
  20b17ba4_a066_67db_7876_8ae83b9109ff --> 49420061_5812_6802_3c39_964bf3930555
  883da1ad_449f_ee4a_3133_4f4e76e38d95["spinner"]
  20b17ba4_a066_67db_7876_8ae83b9109ff --> 883da1ad_449f_ee4a_3133_4f4e76e38d95
  2c1404ab_bf28_6225_f9a0_b9e29400c66c["language-selector"]
  20b17ba4_a066_67db_7876_8ae83b9109ff --> 2c1404ab_bf28_6225_f9a0_b9e29400c66c
  a20493d4_39f4_bced_97b9_027078a02a91["index.tsx"]
  a20493d4_39f4_bced_97b9_027078a02a91 --> 20b17ba4_a066_67db_7876_8ae83b9109ff
  style 20b17ba4_a066_67db_7876_8ae83b9109ff fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

"use client"

import { Button } from "@/examples/base/ui-rtl/button"
import {
  Empty,
  EmptyContent,
  EmptyDescription,
  EmptyHeader,
  EmptyMedia,
  EmptyTitle,
} from "@/examples/base/ui-rtl/empty"
import { Spinner } from "@/examples/base/ui-rtl/spinner"

import { useLanguageContext } from "@/components/language-selector"

const translations = {
  ar: {
    dir: "rtl" as const,
    title: "جارٍ معالجة طلبك",
    description: "يرجى الانتظار بينما نعالج طلبك. لا تقم بتحديث الصفحة.",
    cancel: "إلغاء",
  },
  he: {
    dir: "rtl" as const,
    title: "מעבד את הבקשה שלך",
    description: "אנא המתן בזמן שאנו מעבדים את בקשתך. אל תרענן את הדף.",
    cancel: "ביטול",
  },
}

export function SpinnerEmpty() {
  const context = useLanguageContext()
  const lang = context?.language === "he" ? "he" : "ar"
  const t = translations[lang]

  return (
    <Empty className="w-full border md:p-6" dir={t.dir}>
      <EmptyHeader>
        <EmptyMedia variant="icon">
          <Spinner />
        </EmptyMedia>
        <EmptyTitle>{t.title}</EmptyTitle>
        <EmptyDescription>{t.description}</EmptyDescription>
      </EmptyHeader>
      <EmptyContent>
        <Button variant="outline" size="sm">
          {t.cancel}
        </Button>
      </EmptyContent>
    </Empty>
  )
}

Subdomains

Functions

Dependencies

  • button
  • empty
  • language-selector
  • spinner

Frequently Asked Questions

What does spinner-empty.tsx do?
spinner-empty.tsx is a source file in the ui codebase, written in tsx. It belongs to the Internationalization domain, Dictionary subdomain.
What functions are defined in spinner-empty.tsx?
spinner-empty.tsx defines 1 function(s): SpinnerEmpty.
What does spinner-empty.tsx depend on?
spinner-empty.tsx imports 4 module(s): button, empty, language-selector, spinner.
What files import spinner-empty.tsx?
spinner-empty.tsx is imported by 1 file(s): index.tsx.
Where is spinner-empty.tsx in the architecture?
spinner-empty.tsx is located at apps/v4/app/(app)/examples/rtl/components/spinner-empty.tsx (domain: Internationalization, subdomain: Dictionary, directory: apps/v4/app/(app)/examples/rtl/components).

Analyze Your Own Codebase

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

Try Supermodel Free