From 90232f09560fd70c5754dea3b9e2e209384214c4 Mon Sep 17 00:00:00 2001 From: dawn <90008@gaze.systems> Date: Thu, 21 May 2026 11:20:05 +0300 Subject: [PATCH] fix links in search --- src/views/search.tsx | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/views/search.tsx b/src/views/search.tsx index 32f04a9..05bbaa8 100644 --- a/src/views/search.tsx +++ b/src/views/search.tsx @@ -178,7 +178,7 @@ const RepoContextLink: Component<{ repoDid: Did }> = (props) => { const RepoThreadLink: Component<{ kind: 'issue' | 'pull'; repoDid: Did; - ref: string; + threadRef: string; children: JSX.Element; }> = (props) => { const repoQuery = createQuery(() => ({ @@ -189,7 +189,8 @@ const RepoThreadLink: Component<{ const href = createMemo(() => { const repo = repoQuery.data; if (!repo) return undefined; - return props.kind === 'issue' ? issueHref(repo, props.ref) : pullHref(repo, props.ref); + const fn = props.kind === 'issue' ? issueHref : pullHref; + return fn(repo, props.threadRef); }); return ( @@ -222,7 +223,7 @@ const CommentParentLink: Component<{ hit: SearchHit }> = (props) => { ? (parent().record.value as { repo: Did }).repo : (parent().record.value as { target: { repo: Did } }).target.repo); return ( - + comment on {parent().kind} ); @@ -296,12 +297,12 @@ const ResultTitle: Component<{ hit: SearchHit }> = (props) => { - + {title()} - + {title()} -- 2.51.2