summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFuwn <[email protected]>2025-06-14 21:59:32 -0700
committerFuwn <[email protected]>2025-06-14 21:59:32 -0700
commit79304518db513658991f888236dd2dc8003cb235 (patch)
treed0eaa6619fb48c16d8d0bf4e8b6e8017572f876b
parentfeat: Development commit (diff)
downloadsora-testing-79304518db513658991f888236dd2dc8003cb235.tar.xz
sora-testing-79304518db513658991f888236dd2dc8003cb235.zip
feat: Development commit
-rw-r--r--Sora/App/SoraApp.swift15
-rw-r--r--Sora/Views/Post/Grid/PostGridThumbnailView.swift2
-rw-r--r--project.yml4
3 files changed, 15 insertions, 6 deletions
diff --git a/Sora/App/SoraApp.swift b/Sora/App/SoraApp.swift
index cea526f..8fdfb4d 100644
--- a/Sora/App/SoraApp.swift
+++ b/Sora/App/SoraApp.swift
@@ -14,6 +14,12 @@ func debugPrint(
struct SoraApp: App {
@StateObject private var settings = SettingsManager()
+ @ViewBuilder
+ private func settingsContent() -> some View {
+ SettingsView()
+ .environmentObject(settings)
+ }
+
var body: some Scene {
WindowGroup {
MainView()
@@ -22,9 +28,12 @@ struct SoraApp: App {
#if os(macOS)
SwiftUI.Settings {
- SettingsView()
- .environmentObject(settings)
- .windowResizeBehavior(.enabled)
+ if #available(macOS 15.0, *) {
+ settingsContent()
+ .windowResizeBehavior(.enabled)
+ } else {
+ settingsContent()
+ }
}
#endif
}
diff --git a/Sora/Views/Post/Grid/PostGridThumbnailView.swift b/Sora/Views/Post/Grid/PostGridThumbnailView.swift
index ae9dbcb..8d82c94 100644
--- a/Sora/Views/Post/Grid/PostGridThumbnailView.swift
+++ b/Sora/Views/Post/Grid/PostGridThumbnailView.swift
@@ -40,7 +40,7 @@ struct PostGridThumbnailView: View {
url: thumbnailURL,
transaction: Transaction(animation: .default)
) { image in
- if #available(iOS 18.0, *) {
+ if #available(iOS 18.0, *), #available(macOS 15.0, *) {
imageContent(image: image)
.onScrollVisibilityChange { visible in
if post == posts.last, !manager.endOfData, visible {
diff --git a/project.yml b/project.yml
index c10df0f..c7ab66d 100644
--- a/project.yml
+++ b/project.yml
@@ -62,7 +62,7 @@ targets:
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad: UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone: UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight
IPHONEOS_DEPLOYMENT_TARGET: 17.0
- MACOSX_DEPLOYMENT_TARGET: 15.2
+ MACOSX_DEPLOYMENT_TARGET: 14.0
MARKETING_VERSION: 1.0
SDKROOT: auto
SUPPORTED_PLATFORMS: iphoneos iphonesimulator macosx xros xrsimulator
@@ -70,7 +70,7 @@ targets:
SWIFT_EMIT_LOC_STRINGS: YES
SWIFT_VERSION: 5.0
TARGETED_DEVICE_FAMILY: 1,2,7
- XROS_DEPLOYMENT_TARGET: 2.2
+ XROS_DEPLOYMENT_TARGET: 1.0
dependencies:
- package: Alamofire
- package: NetworkImage