diff --git a/Examples/AcknowExampleSPM/AcknowExampleSPM/Base.lproj/Main.storyboard b/Examples/AcknowExampleSPM/AcknowExampleSPM/Base.lproj/Main.storyboard index e204a62..754522d 100644 --- a/Examples/AcknowExampleSPM/AcknowExampleSPM/Base.lproj/Main.storyboard +++ b/Examples/AcknowExampleSPM/AcknowExampleSPM/Base.lproj/Main.storyboard @@ -1,9 +1,9 @@ - + - + @@ -18,25 +18,34 @@ + - + + + diff --git a/Examples/AcknowExampleSPM/AcknowExampleSPM/ViewController.swift b/Examples/AcknowExampleSPM/AcknowExampleSPM/ViewController.swift index c904673..cbc19e0 100644 --- a/Examples/AcknowExampleSPM/AcknowExampleSPM/ViewController.swift +++ b/Examples/AcknowExampleSPM/AcknowExampleSPM/ViewController.swift @@ -6,6 +6,7 @@ // import UIKit +import SwiftUI import AcknowList class ViewController: UIViewController { @@ -31,5 +32,16 @@ class ViewController: UIViewController { let navigationController = UINavigationController(rootViewController: vc) present(navigationController, animated: true, completion: nil) } + + @IBAction func presentAcknowledgementsSwiftUI(_ sender: AnyObject) { + let listViewController = AcknowListSwiftUIView(acknowledgements: [ + Acknow(title: "Test", text: "Bla bla"), + Acknow(title: "Test URL", repository: URL(string: "https://developer.apple.com")), + Acknow(title: "Test GitHub", repository: URL(string: "https://github.com/vtourraine/AcknowList.git")) + ]) + let viewController = UIHostingController(rootView: listViewController) + let navigationController = UINavigationController(rootViewController: viewController) + present(navigationController, animated: true, completion: nil) + } }