The previous code incorrectly showed the trending tag usage data twice
next to the end of the trending tag lines, instead of one entry for the
usage data and one entry for the account data.
Fix that.
As part of this fix change how the data is displayed. Instead of using
two distinct `TextView`, fixed to the bottom end of the chart, draw the
text directly on the chart. The text is accurately position so that it
is next to the end of the relevant line. If both lines overlap the label
positions are adjusted appropriately.
The chart now uses Pachli blue and orange for the line colours.
While doing this I discovered that the mechanism used to fall back to
particular chart colours if none were specified was incorrect, so fix
that too.
Previous code could return an error on Friendica version strings like
`2024.03-dev-1547`.
Fix this:
- Extend the list of explicitly supported servers to include Fedibird,
Friendica, Glitch, Hometown, Iceshrimp, Pixelfed, and Sharkey.
- Add version parsing routines for these servers.
- Test the version parsing routines fetching every server and version
seen by Fediverse Observer (~ 2,000 servers) and ensuring that the
server and version information can be parsed.
Improve the error message:
- Show the hostname with a `ServerRepository` error
Clean up the code:
- Remove the custom `resultOf` and `mapResult` functions, they have
equivalents in newer versions of the library (like `runSuspendCatching`)
Fixes#372
Commit 993b7469 inadvertently broke this by removing the @SerializedName
annotation, so the user's display name was always null and the UI fell
back to showing the username.
Fixes#371
The previous code unilaterally enabled filter functionality. Some
Mastodon-like servers -- like GoToSocial -- do not support filters, and
this resulted in user visible error messages when connecting to those
servers.
To fix this:
- Extend the set of supported server capabilities to include client and
server side filtering.
- Disable the filter preferences if the server does not support filters
and show a message explaining why it's disabled.
Extend the capabilities model to support this:
- Fetch server software name and version from the nodeinfo endpoints
(implementing the nodeinfo API and schema)
- Extend the use of kotlin-result to provide hierarchies of Error
classes and demonstrate how to chain errors and display more informative
messages without using exceptions.
Fixes#343
Previously some tests had to manually create dependencies (instead of
injecting them) because the dependency required the `TestScope`
`CoroutineScope` as one of its dependencies.
Resolve this with a `FakeCoroutineScopeModule` that provides `TestScope`
as `@ApplicationScope`. The tests can now inject their dependencies,
which will use `TestScope`.
To inject `AccountPreferenceDataStore` it has been updated to use the
current active account when reading or writing preferences.
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)
This PR contains the following updates:
| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
|
[com.google.android.material:material](https://togithub.com/material-components/material-components-android)
| `1.10.0` -> `1.11.0` |
[![age](https://developer.mend.io/api/mc/badges/age/maven/com.google.android.material:material/1.11.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/com.google.android.material:material/1.11.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/com.google.android.material:material/1.10.0/1.11.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/com.google.android.material:material/1.10.0/1.11.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
---
> [!WARNING]
> Some dependencies could not be looked up. Check the Dependency
Dashboard for more information.
---
### Release Notes
<details>
<summary>material-components/material-components-android
(com.google.android.material:material)</summary>
###
[`v1.11.0`](https://togithub.com/material-components/material-components-android/releases/tag/1.11.0)
[Compare
Source](https://togithub.com/material-components/material-components-android/compare/1.10.0...1.11.0)
### Important
Elevation Overlays within default component styles have been replaced by
the new [Tonal Surface Color
system](https://material.io/blog/tone-based-surface-color-m3). Instead
of blending the Primary color with the Surface color based on an
elevation value, components now use a specific Surface color role that
can be more easily understood and customized.
Documentation for the affected components and which Surface color roles
they use has been updated in
2114a11378.
### What's new since 1.10.0
- New [Tonal Surface Color
system](https://material.io/blog/tone-based-surface-color-m3)! Check out
the [design
guidance](https://material.io/blog/tone-based-surface-color-m3) and the
[commit with documentation
updates](2114a11378)
for more details.
- New Carousel variants! 1.11.0 introduces three new Carousel variants:
center-aligned hero, uncontained, and fullscreen. Check out the
[Carousel
documentation](https://togithub.com/material-components/material-components-android/blob/master/docs/components/Carousel.md)
for more details.
#### Dependency Updates
None.
*Note: Earlier versions of 1.11.0 used other versions of the
`androidx.activity` 1.8.0 library dependency, but there is no change in
the dependency from 1.10.0, the last stable MDC library version.*
#### Library Updates
- `Badging`
- Adjusted badge vertical offset for certain components to fit design
requirements
([`78cc54b`](78cc54b8c3))
- Added note in attachBadgeDrawable method docs about menu item views
being re-used when there is a structural change in the menu. Since
badges are attached to the views, this may change the menu item that the
badge is intended for
([`5e6ea58`](5e6ea58280))
- `BottomNavigationView`
- Set badges to be null instead of removing them from the sparse array
so that removing badges before restoring badge states will not override
the current state
([`9f2e686`](9f2e6864d2))
- `BottomSheet`
- Fix sheet corners animation
([`de27132`](de271320e4))
- `Carousel`
- Ensure that extra small size is not larger than the large size
([`17baf71`](17baf71972))
- Fixed crash when recyclerview has a size of zero.
([`26c3129`](26c3129201))
- When navigating with keyboard, scroll focused item to nearest focal
keyline, not the first focal keyline
([`fb9c1c6`](fb9c1c6edf))
- Force hero strategy to be start-aligned if there are not enough items
to make it center-aligned
([`9a2347b`](9a2347bda5))
- Add logic for multibrowse strategy to change strategy when number of
items is less than the number of keylines
([`cbb380d`](cbb380df61))
- Fixed focus order when using keyboard navigation for hero carousels.
([`0356f24`](0356f24a63))
- Cleaning up multi-browse strategy and removing compact arrangement
([`ed4647d`](ed4647d5df))
- Disallowing center aligned hero strategy with only 2 items since it
does not make any sense. With only 2 items there can only be a start
state and end state with the hero strategy.
([`d5d604d`](d5d604d0cc))
- Fix issue with uncontained carousel not having a proper end scroll
value due to assumption made in end scroll calculation
([`8cb444b`](8cb444b268))
- Added tests for hero and multibrowse strategies when the carousel
container is very small.
([`8312162`](8312162f53))
- Update scroll offset to scroll to the estimated position that it was
at upon an initial load
([`4a6ae4d`](4a6ae4d0b6))
- Fixed strategies crashing when there is not enough available space for
a large and a small item
([`c418063`](c418063205))
- Tweak uncontained strategy logic to adjust medium size items to
improve motion
([`93660d4`](93660d4241))
- Fixed formatted for KeylineState and KeylineStateList
([`b80d9a5`](b80d9a5ef4))
- Fixed keyline shifting in RTL for uncontained carousels
([`7151714`](7151714711))
- Reduce the number of truncations in intermediate calculations
([`4ce7e4c`](4ce7e4c8fa))
- Update vertical scroll speed to be faster
([`c6ea2d4`](c6ea2d4040))
- Fix some a11y bugs in Carousel
([`3d84841`](3d84841cad))
- Center aligned uncontained carousel
([`b6f6eb5`](b6f6eb555a))
- Add left-aligned uncontained strategy
([`9d81cac`](9d81cac125))
- Fix orientation not correct in item decoration calculations
([`966f7da`](966f7daec9))
- Update mask size on size change if mask x percentage has been set
([`dc91b39`](dc91b39d7c))
- Fix issue with next carousel item not being masked properly
([`a16f180`](a16f180ce7))
- Add a layout listener to recyclerview to refresh keyline state upon
size change
([`ff52862`](ff528621b3))
- Remove default list from Carousel catalog demos as it is not an
example of a carousel
([`0171624`](0171624c16))
- Add carousel alignment attribute
([`547156e`](547156e497))
- Fix issue with not refreshing keylines
([`674ec44`](674ec44429))
- Fixed MaskableFrameLayout not updating mask after size change when
setting the mask using setMaskXPercentage.
([`14023d2`](14023d2c85))
- Adding docs for fullscreen carousel strategy
([`7c40359`](7c40359d2b))
- Add fullscreen demo to catalog
([`ad6afbf`](ad6afbf6d8))
- Add full screen strategy
([`bc54f2e`](bc54f2e4b3))
- `Catalog`
- Use BottomSheetDialogFragment
([`2c53952`](2c539524ec))
- Update navigation drawer state handling to be more accurate in demo
([`74ac87c`](74ac87cb61))
- Update navigation drawer state handling to be more accurate in custom
drawer demo
([`1252d4f`](1252d4f263))
- When bottom sheet is collapsed, back callback is enabled
([`98439df`](98439df4fb))
- Update side sheet state handling to be more accurate in demos
([`357cf2d`](357cf2d9ca))
- Update bottom sheet state handling to be more accurate in demos
([`f9102c7`](f9102c745a))
- Fixed demos in RTL
([`4e1b130`](4e1b130cdf))
- Make side sheet demo icon easier to see in dark mode
([`79a1953`](79a19537d7))
- Remove explicit Catalog dependency on androidx.activity now that
library depends on it
([`3bb69f5`](3bb69f501a))
- buid.gradle update.
([`4847799`](484779902e))
- Remove edge-to-edge to top app bar demos due to glitches in ActionBar
demo
([`c40e468`](c40e468820))
- Update slider position when carousel is scrolled in uncontained
carousel demo
([`480bbc6`](480bbc6a9b))
- Applied edge-to-edge to top app bar demos
([`aa5b5bc`](aa5b5bc157))
- Add uncontained carousel demo to catalog
([`ef9f918`](ef9f91864f))
- Update slider position when carousel is scrolled in catalog demos
([`3652fde`](3652fde271))
- Applied edge-to-edge to bottom sheet in Carousel demo
([`6c2dd5d`](6c2dd5d69e))
- Fix fullscreen vertical carousel to use vertical dividers
([`af7d09a`](af7d09a43d))
- Add alignment option to hero carousel
([`7cfd30f`](7cfd30f99b))
- `Chip`
- Fix a typo in attributes table in documentation
([`7289aa6`](7289aa681d))
- `CollapsingToolbarLayout`
- Fix issue where expanded text gets ellipsized too aggressively when
using title fade mode and the toolbar has menu items
([`094e3e2`](094e3e21ea))
- Fixed title collapse fade mode color to use a Tonal Surface role
instead of elevation overlay
([`5f2b4b2`](5f2b4b2531))
- `Color`
- Delete unused contrast resources
([`541df07`](541df074a7))
- Updated focused and pressed state from 0.12 to 0.10 to increase the
contrast ratio with tonal surface color.
([`bc824b4`](bc824b4344))
- Updated colors of container transform demo
([`d16f223`](d16f22341e))
- Add ColorStateListDrawable support
([`0663019`](0663019f45))
- Removed layered drawable for the background after tonal surface color.
([`b5d6f1a`](b5d6f1ae45))
- Upgraded to v0.170 for tonal surface colors.
([`8204856`](8204856dd4))
- Update constructor comments
([`ba465a2`](ba465a2b17))
- `Divider`
- Add RTL support
([`6b897c6`](6b897c6121))
- `Documentation`
- Add note to clarify that automatic back handling in components is only
for API 33+
([`ad2b5f8`](ad2b5f8f8b))
- Update Predictive Back doc to recommend 1.10.0 stable version
([`b8b1a66`](b8b1a662de))
- Update doc to explain how to allow Top App Bar to grow taller in
response to system font setting
([`a01a68d`](a01a68de2d))
- Fix carousel docs
([`247240c`](247240c3cd))
- Add uncontained variant docs
([`9ee4aba`](9ee4aba007))
- Minor code block improvements
([`d7e75bb`](d7e75bba59))
- Add guidance in fullscreen strategy docs about portrait orientation
([`caec8d2`](caec8d2849))
- Update chip documentation to use `setOnCheckedStateChangeListener`
instead of `setOnCheckedChangeListener` which was deprecated in favour
of the former
([`0582b1a`](0582b1a094))
- Update example in docs to use `colorContainer` and `colorOnContainer`
instead of `colorPrimary` and `colorOnPrimary`.
([`44bfe2d`](44bfe2ddb8))
- Updated Color dev doc with tonal surface colors.
([`9a4c21d`](9a4c21d77a))
- Updated dev doc for tonal surface colors in affected components.
([`2114a11`](2114a11378))
- Crosslink github docs in javadocs
([`e3b255b`](e3b255b3a0))
- Cross-reference m.io and DAC in Github docs
([`1785bbf`](1785bbfabe))
- `Material 3`
- Introduce U color tokens
([`ad63d3f`](ad63d3ff7e))
- Add Meizu to dynamic colors allowlist
([`faf9a32`](faf9a32770))
- Remove resources loader support for tonal surface update
([`1a9d54f`](1a9d54fa41))
- Added default framework text colors
([`d3dda60`](d3dda60296))
- Updated contrast documentation
([`1d3b8e1`](1d3b8e136d))
- Add shift to dynamic colors allowlist
([`fde37cf`](fde37cfba5))
- Expose attr contrastColorThemeOverlay
([`839b14c`](839b14cf0f))
- Add dynamic contrast support
([`862a7e1`](862a7e10c9))
- `MaterialCardView`
- Support `android:duplicateParentState`.
([`31af945`](31af945caa))
- `MaterialDatePicker`
- Added builder methods for customizing the positive and negative button
content descriptions
([`a00ee50`](a00ee50907))
- Fix header layout overlapping
([`5f1cab6`](5f1cab65b1))
- Fixing the "Column of Days:" announcement causing Talkback verbosity
([`a782e7a`](a782e7a1d8))
- `NavigationView`
- Set material drawable background if the background has been set as a
ColorStateList
([`eba40e9`](eba40e9345))
- `Predictive Back`
- Update to use decelerate interpolator
([`5559cbc`](5559cbc7c7))
- Fix issue where predictive back is not enabled in NavigationView after
rotating the screen or restarting the activity when the NavigationView
is already opened as a drawer
([`bccbd4f`](bccbd4f778))
- Fix issue where modal accessibility is not reset after collapsing
search view predictively, which caused the screen to appear frozen when
using TalkBack
([`8d83a31`](8d83a31b6b))
- Fixed IllegalStateException crashes caused by
MaterialBackAnimationHelper.
([`02dc779`](02dc77923b))
- Fixed `UnsupportedOperationException` `AnimatorSet` crash in
`SearchView`.
([`f101532`](f10153257f))
- `ProgressIndicator`
- Allow extending LinearProgressIndicator and CircularProgressIndicator
(Closes
[#​2361](https://togithub.com/material-components/material-components-android/issues/2361))
([`3b0fd58`](3b0fd5868e))
- `Search`
- Set the `editable` property within `SearchBar`'s
`AccessibilityNodeInfo` representation.
([`be1395b`](be1395bcef))
- Fix issue where predictive back is not enabled in SearchView after
rotating the screen or restarting the activity when the SearchView is
already expanded
([`a51561d`](a51561d8b8))
- Enforced outline variant to use colorSurface as container color.
([`720998d`](720998dcbd))
- Added support to set a default content description if a content
description is not set explicitly.
([`c15a323`](c15a323140))
- `SideSheet`
- Add left sheet/sheet edge documentation.
([`d440e3c`](d440e3c4f8))
- Fix mixed language snippet
([`f91f17b`](f91f17bb4f))
- `Switch`
- Fix drawable scaling for API < 23
([`a10c508`](a10c5083a9))
- Amendments to thumb icon size support
([`db9a641`](db9a6412ec))
- `Tabs`
- Integrated divider token output into the background drawables.
([`6b627c2`](6b627c20e2))
- `TextInputLayout`
- Fix editText paddings on pre-Lollipop
([`2590c42`](2590c42764))
- Fix onMeasure() infinite loop bug caused by posting requestLayout()
before endLayout is fully rendered.
([`93360a5`](93360a5a5d))
- Mutate cursor drawable before tinting it.
([`9a4888f`](9a4888f958))
- `Theming`
- Fix swapped error colors for dynamic contrast theme in light mode
([`f2ccc11`](f2ccc116ea))
- `TimePicker`
- Fix layout getting cut on narrow screens
([`d10201d`](d10201dc88))
- `Tokens`
- Upgraded to v0.175.
([`bfee8a7`](bfee8a74d7))
- `TopAppBar`
- Simplified logics to animate the container color between lifted state
and the default state.
([`1e9f5f0`](1e9f5f0730))
- Fix dynamic status bar foreground lift on scroll color when using
Tonal Surface Color on API Level 33
([`c4ae01a`](c4ae01a5a5))
- Fix dynamic status bar foreground lift on scroll color when using
Tonal Surface Color
([`569ddac`](569ddac527))
- Fixed that liftOnScrollColor doesn't respect to setLifted when
liftOnScroll is set to false.
([`43242f2`](43242f20de))
- Added liftOnScroll and lifted toggles to the catalog.
([`4e995d1`](4e995d1f81))
- Added getMaterialShapeBackground() to return a MaterialShapeDrawable
object of the background (non-lifted layer).
([`c7a0adf`](c7a0adf8dd))
- Updated the handling of liftOnScrollColor not override
android:background.
([`2b476b3`](2b476b3a96))
- `Other`
- Cleanup date formats that specify the same field multiple times.
([`f1da3c3`](f1da3c384f))
- Update androidx.activity dependency to version 1.8.0
([`733fe20`](733fe20d88))
- Update androidx.activity dependency to version 1.8.0-rc01
([`2cfb127`](2cfb127095))
- Remove android:targetSdk where it's not needed
([`09382b8`](09382b896c))
- Update androidx.activity dependency to version 1.8.0-beta01
([`f93c65c`](f93c65c347))
- Added a comment before overridden resources.
([`7d8681f`](7d8681f71d))
- Delete BackLayer component
([`4c89301`](4c89301330))
- Stop running Robolectric tests on APIs < 19.
([`0a6a8a9`](0a6a8a971d))
- Fixed corrupt gradle jar file.
([`ed9b541`](ed9b54129d))
- Upgrade Gradle to 7.6.2.
([`04c0582`](04c05826e4))
- Consistently use window coordinates to calculate Snackbar offsets. In
one place screen and window coordinates are mixed, which leads to bad
behavior in split screen apps.
([`57b2663`](57b26639d8))
- 1.11.0-alpha01 Release.
([`76a681a`](76a681abf6))
#### Full list of release notes
-
[1.11.0-alpha01](https://togithub.com/material-components/material-components-android/releases/tag/1.11.0-alpha01)
-
[1.11.0-alpha02](https://togithub.com/material-components/material-components-android/releases/tag/1.11.0-alpha02)
-
[1.11.0-alpha03](https://togithub.com/material-components/material-components-android/releases/tag/1.11.0-alpha03)
-
[1.11.0-alpha04](https://togithub.com/material-components/material-components-android/releases/tag/1.11.0-alpha04)
-
[1.11.0-alpha05](https://togithub.com/material-components/material-components-android/releases/tag/1.11.0-alpha05)
-
[1.11.0-alpha06](https://togithub.com/material-components/material-components-android/releases/tag/1.11.0-alpha06)
-
[1.11.0-beta01](https://togithub.com/material-components/material-components-android/releases/tag/1.11.0-beta01)
-
[1.11.0-rc01](https://togithub.com/material-components/material-components-android/releases/tag/1.11.0-rc01)
#### Full list of changes
</details>
---
### Configuration
📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).
🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.
♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.
🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.
---
- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box
---
This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/pachli/pachli-android).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4xMjEuMCIsInVwZGF0ZWRJblZlciI6IjM3LjEyMS4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiJ9-->
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)
This PR contains the following updates:
| Package | Type | Update | Change |
|---|---|---|---|
|
[actions/upload-artifact](https://togithub.com/actions/upload-artifact)
| action | major | `v3` -> `v4` |
---
> [!WARNING]
> Some dependencies could not be looked up. Check the Dependency
Dashboard for more information.
---
### Release Notes
<details>
<summary>actions/upload-artifact (actions/upload-artifact)</summary>
### [`v4`](https://togithub.com/actions/upload-artifact/compare/v3...v4)
[Compare
Source](https://togithub.com/actions/upload-artifact/compare/v3...v4)
</details>
---
### Configuration
📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).
🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.
♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.
🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.
---
- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box
---
This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/pachli/pachli-android).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4xMjEuMCIsInVwZGF0ZWRJblZlciI6IjM3LjEyMS4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiJ9-->
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>