diff --git a/src/app/(auth)/login/layout.tsx b/src/app/(auth)/login/layout.tsx index 1b93cad3..b8de2cd9 100644 --- a/src/app/(auth)/login/layout.tsx +++ b/src/app/(auth)/login/layout.tsx @@ -2,7 +2,7 @@ import type { Metadata } from "next"; import Image from "next/image"; export const metadata: Metadata = { - title: "Ouranos — Login", + title: "Login", description: "Your Bluesky web client", }; diff --git a/src/app/(site)/about/layout.tsx b/src/app/(site)/about/layout.tsx index 0098a307..49b6ce3e 100644 --- a/src/app/(site)/about/layout.tsx +++ b/src/app/(site)/about/layout.tsx @@ -1,7 +1,7 @@ import type { Metadata } from "next"; export const metadata: Metadata = { - title: "Ouranos - About", + title: "About", description: "About Ouranos", }; diff --git a/src/app/dashboard/feeds/[feed]/layout.tsx b/src/app/dashboard/feeds/[feed]/layout.tsx index 15e4cef5..10052e31 100644 --- a/src/app/dashboard/feeds/[feed]/layout.tsx +++ b/src/app/dashboard/feeds/[feed]/layout.tsx @@ -1,10 +1,3 @@ -import type { Metadata } from "next"; - -export const metadata: Metadata = { - title: "Ouranos — Feed", - description: "Feed", -}; - export default function FeedLayout({ children, }: { diff --git a/src/app/dashboard/feeds/[feed]/page.tsx b/src/app/dashboard/feeds/[feed]/page.tsx index c66ad28f..a3cce5ba 100644 --- a/src/app/dashboard/feeds/[feed]/page.tsx +++ b/src/app/dashboard/feeds/[feed]/page.tsx @@ -1,5 +1,19 @@ import FeedHeader from "@/components/contentDisplay/feedHeader/FeedHeader"; import FeedContainer from "@/containers/posts/FeedContainer"; +import { getFeedInfo } from "@/lib/api/bsky/feed"; +import { Metadata } from "next"; + +export async function generateMetadata({ searchParams }: Props): Promise { + const feedInfo = await getFeedInfo(searchParams.uri); + const title = feedInfo.view.displayName + ? feedInfo.view.displayName + : "Feed"; + + return { + title: title + " — Ouranos", + description: "Feed", + }; + } interface Props { searchParams: { diff --git a/src/app/dashboard/feeds/layout.tsx b/src/app/dashboard/feeds/layout.tsx index edca7995..4de4651a 100644 --- a/src/app/dashboard/feeds/layout.tsx +++ b/src/app/dashboard/feeds/layout.tsx @@ -2,7 +2,7 @@ import Layout from "@/containers/Layout"; import type { Metadata } from "next"; export const metadata: Metadata = { - title: "Ouranos — Feeds", + title: "Feeds", description: "Feeds", }; diff --git a/src/app/dashboard/home/[feed]/page.tsx b/src/app/dashboard/home/[feed]/page.tsx index 7fd68f48..30a1879e 100644 --- a/src/app/dashboard/home/[feed]/page.tsx +++ b/src/app/dashboard/home/[feed]/page.tsx @@ -1,4 +1,18 @@ import FeedContainer from "@/containers/posts/FeedContainer"; +import { getFeedInfo } from "@/lib/api/bsky/feed"; +import { Metadata } from "next"; + +export async function generateMetadata({ searchParams }: Props): Promise { + const feedInfo = await getFeedInfo(searchParams.uri); + const title = feedInfo.view.displayName + ? feedInfo.view.displayName + : "Feed"; + + return { + title: title + " — Ouranos", + description: "Feed", + }; + } interface Props { searchParams: { diff --git a/src/app/dashboard/home/layout.tsx b/src/app/dashboard/home/layout.tsx index 0111ba93..4f5ddbd9 100644 --- a/src/app/dashboard/home/layout.tsx +++ b/src/app/dashboard/home/layout.tsx @@ -2,7 +2,7 @@ import FeedTabs from "@/components/navigational/feedTabs/FeedTabs"; import type { Metadata } from "next"; export const metadata: Metadata = { - title: "Ouranos — Home", + title: "Home", description: "Home", }; diff --git a/src/app/dashboard/layout.tsx b/src/app/dashboard/layout.tsx index 68d4ef52..5787083a 100644 --- a/src/app/dashboard/layout.tsx +++ b/src/app/dashboard/layout.tsx @@ -8,7 +8,7 @@ import { getProfile } from "@/lib/api/bsky/actor"; import { getSessionFromServer } from "@/lib/api/auth/session"; export const metadata: Metadata = { - title: "Ouranos", + title: { template: "%s — Ouranos", default: "Ouranos" }, description: "Home", }; diff --git a/src/app/dashboard/lists/layout.tsx b/src/app/dashboard/lists/layout.tsx index 4c2cd754..f90dd0c7 100644 --- a/src/app/dashboard/lists/layout.tsx +++ b/src/app/dashboard/lists/layout.tsx @@ -2,7 +2,7 @@ import Layout from "@/containers/Layout"; import type { Metadata } from "next"; export const metadata: Metadata = { - title: "Ouranos — Lists", + title: "Lists", description: "Lists", }; diff --git a/src/app/dashboard/notifications/layout.tsx b/src/app/dashboard/notifications/layout.tsx index cd6e5ca0..107e0d19 100644 --- a/src/app/dashboard/notifications/layout.tsx +++ b/src/app/dashboard/notifications/layout.tsx @@ -2,7 +2,7 @@ import Layout from "@/containers/Layout"; import type { Metadata } from "next"; export const metadata: Metadata = { - title: "Ouranos — Notifications", + title: "Notifications", description: "Notifications", }; diff --git a/src/app/dashboard/search/layout.tsx b/src/app/dashboard/search/layout.tsx index 8db0d7c0..94e20f5b 100644 --- a/src/app/dashboard/search/layout.tsx +++ b/src/app/dashboard/search/layout.tsx @@ -2,7 +2,7 @@ import Layout from "@/containers/Layout"; import type { Metadata } from "next"; export const metadata: Metadata = { - title: "Ouranos — Search", + title: "Search", description: "Search", }; diff --git a/src/app/dashboard/settings/appearance/page.tsx b/src/app/dashboard/settings/appearance/page.tsx index 1ddc2fd7..10505e21 100644 --- a/src/app/dashboard/settings/appearance/page.tsx +++ b/src/app/dashboard/settings/appearance/page.tsx @@ -1,4 +1,10 @@ import AppearanceContainer from "@/containers/settings/AppearanceContainer/AppearanceContainer"; +import { Metadata } from "next"; + +export const metadata: Metadata = { + title: "Appearance", + description: "Appearance", +}; export default function Page() { return ; diff --git a/src/app/dashboard/settings/blocked-users/page.tsx b/src/app/dashboard/settings/blocked-users/page.tsx index 33bf5285..cd4964c3 100644 --- a/src/app/dashboard/settings/blocked-users/page.tsx +++ b/src/app/dashboard/settings/blocked-users/page.tsx @@ -1,4 +1,11 @@ import BlockedUsersContainer from "@/containers/settings/blockedUsersContainer/BlockedUsersContainer"; +import { Metadata } from "next"; + +export const metadata: Metadata = { + title: "Blocked Users", + description: "Blocked Users", +}; + export default function Page() { return ; diff --git a/src/app/dashboard/settings/content-filtering/page.tsx b/src/app/dashboard/settings/content-filtering/page.tsx index a78a1f1e..7c01586e 100644 --- a/src/app/dashboard/settings/content-filtering/page.tsx +++ b/src/app/dashboard/settings/content-filtering/page.tsx @@ -1,4 +1,10 @@ import ContentFilteringContainer from "@/containers/settings/contentFilteringContainer/ContentFilteringContainer"; +import { Metadata } from "next"; + +export const metadata: Metadata = { + title: "Content Filtering", + description: "Content Filtering", +}; export default function Page() { return ; diff --git a/src/app/dashboard/settings/home-feed/page.tsx b/src/app/dashboard/settings/home-feed/page.tsx index 991dc3a5..3784813f 100644 --- a/src/app/dashboard/settings/home-feed/page.tsx +++ b/src/app/dashboard/settings/home-feed/page.tsx @@ -1,4 +1,10 @@ import HomeFeedContainer from "@/containers/settings/homeFeedContainer/HomeFeedContainer"; +import { Metadata } from "next"; + +export const metadata: Metadata = { + title: "Home Feed Preferences", + description: "Home Feed Preferences", +}; export default function Page() { return ; diff --git a/src/app/dashboard/settings/layout.tsx b/src/app/dashboard/settings/layout.tsx index 69602cab..5f40904b 100644 --- a/src/app/dashboard/settings/layout.tsx +++ b/src/app/dashboard/settings/layout.tsx @@ -2,7 +2,7 @@ import Layout from "@/containers/Layout"; import type { Metadata } from "next"; export const metadata: Metadata = { - title: "Ouranos — Settings", + title: { template: "%s — Ouranos", default: "Settings" }, description: "Settings", }; diff --git a/src/app/dashboard/settings/muted-users/page.tsx b/src/app/dashboard/settings/muted-users/page.tsx index 9167ef2d..ab71915f 100644 --- a/src/app/dashboard/settings/muted-users/page.tsx +++ b/src/app/dashboard/settings/muted-users/page.tsx @@ -1,4 +1,10 @@ import MutedUsersContainer from "@/containers/settings/mutedUsersContainer/MutedUsersContainer"; +import { Metadata } from "next"; + +export const metadata: Metadata = { + title: "Muted Users", + description: "Muted Users", +}; export default function Page() { return ; diff --git a/src/app/dashboard/settings/my-feeds/page.tsx b/src/app/dashboard/settings/my-feeds/page.tsx index eb53525d..0aa9abf4 100644 --- a/src/app/dashboard/settings/my-feeds/page.tsx +++ b/src/app/dashboard/settings/my-feeds/page.tsx @@ -1,4 +1,10 @@ import MyFeedsContainer from "@/containers/settings/myFeedsContainer/MyFeedsContainer"; +import { Metadata } from "next"; + +export const metadata: Metadata = { + title: "My Feeds", + description: "My Feeds", +}; export default function Page() { return ; diff --git a/src/app/dashboard/settings/thread-preferences/page.tsx b/src/app/dashboard/settings/thread-preferences/page.tsx index 37bbcb10..07e05df2 100644 --- a/src/app/dashboard/settings/thread-preferences/page.tsx +++ b/src/app/dashboard/settings/thread-preferences/page.tsx @@ -1,4 +1,10 @@ import ThreadPreferencesContainer from "@/containers/settings/threadPreferencesContainer/ThreadPreferencesContainer"; +import { Metadata } from "next"; + +export const metadata: Metadata = { + title: "Thread Preferences", + description: "Thread Preferences", +}; export default function Page() { return ; diff --git a/src/app/dashboard/user/[handle]/(content)/layout.tsx b/src/app/dashboard/user/[handle]/(content)/layout.tsx index 484fb63d..2686cdd7 100644 --- a/src/app/dashboard/user/[handle]/(content)/layout.tsx +++ b/src/app/dashboard/user/[handle]/(content)/layout.tsx @@ -1,10 +1,18 @@ import type { Metadata } from "next"; import ProfileHeader from "@/components/contentDisplay/profileHeader/ProfileHeader"; +import { getProfile } from "@/lib/api/bsky/actor"; -export const metadata: Metadata = { - title: "Ouranos — Profile", - description: "Profile", -}; +export async function generateMetadata({ params }: Props): Promise { + const profile = await getProfile(params.handle); + const title = profile?.displayName + ? `${profile.displayName} (@${params.handle})` + : params.handle; + + return { + title: title, + description: "Profile", + }; +} interface Props { params: { handle: string }; diff --git a/src/app/dashboard/user/[handle]/(follow)/known-followers/page.tsx b/src/app/dashboard/user/[handle]/(follow)/known-followers/page.tsx index 29c6f848..8464c860 100644 --- a/src/app/dashboard/user/[handle]/(follow)/known-followers/page.tsx +++ b/src/app/dashboard/user/[handle]/(follow)/known-followers/page.tsx @@ -1,5 +1,15 @@ -import FollowingContainer from "@/containers/users/FollowingContainer"; import KnownFollowersContainer from "@/containers/users/KnownFollowersContainer"; +import type { Metadata } from "next"; + +export function generateMetadata({ params }: Props): Metadata { + const title = `Followers of @${params.handle} that you know`; + const descripton = `Followers of @${params.handle} that you know`; + + return { + title: title, + description: descripton, + }; +} interface Props { params: { diff --git a/src/app/dashboard/user/[handle]/(post)/post/[id]/liked-by/layout.tsx b/src/app/dashboard/user/[handle]/(post)/post/[id]/liked-by/layout.tsx index 95a9ab69..cd99ba48 100644 --- a/src/app/dashboard/user/[handle]/(post)/post/[id]/liked-by/layout.tsx +++ b/src/app/dashboard/user/[handle]/(post)/post/[id]/liked-by/layout.tsx @@ -1,10 +1,4 @@ import Layout from "@/containers/Layout"; -import type { Metadata } from "next"; - -export const metadata: Metadata = { - title: "Ouranos — Liked By", - description: "Liked By", -}; export default function LikedByLayout({ children, diff --git a/src/app/dashboard/user/[handle]/(post)/post/[id]/liked-by/page.tsx b/src/app/dashboard/user/[handle]/(post)/post/[id]/liked-by/page.tsx index dbb229cc..98c58359 100644 --- a/src/app/dashboard/user/[handle]/(post)/post/[id]/liked-by/page.tsx +++ b/src/app/dashboard/user/[handle]/(post)/post/[id]/liked-by/page.tsx @@ -1,4 +1,15 @@ import LikedByContainer from "@/containers/thread/LikedByContainer"; +import type { Metadata } from "next"; + +export function generateMetadata({ params }: Props): Metadata { + const title = `@${params.handle}'s Post Liked By`; + const descripton = `Users who have liked @${params.handle}'s post`; + + return { + title: title, + description: descripton, + }; +} interface Props { params: { diff --git a/src/app/dashboard/user/[handle]/(post)/post/[id]/page.tsx b/src/app/dashboard/user/[handle]/(post)/post/[id]/page.tsx index c80cb815..a317baed 100644 --- a/src/app/dashboard/user/[handle]/(post)/post/[id]/page.tsx +++ b/src/app/dashboard/user/[handle]/(post)/post/[id]/page.tsx @@ -1,6 +1,33 @@ import PostThreadContainer from "@/containers/thread/PostThreadContainer"; import { getSessionFromServer } from "@/lib/api/auth/session"; import { getProfile } from "@/lib/api/bsky/actor"; +import { getAgent } from "@/lib/api/bsky/agent"; +import { getPostThread } from "@/lib/api/bsky/feed"; +import { AppBskyFeedDefs, AppBskyFeedPost } from "@atproto/api"; +import { Metadata } from "next"; + +export async function generateMetadata({ params }: Props): Promise { + const agent = await getAgent(); + const { handle, id } = params; + const { data } = await agent.resolveHandle({ handle }); + const uri = `at://${data.did}/app.bsky.feed.post/${id}`; + const post = await getPostThread(uri); + + const isThreadViewPost = AppBskyFeedDefs.isThreadViewPost(post) ? true : false; + const threadPost = isThreadViewPost ? post.post as AppBskyFeedDefs.PostView : null; + + const text = + threadPost && AppBskyFeedPost.isRecord(threadPost.record) + ? threadPost.record.text + : ""; + + const title = text !== "" ? `${threadPost?.author.displayName || params.handle}: "${text}"` : `Post by ${params.handle}`; + + return { + title: title, + description: "Feed", + }; +} interface Props { params: { diff --git a/src/app/dashboard/user/[handle]/(post)/post/[id]/quotes/layout.tsx b/src/app/dashboard/user/[handle]/(post)/post/[id]/quotes/layout.tsx index e633b477..268d8d92 100644 --- a/src/app/dashboard/user/[handle]/(post)/post/[id]/quotes/layout.tsx +++ b/src/app/dashboard/user/[handle]/(post)/post/[id]/quotes/layout.tsx @@ -1,10 +1,4 @@ import Layout from "@/containers/Layout"; -import type { Metadata } from "next"; - -export const metadata: Metadata = { - title: "Ouranos — Quotes", - description: "Quotes for this post", -}; export default function RepostedByLayout({ children, diff --git a/src/app/dashboard/user/[handle]/(post)/post/[id]/quotes/page.tsx b/src/app/dashboard/user/[handle]/(post)/post/[id]/quotes/page.tsx index 427c3be7..efee3ea7 100644 --- a/src/app/dashboard/user/[handle]/(post)/post/[id]/quotes/page.tsx +++ b/src/app/dashboard/user/[handle]/(post)/post/[id]/quotes/page.tsx @@ -1,4 +1,15 @@ import QuotesContainer from "@/containers/thread/QuotesContainer"; +import type { Metadata } from "next"; + +export function generateMetadata({ params }: Props): Metadata { + const title = `@${params.handle}'s Post Quotes`; + const descripton = `Users who have quoted @${params.handle}'s post`; + + return { + title: title, + description: descripton, + }; +} interface Props { params: { diff --git a/src/app/dashboard/user/[handle]/(post)/post/[id]/reposted-by/layout.tsx b/src/app/dashboard/user/[handle]/(post)/post/[id]/reposted-by/layout.tsx index 9480060d..268d8d92 100644 --- a/src/app/dashboard/user/[handle]/(post)/post/[id]/reposted-by/layout.tsx +++ b/src/app/dashboard/user/[handle]/(post)/post/[id]/reposted-by/layout.tsx @@ -1,10 +1,4 @@ import Layout from "@/containers/Layout"; -import type { Metadata } from "next"; - -export const metadata: Metadata = { - title: "Ouranos — Reposted By", - description: "Reposted By", -}; export default function RepostedByLayout({ children, diff --git a/src/app/dashboard/user/[handle]/(post)/post/[id]/reposted-by/page.tsx b/src/app/dashboard/user/[handle]/(post)/post/[id]/reposted-by/page.tsx index b95bdd11..0dfefbf9 100644 --- a/src/app/dashboard/user/[handle]/(post)/post/[id]/reposted-by/page.tsx +++ b/src/app/dashboard/user/[handle]/(post)/post/[id]/reposted-by/page.tsx @@ -1,4 +1,15 @@ import RepostedByContainer from "@/containers/thread/RepostedByContainer"; +import type { Metadata } from "next"; + +export function generateMetadata({ params }: Props): Metadata { + const title = `@${params.handle}'s Post Reposted By`; + const descripton = `Users who have reposted @${params.handle}'s post`; + + return { + title: title, + description: descripton, + }; +} interface Props { params: { diff --git a/src/app/dashboard/user/[handle]/lists/[list]/layout.tsx b/src/app/dashboard/user/[handle]/lists/[list]/layout.tsx index 65cbbee0..2c0a2138 100644 --- a/src/app/dashboard/user/[handle]/lists/[list]/layout.tsx +++ b/src/app/dashboard/user/[handle]/lists/[list]/layout.tsx @@ -1,10 +1,3 @@ -import type { Metadata } from "next"; - -export const metadata: Metadata = { - title: "Ouranos — List", - description: "List", -}; - export default function ListsLayout({ children, }: { diff --git a/src/app/dashboard/user/[handle]/lists/[list]/page.tsx b/src/app/dashboard/user/[handle]/lists/[list]/page.tsx index 9f9a370b..12b004b9 100644 --- a/src/app/dashboard/user/[handle]/lists/[list]/page.tsx +++ b/src/app/dashboard/user/[handle]/lists/[list]/page.tsx @@ -1,4 +1,18 @@ import ListContainer from "@/containers/lists/ListContainer"; +import { getListInfo } from "@/lib/api/bsky/list"; +import { Metadata } from "next"; + +export async function generateMetadata({ searchParams }: Props): Promise { + const listInfo = await getListInfo(searchParams.uri); + const title = listInfo.list.name + ? listInfo.list.name + : "List"; + + return { + title: title, + description: "Feed", + }; + } interface Props { searchParams: { diff --git a/src/app/dashboard/user/[handle]/lists/layout.tsx b/src/app/dashboard/user/[handle]/lists/layout.tsx deleted file mode 100644 index 65cbbee0..00000000 --- a/src/app/dashboard/user/[handle]/lists/layout.tsx +++ /dev/null @@ -1,14 +0,0 @@ -import type { Metadata } from "next"; - -export const metadata: Metadata = { - title: "Ouranos — List", - description: "List", -}; - -export default function ListsLayout({ - children, -}: { - children: React.ReactNode; -}) { - return <>{children}; -} diff --git a/src/app/layout.tsx b/src/app/layout.tsx index 90165f79..8167766d 100644 --- a/src/app/layout.tsx +++ b/src/app/layout.tsx @@ -14,7 +14,7 @@ import ThemeProvider from "./providers/theme"; const inter = Inter({ subsets: ["latin"] }); export const metadata: Metadata = { - title: "Ouranos", + title: { template: "%s — Ouranos", default: "Ouranos" }, description: "Your friendly Bluesky client for the web", metadataBase: new URL("https://useouranos.app"), }; diff --git a/src/components/dataDisplay/postEmbed/ExternalEmbed.tsx b/src/components/dataDisplay/postEmbed/ExternalEmbed.tsx index 30b6ff6c..7b3c35a1 100644 --- a/src/components/dataDisplay/postEmbed/ExternalEmbed.tsx +++ b/src/components/dataDisplay/postEmbed/ExternalEmbed.tsx @@ -13,7 +13,7 @@ export default function ExternalEmbed(props: Props) { return ( <> {depth < 2 && ( -
+
)} diff --git a/src/containers/thread/PostThreadContainer.tsx b/src/containers/thread/PostThreadContainer.tsx index ab075c19..38b945c7 100644 --- a/src/containers/thread/PostThreadContainer.tsx +++ b/src/containers/thread/PostThreadContainer.tsx @@ -48,7 +48,7 @@ export default function PostThreadContainer(props: Props) { const { data } = await agent.resolveHandle({ handle }); if (!data) return; const uri = `at://${data.did}/app.bsky.feed.post/${id}`; - return getPostThread(agent, uri); + return getPostThread(uri, agent); }, }); diff --git a/src/containers/thread/ThreadActionsContainer.tsx b/src/containers/thread/ThreadActionsContainer.tsx index 12c945df..8bb11506 100644 --- a/src/containers/thread/ThreadActionsContainer.tsx +++ b/src/containers/thread/ThreadActionsContainer.tsx @@ -10,6 +10,7 @@ interface Props { export default function ThreadActionsContainer(props: Props) { const { avatar, post, rounded } = props; + const postHasReplies = !!post.replyCount; return (
-
- -
+ {postHasReplies && ( +
+ +
+ )}
); } diff --git a/src/lib/api/bsky/feed/index.ts b/src/lib/api/bsky/feed/index.ts index f554f077..2e090c27 100644 --- a/src/lib/api/bsky/feed/index.ts +++ b/src/lib/api/bsky/feed/index.ts @@ -105,7 +105,8 @@ export const getFeed = async (agent: AtpAgent, uri: string, cursor: string) => { return feed; }; -export const getFeedInfo = async (agent: AtpAgent, uri: string) => { +export const getFeedInfo = async (uri: string, agent?: AtpAgent) => { + if (!agent) agent = await getAgent(); const feed = await agent.app.bsky.feed.getFeedGenerator({ feed: uri }); if (!feed.success) throw new Error("Could not fetch feed info"); return feed.data; @@ -226,7 +227,9 @@ export const getPost = async (agent: AtpAgent, uri: string) => { } }; -export const getPostThread = async (agent: AtpAgent, uri: string) => { +export const getPostThread = async (uri: string, agent?: AtpAgent) => { + if (!agent) agent = await getAgent(); + try { const posts = await agent.getPostThread({ uri: uri }); return posts.data.thread; diff --git a/src/lib/api/bsky/list/index.tsx b/src/lib/api/bsky/list/index.tsx index 0d0046ad..381662b9 100644 --- a/src/lib/api/bsky/list/index.tsx +++ b/src/lib/api/bsky/list/index.tsx @@ -1,4 +1,5 @@ import { type AtpAgent } from "@atproto/api"; +import { getAgent } from "../agent"; export const getLists = async ( did: string, @@ -14,7 +15,9 @@ export const getLists = async ( return lists.data; }; -export const getListInfo = async (agent: AtpAgent, uri: string) => { +export const getListInfo = async (uri: string, agent?: AtpAgent) => { + if (!agent) agent = await getAgent(); + const feed = await agent.app.bsky.graph.getList({ list: uri }); if (!feed.success) throw new Error("Could not fetch feed info"); return feed.data; diff --git a/src/lib/hooks/bsky/feed/useFeedInfo.tsx b/src/lib/hooks/bsky/feed/useFeedInfo.tsx index 13505983..21ad1105 100644 --- a/src/lib/hooks/bsky/feed/useFeedInfo.tsx +++ b/src/lib/hooks/bsky/feed/useFeedInfo.tsx @@ -10,7 +10,7 @@ export default function useFeedInfo(feed: string) { const { data, isLoading, isFetching, isRefetching, error } = useQuery({ queryKey: feedInfoKey(feed), queryFn: async () => { - const feedInfo = await getFeedInfo(agent, feed); + const feedInfo = await getFeedInfo(feed, agent); const savedFeeds = await getSavedFeeds(agent); const isSaved = savedFeeds.some((savedFeed) => savedFeed.uri === feed); const isPinned = savedFeeds.some( diff --git a/src/lib/hooks/bsky/list/useListInfo.tsx b/src/lib/hooks/bsky/list/useListInfo.tsx index d2806882..fda2a03b 100644 --- a/src/lib/hooks/bsky/list/useListInfo.tsx +++ b/src/lib/hooks/bsky/list/useListInfo.tsx @@ -9,7 +9,7 @@ export default function useFeedInfo(list: string) { const { data, isLoading, isFetching, isRefetching, error } = useQuery({ queryKey: listInfoKey(list), - queryFn: () => getListInfo(agent, list), + queryFn: () => getListInfo(list, agent), }); return {