Source code

Revision control

Copy as Markdown

Other Tools

Test Info:

<!doctype html>
<title>Shouldn't assert when re-creating a ::file-selector-button pseudo-element after it being display: none</title>
<style>
.tweak::file-selector-button {
display: none;
}
</style>
<input type="file">
<script>
let input = document.querySelector("input");
input.getBoundingClientRect().top;
input.classList.add("tweak");
input.getBoundingClientRect().top;
input.classList.remove("tweak");
</script>