debug: add scroll tracking logs round 2
This commit is contained in:
@@ -96,12 +96,17 @@ struct EntryListView: View {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// --- Mark-as-read ---
|
// --- Mark-as-read ---
|
||||||
|
let debugThis = vm.entries.prefix(3).contains(where: { $0.id == entryId })
|
||||||
|
if debugThis {
|
||||||
|
print("[SCROLL] id=\(entryId) minY=\(Int(newMinY)) maxY=\(Int(frame.maxY)) down=\(isScrollingDown) active=\(trackingActive) cumDown=\(Int(cumulativeDown)) wasVis=\(wasVisible.contains(entryId)) visR=\(String(format:"%.2f",visibleRatio)) vpH=\(Int(viewportHeight)) read=\(entry.isRead) marked=\(markedByScroll.contains(entryId))")
|
||||||
|
}
|
||||||
guard trackingActive,
|
guard trackingActive,
|
||||||
isScrollingDown,
|
isScrollingDown,
|
||||||
!entry.isRead,
|
!entry.isRead,
|
||||||
!markedByScroll.contains(entryId),
|
!markedByScroll.contains(entryId),
|
||||||
wasVisible.contains(entryId),
|
wasVisible.contains(entryId),
|
||||||
frame.maxY < 0 else { return }
|
frame.maxY < 0 else { return }
|
||||||
|
if debugThis { print("[SCROLL-READ] ✅ id=\(entryId)") }
|
||||||
|
|
||||||
markedByScroll.insert(entryId)
|
markedByScroll.insert(entryId)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user