-
Notifications
You must be signed in to change notification settings - Fork 549
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
Headings can be accidentally nested within themselves #93
Comments
While html should follow basic W3C rules, a quick (not-really-a) fix would be a button that removes the formatting from the current selection. |
@Sjeiti see "removeFormat" https://developer.mozilla.org/en-US/docs/Web/API/Document/execCommand |
@jaredreich yeah I tried that with Pell. It removes formatting set by style but not formatting implied by element. I'm afraid you'll need a custom method to strip all elements for that (also needed for #53). |
@Sjeiti ok I see, thanks for the investigation. I'll have to dig deeper. |
This doesn't happen in all browsers. I tried recreating this problem in both Chrome and Firefox and Firefox works fine. I found this on StackOverflow to help explain the issue. Looks like it could be fixed from chromium since the problem is with how the browser determines the blocks used by formatBlock. |
Repro steps:
The text was updated successfully, but these errors were encountered: