mirror of
https://github.com/hex248/ob248.com.git
synced 2026-02-09 11:13:03 +00:00
TravelListItem
This commit is contained in:
25
src/components/TravelListItem.tsx
Normal file
25
src/components/TravelListItem.tsx
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
import type { TravelMetadata } from "@/travel";
|
||||||
|
import { Button } from "./ui/button";
|
||||||
|
import type { MouseEventHandler } from "react";
|
||||||
|
import { cn } from "@/lib/utils";
|
||||||
|
|
||||||
|
export function TravelListItem({
|
||||||
|
metadata,
|
||||||
|
onClick,
|
||||||
|
}: {
|
||||||
|
metadata: TravelMetadata;
|
||||||
|
onClick: MouseEventHandler<HTMLButtonElement>;
|
||||||
|
}) {
|
||||||
|
return (
|
||||||
|
<Button
|
||||||
|
className={cn(
|
||||||
|
"text-sm border cursor-pointer hover:border-accent justify-start",
|
||||||
|
)}
|
||||||
|
onClick={onClick}
|
||||||
|
variant="dummy"
|
||||||
|
size="sm"
|
||||||
|
>
|
||||||
|
{metadata.city}, {metadata.country} - {metadata.date}
|
||||||
|
</Button>
|
||||||
|
);
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user