From 7e528169815cb6e49dfeaf100943c05fbd9dc417 Mon Sep 17 00:00:00 2001 From: Nidal Fakhouri Date: Thu, 5 Sep 2024 10:55:20 -0400 Subject: [PATCH] Restructure Sample Code And Add Sample App --- .../xcshareddata/xcschemes/StytchUI.xcscheme | 34 +- .../xcschemes/StytchUIUnitTests.xcscheme | 54 +++ .../Base.lproj/LaunchScreen.storyboard | 14 +- .../ConsumerWorkbench-Bridging-Header.h} | 0 .../Launch Screen.storyboard | 60 +++ .../AccentColor.colorset/Contents.json | 0 .../AppIcon.appiconset/App icon1024x1024.png | Bin .../AppIcon.appiconset/Contents.json | 0 .../Shared/Assets.xcassets}/Contents.json | 0 .../Contents.json | 0 .../Wordmark-light-mode.png | Bin .../Shared/AuthenticationOptionsView.swift | 0 .../Shared/ContentView.swift | 0 .../Shared/EmailAuthenticationView.swift | 0 .../Shared/Extensions.swift | 0 .../Shared/HobbiesView.swift | 0 .../Shared/Info.plist | 0 .../Shared/OAuthAuthenticationView.swift | 0 .../Shared/OTPAuthenticationView.swift | 0 .../Shared/PasskeysAuthenticationView.swift | 0 .../PasswordAuthenticationView.swift | 0 .../Passwords/PasswordFeedbackView.swift | 0 .../Shared/Passwords/PasswordModel.swift | 0 .../Shared/Passwords/PasswordView.swift | 0 .../Shared/Passwords/ResetPasswordView.swift | 0 .../Shared/SessionView.swift | 0 .../Shared/StytchDemoApp.swift | 0 .../Shared/TOTPAuthenticationView.swift | 0 .../iOS/iOS.entitlements | 0 .../AccentColor.colorset}/Contents.json | 5 + .../AppIcon.appiconset/App icon1024x1024.png | Bin 0 -> 13789 bytes .../AppIcon.appiconset/Contents.json | 14 + .../Assets.xcassets/Contents.json | 0 .../Contents.json | 0 .../Wordmark-light-mode.png | Bin Stytch/DemoApps/StytchDemo/ContentView.swift | 56 +++ Stytch/DemoApps/StytchDemo/Info.plist | 17 + .../StytchDemo/Launch Screen.storyboard | 34 +- Stytch/DemoApps/StytchDemo/LoggedInView.swift | 96 ++++ .../StytchDemo/OTPAuthenticationManager.swift | 59 +++ Stytch/DemoApps/StytchDemo/OTPView.swift | 106 +++++ .../DemoApps/StytchDemo/StytchDemoApp.swift | 10 + .../StytchDemo/User.Name+Helpers.swift | 34 ++ .../StytchDemo/macOS/macOS.entitlements | 15 - .../StytchUIDemo/Launch Screen.storyboard | 14 +- Stytch/Stytch.xcodeproj/project.pbxproj | 427 +++++++++--------- ...Workbench.xcscheme => StytchDemo.xcscheme} | 21 +- 47 files changed, 760 insertions(+), 310 deletions(-) rename Stytch/Stytch.xcodeproj/xcshareddata/xcschemes/StytchDemo (iOS).xcscheme => .swiftpm/xcode/xcshareddata/xcschemes/StytchUI.xcscheme (65%) create mode 100644 .swiftpm/xcode/xcshareddata/xcschemes/StytchUIUnitTests.xcscheme rename Stytch/DemoApps/{StytchDemo/StytchDemo-Bridging-Header.h => ConsumerWorkbench/ConsumerWorkbench-Bridging-Header.h} (100%) create mode 100644 Stytch/DemoApps/ConsumerWorkbench/Launch Screen.storyboard rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/Assets.xcassets/AccentColor.colorset/Contents.json (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/Assets.xcassets/AppIcon.appiconset/App icon1024x1024.png (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/Assets.xcassets/AppIcon.appiconset/Contents.json (100%) rename Stytch/DemoApps/{StytchDemo/Preview Content/Preview Assets.xcassets => ConsumerWorkbench/Shared/Assets.xcassets}/Contents.json (100%) rename Stytch/DemoApps/{StytchDemo/Preview Content/Preview Assets.xcassets => ConsumerWorkbench/Shared/Assets.xcassets}/client-wordmark-light-mode.imageset/Contents.json (100%) rename Stytch/DemoApps/{StytchDemo/Preview Content/Preview Assets.xcassets => ConsumerWorkbench/Shared/Assets.xcassets}/client-wordmark-light-mode.imageset/Wordmark-light-mode.png (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/AuthenticationOptionsView.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/ContentView.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/EmailAuthenticationView.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/Extensions.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/HobbiesView.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/Info.plist (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/OAuthAuthenticationView.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/OTPAuthenticationView.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/PasskeysAuthenticationView.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/Passwords/PasswordAuthenticationView.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/Passwords/PasswordFeedbackView.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/Passwords/PasswordModel.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/Passwords/PasswordView.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/Passwords/ResetPasswordView.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/SessionView.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/StytchDemoApp.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/Shared/TOTPAuthenticationView.swift (100%) rename Stytch/DemoApps/{StytchDemo => ConsumerWorkbench}/iOS/iOS.entitlements (100%) rename Stytch/DemoApps/{StytchUIDemo/Preview Content/Preview Assets.xcassets => StytchDemo/Assets.xcassets/AccentColor.colorset}/Contents.json (51%) create mode 100644 Stytch/DemoApps/StytchDemo/Assets.xcassets/AppIcon.appiconset/App icon1024x1024.png create mode 100644 Stytch/DemoApps/StytchDemo/Assets.xcassets/AppIcon.appiconset/Contents.json rename Stytch/DemoApps/StytchDemo/{Shared => }/Assets.xcassets/Contents.json (100%) rename Stytch/DemoApps/StytchDemo/{Shared/Assets.xcassets/client-wordmark-light-mode.imageset => Assets.xcassets/Wordmark-light-mode.imageset}/Contents.json (100%) rename Stytch/DemoApps/StytchDemo/{Shared/Assets.xcassets/client-wordmark-light-mode.imageset => Assets.xcassets/Wordmark-light-mode.imageset}/Wordmark-light-mode.png (100%) create mode 100644 Stytch/DemoApps/StytchDemo/ContentView.swift create mode 100644 Stytch/DemoApps/StytchDemo/Info.plist create mode 100644 Stytch/DemoApps/StytchDemo/LoggedInView.swift create mode 100644 Stytch/DemoApps/StytchDemo/OTPAuthenticationManager.swift create mode 100644 Stytch/DemoApps/StytchDemo/OTPView.swift create mode 100644 Stytch/DemoApps/StytchDemo/StytchDemoApp.swift create mode 100644 Stytch/DemoApps/StytchDemo/User.Name+Helpers.swift delete mode 100644 Stytch/DemoApps/StytchDemo/macOS/macOS.entitlements rename Stytch/Stytch.xcodeproj/xcshareddata/xcschemes/{B2BWorkbench.xcscheme => StytchDemo.xcscheme} (81%) diff --git a/Stytch/Stytch.xcodeproj/xcshareddata/xcschemes/StytchDemo (iOS).xcscheme b/.swiftpm/xcode/xcshareddata/xcschemes/StytchUI.xcscheme similarity index 65% rename from Stytch/Stytch.xcodeproj/xcshareddata/xcschemes/StytchDemo (iOS).xcscheme rename to .swiftpm/xcode/xcshareddata/xcschemes/StytchUI.xcscheme index 2a80f09eab..5bc3c9c832 100644 --- a/Stytch/Stytch.xcodeproj/xcshareddata/xcschemes/StytchDemo (iOS).xcscheme +++ b/.swiftpm/xcode/xcshareddata/xcschemes/StytchUI.xcscheme @@ -4,7 +4,8 @@ version = "1.7"> + buildImplicitDependencies = "YES" + buildArchitectures = "Automatic"> + BlueprintIdentifier = "StytchUI" + BuildableName = "StytchUI" + BlueprintName = "StytchUI" + ReferencedContainer = "container:"> @@ -39,16 +40,6 @@ debugDocumentVersioning = "YES" debugServiceExtension = "internal" allowLocationSimulation = "YES"> - - - - - + + BlueprintIdentifier = "StytchUI" + BuildableName = "StytchUI" + BlueprintName = "StytchUI" + ReferencedContainer = "container:"> - + diff --git a/.swiftpm/xcode/xcshareddata/xcschemes/StytchUIUnitTests.xcscheme b/.swiftpm/xcode/xcshareddata/xcschemes/StytchUIUnitTests.xcscheme new file mode 100644 index 0000000000..b63c901caf --- /dev/null +++ b/.swiftpm/xcode/xcshareddata/xcschemes/StytchUIUnitTests.xcscheme @@ -0,0 +1,54 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/Stytch/DemoApps/B2BWorkbench/Base.lproj/LaunchScreen.storyboard b/Stytch/DemoApps/B2BWorkbench/Base.lproj/LaunchScreen.storyboard index 53f97643f7..24e7e96f8e 100644 --- a/Stytch/DemoApps/B2BWorkbench/Base.lproj/LaunchScreen.storyboard +++ b/Stytch/DemoApps/B2BWorkbench/Base.lproj/LaunchScreen.storyboard @@ -18,14 +18,10 @@ - - - - - + - - - - - +