Skip to content

Commit 147c378

Browse files
author
work-2025
committed
merge: (slab#4573) (slab#4614)
1 parent ebe16ca commit 147c378

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/quill/src/modules/clipboard.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,9 +170,9 @@ class Clipboard extends Module<ClipboardOptions> {
170170

171171
onCaptureCopy(e: ClipboardEvent, isCut = false) {
172172
if (e.defaultPrevented) return;
173-
e.preventDefault();
174173
const [range] = this.quill.selection.getRange();
175174
if (range == null) return;
175+
e.preventDefault();
176176
const { html, text } = this.onCopy(range, isCut);
177177
e.clipboardData?.setData('text/plain', text);
178178
e.clipboardData?.setData('text/html', html);
@@ -350,6 +350,7 @@ function isLine(node: Node, scroll: ScrollBlot) {
350350
'table',
351351
'td',
352352
'tr',
353+
'th',
353354
'ul',
354355
'video',
355356
].includes(node.tagName.toLowerCase());

0 commit comments

Comments
 (0)