Repository navigation
Android: swipeable station sheet, area menu, overlapping stations and an optimized release APK - #4
Merged
Merged
Conversation
A refactor with no change in behaviour or appearance, so the station sheet, the top controls, the map bridge and the menus can be worked on in separate files. - AppChrome.kt: colour tokens, Menu, Detent, MapChrome (the sheet stop, whether the map is covered, the half-open sheet top and the bottom of the top controls) and MapMove. MapChrome follows the current M3 sheet. - CommonUi.kt: Price, SheetTitle, OptionRow, SettingSwitch, the label helpers and resetTime. - StationSheet.kt: the sheet handle, StationSheetContent, LimitNotice, SheetOverlays (map credit and location button) and ShowStationsButton. - StationRow.kt: StationRow and GoButton. - TopControls.kt: TopControls and SearchAreaButton. - MenuHost.kt: MenuHost reads the open menu itself, so opening a menu no longer recomposes OpenFuelApp. MenuBody sends every close through one closeMenu. Also SettingsContent, PriceForm and ProposalForm. - StationDetail.kt: the station detail sheet. - AreaSearch.kt: LocationSearch. OpenFuelApp gains openDetail(station, stack) for the list and the map and onMapMove(MapMove). The LiveMap call has one argument per line, and each map overlay is its own call. native-root exposes test tags as resource ids for uiautomator.
# Conflicts: # apps/android/app/src/main/java/ca/openfuel/prototype/MenuHost.kt
On a 360 dp screen with large text, HALF to FULL is shorter than the fixed 500 px swipe, so the swipe carried on into the list. Measure both stops first and keep each swipe within that distance.
…ot writes - Finish a snapshot write even when a newer refresh cancels its job, so the saved file never falls behind the stations on screen. - Open the area menu, its chevron and its Back handling only when the menu has room below the chip. - In a window so short that FULL is the collapsed stop, stop treating the sheet as covering the map. - Name the release APK as the build output in docs/BUILD.md.
The record lists the release APK's size, hash and signing key, the unit and instrumentation results at both screen sizes, the upgrade check and the emulator performance comparison with its limits. Screenshots taken before the last two visual fixes are labelled as such.
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
The account paying for this security review has reached its Codex usage limits. The payer can check the Codex usage dashboard. For personal accounts, using credits requires enabling “Use credits for security reviews” in Code review settings. If you do not manage the paying account, contact this repository's admins. |
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.
Android UX overhaul for version 0.3.3-live (code 7).
Station sheet. The sheet has three stops (collapsed, half-open, expanded) and follows the finger while dragging. A drag on the list raises the sheet to the expanded stop before the list scrolls, and lowers it once the list is at its top. Flings move one stop. Back, landscape and narrow screens are handled. A stationary pointer observer fixes the dropped pointer moves in Compose that made swipes register as taps, and sideways swipes on the header no longer count as taps.
Top controls. The area dropdown opens below its chip and stays below it on short screens. It lists recent cities and has an inline city search with debounced, cancellable lookups. "Search here" sits beside the area chip.
Map. The map is framed around the controls, and a station's detail lists the other stations at the same spot, so overlapping markers can be told apart without zooming.
Smoothness and storage. Menus animate when they close or change content. Station snapshots are written to files off the UI thread, migrated from the old preferences cache.
Downloads. The release APK is now an optimized, non-debuggable R8 build (about 1.9 MB instead of 18 MB). It is signed with the same key as earlier downloads, so installed copies update in place. CI builds and uploads the release APK.
Validation:
tools/project.py checkpassed: repository 77, API 45, registry 20, plus generated resources, contracts and fixtures. Map JavaScript syntax and Gitleaks passed.evidence/android-native/ux-0.3.3.json, with screenshots inevidence/android-native/ux-0.3.3/.Baseline profiles are deferred, and gesture feel has not been checked on a physical phone. This PR does not publish a GitHub release or deploy anything.