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

Issue #40 - Add ability to select multiple list items at a time for formatting or deletion #77

Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -482,9 +482,9 @@ export default class NestedList {
classes.push(styleClass);

// since tag is either 'ol' or 'ul' we can safely cast it to HTMLOListElement | HTMLUListElement
return Dom.make(tag, [this.CSS.wrapper, ...classes]) as
| HTMLOListElement
| HTMLUListElement;
return Dom.make(tag, [this.CSS.wrapper, ...classes], {
contentEditable: (!this.readOnly).toString()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can't just add contenteditable to the wrapper without preventing default events (and re-implementing them manually) because user can break a tool's DOM by pressing delete, for example.

}) as HTMLOListElement | HTMLUListElement;
}

/**
Expand Down