NCUserStatus.swift 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. //
  2. // NCUserStatus.swift
  3. // Nextcloud
  4. //
  5. // Created by Marino Faggiana on 23/11/20.
  6. // Copyright © 2020 Marino Faggiana. All rights reserved.
  7. //
  8. import SwiftUI
  9. import Foundation
  10. @available(iOS 13.0, *)
  11. struct NCUserStatus: View {
  12. var body: some View {
  13. VStack(alignment: .leading) {
  14. HStack {
  15. Image("userStatusAway")
  16. .resizable()
  17. .frame(width: 100.0, height: 100.0)
  18. .clipShape(Circle())
  19. }
  20. Text("Hello World44,2")
  21. .font(.headline)
  22. .foregroundColor(Color.red)
  23. .lineLimit(0)
  24. Text("test")
  25. }
  26. }
  27. }
  28. @available(iOS 13.0, *)
  29. struct NCUserStatus_Previews: PreviewProvider {
  30. static var previews: some View {
  31. Group {
  32. NCUserStatus()
  33. }
  34. }
  35. }
  36. @available(iOS 13.0, *)
  37. @objc class NCUserStatusViewController: NSObject {
  38. @objc func makeUserStatusUI() -> UIViewController{
  39. let userStatus = NCUserStatus()
  40. //details.shipName = name
  41. return UIHostingController(rootView: userStatus)
  42. }
  43. }