Skip to content

Commit

Permalink
fix: hashtag search (#4305)
Browse files Browse the repository at this point in the history
  • Loading branch information
bigint committed Dec 21, 2023
2 parents 5e447b4 + add7d54 commit 260eee9
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
11 changes: 7 additions & 4 deletions apps/web/src/components/Shared/Markup/MarkupLink/Hashtag.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import isPrideMonth from '@hey/lib/isPrideMonth';
import stopEventPropagation from '@hey/lib/stopEventPropagation';
import { Leafwatch } from '@lib/leafwatch';
import Link from 'next/link';
import urlcat from 'urlcat';

const Hashtag: FC<MarkupLinkProps> = ({ title }) => {
if (!title) {
Expand All @@ -23,12 +24,14 @@ const Hashtag: FC<MarkupLinkProps> = ({ title }) => {
<span className="inline-flex items-center space-x-1">
<span>
<Link
href={`/search?q=${title.slice(1)}&type=pubs&src=link_click`}
href={urlcat('/search', {
q: title,
src: 'link_click',
type: 'pubs'
})}
onClick={(event) => {
stopEventPropagation(event);
Leafwatch.track(PUBLICATION.CLICK_HASHTAG, {
hashtag: title.slice(1)
});
Leafwatch.track(PUBLICATION.CLICK_HASHTAG, { hashtag: tag });
}}
>
{isPrideHashtag ? <span className="pride-text">{title}</span> : title}
Expand Down
4 changes: 2 additions & 2 deletions apps/web/src/components/Shared/Navbar/NavItems/Logout.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { FC } from 'react';

import { ArrowRightOnRectangleIcon } from '@heroicons/react/24/outline';
import { ArrowRightStartOnRectangleIcon } from '@heroicons/react/24/outline';
import { PROFILE } from '@hey/data/tracking';
import { useRevokeAuthenticationMutation } from '@hey/lens';
import cn from '@hey/ui/cn';
Expand Down Expand Up @@ -66,7 +66,7 @@ const Logout: FC<LogoutProps> = ({ className = '', onClick }) => {
}}
type="button"
>
<ArrowRightOnRectangleIcon className="size-4" />
<ArrowRightStartOnRectangleIcon className="size-4" />
<div>Logout</div>
</button>
);
Expand Down

1 comment on commit 260eee9

@vercel
Copy link

@vercel vercel bot commented on 260eee9 Dec 21, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

web – ./

web-heyxyz.vercel.app
heyxyz.vercel.app
web-git-main-heyxyz.vercel.app
hey.xyz

Please sign in to comment.