mirror of
https://github.com/SideStore/SideStore.git
synced 2026-02-13 16:53:29 +01:00
commit 22f1ff7cd7d4d4750eeda2067d23846900239b83 Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sat May 20 11:29:01 2023 -0700 fix: actually disable LocalConsole's character limit commit 4b51915da7bc0637ccf819ac45c7d727d450ae12 Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sat May 20 11:27:12 2023 -0700 Merge SwiftUI improvements (#265) commit7f73f2adefMerge:72f34dd238a1c7eeAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sat May 20 11:23:07 2023 -0700 Merge remote-tracking branch 'origin/fabianthdev/feature/SwiftUI' into naturecodevoid/swiftui-improvements commit72f34dd286Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Wed Apr 12 18:21:49 2023 -0700 feat: default to Storm icon for PR builds Signed-off-by: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> commit060c37c423Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Apr 9 19:40:53 2023 -0700 fix(icons): sky appears correctly in light mode commit8c2968aeb3Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Apr 9 14:29:03 2023 -0700 fix: build errors commit4f512b6318Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Apr 9 13:54:01 2023 -0700 project(minimuxer): fix actions build error commit5b752cf26eAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Apr 9 13:51:54 2023 -0700 fix: remove duplicate isSideStore checks with a StoreApp extension commit62a478277eAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Apr 9 13:41:58 2023 -0700 fix(AsyncFallibleButton): try to use failureReason and then fallback to localizedDescription commit994b2318a9Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Apr 9 13:38:44 2023 -0700 feat(dev mode): add AFC file explorer and dump profiles commit423ac28ba3Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Apr 9 13:35:14 2023 -0700 project(AltStore): xcode wants to move these around I guess commitaf2cdd48d6Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Apr 9 13:34:57 2023 -0700 feat: add debug logging toggle commit44fe0c5686Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Apr 9 13:33:11 2023 -0700 project(minimuxer): Add libminimuxer as an input file for build step commit3d46a3069aAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Apr 9 13:32:22 2023 -0700 fix: handle source conflict in merge policy commit82e8fb7389Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Apr 9 13:31:39 2023 -0700 docs: include info on Developer Mode commit1dd0cd7d90Merge:92a9650c566841a9Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Thu Apr 6 21:07:33 2023 -0700 Merge branch 'fabianthdev/feature/SwiftUI' into naturecodevoid/swiftui-improvements commit566841a9a6Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Thu Apr 6 21:06:07 2023 -0700 Fix not being able to open the project commit92a9650c0cAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Thu Apr 6 20:49:49 2023 -0700 Apply DevModeView suggestion commitdf94e79472Merge:d3cfc4bacd2c5ad7Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Thu Apr 6 20:48:52 2023 -0700 Merge branch 'fabianthdev/feature/SwiftUI' into naturecodevoid/swiftui-improvements commitcd2c5ad7b4Merge:3466870d6146f1bdAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Thu Apr 6 20:43:10 2023 -0700 Merge remote-tracking branch 'origin/develop' into fabianthdev/feature/SwiftUI commitd3cfc4bab9Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Wed Feb 22 13:05:11 2023 -0800 FileExplorer: Replace file when inserting commitdf62461d4aAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Wed Feb 22 13:04:52 2023 -0800 Settings: Add Export Logs and commit xcodeproj changes commit817d2de5e0Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Wed Feb 22 12:19:07 2023 -0800 Rename View+SideStore commit3ea478ad05Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Wed Feb 22 12:18:42 2023 -0800 DevMode: Add password commit13f9a9d1bfAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Wed Feb 22 11:43:13 2023 -0800 AdvancedSettingsView: improve anisette URL by using a label instead of a placeholder commit3821a6034dAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Tue Feb 21 17:34:56 2023 -0800 project: attempt to fix crashing on launch commit3e8d7da0c3Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Feb 19 13:49:22 2023 -0800 AdvancedSettingsView: Remove autocomplete from anisette URL text field commita42c1a705fAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Feb 19 13:25:59 2023 -0800 SettingsView: Adjust ordering a little bit and remove accent color commit30efc6f210Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Feb 19 13:19:26 2023 -0800 LaunchViewController: Revert changes commit60412721eeAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Feb 19 13:04:42 2023 -0800 Fix build errors hopefully this doesn't have any unintended side effects commitcba00a3b9dAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Feb 19 12:03:22 2023 -0800 Add Advanced Settings in-app commit2aa880d10eAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Feb 19 10:56:01 2023 -0800 Fix build errors after merge commit47848ddd18Merge:deac960e3466870dAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Feb 19 09:56:21 2023 -0800 Merge branch 'fabianthdev/feature/SwiftUI' into naturecodevoid/swiftui-improvements Signed-off-by: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> commitdeac960e10Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Feb 19 09:54:56 2023 -0800 Revert OutputCapturer changes since Fabian already added the fix commit9f05123e42Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Feb 19 09:16:49 2023 -0800 AppIconView: Make isSideStore required commitd9a4b07095Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Feb 19 09:16:07 2023 -0800 Fix changing SideStore app icon not displaying My Apps commit839699ee03Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Feb 19 09:00:19 2023 -0800 Icons: add Vista by Swifticul commit81409227d6Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Feb 19 08:06:33 2023 -0800 Add developer mode commit49b9be160fAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sun Feb 19 07:57:29 2023 -0800 AppRowView: Disable ratings if there aren't any ratings commit3466870d8fAuthor: Fabian Thies <git@fabian-thies.de> Date: Sun Feb 19 14:31:01 2023 +0100 [ADD] UI for writing an app review and submit an app rating commitffe8a92a4eAuthor: Fabian Thies <git@fabian-thies.de> Date: Sun Feb 19 14:30:21 2023 +0100 [CHANGE] UI fixes and SwiftUI previews for easier development commitbc2cae46a8Author: Fabian Thies <git@fabian-thies.de> Date: Sun Feb 19 14:25:13 2023 +0100 [ADD] Refresh all apps functionality in MyAppsView commita95d8a502cAuthor: Fabian Thies <git@fabian-thies.de> Date: Sun Feb 19 11:40:26 2023 +0100 [FIX] STDOUT output not visible in Xcode console commit19e66112ddAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sat Feb 18 20:27:06 2023 -0800 SourcesView: Fix 1 trusted source causing an error making all trusted sources fail to load commit0d3cb843eaAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sat Feb 18 20:26:32 2023 -0800 SourcesViewController: Fix 1 trusted source causing an error making all trusted sources fail to load commitdf1a662accAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sat Feb 18 20:25:58 2023 -0800 FetchTrustedSourcesOperation: Remove redundant if statement commit684c9e08ebAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Sat Feb 18 10:48:05 2023 -0800 Fix HMR commitc585c57965Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Fri Feb 17 18:51:06 2023 -0800 Revert fixes since it didn't actually fix the problem commit3605ca6422Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Fri Feb 17 18:20:56 2023 -0800 Fix HMR again commit40f4c94f4dAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Fri Feb 17 18:11:25 2023 -0800 Fix HMR crashing the app commit986465d8f4Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Fri Feb 17 17:44:56 2023 -0800 Project: Add HMR https://github.com/krzysztofzablocki/Inject#individual-developer-setup-once-per-machine commit09db1ba9fcAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Thu Feb 16 18:13:32 2023 -0800 SettingsView: Move App Icon to a new, general settings section commit8874480b8cAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Thu Feb 16 17:57:51 2023 -0800 Icons: invert Sky commitf0cc4613daAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Thu Feb 16 17:57:19 2023 -0800 AppIconsView: Add artists commitbec78322a4Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Wed Feb 15 21:00:28 2023 -0800 actions: Add build step that changes default icon commit03777fd2e7Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Wed Feb 15 20:49:07 2023 -0800 Icons: add Sky, Honeydew, Midnight commit96ae60a9f2Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Wed Feb 15 19:36:10 2023 -0800 AppIconsView: improve the way primary icons are handled commitc7ad6b10a1Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Wed Feb 15 19:35:57 2023 -0800 Icons: reduce image sizes commit8b8e471c97Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Wed Feb 15 18:52:42 2023 -0800 Add App Icon changer commit38c0a8a9a3Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Tue Feb 14 08:24:49 2023 -0800 Fix ConnectAppleIDView being shoved into a sidebar on iPad commite7ff6496c1Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Tue Feb 14 08:20:16 2023 -0800 AuthenticationOperation: fix 2FA code not being displayed Bandaid fix, it would be better to have the alert in ConnectAppleIDView commitc2e89b09eaAuthor: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Mon Feb 13 21:44:48 2023 -0800 RootView: Fix UI being shoved into sidebar on iPad (closes #264, thanks @Swifticul!) commitec4dbb6679Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Mon Feb 13 21:06:59 2023 -0800 OutputCapturer: fix logging disappearing from Xcode/idevicedebug run commitd80c9ba2a8Author: naturecodevoid <44983869+naturecodevoid@users.noreply.github.com> Date: Mon Feb 13 21:06:17 2023 -0800 remove unused apps.json files commitb2f81bf7c6Author: Fabian Thies <git@fabian-thies.de> Date: Mon Feb 13 18:56:34 2023 +0100 [ADD] LocalConsole showing STDOUT and STDERR commit2fffa6e122Author: Fabian Thies <git@fabian-thies.de> Date: Sat Feb 4 14:35:58 2023 +0100 [FIX] App compatibility info commit723c8e9539Author: Fabian Thies <git@fabian-thies.de> Date: Sat Feb 4 14:29:02 2023 +0100 [ADD] Debug entries for refresh attempts, sending feedback, advanced settings, and resetting the pairing file commit07159b0ea6Author: Fabian Thies <git@fabian-thies.de> Date: Sat Feb 4 13:07:04 2023 +0100 [ADD] Error log view commite0bd54389cAuthor: Fabian Thies <git@fabian-thies.de> Date: Sat Feb 4 12:55:25 2023 +0100 [FIX] Various UI issues commit57213fbf0cAuthor: Fabian Thies <git@fabian-thies.de> Date: Sat Feb 4 12:46:43 2023 +0100 [ADD] App report button and trusted source badge in app detail view commit0239dfcd6dAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri Feb 3 18:19:07 2023 +0100 [FIX] AppIDsView and authentication workflow commit5af6f825eeAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri Feb 3 18:16:48 2023 +0100 [FIX] Full screen app screenshot previews commitb4859512abAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri Feb 3 14:58:06 2023 +0100 [FIX] Accent color commit3d0f385af7Author: Fabian Thies <git@fabian-thies.de> Date: Tue Jan 31 22:38:42 2023 +0100 [CHANGE] Overhaul of the AppDetailView with version history, reviews & ratings, and app information commitf3e58e1485Author: Fabian Thies <git@fabian-thies.de> Date: Tue Jan 31 22:37:37 2023 +0100 [UPDATE] AppPillButton dimensions and expiration text commitd3e04c1db7Author: Fabian Thies <git@fabian-thies.de> Date: Tue Jan 31 22:35:09 2023 +0100 [FIX] Show App IDs button only if user is logged in with their Apple ID commited1970245aAuthor: Fabian Thies <git@fabian-thies.de> Date: Tue Jan 31 22:32:11 2023 +0100 [ADD] Load and show trusted sources with option to add them to the app commit15dd885a1bAuthor: Fabian Thies <git@fabian-thies.de> Date: Tue Jan 31 22:30:21 2023 +0100 [ADD] Credits section in SettingsView commit4663c01700Author: Fabian Thies <git@fabian-thies.de> Date: Mon Jan 16 21:23:16 2023 +0100 [CHANGE] Extracted all strings into the Localizable.strings commite733601c66Author: Fabian Thies <git@fabian-thies.de> Date: Mon Jan 16 19:03:33 2023 +0100 [FIX] Text alignment in SettingsView commitfc974a8079Author: Fabian Thies <git@fabian-thies.de> Date: Mon Jan 16 19:02:58 2023 +0100 [ADD] Hint for new users who don't have any sources commit6aaadc79e5Author: Fabian Thies <git@fabian-thies.de> Date: Mon Jan 16 18:59:39 2023 +0100 [ADD] AppScreenshot view with ImageProcessor to automatically rotate landscape screenshots commitb9177e89c6Author: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 13:37:38 2023 +0100 [FIX] Issues introduced by changes to the AltSource specification. commit1531c0a77fAuthor: Fabian Thies <github@fabian-thies.de> Date: Fri Jan 13 12:48:27 2023 +0100 [UPDATE] Translations (#7) This PR merges all the new translations made on the SideStore weblate instance (https://translate.sidestore.io/projects/sidestore/app). New translations: - French - Korean Updated translations: - Spanish Co-authored-by: bogotesr <bogotesr@gmail.com> Co-authored-by: GABO1423 <35014183+GABO1423@users.noreply.github.com> Co-authored-by: Joss Laymon <71040782+bogotesr@users.noreply.github.com> Co-authored-by: mindfreakdev <shost212@gmail.com> Co-authored-by: Python <rjp2030@proton.me> Co-authored-by: Testi Cules <ervd516@gmail.com> commit1dde36faceAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 12:25:50 2023 +0100 [FIX] Changes made by Xcode 14 after building the app commitc3c3783ba4Author: Upal <shost212@gmail.com> Date: Mon Dec 26 19:18:33 2022 +0530 Added Hindi Language (#5) * Added Hindi Language commit8400af3423Author: mindfreakdev <shost212@gmail.com> Date: Sun Dec 25 16:52:01 2022 +0530 Added Dutch Language commit243c7efc09Author: mindfreakdev <shost212@gmail.com> Date: Sun Dec 25 12:30:42 2022 +0530 Added Ukrainian Language commit0298a0235bAuthor: mindfreakdev <shost212@gmail.com> Date: Sun Dec 25 12:28:00 2022 +0530 Added Ukrainian Language commite5b2496b09Author: Gabriel Morazán <35014183+GABO1423@users.noreply.github.com> Date: Sun Dec 25 01:08:47 2022 -0400 Screen Crunch sucks Signed-off-by: Gabriel Morazán <35014183+GABO1423@users.noreply.github.com> commit75c52a3af2Author: GABO1423 <35014183+GABO1423@users.noreply.github.com> Date: Sun Dec 25 00:58:22 2022 -0400 Spanish Translation Tweaks commit2c07009b04Author: bogotesr <bogotesr@gmail.com> Date: Sat Dec 24 21:06:28 2022 -0700 Add es-419 and finish adding support for the translations Added Latin American Spanish (probably not the best translation) Made everything reference the swiftgen stuff rather than having strings commit6257fdcd61Author: Fabian Thies <git@fabian-thies.de> Date: Thu Dec 22 10:29:57 2022 +0100 [CHANGE] Extracted some example strings and replaced them by generated localized strings commite23956d4edAuthor: Fabian Thies <git@fabian-thies.de> Date: Thu Dec 22 10:21:57 2022 +0100 [ADD] SwiftGen configuration and generated files commit1341de8315Author: Fabian Thies <git@fabian-thies.de> Date: Thu Dec 22 10:10:58 2022 +0100 [ADD] Empty Localizable.strings commit77f5844e4dAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 12:04:10 2023 +0100 [WIP] AppScreenshot view with ImageProcessor to automatically rotate landscape images. Possible through my fork of the AsyncImage framework. commitb3c4819e8dAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 12:02:56 2023 +0100 [WIP] Fetch trusted sources in SourcesView commita6ca73f8fcAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 12:02:06 2023 +0100 [WIP] AppIDs view in My Apps section commitf17d00c0bcAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 12:00:00 2023 +0100 [ADD] Badge in AppDetailView for apps from the official source and (WIP) trusted sources commit875453533bAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 11:58:25 2023 +0100 [ADD] Hint view in MyAppsView telling the user about where to find updates in the future if no updates are available commit9a7a39a58eAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 11:54:44 2023 +0100 [FIX] App permission icon color commit65db392388Author: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 11:51:06 2023 +0100 [ADD] Show source name and external url domain in NewsItemView commit6a6fc22995Author: Fabian Thies <git@fabian-thies.de> Date: Fri Dec 23 16:02:57 2022 +0100 [ADD] Full-screen app screenshot preview commit5697c4c063Author: Fabian Thies <git@fabian-thies.de> Date: Fri Dec 23 15:21:16 2022 +0100 [CHANGE] Replace system image name strings with SFSymbols commitbcd54067d3Author: Fabian Thies <git@fabian-thies.de> Date: Fri Dec 23 13:12:39 2022 +0100 [ADD] Dependency: SFSafeSymbols commitc7ce32a562Author: Fabian Thies <git@fabian-thies.de> Date: Wed Dec 21 17:49:49 2022 +0100 [ADD] WIP: Promoted category cards and app list filter button in BrowseView commit5a1496a3cdAuthor: Fabian Thies <git@fabian-thies.de> Date: Wed Dec 21 17:48:45 2022 +0100 [FIX] AccentColor in dark mode commit497c048240Author: Fabian Thies <git@fabian-thies.de> Date: Wed Dec 21 17:48:23 2022 +0100 [ADD] Carousel for SideStore-specific announcements in NewsView commit02e48a207fAuthor: Fabian Thies <git@fabian-thies.de> Date: Wed Dec 21 17:45:44 2022 +0100 [ADD] WIP: Add My Apps view with support for sideloading new apps, refreshing installed apps and much more commita0eb30f98eAuthor: Fabian Thies <git@fabian-thies.de> Date: Mon Dec 12 19:20:54 2022 +0100 [CHANGE] Fixed the AppRowView background blur effect commit378631e976Author: Fabian Thies <git@fabian-thies.de> Date: Mon Dec 12 19:20:10 2022 +0100 [ADD] Backported dismiss() environment variable to let views dismiss themselves commit0e7083539dAuthor: Fabian Thies <git@fabian-thies.de> Date: Mon Dec 12 19:18:57 2022 +0100 [ADD] Search bar for BrowseView on iOS 15 commit0c034b61d9Author: Fabian Thies <git@fabian-thies.de> Date: Mon Dec 12 19:16:36 2022 +0100 [CHANGE] Fetch news when NewsView appears commit89dea75b84Author: Fabian Thies <git@fabian-thies.de> Date: Mon Dec 12 19:15:16 2022 +0100 Improved app detail view commit81ea791b63Author: Fabian Thies <git@fabian-thies.de> Date: Mon Dec 12 19:12:38 2022 +0100 [ADD] Authentication view for connecting SideStore to an Apple ID commitc81f716427Author: Fabian Thies <git@fabian-thies.de> Date: Sun Nov 27 16:41:30 2022 +0100 [WIP] Fixed the app permissions grid in AppDetailView commiteb151d74ddAuthor: Fabian Thies <git@fabian-thies.de> Date: Sun Nov 27 16:17:08 2022 +0100 [ADD] Expandable app and version description texts commit0dc7af5e51Author: Fabian Thies <git@fabian-thies.de> Date: Sun Nov 27 00:26:15 2022 +0100 [ADD] iOS 13 compatible AsyncImage implementation with cache commitd3e8473f45Author: Fabian Thies <git@fabian-thies.de> Date: Wed Nov 23 22:34:02 2022 +0100 [ADD] News, Browse and Settings views ported to SwiftUI This commit contains WIP SwiftUI versions of most of the views in SideStore. commit38a1c7eef6Author: Fabian Thies <git@fabian-thies.de> Date: Sat May 20 20:05:36 2023 +0200 Fix rebase issues commitf6252c3a8bAuthor: Fabian Thies <git@fabian-thies.de> Date: Sat May 20 19:10:51 2023 +0200 Fix trusted sources being enabled in onboarding process regardless of user choice commit653d80b88eAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri May 19 13:14:15 2023 +0200 Add onboarding screens for an easy setup of SideStore commit89609ad35cAuthor: Fabian Thies <git@fabian-thies.de> Date: Sun Feb 19 14:31:01 2023 +0100 [ADD] UI for writing an app review and submit an app rating commit2211013e57Author: Fabian Thies <git@fabian-thies.de> Date: Sun Feb 19 14:30:21 2023 +0100 [CHANGE] UI fixes and SwiftUI previews for easier development commitf206ee1406Author: Fabian Thies <git@fabian-thies.de> Date: Sun Feb 19 14:25:13 2023 +0100 [ADD] Refresh all apps functionality in MyAppsView commit00dc9b36afAuthor: Fabian Thies <git@fabian-thies.de> Date: Sun Feb 19 11:40:26 2023 +0100 [FIX] STDOUT output not visible in Xcode console commit24146cef90Author: Fabian Thies <git@fabian-thies.de> Date: Mon Feb 13 18:56:34 2023 +0100 [ADD] LocalConsole showing STDOUT and STDERR commitc46a50ec58Author: Fabian Thies <git@fabian-thies.de> Date: Sat Feb 4 14:35:58 2023 +0100 [FIX] App compatibility info commitde7e909c01Author: Fabian Thies <git@fabian-thies.de> Date: Sat Feb 4 14:29:02 2023 +0100 [ADD] Debug entries for refresh attempts, sending feedback, advanced settings, and resetting the pairing file commitfbc754d8b7Author: Fabian Thies <git@fabian-thies.de> Date: Sat Feb 4 13:07:04 2023 +0100 [ADD] Error log view commit767d878051Author: Fabian Thies <git@fabian-thies.de> Date: Sat Feb 4 12:55:25 2023 +0100 [FIX] Various UI issues commit132b140af2Author: Fabian Thies <git@fabian-thies.de> Date: Sat Feb 4 12:46:43 2023 +0100 [ADD] App report button and trusted source badge in app detail view commitdf7d8871ffAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri Feb 3 18:19:07 2023 +0100 [FIX] AppIDsView and authentication workflow commitca2398e4c7Author: Fabian Thies <git@fabian-thies.de> Date: Fri Feb 3 18:16:48 2023 +0100 [FIX] Full screen app screenshot previews commitb8f02d2152Author: Fabian Thies <git@fabian-thies.de> Date: Fri Feb 3 14:58:06 2023 +0100 [FIX] Accent color commite85876cd24Author: Fabian Thies <git@fabian-thies.de> Date: Tue Jan 31 22:38:42 2023 +0100 [CHANGE] Overhaul of the AppDetailView with version history, reviews & ratings, and app information commit3f06a53058Author: Fabian Thies <git@fabian-thies.de> Date: Tue Jan 31 22:37:37 2023 +0100 [UPDATE] AppPillButton dimensions and expiration text commit4ee053a4f9Author: Fabian Thies <git@fabian-thies.de> Date: Tue Jan 31 22:35:09 2023 +0100 [FIX] Show App IDs button only if user is logged in with their Apple ID commite5369524ceAuthor: Fabian Thies <git@fabian-thies.de> Date: Tue Jan 31 22:32:11 2023 +0100 [ADD] Load and show trusted sources with option to add them to the app commit77465cebd0Author: Fabian Thies <git@fabian-thies.de> Date: Tue Jan 31 22:30:21 2023 +0100 [ADD] Credits section in SettingsView commitf90bf3bfcfAuthor: Fabian Thies <git@fabian-thies.de> Date: Mon Jan 16 21:23:16 2023 +0100 [CHANGE] Extracted all strings into the Localizable.strings commit0000610b9dAuthor: Fabian Thies <git@fabian-thies.de> Date: Mon Jan 16 19:03:33 2023 +0100 [FIX] Text alignment in SettingsView commitc7e095583dAuthor: Fabian Thies <git@fabian-thies.de> Date: Mon Jan 16 19:02:58 2023 +0100 [ADD] Hint for new users who don't have any sources commita725f3e9ccAuthor: Fabian Thies <git@fabian-thies.de> Date: Mon Jan 16 18:59:39 2023 +0100 [ADD] AppScreenshot view with ImageProcessor to automatically rotate landscape screenshots commitb5dea18073Author: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 13:37:38 2023 +0100 [FIX] Issues introduced by changes to the AltSource specification. commitb9b309e603Author: Fabian Thies <github@fabian-thies.de> Date: Fri Jan 13 12:48:27 2023 +0100 [UPDATE] Translations (#7) This PR merges all the new translations made on the SideStore weblate instance (https://translate.sidestore.io/projects/sidestore/app). New translations: - French - Korean Updated translations: - Spanish Co-authored-by: bogotesr <bogotesr@gmail.com> Co-authored-by: GABO1423 <35014183+GABO1423@users.noreply.github.com> Co-authored-by: Joss Laymon <71040782+bogotesr@users.noreply.github.com> Co-authored-by: mindfreakdev <shost212@gmail.com> Co-authored-by: Python <rjp2030@proton.me> Co-authored-by: Testi Cules <ervd516@gmail.com> commit15f1be0aa8Author: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 12:25:50 2023 +0100 [FIX] Changes made by Xcode 14 after building the app commitffd80ce0b4Author: Upal <shost212@gmail.com> Date: Mon Dec 26 19:18:33 2022 +0530 Added Hindi Language (#5) * Added Hindi Language commit350891ee2aAuthor: mindfreakdev <shost212@gmail.com> Date: Sun Dec 25 16:52:01 2022 +0530 Added Dutch Language commit5dec1cd561Author: mindfreakdev <shost212@gmail.com> Date: Sun Dec 25 12:30:42 2022 +0530 Added Ukrainian Language commitc4d235d742Author: mindfreakdev <shost212@gmail.com> Date: Sun Dec 25 12:28:00 2022 +0530 Added Ukrainian Language commitcdc6675dd5Author: Gabriel Morazán <35014183+GABO1423@users.noreply.github.com> Date: Sun Dec 25 01:08:47 2022 -0400 Screen Crunch sucks Signed-off-by: Gabriel Morazán <35014183+GABO1423@users.noreply.github.com> commit85635bb26eAuthor: GABO1423 <35014183+GABO1423@users.noreply.github.com> Date: Sun Dec 25 00:58:22 2022 -0400 Spanish Translation Tweaks commit3be0a4a89cAuthor: bogotesr <bogotesr@gmail.com> Date: Sat Dec 24 21:06:28 2022 -0700 Add es-419 and finish adding support for the translations Added Latin American Spanish (probably not the best translation) Made everything reference the swiftgen stuff rather than having strings commit47e47fb3cfAuthor: Fabian Thies <git@fabian-thies.de> Date: Thu Dec 22 10:29:57 2022 +0100 [CHANGE] Extracted some example strings and replaced them by generated localized strings commit48903034b6Author: Fabian Thies <git@fabian-thies.de> Date: Thu Dec 22 10:21:57 2022 +0100 [ADD] SwiftGen configuration and generated files commit6952218ee7Author: Fabian Thies <git@fabian-thies.de> Date: Thu Dec 22 10:10:58 2022 +0100 [ADD] Empty Localizable.strings commit80146c1e03Author: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 12:04:10 2023 +0100 [WIP] AppScreenshot view with ImageProcessor to automatically rotate landscape images. Possible through my fork of the AsyncImage framework. commit642ae996c9Author: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 12:02:56 2023 +0100 [WIP] Fetch trusted sources in SourcesView commit8040636aa5Author: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 12:02:06 2023 +0100 [WIP] AppIDs view in My Apps section commit731fcfaca7Author: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 12:00:00 2023 +0100 [ADD] Badge in AppDetailView for apps from the official source and (WIP) trusted sources commit708fb3fccdAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 11:58:25 2023 +0100 [ADD] Hint view in MyAppsView telling the user about where to find updates in the future if no updates are available commit9f429fb068Author: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 11:54:44 2023 +0100 [FIX] App permission icon color commit29fc693f4dAuthor: Fabian Thies <git@fabian-thies.de> Date: Fri Jan 13 11:51:06 2023 +0100 [ADD] Show source name and external url domain in NewsItemView commit6f373ad305Author: Fabian Thies <git@fabian-thies.de> Date: Fri Dec 23 16:02:57 2022 +0100 [ADD] Full-screen app screenshot preview commitc069d779d9Author: Fabian Thies <git@fabian-thies.de> Date: Fri Dec 23 15:21:16 2022 +0100 [CHANGE] Replace system image name strings with SFSymbols commitcd88970a22Author: Fabian Thies <git@fabian-thies.de> Date: Fri Dec 23 13:12:39 2022 +0100 [ADD] Dependency: SFSafeSymbols commit6b6708e43cAuthor: Fabian Thies <git@fabian-thies.de> Date: Wed Dec 21 17:49:49 2022 +0100 [ADD] WIP: Promoted category cards and app list filter button in BrowseView commit9206eeb9e3Author: Fabian Thies <git@fabian-thies.de> Date: Wed Dec 21 17:48:45 2022 +0100 [FIX] AccentColor in dark mode commit080bbb3c51Author: Fabian Thies <git@fabian-thies.de> Date: Wed Dec 21 17:48:23 2022 +0100 [ADD] Carousel for SideStore-specific announcements in NewsView commitea2c862900Author: Fabian Thies <git@fabian-thies.de> Date: Wed Dec 21 17:45:44 2022 +0100 [ADD] WIP: Add My Apps view with support for sideloading new apps, refreshing installed apps and much more commit4fe72ea113Author: Fabian Thies <git@fabian-thies.de> Date: Mon Dec 12 19:20:54 2022 +0100 [CHANGE] Fixed the AppRowView background blur effect commitc486a62b50Author: Fabian Thies <git@fabian-thies.de> Date: Mon Dec 12 19:20:10 2022 +0100 [ADD] Backported dismiss() environment variable to let views dismiss themselves commit3ce4451da4Author: Fabian Thies <git@fabian-thies.de> Date: Mon Dec 12 19:18:57 2022 +0100 [ADD] Search bar for BrowseView on iOS 15 commit294ba12391Author: Fabian Thies <git@fabian-thies.de> Date: Mon Dec 12 19:16:36 2022 +0100 [CHANGE] Fetch news when NewsView appears commit4a3343fe61Author: Fabian Thies <git@fabian-thies.de> Date: Mon Dec 12 19:15:16 2022 +0100 Improved app detail view commitd1e6ddd435Author: Fabian Thies <git@fabian-thies.de> Date: Mon Dec 12 19:12:38 2022 +0100 [ADD] Authentication view for connecting SideStore to an Apple ID commit3e0379dc70Author: Fabian Thies <git@fabian-thies.de> Date: Sun Nov 27 16:41:30 2022 +0100 [WIP] Fixed the app permissions grid in AppDetailView commitd99674f8bdAuthor: Fabian Thies <git@fabian-thies.de> Date: Sun Nov 27 16:17:08 2022 +0100 [ADD] Expandable app and version description texts commitca7acc17daAuthor: Fabian Thies <git@fabian-thies.de> Date: Sun Nov 27 00:26:15 2022 +0100 [ADD] iOS 13 compatible AsyncImage implementation with cache commit16a8bce102Author: Fabian Thies <git@fabian-thies.de> Date: Wed Nov 23 22:34:02 2022 +0100 [ADD] News, Browse and Settings views ported to SwiftUI This commit contains WIP SwiftUI versions of most of the views in SideStore.
This commit is contained in:
54
AltStore/Views/My Apps/AppAction.swift
Normal file
54
AltStore/Views/My Apps/AppAction.swift
Normal file
@@ -0,0 +1,54 @@
|
||||
//
|
||||
// AppAction.swift
|
||||
// SideStore
|
||||
//
|
||||
// Created by Fabian Thies on 20.12.22.
|
||||
// Copyright © 2022 SideStore. All rights reserved.
|
||||
//
|
||||
|
||||
import Foundation
|
||||
import SFSafeSymbols
|
||||
|
||||
enum AppAction: Int, CaseIterable {
|
||||
case install, open, refresh
|
||||
case activate, deactivate
|
||||
case remove
|
||||
case enableJIT
|
||||
case backup, exportBackup, restoreBackup
|
||||
case chooseCustomIcon, resetCustomIcon
|
||||
|
||||
|
||||
var title: String {
|
||||
switch self {
|
||||
case .install: return L10n.AppAction.install
|
||||
case .open: return L10n.AppAction.open
|
||||
case .refresh: return L10n.AppAction.refresh
|
||||
case .activate: return L10n.AppAction.activate
|
||||
case .deactivate: return L10n.AppAction.deactivate
|
||||
case .remove: return L10n.AppAction.remove
|
||||
case .enableJIT: return L10n.AppAction.enableJIT
|
||||
case .backup: return L10n.AppAction.backup
|
||||
case .exportBackup: return L10n.AppAction.exportBackup
|
||||
case .restoreBackup: return L10n.AppAction.restoreBackup
|
||||
case .chooseCustomIcon: return L10n.AppAction.chooseCustomIcon
|
||||
case .resetCustomIcon: return L10n.AppAction.resetIcon
|
||||
}
|
||||
}
|
||||
|
||||
var symbol: SFSymbol {
|
||||
switch self {
|
||||
case .install: return .squareAndArrowDown
|
||||
case .open: return .arrowUpForwardApp
|
||||
case .refresh: return .arrowClockwise
|
||||
case .activate: return .checkmarkCircle
|
||||
case .deactivate: return .xmarkCircle
|
||||
case .remove: return .trash
|
||||
case .enableJIT: return .bolt
|
||||
case .backup: return .docOnDoc
|
||||
case .exportBackup: return .arrowUpDoc
|
||||
case .restoreBackup: return .arrowDownDoc
|
||||
case .chooseCustomIcon: return .photo
|
||||
case .resetCustomIcon: return .arrowUturnLeft
|
||||
}
|
||||
}
|
||||
}
|
||||
119
AltStore/Views/My Apps/AppIDsView.swift
Normal file
119
AltStore/Views/My Apps/AppIDsView.swift
Normal file
@@ -0,0 +1,119 @@
|
||||
//
|
||||
// AppIDsView.swift
|
||||
// SideStore
|
||||
//
|
||||
// Created by Fabian Thies on 23.12.22.
|
||||
// Copyright © 2022 SideStore. All rights reserved.
|
||||
//
|
||||
|
||||
import SwiftUI
|
||||
import AltStoreCore
|
||||
|
||||
struct AppIDsView: View {
|
||||
|
||||
@Environment(\.dismiss) var dismiss
|
||||
|
||||
@SwiftUI.FetchRequest(sortDescriptors: [
|
||||
NSSortDescriptor(keyPath: \AppID.name, ascending: true),
|
||||
NSSortDescriptor(keyPath: \AppID.bundleIdentifier, ascending: true),
|
||||
NSSortDescriptor(keyPath: \AppID.expirationDate, ascending: true)
|
||||
], predicate: NSPredicate(format: "%K == %@", #keyPath(AppID.team), DatabaseManager.shared.activeTeam() ?? Team()))
|
||||
var appIDs: FetchedResults<AppID>
|
||||
|
||||
@State var isLoading: Bool = false
|
||||
|
||||
|
||||
var body: some View {
|
||||
ScrollView {
|
||||
LazyVStack(alignment: .leading) {
|
||||
Text(L10n.AppIDsView.description)
|
||||
.foregroundColor(.secondary)
|
||||
|
||||
ForEach(appIDs, id: \.identifier) { appId in
|
||||
HStack {
|
||||
VStack(alignment: .leading) {
|
||||
Text(appId.name)
|
||||
.bold()
|
||||
|
||||
Text(appId.bundleIdentifier)
|
||||
.font(.footnote)
|
||||
.foregroundColor(.secondary)
|
||||
}
|
||||
|
||||
Spacer()
|
||||
|
||||
if let expirationDate = appId.expirationDate {
|
||||
VStack(spacing: 4) {
|
||||
Text("Expires in")
|
||||
.font(.caption)
|
||||
.foregroundColor(.accentColor)
|
||||
|
||||
SwiftUI.Button {
|
||||
|
||||
} label: {
|
||||
Text(DateFormatterHelper.string(forExpirationDate: expirationDate).uppercased())
|
||||
.bold()
|
||||
}
|
||||
.buttonStyle(PillButtonStyle(tintColor: .altPrimary))
|
||||
.disabled(true)
|
||||
}
|
||||
}
|
||||
}
|
||||
.padding()
|
||||
.tintedBackground(.accentColor)
|
||||
.clipShape(RoundedRectangle(cornerRadius: 24, style: .circular))
|
||||
}
|
||||
}
|
||||
.padding()
|
||||
}
|
||||
.navigationTitle(L10n.AppIDsView.title)
|
||||
.toolbar {
|
||||
ToolbarItem(placement: .cancellationAction) {
|
||||
if self.isLoading {
|
||||
ProgressView()
|
||||
.progressViewStyle(.circular)
|
||||
}
|
||||
}
|
||||
|
||||
ToolbarItem(placement: .confirmationAction) {
|
||||
SwiftUI.Button(L10n.Action.done, action: self.dismiss)
|
||||
}
|
||||
}
|
||||
.onAppear(performAsync: self.updateAppIDs)
|
||||
}
|
||||
|
||||
|
||||
func updateAppIDs() async {
|
||||
self.isLoading = true
|
||||
defer { self.isLoading = false }
|
||||
|
||||
await withCheckedContinuation { continuation in
|
||||
AppManager.shared.fetchAppIDs { result in
|
||||
do {
|
||||
let (_, context) = try result.get()
|
||||
try context.save()
|
||||
} catch {
|
||||
print(error)
|
||||
NotificationManager.shared.reportError(error: error)
|
||||
}
|
||||
|
||||
continuation.resume()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
extension View {
|
||||
|
||||
func onAppear(performAsync task: @escaping () async -> Void) -> some View {
|
||||
self.onAppear(perform: { Task { await task() } })
|
||||
}
|
||||
}
|
||||
|
||||
struct AppIDsView_Previews: PreviewProvider {
|
||||
static var previews: some View {
|
||||
NavigationView {
|
||||
AppIDsView()
|
||||
}
|
||||
}
|
||||
}
|
||||
437
AltStore/Views/My Apps/MyAppsView.swift
Normal file
437
AltStore/Views/My Apps/MyAppsView.swift
Normal file
@@ -0,0 +1,437 @@
|
||||
//
|
||||
// MyAppsView.swift
|
||||
// SideStoreUI
|
||||
//
|
||||
// Created by Fabian Thies on 18.11.22.
|
||||
// Copyright © 2022 Fabian Thies. All rights reserved.
|
||||
//
|
||||
|
||||
import SwiftUI
|
||||
import SFSafeSymbols
|
||||
import MobileCoreServices
|
||||
import AltStoreCore
|
||||
|
||||
struct MyAppsView: View {
|
||||
|
||||
// TODO: Refactor
|
||||
@SwiftUI.FetchRequest(sortDescriptors: [
|
||||
NSSortDescriptor(keyPath: \InstalledApp.storeApp?.latestVersion?.date, ascending: true),
|
||||
NSSortDescriptor(keyPath: \InstalledApp.name, ascending: true)
|
||||
], predicate: NSPredicate(format: "%K == YES AND %K != nil AND %K != %K",
|
||||
#keyPath(InstalledApp.isActive), #keyPath(InstalledApp.storeApp),
|
||||
#keyPath(InstalledApp.version), #keyPath(InstalledApp.storeApp.latestVersion.version))
|
||||
)
|
||||
var updates: FetchedResults<InstalledApp>
|
||||
|
||||
|
||||
@SwiftUI.FetchRequest(sortDescriptors: [
|
||||
NSSortDescriptor(keyPath: \InstalledApp.expirationDate, ascending: true),
|
||||
NSSortDescriptor(keyPath: \InstalledApp.refreshedDate, ascending: false),
|
||||
NSSortDescriptor(keyPath: \InstalledApp.name, ascending: true)
|
||||
], predicate: NSPredicate(format: "%K == YES", #keyPath(InstalledApp.isActive)))
|
||||
var activeApps: FetchedResults<InstalledApp>
|
||||
|
||||
@AppStorage("shouldShowAppUpdateHint")
|
||||
var shouldShowAppUpdateHint: Bool = true
|
||||
|
||||
@ObservedObject
|
||||
var viewModel = MyAppsViewModel()
|
||||
|
||||
// TODO: Refactor
|
||||
@State var isRefreshingAllApps: Bool = false
|
||||
@State var selectedSideloadingIpaURL: URL?
|
||||
|
||||
var remainingAppIDs: Int {
|
||||
guard let team = DatabaseManager.shared.activeTeam() else {
|
||||
return 0
|
||||
}
|
||||
|
||||
let maximumAppIDCount = 10
|
||||
return max(maximumAppIDCount - team.appIDs.count, 0)
|
||||
}
|
||||
|
||||
// TODO: Refactor
|
||||
let sideloadFileTypes: [String] = {
|
||||
if let types = UTTypeCreateAllIdentifiersForTag(kUTTagClassFilenameExtension, "ipa" as CFString, nil)?.takeRetainedValue()
|
||||
{
|
||||
return (types as NSArray).map { $0 as! String }
|
||||
}
|
||||
else
|
||||
{
|
||||
return ["com.apple.itunes.ipa"] // Declared by the system.
|
||||
}
|
||||
}()
|
||||
|
||||
|
||||
var body: some View {
|
||||
ScrollView {
|
||||
LazyVStack(spacing: 16) {
|
||||
if let progress = SideloadingManager.shared.progress {
|
||||
VStack {
|
||||
Text(L10n.MyAppsView.sideloading)
|
||||
.padding()
|
||||
|
||||
ProgressView(progress)
|
||||
.progressViewStyle(LinearProgressViewStyle())
|
||||
}
|
||||
.background(Color(UIColor.secondarySystemBackground))
|
||||
}
|
||||
|
||||
if updates.isEmpty {
|
||||
if shouldShowAppUpdateHint {
|
||||
updatesSection
|
||||
}
|
||||
}
|
||||
|
||||
HStack {
|
||||
Text(L10n.MyAppsView.active)
|
||||
.font(.title2)
|
||||
.bold()
|
||||
|
||||
Spacer()
|
||||
|
||||
if !self.isRefreshingAllApps {
|
||||
SwiftUI.Button(L10n.MyAppsView.refreshAll, action: self.refreshAllApps)
|
||||
} else {
|
||||
ProgressView()
|
||||
.progressViewStyle(CircularProgressViewStyle())
|
||||
}
|
||||
}
|
||||
|
||||
ForEach(activeApps, id: \.bundleIdentifier) { app in
|
||||
|
||||
if let storeApp = app.storeApp {
|
||||
NavigationLink {
|
||||
AppDetailView(storeApp: storeApp)
|
||||
} label: {
|
||||
self.rowView(for: app)
|
||||
}
|
||||
.buttonStyle(PlainButtonStyle())
|
||||
} else {
|
||||
self.rowView(for: app)
|
||||
}
|
||||
}
|
||||
|
||||
if let activeTeam = DatabaseManager.shared.activeTeam() {
|
||||
VStack {
|
||||
if activeTeam.type == .free {
|
||||
Text("\(remainingAppIDs) \(L10n.MyAppsView.appIDsRemaining)")
|
||||
.foregroundColor(.secondary)
|
||||
}
|
||||
|
||||
ModalNavigationLink(L10n.MyAppsView.viewAppIDs) {
|
||||
NavigationView {
|
||||
AppIDsView()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.padding(.horizontal)
|
||||
}
|
||||
.background(Color(UIColor.systemGroupedBackground).ignoresSafeArea())
|
||||
.navigationTitle(L10n.MyAppsView.myApps)
|
||||
.toolbar {
|
||||
ToolbarItem(placement: .navigationBarLeading) {
|
||||
ModalNavigationLink {
|
||||
DocumentPicker(selectedUrl: $selectedSideloadingIpaURL, supportedTypes: sideloadFileTypes)
|
||||
.ignoresSafeArea()
|
||||
} label: {
|
||||
Image(systemSymbol: .plus)
|
||||
.imageScale(.large)
|
||||
}
|
||||
.onChange(of: self.selectedSideloadingIpaURL) { newValue in
|
||||
guard let url = newValue else {
|
||||
return
|
||||
}
|
||||
|
||||
self.sideloadApp(at: url)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
var updatesSection: some View {
|
||||
HintView {
|
||||
HStack(alignment: .center) {
|
||||
Text(L10n.MyAppsView.Hints.NoUpdates.title)
|
||||
.bold()
|
||||
Spacer()
|
||||
|
||||
Menu {
|
||||
SwiftUI.Button {
|
||||
self.dismissUpdatesHint(forever: false)
|
||||
} label: {
|
||||
Label(L10n.MyAppsView.Hints.NoUpdates.dismissForNow, systemSymbol: .zzz)
|
||||
}
|
||||
|
||||
SwiftUI.Button {
|
||||
self.dismissUpdatesHint(forever: true)
|
||||
} label: {
|
||||
Label(L10n.MyAppsView.Hints.NoUpdates.dontShowAgain, systemSymbol: .xmark)
|
||||
}
|
||||
} label: {
|
||||
Image(systemSymbol: .xmark)
|
||||
}
|
||||
.foregroundColor(.secondary)
|
||||
}
|
||||
|
||||
Text(L10n.MyAppsView.Hints.NoUpdates.text)
|
||||
.font(.callout)
|
||||
.foregroundColor(.secondary)
|
||||
}
|
||||
}
|
||||
|
||||
@ViewBuilder
|
||||
func rowView(for app: AppProtocol) -> some View {
|
||||
AppRowView(app: app, showRemainingDays: true)
|
||||
.contextMenu(ContextMenu(menuItems: {
|
||||
ForEach(self.actions(for: app), id: \.self) { action in
|
||||
SwiftUI.Button {
|
||||
self.perform(action: action, for: app)
|
||||
} label: {
|
||||
Label(action.title, systemSymbol: action.symbol)
|
||||
}
|
||||
}
|
||||
}))
|
||||
}
|
||||
|
||||
func refreshAllApps() {
|
||||
let installedApps = InstalledApp.fetchAppsForRefreshingAll(in: DatabaseManager.shared.viewContext)
|
||||
|
||||
self.isRefreshingAllApps = true
|
||||
self.refresh(installedApps) { result in
|
||||
self.isRefreshingAllApps = false
|
||||
}
|
||||
}
|
||||
|
||||
func dismissUpdatesHint(forever: Bool) {
|
||||
withAnimation {
|
||||
self.shouldShowAppUpdateHint = false
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
extension MyAppsView {
|
||||
// TODO: Convert to async?
|
||||
func refresh(_ apps: [InstalledApp], completionHandler: @escaping ([String : Result<InstalledApp, Error>]) -> Void) {
|
||||
let group = AppManager.shared.refresh(apps, presentingViewController: nil, group: self.viewModel.refreshGroup)
|
||||
|
||||
group.completionHandler = { results in
|
||||
DispatchQueue.main.async {
|
||||
let failures = results.compactMapValues { result -> Error? in
|
||||
switch result {
|
||||
case .failure(OperationError.cancelled):
|
||||
return nil
|
||||
case .failure(let error):
|
||||
return error
|
||||
case .success:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
|
||||
guard !failures.isEmpty else { return }
|
||||
|
||||
if let failure = failures.first, results.count == 1 {
|
||||
NotificationManager.shared.reportError(error: failure.value)
|
||||
} else {
|
||||
// TODO: Localize
|
||||
let title = "\(L10n.MyAppsView.failedToRefresh) \(failures.count) \(L10n.MyAppsView.apps)"
|
||||
|
||||
let error = failures.first?.value as NSError?
|
||||
let message = error?.localizedFailure ?? error?.localizedFailureReason ?? error?.localizedDescription
|
||||
|
||||
NotificationManager.shared.showNotification(title: title, detailText: message)
|
||||
}
|
||||
|
||||
self.viewModel.refreshGroup = nil
|
||||
completionHandler(results)
|
||||
}
|
||||
}
|
||||
|
||||
self.viewModel.refreshGroup = group
|
||||
}
|
||||
}
|
||||
|
||||
extension MyAppsView {
|
||||
func actions(for app: AppProtocol) -> [AppAction] {
|
||||
guard let installedApp = app as? InstalledApp else {
|
||||
return []
|
||||
}
|
||||
|
||||
guard installedApp.bundleIdentifier != StoreApp.altstoreAppID else {
|
||||
return [.refresh]
|
||||
}
|
||||
|
||||
var actions: [AppAction] = []
|
||||
|
||||
if installedApp.isActive {
|
||||
actions.append(.open)
|
||||
actions.append(.refresh)
|
||||
actions.append(.enableJIT)
|
||||
} else {
|
||||
actions.append(.activate)
|
||||
}
|
||||
|
||||
actions.append(.chooseCustomIcon)
|
||||
if installedApp.hasAlternateIcon {
|
||||
actions.append(.resetCustomIcon)
|
||||
}
|
||||
|
||||
if installedApp.isActive {
|
||||
actions.append(.backup)
|
||||
} else if let _ = UTTypeCopyDeclaration(installedApp.installedAppUTI as CFString)?.takeRetainedValue() as NSDictionary?, !UserDefaults.standard.isLegacyDeactivationSupported {
|
||||
// Allow backing up inactive apps if they are still installed,
|
||||
// but on an iOS version that no longer supports legacy deactivation.
|
||||
// This handles edge case where you can't install more apps until you
|
||||
// delete some, but can't activate inactive apps again to back them up first.
|
||||
actions.append(.backup)
|
||||
}
|
||||
|
||||
if let backupDirectoryURL = FileManager.default.backupDirectoryURL(for: installedApp) {
|
||||
|
||||
// TODO: Refactor
|
||||
var backupExists = false
|
||||
var outError: NSError? = nil
|
||||
|
||||
let coordinator = NSFileCoordinator()
|
||||
coordinator.coordinate(readingItemAt: backupDirectoryURL, options: [.withoutChanges], error: &outError) { (backupDirectoryURL) in
|
||||
backupExists = FileManager.default.fileExists(atPath: backupDirectoryURL.path)
|
||||
}
|
||||
|
||||
if backupExists {
|
||||
actions.append(.exportBackup)
|
||||
|
||||
if installedApp.isActive {
|
||||
actions.append(.restoreBackup)
|
||||
}
|
||||
} else if let error = outError {
|
||||
print("Unable to check if backup exists:", error)
|
||||
}
|
||||
}
|
||||
|
||||
if installedApp.isActive {
|
||||
actions.append(.deactivate)
|
||||
}
|
||||
|
||||
if installedApp.bundleIdentifier != StoreApp.altstoreAppID {
|
||||
actions.append(.remove)
|
||||
}
|
||||
|
||||
return actions
|
||||
}
|
||||
|
||||
func perform(action: AppAction, for app: AppProtocol) {
|
||||
guard let installedApp = app as? InstalledApp else {
|
||||
// Invalid state.
|
||||
return
|
||||
}
|
||||
|
||||
switch action {
|
||||
case .install: break
|
||||
case .open: self.open(installedApp)
|
||||
case .refresh: self.refresh(installedApp)
|
||||
case .activate: self.activate(installedApp)
|
||||
case .deactivate: self.deactivate(installedApp)
|
||||
case .remove: self.remove(installedApp)
|
||||
case .enableJIT: self.enableJIT(for: installedApp)
|
||||
case .backup: self.backup(installedApp)
|
||||
case .exportBackup: self.exportBackup(installedApp)
|
||||
case .restoreBackup: self.restoreBackup(installedApp)
|
||||
case .chooseCustomIcon: self.chooseIcon(for: installedApp)
|
||||
case .resetCustomIcon: self.resetIcon(for: installedApp)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
func open(_ app: InstalledApp) {
|
||||
UIApplication.shared.open(app.openAppURL) { success in
|
||||
guard !success else { return }
|
||||
|
||||
NotificationManager.shared.reportError(error: OperationError.openAppFailed(name: app.name))
|
||||
}
|
||||
}
|
||||
|
||||
func refresh(_ app: InstalledApp) {
|
||||
let previousProgress = AppManager.shared.refreshProgress(for: app)
|
||||
guard previousProgress == nil else {
|
||||
previousProgress?.cancel()
|
||||
return
|
||||
}
|
||||
|
||||
self.refresh([app]) { (results) in
|
||||
print("Finished refreshing with results:", results.map { ($0, $1.error?.localizedDescription ?? "success") })
|
||||
}
|
||||
}
|
||||
|
||||
func activate(_ app: InstalledApp) {
|
||||
|
||||
}
|
||||
|
||||
func deactivate(_ app: InstalledApp) {
|
||||
|
||||
}
|
||||
|
||||
func remove(_ app: InstalledApp) {
|
||||
|
||||
}
|
||||
|
||||
func enableJIT(for app: InstalledApp) {
|
||||
AppManager.shared.enableJIT(for: app) { result in
|
||||
switch result {
|
||||
case .success:
|
||||
break
|
||||
case .failure(let error):
|
||||
NotificationManager.shared.reportError(error: error)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func backup(_ app: InstalledApp) {
|
||||
|
||||
}
|
||||
|
||||
func exportBackup(_ app: InstalledApp) {
|
||||
|
||||
}
|
||||
|
||||
func restoreBackup(_ app: InstalledApp) {
|
||||
|
||||
}
|
||||
|
||||
func chooseIcon(for app: InstalledApp) {
|
||||
|
||||
}
|
||||
|
||||
func resetIcon(for app: InstalledApp) {
|
||||
|
||||
}
|
||||
|
||||
func setIcon(for app: InstalledApp, to image: UIImage? = nil) {
|
||||
|
||||
}
|
||||
|
||||
func sideloadApp(at url: URL) {
|
||||
SideloadingManager.shared.sideloadApp(at: url) { result in
|
||||
switch result {
|
||||
case .success:
|
||||
print("App sideloaded successfully.")
|
||||
case .failure(let error):
|
||||
print("Failed to sideload app: \(error.localizedDescription)")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
struct MyAppsView_Previews: PreviewProvider {
|
||||
|
||||
static let context = DatabaseManager.shared.viewContext
|
||||
static let app = StoreApp.makeAltStoreApp(in: context)
|
||||
|
||||
static var previews: some View {
|
||||
NavigationView {
|
||||
MyAppsView()
|
||||
}
|
||||
}
|
||||
}
|
||||
16
AltStore/Views/My Apps/MyAppsViewModel.swift
Normal file
16
AltStore/Views/My Apps/MyAppsViewModel.swift
Normal file
@@ -0,0 +1,16 @@
|
||||
//
|
||||
// MyAppsViewModel.swift
|
||||
// SideStore
|
||||
//
|
||||
// Created by Fabian Thies on 13.12.22.
|
||||
// Copyright © 2022 SideStore. All rights reserved.
|
||||
//
|
||||
|
||||
import SwiftUI
|
||||
import AltStoreCore
|
||||
|
||||
class MyAppsViewModel: ViewModel {
|
||||
|
||||
var refreshGroup: RefreshGroup?
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user