Home / File/ popover-demo.tsx — ui Source File

popover-demo.tsx — ui Source File

Architecture documentation for popover-demo.tsx, a tsx file in the ui codebase. 4 imports, 0 dependents.

File tsx ComponentRegistry ChartRegistry 4 imports 1 functions

Entity Profile

Dependency Diagram

graph LR
  dfef7cbf_7725_e3b8_ddc5_5549f0029612["popover-demo.tsx"]
  57e86e45_ac6e_7278_be08_9092724e8401["button"]
  dfef7cbf_7725_e3b8_ddc5_5549f0029612 --> 57e86e45_ac6e_7278_be08_9092724e8401
  80cf663d_a411_487c_d69e_ac9d405cd2ec["input"]
  dfef7cbf_7725_e3b8_ddc5_5549f0029612 --> 80cf663d_a411_487c_d69e_ac9d405cd2ec
  d752035b_6ed3_c6ef_e27c_eef51af9ec8d["label"]
  dfef7cbf_7725_e3b8_ddc5_5549f0029612 --> d752035b_6ed3_c6ef_e27c_eef51af9ec8d
  64a3481c_a85b_fe79_409a_cb7f3f4bb871["popover"]
  dfef7cbf_7725_e3b8_ddc5_5549f0029612 --> 64a3481c_a85b_fe79_409a_cb7f3f4bb871
  style dfef7cbf_7725_e3b8_ddc5_5549f0029612 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

import { Button } from "@/registry/new-york-v4/ui/button"
import { Input } from "@/registry/new-york-v4/ui/input"
import { Label } from "@/registry/new-york-v4/ui/label"
import {
  Popover,
  PopoverContent,
  PopoverTrigger,
} from "@/registry/new-york-v4/ui/popover"

export default function PopoverDemo() {
  return (
    <Popover>
      <PopoverTrigger asChild>
        <Button variant="outline">Open popover</Button>
      </PopoverTrigger>
      <PopoverContent className="w-80">
        <div className="grid gap-4">
          <div className="space-y-2">
            <h4 className="leading-none font-medium">Dimensions</h4>
            <p className="text-muted-foreground text-sm">
              Set the dimensions for the layer.
            </p>
          </div>
          <div className="grid gap-2">
            <div className="grid grid-cols-3 items-center gap-4">
              <Label htmlFor="width">Width</Label>
              <Input
                id="width"
                defaultValue="100%"
                className="col-span-2 h-8"
              />
            </div>
            <div className="grid grid-cols-3 items-center gap-4">
              <Label htmlFor="maxWidth">Max. width</Label>
              <Input
                id="maxWidth"
                defaultValue="300px"
                className="col-span-2 h-8"
              />
            </div>
            <div className="grid grid-cols-3 items-center gap-4">
              <Label htmlFor="height">Height</Label>
              <Input
                id="height"
                defaultValue="25px"
                className="col-span-2 h-8"
              />
            </div>
            <div className="grid grid-cols-3 items-center gap-4">
              <Label htmlFor="maxHeight">Max. height</Label>
              <Input
                id="maxHeight"
                defaultValue="none"
                className="col-span-2 h-8"
              />
            </div>
          </div>
        </div>
      </PopoverContent>
    </Popover>
  )
}

Subdomains

Functions

Dependencies

  • button
  • input
  • label
  • popover

Frequently Asked Questions

What does popover-demo.tsx do?
popover-demo.tsx is a source file in the ui codebase, written in tsx. It belongs to the ComponentRegistry domain, ChartRegistry subdomain.
What functions are defined in popover-demo.tsx?
popover-demo.tsx defines 1 function(s): PopoverDemo.
What does popover-demo.tsx depend on?
popover-demo.tsx imports 4 module(s): button, input, label, popover.
Where is popover-demo.tsx in the architecture?
popover-demo.tsx is located at apps/v4/registry/new-york-v4/examples/popover-demo.tsx (domain: ComponentRegistry, subdomain: ChartRegistry, directory: apps/v4/registry/new-york-v4/examples).

Analyze Your Own Codebase

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

Try Supermodel Free