aboutsummaryrefslogtreecommitdiffstats
path: root/web_src/js/features/repo-legacy.js
diff options
context:
space:
mode:
authorwxiaoguang <wxiaoguang@gmail.com>2021-11-12 20:37:45 +0800
committerGitHub <noreply@github.com>2021-11-12 20:37:45 +0800
commit7f802631c54d2e91301158380b273b872d62bd80 (patch)
treed2c138ae0c01fa557a0601829436bae06ac7861c /web_src/js/features/repo-legacy.js
parent0db7a32b9233d2c0039df4e89356ef0cbcef6dae (diff)
downloadgitea-7f802631c54d2e91301158380b273b872d62bd80.tar.gz
gitea-7f802631c54d2e91301158380b273b872d62bd80.zip
Fix some incorrect async functions, improve frontend document. (#17597)
Diffstat (limited to 'web_src/js/features/repo-legacy.js')
-rw-r--r--web_src/js/features/repo-legacy.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/web_src/js/features/repo-legacy.js b/web_src/js/features/repo-legacy.js
index f4a8c0cf3e..8945360cd5 100644
--- a/web_src/js/features/repo-legacy.js
+++ b/web_src/js/features/repo-legacy.js
@@ -351,6 +351,7 @@ export function initRepository() {
// Edit issue or comment content
$(document).on('click', '.edit-content', async function (event) {
+ event.preventDefault();
$(this).closest('.dropdown').find('.menu').toggle('visible');
const $segment = $(this).closest('.header').next();
const $editContentZone = $segment.find('.edit-content-zone');
@@ -511,7 +512,6 @@ export function initRepository() {
$textarea.focus();
$simplemde.codemirror.focus();
});
- event.preventDefault();
});
initRepoIssueCommentDelete();