feat(store): stretch cover image on pull-down overscroll
- Remove max(0) clamp in ScrollOffsetReader to allow negative values during bounce - Add stretchAmount computed var (max(0, -scrollOffset)) - Hero image frame grows by stretchAmount and offsets upward on overscroll - isCategoryTabsPinned still uses max(0, scrollOffset) via >= check
This commit is contained in:
@@ -38,6 +38,7 @@ struct StoreDetailView: View {
|
||||
@State var scrollOffset: CGFloat = 0
|
||||
|
||||
var isCategoryTabsPinned: Bool { scrollOffset >= topSectionHeight }
|
||||
var stretchAmount: CGFloat { max(0, -scrollOffset) }
|
||||
|
||||
let cardTopInset: CGFloat = 180
|
||||
let summaryCardBaseHeight: CGFloat = 212
|
||||
|
||||
Reference in New Issue
Block a user