Fix embedded note content escaping

This commit is contained in:
Bojan Mojsilovic 2024-02-06 13:28:58 +01:00
parent ac780f455c
commit 72cd3d9d2e

View File

@ -20,6 +20,8 @@ const EmbeddedNote: Component<{ note: PrimalNote, mentionedUsers?: Record<string
const threadContext = useThreadContext();
const intl = useIntl();
let noteContent: HTMLDivElement | undefined;
const noteId = () => nip19.noteEncode(props.note.post.id);
const navToThread = () => {
@ -94,12 +96,13 @@ const EmbeddedNote: Component<{ note: PrimalNote, mentionedUsers?: Record<string
</span>
</span>
</div>
<div class={styles.noteContent}>
<div class={styles.noteContent} ref={noteContent}>
<ParsedNote
note={props.note}
ignoreMentionedNotes={true}
shorten={true}
isEmbeded={true}
width={noteContent?.getBoundingClientRect().width}
/>
</div>
</>