'use client'; import * as React from 'react'; import { X, Download } from 'lucide-react'; import { Button } from '@/components/ui/Button'; import { cn } from '@/lib/utils/cn'; export interface ExportSettings { format: 'wav'; bitDepth: 16 | 24 | 32; normalize: boolean; filename: string; } export interface ExportDialogProps { open: boolean; onClose: () => void; onExport: (settings: ExportSettings) => void; isExporting?: boolean; } export function ExportDialog({ open, onClose, onExport, isExporting }: ExportDialogProps) { const [settings, setSettings] = React.useState({ format: 'wav', bitDepth: 16, normalize: true, filename: 'mix', }); const handleExport = () => { onExport(settings); }; if (!open) return null; return (
{/* Header */}

Export Audio

{/* Settings */}
{/* Filename */}
setSettings({ ...settings, filename: e.target.value })} className="w-full px-3 py-2 bg-background border border-border rounded text-foreground focus:outline-none focus:ring-2 focus:ring-primary" disabled={isExporting} />

.wav will be added automatically

{/* Format */}
{/* Bit Depth */}
{[16, 24, 32].map((depth) => ( ))}
{/* Normalize */}

Prevents clipping by adjusting peak levels

{/* Actions */}
); }