From 009c8153d839190d8c4a3a0f4fdd082dff89c2cc Mon Sep 17 00:00:00 2001 From: Fansen Date: Sun, 14 Jun 2026 21:51:07 +0800 Subject: [PATCH] fix: remove duplicate Text content Group in compactView overlay The compactView in OverlayView contained two identical Text content Group blocks, causing all overlay text (transcription results, preview, errors, update notifications) to render twice. Closes #50 --- Sources/Typeno/main.swift | 33 --------------------------------- 1 file changed, 33 deletions(-) diff --git a/Sources/Typeno/main.swift b/Sources/Typeno/main.swift index b1c414f..3c34d1d 100644 --- a/Sources/Typeno/main.swift +++ b/Sources/Typeno/main.swift @@ -2385,39 +2385,6 @@ struct OverlayView: View { .controlSize(.mini) } - // Text content - Group { - if case .done(let text) = appState.phase { - Text(text) - .foregroundStyle(.white) - .lineLimit(1) - .truncationMode(.head) - } else if case .recording = appState.phase { - if appState.previewTranscript.isEmpty { - Text(L("Listening...", "聆听中...")) - .foregroundStyle(.white.opacity(0.35)) - .lineLimit(1) - .truncationMode(.head) - } else { - Text(appState.previewTranscript) - .foregroundStyle(.white.opacity(0.9)) - .lineLimit(1) - .truncationMode(.head) - } - } else if case .error = appState.phase { - Text(appState.phase.subtitle) - .foregroundStyle(.red.opacity(0.9)) - .font(.system(size: 12)) - .lineLimit(8) - .fixedSize(horizontal: false, vertical: true) - } else { - Text(appState.phase.subtitle) - .foregroundStyle(.white.opacity(0.7)) - .lineLimit(1) - .truncationMode(.head) - } - } - // Text content Group { if case .done(let text) = appState.phase {