mirror of
https://github.com/fsolla/teqo.git
synced 2026-11-15 10:43:07 +00:00
Remove o bottom drawer não-modal (snap/peek/scroll-coupling) e introduz um FAB em todas as larguras fora do Início e wizards. Abrir o FAB mostra overlay modal: Dialog no desktop (busca em cima) e Drawer no mobile (ações em cima), reutilizando strip e busca globais do Início. Closes #260 Co-authored-by: Francisco Solla <fsolla@users.noreply.github.com>
38 lines
822 B
TypeScript
38 lines
822 B
TypeScript
'use client'
|
|
|
|
import { Zap } from 'lucide-react'
|
|
|
|
import { Button } from '@/components/ui/button'
|
|
import { cn } from '@/lib/utils'
|
|
|
|
export const CampaignQuickActionsFab = ({
|
|
open,
|
|
onOpenChange,
|
|
className,
|
|
}: {
|
|
open: boolean
|
|
onOpenChange: (open: boolean) => void
|
|
className?: string
|
|
}) => {
|
|
if (open) return null
|
|
|
|
return (
|
|
<div
|
|
className={cn(
|
|
'pointer-events-none fixed bottom-4 right-4 z-40 print:hidden',
|
|
'pb-[max(0px,env(safe-area-inset-bottom))]',
|
|
className,
|
|
)}
|
|
>
|
|
<Button
|
|
type="button"
|
|
size="icon"
|
|
className="pointer-events-auto size-12 rounded-full shadow-lg"
|
|
aria-label="Ações rápidas"
|
|
onClick={() => onOpenChange(true)}
|
|
>
|
|
<Zap className="size-5" aria-hidden />
|
|
</Button>
|
|
</div>
|
|
)
|
|
}
|