Track HiveGrid Cloud planning reference

This commit is contained in:
david committed 2026-06-26 20:48:01 +02:00
1 parent b3d5ea6764
commit e341c5938a
5784 files changed
+1104929 -3

No files matched your search

@@ -0,0 +1,44 @@
/* This example requires Tailwind CSS v2.0+ */
import { Fragment, ReactNode } from "react";
import { Popover, Transition } from "@headlessui/react";
import ChevronDownIcon from "../icons/ChevronDownIcon";
import { Button } from "../button";
interface Props {
title: string;
className?: string;
disabled?: boolean;
children: ReactNode;
}
export default function ButtonFlyout({ title, className, disabled, children }: Props) {
return (
<Popover className="relative">
{() => (
<>
<Popover.Button as={Button} type="button" variant="outline" disabled={disabled} className={className}>
<span className="inline-flex items-center space-x-2">
<span>{title}</span>
<ChevronDownIcon className="h-5 w-5 text-muted-foreground" />
</span>
</Popover.Button>
<Transition
as={Fragment}
enter="transition ease-out duration-200"
enterFrom="opacity-0 translate-y-1"
enterTo="opacity-100 translate-y-0"
leave="transition ease-in duration-150"
leaveFrom="opacity-100 translate-y-0"
leaveTo="opacity-0 translate-y-1"
>
<Popover.Panel className="absolute left-1/2 z-10 mt-3 w-screen max-w-xs -translate-x-1/2 transform px-2 sm:px-0">
<div className="overflow-hidden rounded-lg shadow-lg ring-1 ring-black ring-opacity-5">
<div className="bg-background relative grid gap-6 px-5 py-6 sm:gap-8 sm:p-8">{children}</div>
</div>
</Popover.Panel>
</Transition>
</>
)}
</Popover>
);
}