+ {props.quotesCount === 0 ? null : (
+
+ Post quotes
+ {props.quotesCount}
+
+ )}
+ {props.showComments === false ? null : (
+
+ Post comments
+ {props.commentsCount}
+
+ )}
+
+ );
+};
const ReaderEmpty = () => {
return (
diff --git a/app/reader/SubscriptionsContent.tsx b/app/reader/SubscriptionsContent.tsx
index 8ab81907..7da17035 100644
--- a/app/reader/SubscriptionsContent.tsx
+++ b/app/reader/SubscriptionsContent.tsx
@@ -1,5 +1,4 @@
import { PubListing } from "app/discover/PubListing";
-import { PublicationsList } from "app/discover/page";
import { ButtonPrimary } from "components/Buttons";
import { DiscoverSmall } from "components/Icons/DiscoverSmall";
import { Json } from "supabase/database.types";
diff --git a/app/reader/page.tsx b/app/reader/page.tsx
index dc233693..e261c420 100644
--- a/app/reader/page.tsx
+++ b/app/reader/page.tsx
@@ -92,7 +92,13 @@ export default async function Reader(props: {}) {
if (!auth_res?.atp_did) return;
let { data: publications } = await supabaseServerClient
.from("publication_subscriptions")
- .select(`publications(*, documents_in_publications(documents(*)))`)
+ .select(
+ `publications(*, documents_in_publications(documents(
+ *,
+ comments_on_documents(count),
+ document_mentions_in_bsky(count)
+ )))`,
+ )
.eq("identity", auth_res?.atp_did);
// get publications to fit PublicationList type
@@ -127,6 +133,9 @@ export default async function Reader(props: {}) {
data: postInPub.documents!.data,
uri: postInPub.documents!.uri,
indexed_at: postInPub.documents!.indexed_at,
+ comments_on_documents: postInPub.documents?.comments_on_documents,
+ document_mentions_in_bsky:
+ postInPub.documents?.document_mentions_in_bsky,
},
}));
}) || [];
@@ -173,11 +182,6 @@ export default async function Reader(props: {}) {
),
},
- discover: {
- controls: null,
- content: <>>,
- href: "/discover",
- },
}}
/>
diff --git a/components/ActionBar/Publications.tsx b/components/ActionBar/Publications.tsx
index d436717d..816bea6c 100644
--- a/components/ActionBar/Publications.tsx
+++ b/components/ActionBar/Publications.tsx
@@ -99,6 +99,8 @@ export const PubIcon = (props: {
}) => {
if (!props.record) return;
+ let iconSizeClassName = `${props.small ? "w-4 h-4" : props.large ? "w-12 h-12" : "w-6 h-6"} rounded-full`;
+
return props.record.icon ? (
) : (
-
+
diff --git a/components/PageLayouts/DashboardLayout.tsx b/components/PageLayouts/DashboardLayout.tsx
index b67f148b..8a4baa75 100644
--- a/components/PageLayouts/DashboardLayout.tsx
+++ b/components/PageLayouts/DashboardLayout.tsx
@@ -122,7 +122,6 @@ export function DashboardLayout<
[name: string]: {
content: React.ReactNode;
controls: React.ReactNode;
- href?: string;
};
},
>(props: {
@@ -135,7 +134,7 @@ export function DashboardLayout<
actions: React.ReactNode;
}) {
let [tab, setTab] = useState(props.defaultTab);
- let { content, controls, href } = props.tabs[tab];
+ let { content, controls } = props.tabs[tab];
let [headerState, setHeaderState] = useState<"default" | "controls">(
"default",
@@ -166,21 +165,6 @@ export function DashboardLayout<
{Object.keys(props.tabs).length > 1 && (
{Object.keys(props.tabs).map((t) => {
- if (props.tabs[t].href)
- return (
-
- setTab(t)}
- />
-
- );
return (