'use client' import { useState } from 'react' import { Button } from '@/components/ui/button' import { DestructiveConfirmDialog } from '@/components/ui/destructive-confirm-dialog' import { Lock, Loader2 } from 'lucide-react' interface ExecuteStepProps { periodName: string isRunning: boolean error: string | null /** Advisory: AB closing a profit year with no bolagsskatt booked. */ bolagsskattMissing?: boolean onBack: () => void onExecute: () => Promise } /** * Final confirmation before executing year-end. Uses the destructive confirm * dialog because year-end is irreversible per BFL: once the period is closed, * no further entries can be posted to it and the closing transaction is * immutable. */ export function ExecuteStep({ periodName, isRunning, error, bolagsskattMissing, onBack, onExecute }: ExecuteStepProps) { const [confirmOpen, setConfirmOpen] = useState(false) return (
) }