Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate main view to SwiftUI #113

Merged
merged 75 commits into from
Sep 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
75 commits
Select commit Hold shift + click to select a range
74c2dc0
Basic SwiftUI account list.
jensutbult Feb 2, 2023
5474870
Dropped the idea of reusing the old OATHViewModel and started rewriti…
jensutbult Feb 17, 2023
facbc6e
Fixed broken logic for setting title and subtitle of an Account.
jensutbult Feb 17, 2023
346e890
Calculate accounts with non default period correctly.
jensutbult Feb 21, 2023
1de3052
Account model sends refresh when it needs to be re-calculated.
jensutbult Feb 21, 2023
9c921b1
Only refresh when connection is wired. Prepared for refreshing indivi…
jensutbult Feb 21, 2023
eb7af3c
Update code if Account already exists instead of always creating a ne…
jensutbult Feb 21, 2023
67fe5e8
Removed commented out code.
jensutbult Feb 21, 2023
24a521d
Do not animate going from 0 to 1 progress in pie view.
jensutbult Feb 21, 2023
9cc519d
Proper observation of state changes in AccountDetailsView.
jensutbult Feb 23, 2023
64e2986
AccountRowView holds on to Account a little to long and does not rele…
jensutbult Feb 24, 2023
0045b74
Added requires touch and calculate status icons.
jensutbult Mar 6, 2023
50e228d
Code and status icon on same line and proper horizontal alignement.
jensutbult Mar 7, 2023
bba9faa
Show title and subtitle in details view.
jensutbult Mar 7, 2023
70280d3
Rudimentary menu in account details view and calculate of individual …
jensutbult Mar 9, 2023
26ced10
Enable/disable calculate and copy in account details menu.
jensutbult Mar 13, 2023
1016d90
Better animation timing.
jensutbult Mar 14, 2023
6428a8a
Configuration hooked into the SwiftUI menu.
jensutbult Mar 14, 2023
b6c66f4
About view hooked up in menu.
jensutbult Mar 15, 2023
3be906a
Hooked up add account and some UI polish to navigation bars.
jensutbult Mar 15, 2023
a3187f5
Delete account hooked up.
jensutbult Mar 15, 2023
b21b59f
Bumped version to 1.7.2 and added ITSAppUsesNonExemptEncryption key t…
jensutbult Mar 15, 2023
9f1f2ea
Implemented rename account.
jensutbult Mar 17, 2023
6e0a181
Only show rename account if key supports it.
jensutbult Mar 21, 2023
64d496a
Cache access key in memory.
jensutbult Mar 22, 2023
b988b79
Save access keys to KeyChain.
jensutbult Mar 23, 2023
9cef922
Pinning implemented.
jensutbult Mar 27, 2023
241168c
Handle auth when adding, deleting and renaming an account.
jensutbult Mar 27, 2023
ce92932
Fixes bug where updating a single account would trigger all accounts …
jensutbult Mar 27, 2023
2f2f9d9
Fixed issues with requires touch and lightning keys.
jensutbult Mar 27, 2023
fb1edcf
Alignment fixes to OTP presentation.
jensutbult Mar 28, 2023
ad07bca
YKFOATHCredential fully hidden from view model. Calculate steam code …
jensutbult Mar 28, 2023
0804673
Remove Steam logic from MainViewModel.
jensutbult Mar 28, 2023
bbe44ee
Remove pinned accounts when removing lightning YubiKey and dismiss ac…
jensutbult Mar 28, 2023
6c87a24
Insert yubikey screen.
jensutbult Mar 29, 2023
47170b5
Search accounts implemented.
jensutbult Mar 30, 2023
daca451
Minor UI tweaks to account cells and account detail view.
jensutbult Mar 30, 2023
80bea50
Fixed bug where pinned accounts failed to re-calculate.
jensutbult Mar 30, 2023
4f8cc37
Improved search and list status view.
jensutbult Mar 30, 2023
2b4effc
Workaround for the iOS bug where List Views retains its objects even …
jensutbult Apr 4, 2023
b3855b0
Removed unused onDisappear().
jensutbult Apr 17, 2023
df26620
Bumped version and fixed spelling error in change log.
jensutbult Apr 27, 2023
dbc8db9
SwiftUI detached menu mostly on par with previous implementation.
jensutbult Apr 27, 2023
ee0f815
Confirmation dialog when deleting an account.
jensutbult Apr 27, 2023
853c767
Fixed issue where taps on account rows would be ignored.
jensutbult Apr 28, 2023
0e513ba
Rudimentary support for YubiOTP NDEF tags and otpauth-urls.
jensutbult May 29, 2023
6f74d5c
Use yubikey image for the OTPRowView instead of Text.
jensutbult May 30, 2023
362d3fb
Implemented toast when copying otp codes.
jensutbult Jun 13, 2023
4025278
Added unique id for Account to force the List to not reuse the Accoun…
jensutbult Jun 13, 2023
1cd3073
Copy-on-long-press for accounts that requires NFC scan.
jensutbult Jun 15, 2023
97979a9
Cleaned up the code regarding credential state and how we handle tran…
jensutbult Jun 20, 2023
82d29ae
Added whats new button to swiftui main view.
jensutbult Jun 20, 2023
6c9ca08
Show touch yubikey toast.
jensutbult Jun 21, 2023
aa6c1be
Use toast when copying otp in details view.
jensutbult Jun 21, 2023
ab3047c
Improved colors and animation of the otp code.
jensutbult Jun 21, 2023
866e226
HOTP AccountRowViews are grayed out until they have been calculated.
jensutbult Jun 22, 2023
868c2b0
PIV extension module implemented in SwiftUI.
jensutbult Jun 26, 2023
3a8e727
Fix bug where connections would fail in PIV-extension if app was star…
jensutbult Jun 27, 2023
24611fb
Only copy YubiOTP when the corresponding setting is set to true.
jensutbult Jun 27, 2023
d818bbe
Disable "Add account" amd "Configuration" in menu for iPads if no key…
jensutbult Jun 27, 2023
12e94b9
Make sure we present the app in single view on iPad.
jensutbult Jun 27, 2023
51a4de2
Disable pull-to-refresh on iPad.
jensutbult Aug 16, 2023
f4c35a5
Handle duplicate accounts when adding new account to key.
jensutbult Aug 16, 2023
e8bd00f
Show dismiss NFC modal hint.
jensutbult Aug 16, 2023
797389e
Handle pinning when renaming an account.
jensutbult Aug 16, 2023
5db8e92
Deleted old UIKit files.
jensutbult Aug 16, 2023
3406f0d
Fixed issue that disabled animations in main view.
jensutbult Aug 18, 2023
5b59143
Bumped build number and version.
jensutbult Aug 18, 2023
adc1c07
Dismiss any views presented on top of MainView when the PIVTokenView …
jensutbult Aug 18, 2023
c965a8e
Animation tweaks.
jensutbult Aug 21, 2023
5fd714b
Removed debug print.
jensutbult Aug 22, 2023
a5a7171
Fixed copyright text.
jensutbult Aug 22, 2023
92d37aa
Fixes crash on iPad and adjusts menu in details view. Draft change log.
jensutbult Sep 18, 2023
996f384
Password save dialog now displays correctly on iPad.
jensutbult Sep 18, 2023
39c5f40
Remove non-functioning passcode to store accesskeys for devices with …
jensutbult Sep 19, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
157 changes: 101 additions & 56 deletions Authenticator.xcodeproj/project.pbxproj

