mirror of
				https://gitee.com/gitea/gitea
				synced 2025-11-04 16:40:24 +08:00 
			
		
		
		
	Fix EasyMDE image paste bug during refactoring (#18207)
This commit is contained in:
		@@ -458,8 +458,10 @@ export function initRepoPullRequestReview() {
 | 
			
		||||
 | 
			
		||||
  const $reviewBox = $('.review-box');
 | 
			
		||||
  if ($reviewBox.length === 1) {
 | 
			
		||||
    createCommentEasyMDE($reviewBox.find('textarea'));
 | 
			
		||||
    initCompImagePaste($reviewBox);
 | 
			
		||||
    (async () => {
 | 
			
		||||
      await createCommentEasyMDE($reviewBox.find('textarea'));
 | 
			
		||||
      initCompImagePaste($reviewBox);
 | 
			
		||||
    })();
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  // The following part is only for diff views
 | 
			
		||||
 
 | 
			
		||||
@@ -64,10 +64,13 @@ export function initRepoCommentForm() {
 | 
			
		||||
    });
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  createCommentEasyMDE($('.comment.form textarea:not(.review-textarea)'));
 | 
			
		||||
  (async () => {
 | 
			
		||||
    await createCommentEasyMDE($('.comment.form textarea:not(.review-textarea)'));
 | 
			
		||||
    initCompImagePaste($('.comment.form'));
 | 
			
		||||
  })();
 | 
			
		||||
 | 
			
		||||
  initBranchSelector();
 | 
			
		||||
  initCompMarkupContentPreviewTab($('.comment.form'));
 | 
			
		||||
  initCompImagePaste($('.comment.form'));
 | 
			
		||||
 | 
			
		||||
  // List submits
 | 
			
		||||
  function initListSubmits(selector, outerSelector) {
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user