From d260c81d58cb9847a53be3fb05df3165eb74e186 Mon Sep 17 00:00:00 2001 From: 50/50 <80717571+50n50@users.noreply.github.com> Date: Sun, 1 Jun 2025 22:47:35 +0200 Subject: [PATCH] More UI enhancements (#148) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Minor changes * more minor changes * MORE MINOR CHANGES * Fixed one singular bug * Update SettingsViewGeneral.swift * fuck conflicts * fuck you and your credits * buh buh * Update SettingsViewAbout.swift * What's that? What's a properly working code without unnecessary issues? * Type shit maybe? * Create ios.yml * smol * type shi shi * end * Fixed system theme bug * (hopefully) fixed sliding items in search + recent searches spam * Fixed open keyboard in media view * Fixed searchviewdata + fixed toggle color being too light * fixed episode slider sensitivity * new recent searches, not fully done but wtv WHO CARES 💯 * Add module screen fix * Delete .github/workflows/ios.yml * UI modifications * Scroll to close keyboard * Text change * Downloadview transition * Search cards text fixed * Reduced header spacing + moved down a to match library * Text change * Small tab bar tweak for search view * added gradient to player buttons * reduced summary size * IBH special 💯 * Fixed different height text? * Removed seperator * Some more fixes start watching button * MediaInfoView modifications * Fixed settingsviewdata * Changed x mark and fixed episode swipe for 4 items * Delete Package.resolved * fix * fix * Update Package.resolved * Removed version lalel type shi * Who thought this view existed? 😭 * Less wide tab bar * Actions button for movies + resetting watch progress * Disabled switching back from search to other views for 0.5 seconds (no other fix available rn) * Added divider (IBH) * Hide tab bar in module lib * Update SettingsViewAbout.swift * Decreased xmark size and increased search bar clear button size * Disabled bounce scroll, make date more visible, added swipe to go back --------- Co-authored-by: cranci <100066266+cranci1@users.noreply.github.com> --- Sora/Utils/TabBar/TabBar.swift | 6 +++--- Sora/Views/MediaInfoView/MediaInfoView.swift | 16 +++++++++++----- 2 files changed, 14 insertions(+), 8 deletions(-) diff --git a/Sora/Utils/TabBar/TabBar.swift b/Sora/Utils/TabBar/TabBar.swift index 0124083..a646e58 100644 --- a/Sora/Utils/TabBar/TabBar.swift +++ b/Sora/Utils/TabBar/TabBar.swift @@ -77,9 +77,9 @@ struct TabBar: View { } }) { Image(systemName: "xmark") - .font(.system(size: 30)) + .font(.system(size: 20)) .foregroundStyle(.gray) - .frame(width: 24, height: 24) + .frame(width: 20, height: 20) .matchedGeometryEffect(id: "xmark", in: animation) .padding(16) .background( @@ -133,7 +133,7 @@ struct TabBar: View { searchQuery = "" }) { Image(systemName: "xmark.circle.fill") - .font(.footnote) + .font(.system(size: 16)) .foregroundStyle(.gray) .opacity(0.7) } diff --git a/Sora/Views/MediaInfoView/MediaInfoView.swift b/Sora/Views/MediaInfoView/MediaInfoView.swift index 7269dfe..e159a6c 100644 --- a/Sora/Views/MediaInfoView/MediaInfoView.swift +++ b/Sora/Views/MediaInfoView/MediaInfoView.swift @@ -171,6 +171,13 @@ struct MediaInfoView: View { AnalyticsManager.shared.sendEvent(event: "search", additionalData: ["title": title]) } tabBarController.hideTabBar() + + if let windowScene = UIApplication.shared.connectedScenes.first as? UIWindowScene, + let window = windowScene.windows.first, + let navigationController = window.rootViewController?.children.first as? UINavigationController { + navigationController.interactivePopGestureRecognizer?.isEnabled = true + navigationController.interactivePopGestureRecognizer?.delegate = nil + } } .onDisappear(){ tabBarController.showTabBar() @@ -287,11 +294,11 @@ struct MediaInfoView: View { if !airdate.isEmpty && airdate != "N/A" && airdate != "No Data" { HStack(spacing: 4) { Image(systemName: "calendar") - .foregroundColor(.secondary) + .foregroundColor(.accentColor) Text(airdate) .font(.system(size: 14)) - .foregroundColor(.secondary) + .foregroundColor(.accentColor) } } @@ -363,9 +370,9 @@ struct MediaInfoView: View { let lastPlayedTime = UserDefaults.standard.double(forKey: "lastPlayedTime_\(ep.href)") let totalTime = UserDefaults.standard.double(forKey: "totalTime_\(ep.href)") let progress = totalTime > 0 ? lastPlayedTime / totalTime : 0 - return progress <= 0.9 ? "Mark as watched" : "Reset progress" + return progress <= 0.9 ? "Mark watched" : "Reset progress" } - return "Mark as watched" + return "Mark watched" }()) .font(.system(size: 14, weight: .medium)) .foregroundColor(.primary) @@ -419,7 +426,6 @@ struct MediaInfoView: View { .fixedSize(horizontal: false, vertical: true) .frame(maxWidth: .infinity, alignment: .leading) .padding(.top, 4) - .padding(.leading, 2.8) Text("The module provided only a single episode, this is most likely a movie, so we decided to make separate screens for these cases.") .font(.caption) .foregroundColor(.gray)