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
  3d6dffca_40cd_8f27_71d0_e341fb18af66["popover-demo.tsx"]
  aa2f3ec6_f291_3763_88ec_65a3f5ad5939["button"]
  3d6dffca_40cd_8f27_71d0_e341fb18af66 --> aa2f3ec6_f291_3763_88ec_65a3f5ad5939
  2de1d0e1_ab37_e1b0_4ef3_da8c8fa66107["input"]
  3d6dffca_40cd_8f27_71d0_e341fb18af66 --> 2de1d0e1_ab37_e1b0_4ef3_da8c8fa66107
  fa665cdb_5f79_b81a_95ab_12ba182fc175["label"]
  3d6dffca_40cd_8f27_71d0_e341fb18af66 --> fa665cdb_5f79_b81a_95ab_12ba182fc175
  e33b0d79_0534_28ec_a112_ac16ee736e09["popover"]
  3d6dffca_40cd_8f27_71d0_e341fb18af66 --> e33b0d79_0534_28ec_a112_ac16ee736e09
  style 3d6dffca_40cd_8f27_71d0_e341fb18af66 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

import { Button } from "@/registry/new-york/ui/button"
import { Input } from "@/registry/new-york/ui/input"
import { Label } from "@/registry/new-york/ui/label"
import {
  Popover,
  PopoverContent,
  PopoverTrigger,
} from "@/registry/new-york/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="font-medium leading-none">Dimensions</h4>
            <p className="text-sm text-muted-foreground">
              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 deprecated/www/registry/new-york/examples/popover-demo.tsx (domain: ComponentRegistry, subdomain: ChartRegistry, directory: deprecated/www/registry/new-york/examples).

Analyze Your Own Codebase

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

Try Supermodel Free