Commit 55ebeaaf authored by tom's avatar tom Committed by tom goriunov

enable links to public tags look up page

parent e262937d
import type { EntityTag } from './types'; import type { EntityTag } from './types';
// import { route } from 'nextjs-routes'; import { route } from 'nextjs-routes';
export function getTagLinkParams(data: EntityTag): { type: 'external' | 'internal'; href: string } | undefined { export function getTagLinkParams(data: EntityTag): { type: 'external' | 'internal'; href: string } | undefined {
if (data.meta?.warpcastHandle) { if (data.meta?.warpcastHandle) {
...@@ -17,10 +17,10 @@ export function getTagLinkParams(data: EntityTag): { type: 'external' | 'interna ...@@ -17,10 +17,10 @@ export function getTagLinkParams(data: EntityTag): { type: 'external' | 'interna
}; };
} }
// if (data.tagType === 'generic' || data.tagType === 'protocol') { if (data.tagType === 'generic' || data.tagType === 'protocol') {
// return { return {
// type: 'internal', type: 'internal',
// href: route({ pathname: '/accounts/label/[slug]', query: { slug: data.slug, tagType: data.tagType, tagName: data.name } }), href: route({ pathname: '/accounts/label/[slug]', query: { slug: data.slug, tagType: data.tagType, tagName: data.name } }),
// }; };
// } }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment