mirror of
https://github.com/Psychotoxical/psysonic.git
synced 2026-07-22 15:25:46 +00:00
fix(ui): in-page browse virtual lists and cover load priority (#783)
* fix(ui): in-page browse virtual lists and cover load priority Align virtualizer scrollMargin with the in-page scroll viewport so artist/album rows do not vanish on deep scroll after #731. Resolve CachedImage IntersectionObserver root to the nearest scrolling pane so network fetch slots favor visible covers; throttle Artists infinite scroll to one page per visibleCount update. * chore(release): CHANGELOG and credits for PR #783
This commit is contained in:
@@ -59,14 +59,10 @@ export function VirtualCardGrid<T>({
|
||||
return document.getElementById(APP_MAIN_SCROLL_VIEWPORT_ID) as HTMLElement | null;
|
||||
}, [scrollRootId]);
|
||||
|
||||
const scrollMargin = useVirtualizerScrollMargin(
|
||||
wrapRef,
|
||||
() => document.getElementById(APP_MAIN_SCROLL_VIEWPORT_ID),
|
||||
{
|
||||
active: !disableVirtualization,
|
||||
deps: [layoutSignal, virtualRowCount],
|
||||
},
|
||||
);
|
||||
const scrollMargin = useVirtualizerScrollMargin(wrapRef, getScrollElement, {
|
||||
active: !disableVirtualization,
|
||||
deps: [layoutSignal, virtualRowCount, scrollRootId],
|
||||
});
|
||||
|
||||
const virtualizer = useVirtualizer({
|
||||
count: disableVirtualization ? 0 : virtualRowCount,
|
||||
|
||||
Reference in New Issue
Block a user