Extjs HtmlEditor - a numbered list and a list of markers

I am trying to work with HTMLEditor at http://jsfiddle.net/WEEU3/
But when I selected the numbered list or Bullet list for input, I press the keyboard enter key. What is it like enter image description here

I think how

1. first 2. second 3. third 

And when I focus on the third . I click to number. I think, for example,

  1. first 2. second third 

But all the words will be numbered. How to fix it. Thank you very much

+4
source share
1 answer

There seems to be a bug with htmleditor on 4.1.1. In addition, you should not use the new to create ExtJS objects. This will cause other ExtJS problems.

Upgrading to 4.2.x will fix your problem with htmleditor.

Your code should be better formatted. You should also use the correct ExtJS methods to get ie elements:

 Ext.create('Ext.form.Panel', { // should be using Ext.create(), not new title: 'HTML Editor', width: 500, bodyPadding: 10, renderTo: Ext.getBody(), items: [{ xtype: 'htmleditor', name: 'editor', enableColors: true, enableAlignments: false, enableLists: true, enableSourceEdit: false, anchor: '100%' }], dockedItems: [{ xtype: 'toolbar', items: [{ xtype: 'button', text: 'Get HTML', handler: function(btn) { // example of getting all form values console.log(btn.up('form').getForm().getValues()); // proper example of getting by component alert(btn.up('form').down('htmleditor').getValue()); } }] }] }); 
+1
source

Source: https://habr.com/ru/post/1491066/


All Articles