We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b6bcda6 commit d2f0e46Copy full SHA for d2f0e46
highlight-helper.js
@@ -1241,11 +1241,11 @@ if (isTouchDevice && isWebKit) {
1241
tempInput.inputMode = 'none'; // Don't show keyboard
1242
tempInput.tabIndex = -1; // Prevent user from tabbing to input
1243
const initializeSelection = (event) => {
1244
- if (document.readyState !== 'complete') return setTimeout(initializeSelection, 10);
1245
- document.body.append(tempInput);
+ if (document.readyState !== 'complete') return setTimeout(initializeSelection, 20);
+ if (!tempInput.parentElement) document.body.append(tempInput);
1246
tempInput.focus();
1247
setTimeout(() => {
1248
- tempInput.remove();
+ tempInput.blur();
1249
}, 100);
1250
}
1251
initializeSelection();
0 commit comments