fix: prevent duplicate uploads and group asset commits
This commit is contained in:
@@ -35,6 +35,7 @@ interface ModalActionsProps {
|
||||
onConfirm: () => void
|
||||
/** Tailwind classes for the confirm button (default: white bg) */
|
||||
confirmClassName?: string
|
||||
disabled?: boolean
|
||||
}
|
||||
|
||||
export function ModalActions({
|
||||
@@ -43,20 +44,23 @@ export function ModalActions({
|
||||
onCancel,
|
||||
onConfirm,
|
||||
confirmClassName = 'bg-white text-[#000000] hover:bg-gray-200',
|
||||
disabled = false,
|
||||
}: ModalActionsProps) {
|
||||
return (
|
||||
<div className="flex gap-3">
|
||||
<button
|
||||
onClick={onCancel}
|
||||
disabled={disabled}
|
||||
className="flex-1 bg-black-700 text-gray-300 font-medium text-sm
|
||||
py-2.5 px-4 rounded-xl border border-white/10 transition-colors duration-150
|
||||
py-2.5 px-4 rounded-xl border border-white/10 transition-colors duration-150 disabled:opacity-50 disabled:cursor-not-allowed
|
||||
hover:bg-black-600"
|
||||
>
|
||||
{cancelLabel}
|
||||
</button>
|
||||
<button
|
||||
onClick={onConfirm}
|
||||
className={`flex-1 font-medium text-sm py-2.5 px-4 rounded-xl transition-colors duration-150 ${confirmClassName}`}
|
||||
disabled={disabled}
|
||||
className={`flex-1 font-medium text-sm py-2.5 px-4 rounded-xl transition-colors duration-150 disabled:opacity-50 disabled:cursor-not-allowed ${confirmClassName}`}
|
||||
>
|
||||
{confirmLabel}
|
||||
</button>
|
||||
|
||||
Reference in New Issue
Block a user