[Issue-7] Adjust sheet header appearance #8
Merged
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.
Introduction
There should be no unsightly gap above the header for fixed size sheets (no drag indicator).
Purpose
Refactor sheet layout to have zero gap above the header (if any) for fixed size sheets.
Fix #7
Scope
Discussion
The layout of the area above the heading was weird. Even with the drag indicator, the offset from the sheet top to drag indicator top was = sheet.cornerRadius - indicator.layout.height, which made little sense. Now there's a simple property
topInset
that positions the indicator within the sheet and is independent of sheet corner radius. For resizable sheets, the height of the drag area = topInset + indicator.height. For fixed sheets, that view is hidden and has a height of 0.For resizable sheets the drag indicator by default is closer to the top of the sheet (now: 8, before: 16 - 4 = 12).
馃摫 Screenshots
馃搱 Coverage
Code
100%
Documentation
100%