fixed nextjs build with super cringe solution (will be revert in next commit)

This commit is contained in:
Ren Amamiya
2023-04-21 10:45:29 +07:00
parent 5a7389b7e8
commit a2aad487ab
11 changed files with 44 additions and 26 deletions

View File

@@ -18,7 +18,7 @@ export default function AppActions() {
};
const reload = () => {
router.refresh();
window.location.reload();
};
useLayoutEffect(() => {

View File

@@ -10,7 +10,7 @@ export const ChannelListItem = ({ data }: { data: any }) => {
return (
<ActiveLink
href={`/nostr/channels/${data.event_id}`}
href={`/nostr/channels?id=${data.event_id}`}
activeClassName="dark:bg-zinc-900 dark:text-zinc-100 hover:dark:bg-zinc-800"
className="inline-flex items-center gap-2 rounded-md px-2.5 py-1.5 hover:bg-zinc-900"
>

View File

@@ -18,7 +18,7 @@ export default function ChatList() {
const profile = JSON.parse(activeAccount.metadata);
const openSelfChat = () => {
router.push(`/nostr/chats/${activeAccount.pubkey}`);
router.push(`/nostr/chats?pubkey=${activeAccount.pubkey}`);
};
useEffect(() => {

View File

@@ -11,7 +11,7 @@ export const ChatListItem = ({ pubkey }: { pubkey: string }) => {
return (
<ActiveLink
href={`/nostr/chats/${pubkey}`}
href={`/nostr/chats?pubkey=${pubkey}`}
activeClassName="dark:bg-zinc-900 dark:text-zinc-100 hover:dark:bg-zinc-800"
className="inline-flex items-center gap-2 rounded-md px-2.5 py-1.5 hover:bg-zinc-900"
>