Fix TypeScript typecheck errors
Some checks failed
linter / quality (push) Has been cancelled
tests / ci (push) Has been cancelled
tests / ui (push) Has been cancelled

This commit is contained in:
Codex Agent
2026-01-30 15:56:06 +01:00
parent 916b204688
commit b1f9f7cee0
42 changed files with 324 additions and 72 deletions

View File

@@ -98,7 +98,7 @@ export function CTAButton({
iconRight,
}: {
label: string;
onPress: () => void;
onPress?: () => void;
tone?: 'primary' | 'ghost' | 'danger';
fullWidth?: boolean;
disabled?: boolean;
@@ -110,7 +110,7 @@ export function CTAButton({
const { primary, surface, border, text, danger, glassSurfaceStrong } = useAdminTheme();
const isPrimary = tone === 'primary';
const isDanger = tone === 'danger';
const isDisabled = disabled || loading;
const isDisabled = disabled || loading || !onPress;
const backgroundColor = isDanger ? danger : isPrimary ? primary : glassSurfaceStrong ?? surface;
const borderColor = isPrimary || isDanger ? 'transparent' : border;
const labelColor = isPrimary || isDanger ? 'white' : text;