Large diffs are not rendered by default.

117 changes: 0 additions & 117 deletions Authenticator/AppDelegate.swift

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{
"colors" : [
{
"color" : {
"color-space" : "extended-gray",
"components" : {
"alpha" : "1.000",
"white" : "0.000"
}
},
"idiom" : "universal"
},
{
"appearances" : [
{
"appearance" : "luminosity",
"value" : "dark"
}
],
"color" : {
"color-space" : "extended-gray",
"components" : {
"alpha" : "1.000",
"white" : "0.926"
}
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
43 changes: 43 additions & 0 deletions Authenticator/AuthenticatorApp.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
/*
* Copyright (C) Yubico.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

import SwiftUI

@main
struct AuthenticatorApp: App {

@Environment(\.scenePhase) var scenePhase
@StateObject var toastPresenter = ToastPresenter()
@StateObject var notificationsViewModel = NotificationsViewModel()

var body: some Scene {
WindowGroup {
ZStack {
MainView()
.toast(isPresenting: $toastPresenter.isPresenting, message: toastPresenter.message)
}
.fullScreenCover(isPresented: $notificationsViewModel.showPIVTokenView) {
TokenRequestView(userInfo: notificationsViewModel.userInfo)
}
.transaction { transaction in
transaction.disablesAnimations = notificationsViewModel.showPIVTokenView
}
.navigationViewStyle(.stack)
.environmentObject(toastPresenter)
.environmentObject(notificationsViewModel)
}
}
}
2 changes: 2 additions & 0 deletions Authenticator/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>ITSAppUsesNonExemptEncryption</key>
<false/>
<key>CFBundleShortVersionString</key>
<string>$(MARKETING_VERSION)</string>
<key>CFBundleURLTypes</key>
Expand Down
Loading
Loading