Artifactory rail: size the scroll box with fixedSize, not a measurement - #238
Merged
Merged
Conversation
Reported with a screenshot: a large gap between the ARTIFACTORY header and the "3 message records" row under it. The box was taller than its rows and bottom-anchored, so the slack sat between the header and the first row. This is the second failure of sizing the scroll box from a measured content height — first a zero start that never laid out (#237), now a stale reading. Preferences from inside a ScrollView are not a foundation to build on. Replaced with the idiom that needs no measuring: `.frame(maxHeight:)` under `.fixedSize(horizontal: false, vertical: true)`. fixedSize asks the scroll view for its ideal height, which is its content's, and the frame clamps that. The box is exactly as tall as the posts until the cap and scrolls after. No state, nothing to go stale, nothing to fire late. All GeometryReader and preference plumbing removed. Suite: 1482 tests / 153 suites pass; swiftlint 0 errors, format clean. Signed-off-by: scgopi <scgopireddy@gmail.com> Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019A6NULwEiBXEdRXwEKMcRH
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.
Reported with a screenshot: a large gap between the ARTIFACTORY header and the 3 message records row under it.
The box was taller than its rows and bottom-anchored, so the slack sat between the header and the first row. This is the second failure of sizing the scroll box from a measured content height — first a zero start that never laid out (#237), now a stale reading. Preferences from inside a
ScrollVieware not a foundation to build on.Replaced with the idiom that needs no measuring:
.frame(maxHeight: 600).fixedSize(horizontal: false, vertical: true).fixedSizeasks the scroll view for its ideal height — its content's — and the frame under it clamps that. The box is exactly as tall as the posts until the cap and scrolls after. No state, nothing to go stale, nothing to fire late. AllGeometryReader/ preference plumbing removed.Suite 1482 tests / 153 suites pass; swiftlint 0 errors,
swift-format --strictclean. Needs a human's eyes — no GUI automation here.🤖 Generated with Claude Code
https://claude.ai/code/session_019A6NULwEiBXEdRXwEKKcRH