Do not apply a background-color if "null" + allow 0 width #17

Merged
eric-burel merged 2 commits from patch-1 into master 2023-03-27 11:52:35 +02:00
eric-burel commented 2023-03-23 17:00:19 +01:00 (Migrated from github.com)

It's impossible to change the background-color via class because the inline color from style is always preferred. Differentiating "undefined" from "null" allow user to specify when they want no background color to be applied. Especially useful when using Tailwind, Bootstrap.

Also, allowing a 0 width should be possible, for instance to rely instead on borders to display the cursor.

It's impossible to change the background-color via class because the inline color from style is always preferred. Differentiating "undefined" from "null" allow user to specify when they want no background color to be applied. Especially useful when using Tailwind, Bootstrap. Also, allowing a 0 width should be possible, for instance to rely instead on borders to display the cursor.
marijnh commented 2023-03-27 08:30:08 +02:00 (Migrated from github.com)

Could use use false instead of null here? Making null and undefined do different things seems likely to trip people up.

Could use use `false` instead of `null` here? Making null and undefined do different things seems likely to trip people up.
eric-burel commented 2023-03-27 11:31:24 +02:00 (Migrated from github.com)

Yes that's a good idea, done.

Yes that's a good idea, done.
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
prosemirror/prosemirror-dropcursor!17
No description provided.