From 01116180d1bc24470e9aa2fa24752ce8bb04551c Mon Sep 17 00:00:00 2001 From: yumoqing Date: Thu, 2 Jul 2026 22:13:26 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20compile=20errors=20=E2=80=94=20frame=20A?= =?UTF-8?q?PI=20+=20sheet=20binding=20for=20let=20hlsRecorder?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Sources/MiniPlayerApp.swift | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/Sources/MiniPlayerApp.swift b/Sources/MiniPlayerApp.swift index 3e26e0e..8700f85 100644 --- a/Sources/MiniPlayerApp.swift +++ b/Sources/MiniPlayerApp.swift @@ -583,9 +583,14 @@ struct BricksAppView: View { bridge.showToastMsg(error.localizedDescription) } } - .sheet(item: $bridge.hlsRecorder.pendingExportURL) { url in - ActivityShareSheet(url: url) { - bridge.hlsRecorder.pendingExportURL = nil + .sheet(isPresented: Binding( + get: { bridge.hlsRecorder.pendingExportURL != nil }, + set: { if !$0 { bridge.hlsRecorder.pendingExportURL = nil } } + )) { + if let url = bridge.hlsRecorder.pendingExportURL { + ActivityShareSheet(url: url) { + bridge.hlsRecorder.pendingExportURL = nil + } } } #endif @@ -707,7 +712,7 @@ struct ControlToolbar: View { Text(bridge.currentTrackLabel) .font(.system(size: 11, design: .monospaced)) .foregroundColor(.white) - .frame(minWidth: 50, height: 28) + .frame(height: 28) .padding(.horizontal, 4) .background(Color.white.opacity(0.15)) .cornerRadius(4)