mirror of
https://github.com/jeffvli/feishin.git
synced 2026-05-07 04:20:12 +02:00
support dynamic header album name in paginated list
This commit is contained in:
@@ -1213,7 +1213,9 @@ export const ItemDetailList = ({
|
||||
lastVisibleStartIndexRef.current = range.startIndex;
|
||||
const el = headerLeftRef.current;
|
||||
if (el) {
|
||||
const album = getItem?.(range.startIndex) as Album | undefined;
|
||||
const album = (
|
||||
getItem ? getItem(range.startIndex) : dataSourceRef.current[range.startIndex]
|
||||
) as Album | undefined;
|
||||
const name = album?.name ?? '';
|
||||
if (name) {
|
||||
lastHeaderNameRef.current = name;
|
||||
|
||||
Reference in New Issue
Block a user