LibWeb: Don't attempt to set selection if control has no selectable text

This commit is contained in:
Tim Ledbetter 2024-09-08 23:59:31 +01:00 committed by Jelle Raaijmakers
commit 2c8fb49578
Notes: github-actions[bot] 2024-09-09 09:05:03 +00:00
4 changed files with 18 additions and 0 deletions

View file

@ -0,0 +1,11 @@
<!DOCTYPE html>
<script src="../include.js"></script>
<script>
test(() => {
const inputElement = document.createElement("input");
inputElement.type = "color";
inputElement.value = "#000000";
inputElement.select();
println("PASS (didn't crash)");
});
</script>