Follow up analyze tab - #5750
Open
vitaliy-sova-ios wants to merge 6 commits into
Open
Conversation
…ithout saving changes, the Save button turns dark.
… in the entire window jumps.
Replace the medium sheet with a custom UIPresentationController: landscape shows a 393pt left-side panel matching the plan route layout, portrait shows a content-height bottom sheet. Both slide in from the bottom. Content is pinned to the safe area, fixing the title/description clipping under the Dynamic Island in landscape.
Contributor
|
The new exact-height cache does not account for Dynamic Type changes. |
Contributor
Author
2026-09-10.13.52.26.mov |
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.
Related issue / task
Fixes #5674
Summary
Two changes on this branch.
1. Get elevation data screen — adaptive presentation
Replaces the
UISheetPresentationControllermedium sheet with a customUIPresentationController:same geometry as the Plan Route panel — identical left/top/bottom insets,
the same
visibleMapWidth >= 252gate, and the same "always a side panel"behavior on iPad / Mac Catalyst.
(
systemLayoutSizeFitting, safe-area-independent so the measurement isidempotent) + bottom safe area.
viewedges tosafeAreaLayoutGuide,which fixes the reported bug: title / description / option rows were
clipped under the Dynamic Island in landscape.
containerView.accessibilityViewIsModal = true— a custom presentationdoes not get VoiceOver modal isolation for free the way
.pageSheetdid.(there is no navigation controller wrapper anymore); this mirrors what
OAChoosePlanHelperdoes internally.Everything lives in
GetElevationDataViewController.swift(no new file, toavoid a manual
project.pbxprojedit).2. Plan Route → Analyze tab — road-attribute section jitter (iteration 3)
Road-attribute rows (Surface / Smoothness / Steepness / Road types) now get
exact, synchronous heights from a content-keyed cache instead of
automaticDimension. Expand/collapse and the following scroll no longerjerk
contentOffset(worst when the section header is pinned at the top).The section-header structure and its floating behavior are unchanged.
measuredRowHeightscache keyed by"<stat.name>|expanded|collapsed".roadAttrRowHeight=chartTopInset(20) + chartHeight(54) + measured legend height; verified to match the real card constraints andAnalyzeCardCell(card fills the cell vertically, 16pt horizontal inset).heightForRowAt/estimatedHeightForRowAtreturn the exact height forroad-attribute rows,
automaticDimension/ a fixed estimate for thechart / stats / status rows.
toggleRoadAttributepre-warms the new-state height, swaps the legend inplace (keeps the bar chart), then
beginUpdates()/endUpdates().applyRenderStateand on atable-width change in
viewDidLayoutSubviews.Testing
Tested on:
Scenarios
Get elevation data
up from the bottom.
Analyze tab
Relevant checks
AI disclaimer
Implementation:
claude-sonnet-5)Prompts used (summarised):
Route panel; first implemented by embedding it in the Plan Route panel,
then reverted after a janky resize animation.
sheetPresentationControllervs a customUIPresentationController; implement the custom presentation controller(adaptive side panel / bottom sheet).
iteration 3 (exact synchronous row heights + cache).
Decided by the agent, not requested explicitly:
minimumMapWidth,the side-panel eligibility check) copied from
PlanRouteScrollableViewControllerrather than derived or shared.medium sheet's behavior).
panel's 28.
safeAreaLayoutGuide(also resolves theoriginal landscape report).
OAChoosePlanHelper.showImplinlinebecause the helper needs a
UINavigationControllerthat no longer exists.project.pbxprojchange.Final review:
claude-sonnet-5)Significant findings:
presentation — fixed (
accessibilityViewIsModal).