import { ArrowUpIcon, CoinsIcon, LoaderCircleIcon } from "lucide-react"; import { DynamicIcon } from "@storyteller/icons"; import { ButtonHTMLAttributes } from "react"; import { twMerge } from "tailwind-merge"; import { Tooltip } from "@storyteller/ui-tooltip"; interface GenerateIconButtonProps extends Omit< ButtonHTMLAttributes, "children" > { credits?: number | null; loading?: boolean; } /** * Compact generate control: credit cost as plain text next to a circular * arrow-up button. Desktop promptboxes use this; the mobile form keeps the * labeled `GenerateButton` pill. */ export const GenerateIconButton = ({ credits, loading, className, disabled, ...rest }: GenerateIconButtonProps) => { const isDisabled = disabled || loading; return (
{credits != null && ( {credits} )}
); }; export default GenerateIconButton;