-
-
Notifications
You must be signed in to change notification settings - Fork 1
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
Improve ContactList layout and improve subtitle line breaking #18
Conversation
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #18 +/- ##
==========================================
+ Coverage 80.07% 81.23% +1.17%
==========================================
Files 5 4 -1
Lines 311 309 -2
==========================================
+ Hits 249 251 +2
+ Misses 62 58 -4
Continue to review full report in Codecov by Sentry.
|
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.
Thank you for the great improvements; this looks great @Supereg! 🚀
Will tag the new SpeziViews later on and still include it in this PR. |
This looks much better! Thank you @Supereg! |
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.
👍🚀
# Fix dark mode appearance ## ♻️ Current situation & Problem This PR fixes appearance in dark mode. Due to refactorings to lists in #18, we know have to adapt to different backgrounds (e.g., placed directly into a view, placed into a grouped background view, like a List cell). This was primarily an issue as we used a background color instead of a fill color (see [tertiarySystemFill](https://developer.apple.com/documentation/uikit/uicolor/3255076-tertiarysystemfill) being recommended for buttons and compare to [secondarySystemBackground](https://developer.apple.com/documentation/uikit/uicolor/3173137-secondarysystembackground) which we previously used). ## ⚙️ Release Notes * Fixes appearance in light background when appearing in Lists. ## 📚 Documentation -- ## ✅ Testing -- ## 📝 Code of Conduct & Contributing Guidelines By submitting creating this pull request, you agree to follow our [Code of Conduct](https://github.com/StanfordSpezi/.github/blob/main/CODE_OF_CONDUCT.md) and [Contributing Guidelines](https://github.com/StanfordSpezi/.github/blob/main/CONTRIBUTING.md): - [x] I agree to follow the [Code of Conduct](https://github.com/StanfordSpezi/.github/blob/main/CODE_OF_CONDUCT.md) and [Contributing Guidelines](https://github.com/StanfordSpezi/.github/blob/main/CONTRIBUTING.md).
Improve ContactList layout and improve subtitle line breaking
♻️ Current situation & Problem
Currently, the
ContactsList
view is built using a custom ScrollView implementation and drawing custom backgrounds with shades around theContactView
s. This doesn't really feel native on iOS. Instead, this PR rethinks the implementation by rebuilding theContactsList
view using SwiftUI standard components likeList
. This makes theContactsList
now feel right at home.Further, previously the subtitle, consisting of the Person's title and organization, was built using multiple distinct
Text
instances. This caused problems when the text was longer than the view was capable of displaying. This PR ensures that a persons title and organization are combined into a singleText
view and allows to to wrap into a second line.Lastly, this PR migrates the PR to use String catalogs, optimizes key naming and bumps the target to iOS 17.
Below are two screenshots comparing the previous implementation to the updated one.
⚙️ Release Notes
ContactsView
that feel way more native to iOS📚 Documentation
--
✅ Testing
Tests were slightly adjusted, due to issues with line breaks in the labels.
📝 Code of Conduct & Contributing Guidelines
By submitting creating this pull request, you agree to follow our Code of Conduct and Contributing Guidelines: