Home / File/ layout.tsx — ui Source File

layout.tsx — ui Source File

Architecture documentation for layout.tsx, a tsx file in the ui codebase. 5 imports, 0 dependents.

File tsx ComponentRegistry Styles 5 imports 1 functions

Entity Profile

Dependency Diagram

graph LR
  2dbbc828_90a0_ad20_8b3c_942d74931976["layout.tsx"]
  9c1a1e1b_87f8_29d5_c12d_e83869cf94e4["next"]
  2dbbc828_90a0_ad20_8b3c_942d74931976 --> 9c1a1e1b_87f8_29d5_c12d_e83869cf94e4
  ee1bd2ee_dc29_449d_093b_3c77e83b3561["announcement"]
  2dbbc828_90a0_ad20_8b3c_942d74931976 --> ee1bd2ee_dc29_449d_093b_3c77e83b3561
  92027577_46c9_9cf9_86f6_c32f42e44e04["page-header"]
  2dbbc828_90a0_ad20_8b3c_942d74931976 --> 92027577_46c9_9cf9_86f6_c32f42e44e04
  89c91d90_5c60_9064_52c7_ec3cfe60a73b["theme-customizer"]
  2dbbc828_90a0_ad20_8b3c_942d74931976 --> 89c91d90_5c60_9064_52c7_ec3cfe60a73b
  aa2f3ec6_f291_3763_88ec_65a3f5ad5939["button"]
  2dbbc828_90a0_ad20_8b3c_942d74931976 --> aa2f3ec6_f291_3763_88ec_65a3f5ad5939
  style 2dbbc828_90a0_ad20_8b3c_942d74931976 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

import { Metadata } from "next"

import { Announcement } from "@/components/announcement"
import {
  PageActions,
  PageHeader,
  PageHeaderDescription,
  PageHeaderHeading,
} from "@/components/page-header"
import { Customizer } from "@/components/theme-customizer"
import { Button } from "@/registry/new-york/ui/button"

const title = "Add colors. Make it yours."
const description =
  "Hand-picked themes that you can copy and paste into your apps."

export const metadata: Metadata = {
  title,
  description,
  openGraph: {
    images: [
      {
        url: `/og?title=${encodeURIComponent(
          title
        )}&description=${encodeURIComponent(description)}`,
      },
    ],
  },
  twitter: {
    card: "summary_large_image",
    images: [
      {
        url: `/og?title=${encodeURIComponent(
          title
        )}&description=${encodeURIComponent(description)}`,
      },
    ],
  },
}

export default function ThemesLayout({
  children,
}: {
  children: React.ReactNode
}) {
  return (
    <>
      <PageHeader>
        <Announcement />
        <PageHeaderHeading>{title}</PageHeaderHeading>
        <PageHeaderDescription>{description}</PageHeaderDescription>
        <div className="mt-2 rounded-full bg-blue-600 px-3 py-1 text-xs text-white">
          New Theme Editor coming soon
        </div>
      </PageHeader>
      <div id="themes" className="border-grid scroll-mt-24 border-b">
        <div className="container-wrapper">
          <div className="container flex items-center py-4">
            <Customizer />
          </div>
        </div>
      </div>
      <div className="container-wrapper">
        <div className="container py-6">
          <section id="themes" className="scroll-mt-20">
            {children}
          </section>
        </div>
      </div>
    </>
  )
}

Subdomains

Functions

Dependencies

  • announcement
  • button
  • next
  • page-header
  • theme-customizer

Frequently Asked Questions

What does layout.tsx do?
layout.tsx is a source file in the ui codebase, written in tsx. It belongs to the ComponentRegistry domain, Styles subdomain.
What functions are defined in layout.tsx?
layout.tsx defines 1 function(s): ThemesLayout.
What does layout.tsx depend on?
layout.tsx imports 5 module(s): announcement, button, next, page-header, theme-customizer.
Where is layout.tsx in the architecture?
layout.tsx is located at deprecated/www/app/(app)/themes/layout.tsx (domain: ComponentRegistry, subdomain: Styles, directory: deprecated/www/app/(app)/themes).

Analyze Your Own Codebase

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

Try Supermodel Free