snapshot of https://github.com/shadcn-ui/ui.git (main, 2026-09-15; blobs > 131072B omitted)
This commit is contained in:
42
apps/v4/registry/new-york-v4/examples/item-link.tsx
Normal file
42
apps/v4/registry/new-york-v4/examples/item-link.tsx
Normal file
@@ -0,0 +1,42 @@
|
||||
import { ChevronRightIcon, ExternalLinkIcon } from "lucide-react"
|
||||
|
||||
import {
|
||||
Item,
|
||||
ItemActions,
|
||||
ItemContent,
|
||||
ItemDescription,
|
||||
ItemTitle,
|
||||
} from "@/registry/new-york-v4/ui/item"
|
||||
|
||||
export default function ItemLink() {
|
||||
return (
|
||||
<div className="flex w-full max-w-md flex-col gap-4">
|
||||
<Item asChild>
|
||||
<a href="#">
|
||||
<ItemContent>
|
||||
<ItemTitle>Visit our documentation</ItemTitle>
|
||||
<ItemDescription>
|
||||
Learn how to get started with our components.
|
||||
</ItemDescription>
|
||||
</ItemContent>
|
||||
<ItemActions>
|
||||
<ChevronRightIcon className="size-4" />
|
||||
</ItemActions>
|
||||
</a>
|
||||
</Item>
|
||||
<Item variant="outline" asChild>
|
||||
<a href="#" target="_blank" rel="noopener noreferrer">
|
||||
<ItemContent>
|
||||
<ItemTitle>External resource</ItemTitle>
|
||||
<ItemDescription>
|
||||
Opens in a new tab with security attributes.
|
||||
</ItemDescription>
|
||||
</ItemContent>
|
||||
<ItemActions>
|
||||
<ExternalLinkIcon className="size-4" />
|
||||
</ItemActions>
|
||||
</a>
|
||||
</Item>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
Reference in New Issue
Block a user