diff --git a/frontend/src/components/Layout/ListItem.tsx b/frontend/src/components/Layout/ListItem.tsx index aa62ea9..fd93adb 100644 --- a/frontend/src/components/Layout/ListItem.tsx +++ b/frontend/src/components/Layout/ListItem.tsx @@ -90,7 +90,7 @@ const UserListItem: React.FC = ({ title, username, isLive, on e.currentTarget.onerror = null; }} alt={`user ${username}`} - className="rounded-xl border-[0.15em] border-[var(--bg-color)] cursor-pointer" + className="rounded-xl border-[0.15em] border-[var(--bg-color)] aspect-video cursor-pointer" style={{ backgroundColor: 'white' }} /> @@ -134,7 +134,7 @@ const VodListItem: React.FC = ({ {title} {/* Duration badge */} -
{length}
+ {length &&
{length}
}
@@ -142,8 +142,8 @@ const VodListItem: React.FC = ({ {variant != "vodDashboard" &&

{username}

}

{category_name}

-

{datetime}

-

{views} views

+ {datetime &&

{datetime}

} + {/*

{views} views

*/}
diff --git a/frontend/src/components/Layout/ListRow.tsx b/frontend/src/components/Layout/ListRow.tsx index b30a4e4..9bb3111 100644 --- a/frontend/src/components/Layout/ListRow.tsx +++ b/frontend/src/components/Layout/ListRow.tsx @@ -50,12 +50,6 @@ const ListRow = forwardRef((props, ref) => { const scrollAmount = window.innerWidth * 0.4; const navigate = useNavigate(); - const handleVodClick = (item: VodType) => { - if (type === "vod" && "username" in item && "vod_id" in item) { - navigate(`/stream/${item.username}/vods/${item.vod_id}`); // ✅ Directly navigate - } - }; - const addMoreItems = (newItems: ItemType[]) => { setCurrentItems((prevItems) => [...prevItems, ...newItems]); }; @@ -175,6 +169,7 @@ const ListRow = forwardRef((props, ref) => { /> ); } else if (type === "vod" && isVodType(item)) { + console.log(item); return ( { variant="search" type="vod" items={searchState.searchResults.vods.map((vod: any) => ({ - id: vod.vod_id, + vod_id: vod.vod_id, type: "vod", title: vod.title, - username: vod.username, - thumbnail: vod.thumbnail_url, + username: vod.username }))} title="VODs" onItemClick={(username, vod_id) => navigate(`/vods/${username}/${vod_id}`)}