1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-06 10:37:20 +00:00

Fix readme path and markdown link paste (#34755)

This commit is contained in:
wxiaoguang
2025-06-18 12:19:54 +08:00
committed by GitHub
parent 08c634b7b7
commit b38813878c
3 changed files with 4 additions and 4 deletions

View File

@ -135,7 +135,7 @@ function handleClipboardText(textarea: HTMLTextAreaElement, e: ClipboardEvent, p
// when pasting links over selected text, turn it into [text](link)
const pastedAsMarkdown = pasteAsMarkdownLink(textarea, pastedText);
if (pastedText) {
if (pastedAsMarkdown) {
e.preventDefault();
replaceTextareaSelection(textarea, pastedAsMarkdown);
}