Repository navigation
Conversation
- Implement 3-tap local document state for coin button visibility - Add ClaimCreditButton and StoreButton at BottomEnd matching GamingWidget layout - Add BuddyPreferences and StoreActivity to persist and display per-widget coin counts - Import button vector drawables and add Robolectric/CoreDocument unit tests
…utton and StoreButton
…eusable pill/chip composables
…ers, and redundant loads
ashnohe
requested review from
alabiaga,
madebymozart and
yrezgui
as code owners
October 13, 2026 20:16
ashnohe
requested review from
MayuriKhinvasara
and removed request for
madebymozart
October 13, 2026 20:26
Contributor
Author
|
@alabiaga sorry for the churn on that. This PR is safe to review now. |
yrezgui
requested changes
Oct 14, 2026
yrezgui
left a comment
Contributor
There was a problem hiding this comment.
The README.md of app widgets doesn't mention Remote Compose. It's not clear what Remote Compose is bringing compared to Jetpack Glance from your sample
yrezgui
approved these changes
Oct 15, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR introduces both local state and shared app state to the Remote Compose
AndroidPetWidgetsample, along with a companionStoreActivity.What's New
rememberMutableRemoteIntandonTouchDown(valueChange(...))on the pet container inAndroidPetWidgetto track taps locally in the Remote Compose document without waking the app process.ClaimCreditButtoncoin icon on the host.BuddyPreferences):ClaimCreditButtoninvokesRemoteModifier.onClickto persist collected coins perwidgetIdinSharedPreferences.StoreButtonto launchStoreActivityfor the active widget.StoreActivityusing Material 3 dynamic colors,Scaffold+TopAppBar,LazyRowFilterChips to filter by widget instance, andElevatedCards displaying each buddy's collected credits.Code Cleanup & Simplifications
After migrating the initial implementation, we did several passes of refactoring reducing the implementation by ~1.3k lines of code bringing the entire commit down to ~700 lines of code.
Note that this isn't the entire Gaming Widget, more PRs are planned.
https://github.com/user-attachments/assets/d122ab04-bd41-4b1d-bdfc-c29e69259298
Shows tapping 3 times to get a gold coin, collecting the gold coin, and seeing the number of gold coins collected per widget in the Store.