Skip to content

Commit c2282dd

Browse files
deand0npionxzh
authored andcommitted
fix: super long string can be partially selected without collapsing
1 parent 76322b9 commit c2282dd

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/components/DataTypes/String.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ export const stringType = defineEasyType<string>({
2525
cursor: hasRest ? 'pointer' : 'inherit'
2626
}}
2727
onClick={() => {
28+
if (window.getSelection()?.type === 'Range') {
29+
return
30+
}
31+
2832
if (hasRest) {
2933
setShowRest(value => !value)
3034
}

0 commit comments

Comments
 (0)