feat: watch history

This commit is contained in:
Adrian Castro
2024-03-27 12:31:16 +01:00
parent fa2425c183
commit 8c8ad47581
5 changed files with 107 additions and 73 deletions

View File

@@ -1,18 +1,22 @@
import React from "react";
import { View } from "tamagui";
import { ItemListSection, watching } from "~/components/item/ItemListSection";
import { ItemListSection } from "~/components/item/ItemListSection";
import ScreenLayout from "~/components/layout/ScreenLayout";
import { useBookmarkStore } from "~/stores/settings";
import { useBookmarkStore, useWatchHistoryStore } from "~/stores/settings";
export default function HomeScreen() {
const { bookmarks } = useBookmarkStore();
const { watchHistory } = useWatchHistoryStore();
return (
<View style={{ flex: 1 }} flex={1}>
<ScreenLayout>
<ItemListSection title="Bookmarks" items={bookmarks} />
<ItemListSection title="Continue Watching" items={watching} />
<ItemListSection
title="Continue Watching"
items={watchHistory.map((x) => x.item)}
/>
</ScreenLayout>
</View>
);