-
-
Notifications
You must be signed in to change notification settings - Fork 195
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
#796: Add a button to sort files on "Manage your files" screen #946
#796: Add a button to sort files on "Manage your files" screen #946
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's an issue with the callbacks from the rows, I'm not getting the alert shown when tapping them (see video)
RPReplay_Final1688221466.MP4
Other than that and the details label sizes I mentioned in my other comment, this is a great step forward in the SwiftUI migration process 🥳 ! also, good call on making the delete and fix icons a bit bigger, they're much easier to tap now
.foregroundColor(themeViewModel.primaryColor) | ||
|
||
Text(item.path) | ||
.font(.subheadline) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this .subheadline
and the next one, needs to be a bit smaller, to emulate what we have on the library cells
Interesting 🤔 It worked initially. I’ll try to fix it tomorrow |
@GianniCarlo I've pushed the fix. In which I've learned that SwiftUI has some troubles handling multiple Finding number 2: SwiftUI defines some data type Finding number 3: when deleting files from Storage Management, it can leave "empty" LibraryItem in the DB, which shows in the Library, but cannot be played. I think this should be fixed, and I will submit it in the separate PR |
97ecd4b
to
8ee2884
Compare
8ee2884
to
5bd7433
Compare
I'll take a look at the new changes in the morning, I got held up today by trying to figure out why Realm was not compiling, and it was because of the build setting |
Purpose
Requested enhancement to add sort option in Storage Management screen. Current sort options are Size (default), and Title. Further options can be added (full path, creation date etc.)
Related tasks
#796
Approach
Initially, rewrite entire screen to SwiftUI. Correspondently, update ViewModel, Coordinator and Tests. Delete StorageViewController, StorageTableViewCell and unused StoryBoard Scenes.
Then, add a sort button similar to that in Library, which shows Picker with sort options: Size (default), and Title. After selecting new option, ViewModel re-sorts files and stores the selection in UserDefaults.
Things to be aware of / Things to focus on
Translation for one of the sort option ("Size") is missing. There is a "TODO" comment in
StorageView
about itScreenshots