Open cezarypiatek opened 5 days ago
I did some investigation and it looks like the method below has invalid signature and hence is not used at all (typo in name s
vs z
and secod parameter is never passed)
https://github.com/xdan/jodit/blob/30bb40f3301a9f85dd3c7a6dcace2cbd6cfe5d30/src/plugins/font/config.ts#L39
Another problem with it is that value
sometimes comes without unit and it's impossible to tell what is the actual unit (sometimes the values is express in px
and sometimes in pt
)
The problems might be cause by the fact that here is used totally different implementation responsible for value normalization https://github.com/xdan/jodit/blob/30bb40f3301a9f85dd3c7a6dcace2cbd6cfe5d30/src/plugins/font/font.ts#L43
Also calling normalize on the list indices seems to be sth completly wrong
Jodit Version: 4.2.43
Browser: Chrome OS: Windows Is React App: True
Issue 1: Incorrectly displayed font size
Jodit config
After changing font size the value is displayed incorrectly on the toolbar (unit duplicated)
Issue 2: After starting new line, the font size in the toolbar has wrong value (14 -> 18 -> 14)
1) Change font to different size then default 2) type 3 lines of text - when starting 3rd line the font size on the toolbard has changed by itself
Issue 3: Default font size not working correctly
Setting the default font size to
12pt
is displayed as16pt
(probably pt <--> px conversion issue)