fixed little thigngs i guess?
Some checks are pending
Build and Release IPA / Build IPA and Mac Catalyst (push) Waiting to run

This commit is contained in:
cranci1 2024-12-30 11:21:58 +01:00
parent 3420c3165b
commit 2e528fcfa5
7 changed files with 28 additions and 17 deletions

View file

@ -39,7 +39,7 @@
132417D72D13242400B4F2D2 /* CircularProgressBar.swift in Sources */ = {isa = PBXBuildFile; fileRef = 132417D62D13242400B4F2D2 /* CircularProgressBar.swift */; };
132417D92D1328B900B4F2D2 /* VideoPlayerView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 132417D82D1328B900B4F2D2 /* VideoPlayerView.swift */; };
1352BA712D1ABC30000A9AF9 /* URLSession.swift in Sources */ = {isa = PBXBuildFile; fileRef = 1352BA702D1ABC30000A9AF9 /* URLSession.swift */; };
13B3A4B22D1477F100BCC0D5 /* StorageSettingsView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 13B3A4B12D1477F100BCC0D5 /* StorageSettingsView.swift */; };
13B3A4B22D1477F100BCC0D5 /* SettingsStorageView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 13B3A4B12D1477F100BCC0D5 /* SettingsStorageView.swift */; };
13C9821F2D2152B1007A0132 /* GitHubRelease.swift in Sources */ = {isa = PBXBuildFile; fileRef = 13C9821E2D2152B1007A0132 /* GitHubRelease.swift */; };
/* End PBXBuildFile section */
@ -77,7 +77,7 @@
132417D82D1328B900B4F2D2 /* VideoPlayerView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = VideoPlayerView.swift; sourceTree = "<group>"; };
1352BA6F2D1AB113000A9AF9 /* Sora.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = Sora.entitlements; sourceTree = "<group>"; };
1352BA702D1ABC30000A9AF9 /* URLSession.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = URLSession.swift; sourceTree = "<group>"; };
13B3A4B12D1477F100BCC0D5 /* StorageSettingsView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StorageSettingsView.swift; sourceTree = "<group>"; };
13B3A4B12D1477F100BCC0D5 /* SettingsStorageView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SettingsStorageView.swift; sourceTree = "<group>"; };
13C9821E2D2152B1007A0132 /* GitHubRelease.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GitHubRelease.swift; sourceTree = "<group>"; };
/* End PBXFileReference section */
@ -246,7 +246,7 @@
132417AD2D131A0600B4F2D2 /* SettingsLogsView.swift */,
132417AE2D131A0600B4F2D2 /* SettingsModuleView.swift */,
132417AF2D131A0600B4F2D2 /* SettingsPlayerView.swift */,
13B3A4B12D1477F100BCC0D5 /* StorageSettingsView.swift */,
13B3A4B12D1477F100BCC0D5 /* SettingsStorageView.swift */,
);
path = SubPages;
sourceTree = "<group>";
@ -365,7 +365,7 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
13B3A4B22D1477F100BCC0D5 /* StorageSettingsView.swift in Sources */,
13B3A4B22D1477F100BCC0D5 /* SettingsStorageView.swift in Sources */,
132417BB2D131A0600B4F2D2 /* SettingsIUView.swift in Sources */,
132417C42D131A0600B4F2D2 /* MediaExtraction.swift in Sources */,
132417B82D131A0600B4F2D2 /* SearchView.swift in Sources */,

View file

@ -31,6 +31,7 @@ struct ContentView: View {
}
.onAppear {
checkForUpdate()
Logger.shared.log("Started Sora")
}
}

View file

@ -61,12 +61,22 @@ struct LibraryView: View {
}
func itemView(_ item: LibraryItem) -> some View {
VStack {
KFImage(URL(string: item.image))
.resizable()
.aspectRatio(2/3, contentMode: .fill)
.cornerRadius(10)
.frame(width: 150, height: 225)
VStack() {
ZStack(alignment: .bottomTrailing) {
KFImage(URL(string: item.image))
.resizable()
.aspectRatio(2/3, contentMode: .fill)
.cornerRadius(10)
.frame(width: 150, height: 225)
KFImage(URL(string: item.module.iconURL))
.resizable()
.aspectRatio(contentMode: .fit)
.frame(width: 30, height: 30)
.background(Color.white)
.clipShape(Circle())
.padding(5)
}
Text(item.title)
.font(.subheadline)
@ -82,4 +92,4 @@ struct LibraryView: View {
}
}
}
}
}

View file

@ -39,9 +39,9 @@ struct MediaView: View {
HStack(alignment: .top, spacing: 10) {
KFImage(URL(string: item.imageUrl))
.resizable()
.aspectRatio(contentMode: .fit)
.frame(height: 190)
.aspectRatio(2/3, contentMode: .fill)
.cornerRadius(10)
.frame(width: 150, height: 225)
VStack(alignment: .leading, spacing: 4) {
Text(item.name)

View file

@ -49,7 +49,7 @@ struct SettingsView: View {
Text("Modules")
}
}
NavigationLink(destination: StorageSettingsView()) {
NavigationLink(destination: SettingsStorageView()) {
HStack {
Image(systemName: "externaldrive.fill")
Text("Storage")

View file

@ -1,5 +1,5 @@
//
// StorageSettingsView.swift
// SettingsStorageView.swift
// Sora
//
// Created by Francesco on 19/12/24.
@ -7,7 +7,7 @@
import SwiftUI
struct StorageSettingsView: View {
struct SettingsStorageView: View {
@State private var appSize: String = "Calculating..."
@State private var storageDetails: [(String, Double, Color)] = []
@State private var deviceStorage: (total: Int64, used: Int64) = (0, 0)
@ -42,9 +42,9 @@ struct StorageSettingsView: View {
RoundedRectangle(cornerRadius: 0)
.fill(detail.2)
.frame(width: geometry.size.width * CGFloat(detail.1 * 1024 * 1024) / CGFloat(deviceStorage.total))
.frame(height: 24)
}
}
.frame(height: 24)
.clipShape(RoundedRectangle(cornerRadius: 8))
}
}