Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
TCOTC committed Nov 25, 2024
1 parent 23ee202 commit 3643c21
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/src/boot/globalEvent/click.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ export const globalClick = (event: MouseEvent & { target: HTMLElement }) => {
}
const copyElement = hasTopClosestByClassName(event.target, "protyle-action__copy");
if (copyElement) {
let text = copyElement.parentElement.nextElementSibling.textContent.replace("\n", "");
let text = copyElement.parentElement.nextElementSibling.textContent.replace("/\n$/", "");
text = text.replace(/\u00A0/g, " "); // Replace non-breaking spaces with normal spaces when copying https://github.com/siyuan-note/siyuan/issues/9382
writeText(text);
showMessage(window.siyuan.languages.copied, 2000);
Expand Down

0 comments on commit 3643c21

Please sign in to comment.