You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After upgrading to v2.0.0 bulleted lists started showing as numbered lists. This works fine on previous versions.
I'm not sure if this has to do with my custom toolbar implementation, but I'll explain it anyway. My use case requires multiple different editors to share a single toolbar which is not supported out of the box. So I built a system that tracks which editor is currently selected, and implemented custom functions that apply formats (bold, italics, color, list, etc.) to the selected text.
This was inspired by the following comment #633 (comment)
To do this I created the toolbar UI which consists of a collection of buttons that each trigger some function that formats the selected text.
Below is the function that applies the bullet format. (The onNumberedList function is almost identical, instead it sets "list" format to "ordered")
For some reason...
v2.0 doesn't use <ul>, it uses <ol> and then specifies that items are bulleted using <li data-list="bullet">"
Not only this, but if you have any old v1.6 content that you insert using JavaScript that has <ul> then v2.0 actually sanitises (removes) it, leaving you with nothing and scratching your head.
I struggled with this, staring into my code thinking I was doing something wrong.
So I've had to pre-treat v1.6 by replacing <ul> with <ol> and then all the <li> with <li data-list="bullet">".
This seems like the beginning of a nightmare too, as I believe <code></code> may no longer work either as a <div> is used... I'll need to look into that too.
I've done some digging and I can't see a way of calling a function to convert 1.6 text to 2.0 text, that would be a godsend!
After upgrading to v2.0.0 bulleted lists started showing as numbered lists. This works fine on previous versions.
I'm not sure if this has to do with my custom toolbar implementation, but I'll explain it anyway. My use case requires multiple different editors to share a single toolbar which is not supported out of the box. So I built a system that tracks which editor is currently selected, and implemented custom functions that apply formats (bold, italics, color, list, etc.) to the selected text.
This was inspired by the following comment #633 (comment)
To do this I created the toolbar UI which consists of a collection of buttons that each trigger some function that formats the selected text.
Below is the function that applies the bullet format. (The
onNumberedList
function is almost identical, instead it sets "list" format to "ordered")Steps for Reproduction
Expected behavior:
To appear as an unordered (bullet) list.
Actual behavior:
Appears as an ordered list.
Platforms:
Firefox 124.0.2, Windows 10 Home
Version:
2.0.0
The text was updated successfully, but these errors were encountered: