Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

interop: Trailing whitespace in h1/h2 is selectable in firefox, not selectable in chrome #149

Open
untitaker opened this issue Jun 13, 2022 · 0 comments

Comments

@untitaker
Copy link

Repro case:

<h1>hello world </h1>

your selection:

<div id=selection />

<script>
    window.setInterval(() => {
        document.getElementById("selection").innerText = "'" + window.getSelection() + "'";
    }, 100);
</script>

there is trailing whitespace in "hello world". That whitespace can be selected in Firefox and is reflected in the selection API, but not in Chrome, and so it is not.

I originally opened whatwg/html#8003, but it was suggested that this is a better place to file this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants