[ios] Switched OSM profile to SwiftUI and redesigned it

Signed-off-by: Yannik Bloscheck <git@yannikbloscheck.com>
This commit is contained in:
Yannik Bloscheck
2025-07-04 21:20:43 +02:00
committed by Yannik Bloscheck
parent db1ef9b148
commit 15c7e71866
127 changed files with 1753 additions and 2503 deletions

View File

@@ -0,0 +1,24 @@
import UIKit
import SwiftUI
/// Class for accesing SwiftUI views from Objective-C code
@objc class BridgeControllers: NSObject {
/// The `ProfileView`
@objc static func profile() -> UIViewController {
return UIHostingController(rootView: ProfileView())
}
/// The `ProfileView` for presentation in an alert
@objc static func profileAsAlert() -> UIViewController {
return UIHostingController(rootView: ProfileView(isPresentedAsAlert: true))
}
}
/// Class for using the SwiftUI `ProfileView` in the interface builder
class ProfileBridgeController: UIHostingController<ProfileView> {
required init?(coder aDecoder: NSCoder) {
super.init(coder: aDecoder, rootView: ProfileView())
}
}