codex-team / codex-team/editor.js
[Bug] The copied HTML data from Editor.js have wrong <p>
- Dominant language
- TypeScript
- Stars
- 31.9k
- Forks
- 2.2k
- Avg merge
- 1d 1h
- Merged PRs (30d)
- 1
Description
Describe a bug.
The copied HTML data from Editor.js have wrong `
`.
`
` can't contain `
`~`
` tags by HTML syntax rule.
https://stackoverflow.com/questions/15656785/should-a-heading-be-inside-or-outside-a-p
Steps to reproduce:
1. Instert the following debug code.
`src/components/modules/rectangleSelection.ts` line 307
```typescript
const textHTML = fakeClipboard.innerHTML;
console.log(textHTML); // debug code
e.clipboardData.setData('text/plain', textPlain);
```
2. Copy an heading block by `ctrl + c` in `example/example-dev.html`

3. The wrong HTML is output to console.
```html
Editor.js
```
Expected behavior: `
`.
Editor.js version: 2.20.1
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.