Fix iOS 18 build + performances

This commit is contained in:
Thomas Ricouard 2024-06-12 20:37:43 +02:00
parent 375ea665b4
commit 02d73de113
5 changed files with 18 additions and 14 deletions

View file

@ -3,10 +3,10 @@
{
"identity" : "bodega",
"kind" : "remoteSourceControl",
"location" : "https://github.com/mergesort/Bodega",
"location" : "https://github.com/Dimillian/Bodega",
"state" : {
"revision" : "f0554077c178088ba11557bbdbb71775cc6a1b84",
"version" : "2.1.0"
"branch" : "main",
"revision" : "a144ed8afdd760b65b6b9a136ba8bb75cd19387e"
}
},
{
@ -129,10 +129,10 @@
{
"identity" : "swiftui-introspect",
"kind" : "remoteSourceControl",
"location" : "https://github.com/siteline/SwiftUI-Introspect.git",
"location" : "https://github.com/Dimillian/swiftui-introspect",
"state" : {
"revision" : "7dc5b287f8040e4ad5038739850b758e78f77808",
"version" : "1.1.4"
"branch" : "main",
"revision" : "e5d36b00e6e437b552aa76ed6d1eca71d6fd8f8b"
}
}
],

View file

@ -122,7 +122,7 @@ struct AppView: View {
.tag(tab)
}
}
.introspect(.tabView, on: .iOS(.v17)) { (tabview: UITabBarController) in
.introspect(.tabView, on: .iOS(.v18)) { (tabview: UITabBarController) in
tabview.tabBar.isHidden = horizontalSizeClass == .regular
tabview.customizableViewControllers = []
tabview.moreNavigationController.isNavigationBarHidden = true

View file

@ -264,10 +264,14 @@ struct SettingsTabs: View {
Text("settings.app.icon")
} icon: {
let icon = IconSelectorView.Icon(string: UIApplication.shared.alternateIconName ?? "AppIcon")
if let image: UIImage = .init(named: icon.appIconName) {
Image(uiImage: .init(named: icon.appIconName)!)
.resizable()
.frame(width: 25, height: 25)
.cornerRadius(4)
} else {
EmptyView()
}
}
}
#endif

View file

@ -22,8 +22,8 @@ let package = Package(
.package(name: "Env", path: "../Env"),
.package(name: "StatusKit", path: "../StatusKit"),
.package(name: "DesignSystem", path: "../DesignSystem"),
.package(url: "https://github.com/siteline/SwiftUI-Introspect.git", from: "1.0.0"),
.package(url: "https://github.com/mergesort/Bodega", exact: "2.1.0"),
.package(url: "https://github.com/Dimillian/swiftui-introspect", branch: "main"),
.package(url: "https://github.com/Dimillian/Bodega", branch: "main"),
],
targets: [
.target(

View file

@ -68,7 +68,7 @@ public struct TimelineView: View {
.scrollContentBackground(.hidden)
.background(theme.primaryBackgroundColor)
#endif
.introspect(.list, on: .iOS(.v17)) { (collectionView: UICollectionView) in
.introspect(.list, on: .iOS(.v18)) { (collectionView: UICollectionView) in
DispatchQueue.main.async {
self.collectionView = collectionView
}