bug: thread navigation reload
This commit is contained in:
parent
1e11e6a1a2
commit
e09df95adf
@ -215,13 +215,12 @@ export default function Note(props: NoteProps) {
|
||||
return;
|
||||
}
|
||||
|
||||
e.stopPropagation();
|
||||
if (props.onClick) {
|
||||
e.stopPropagation();
|
||||
props.onClick(eTarget);
|
||||
return;
|
||||
}
|
||||
|
||||
e.stopPropagation();
|
||||
const link = eventLink(eTarget.id, eTarget.relays);
|
||||
// detect cmd key and open in new tab
|
||||
if (e.metaKey) {
|
||||
|
@ -2,7 +2,7 @@ import "./Thread.css";
|
||||
import { useMemo, useState, ReactNode } from "react";
|
||||
import { useIntl } from "react-intl";
|
||||
import { useNavigate, useLocation, Link, useParams } from "react-router-dom";
|
||||
import { TaggedRawEvent, u256, EventKind, encodeTLV, NostrPrefix } from "@snort/nostr";
|
||||
import { TaggedRawEvent, u256, EventKind, NostrPrefix } from "@snort/nostr";
|
||||
import { EventExt, Thread as ThreadInfo } from "System/EventExt";
|
||||
|
||||
import { eventLink, unwrap, getReactions, parseNostrLink, getAllReactions, findTag } from "Util";
|
||||
@ -221,10 +221,7 @@ export default function Thread() {
|
||||
|
||||
function navigateThread(e: TaggedRawEvent) {
|
||||
setCurrentId(e.id);
|
||||
const link = encodeTLV(e.id, NostrPrefix.Event, e.relays);
|
||||
navigate(`/e/${link}`, {
|
||||
replace: true,
|
||||
});
|
||||
//const link = encodeTLV(e.id, NostrPrefix.Event, e.relays);
|
||||
}
|
||||
|
||||
const chains = useMemo(() => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user