From eb0a1afbbbbc94588af1100e0f57e3a69437a423 Mon Sep 17 00:00:00 2001 From: Stephen Zhou <38493346+hyoban@users.noreply.github.com> Date: Wed, 22 Jan 2025 22:20:01 +0800 Subject: [PATCH] update --- .../screens/(stack)/feeds/[feedId]/index.tsx | 52 +++++++------------ 1 file changed, 20 insertions(+), 32 deletions(-) diff --git a/apps/mobile/src/screens/(stack)/feeds/[feedId]/index.tsx b/apps/mobile/src/screens/(stack)/feeds/[feedId]/index.tsx index f71c12ad2b..81704ad8e5 100644 --- a/apps/mobile/src/screens/(stack)/feeds/[feedId]/index.tsx +++ b/apps/mobile/src/screens/(stack)/feeds/[feedId]/index.tsx @@ -1,49 +1,37 @@ import { Stack, useLocalSearchParams } from "expo-router" -import { useState } from "react" -import { View } from "react-native" +import { ScrollView, Text, View } from "react-native" import { BlurEffect } from "@/src/components/common/BlurEffect" -import { EntryListContentGrid } from "@/src/modules/entry-list/entry-list-gird" -import { getEntry } from "@/src/store/entry/getter" -import { useEntryIdsByFeedId, usePrefetchEntries } from "@/src/store/entry/hooks" -import { useFeed } from "@/src/store/feed/hooks" -function FeedEntryList({ feedId }: { feedId: string }) { - const [pageParam, setPageParam] = useState() - usePrefetchEntries({ feedId, pageParam }) - const feed = useFeed(feedId) - const entryIds = useEntryIdsByFeedId(feedId) +export default function Feed() { + const { feedId } = useLocalSearchParams() return ( - + - { - const lastEntryId = entryIds.at(-1) - if (!lastEntryId) return - const lastEntry = getEntry(lastEntryId) - if (!lastEntry) return - setPageParam(lastEntry.publishedAt.toISOString()) + headerTitle: "Feed", }} /> + + Feed {feedId} + Feed {feedId} + Feed {feedId} + Feed {feedId} + Feed {feedId} + Feed {feedId} + Feed {feedId} + Feed {feedId} + Feed {feedId} + Feed {feedId} + Feed {feedId} + Feed {feedId} + ) } - -export default function Feed() { - const { feedId } = useLocalSearchParams() - if (!feedId || Array.isArray(feedId)) { - return null - } - - return -}