Skip to content

Latest commit

 

History

History
1528 lines (1323 loc) · 47 KB

CHANGELOG.MD

File metadata and controls

1528 lines (1323 loc) · 47 KB

Changelog

Tags:

  • 💥 [Breaking Change]
  • 🚀 [New Feature]
  • 🐛 [Bug Fix]
  • 📝 [Documentation]
  • 🏠 [Internal]
  • 💅 [Polish]

3.5.4

🐛 Bug Fix

3.5.3

🐛 Bug Fix

3.5.2

🏠 Internal

🐛 Bug Fix

🚀 New Feature

New option link.hotkeys: string[] = ['ctrl+k', 'cmd+k']

Execute new command openLinkDialog. Related: xdan#576

3.5.1

🏠 Internal

  • Removed useAceEditor option. xdan#544
  • Added component and persistent decorators
import {component, persistent} from "./src/core/decorators";

@component
class Item extends UIElement{
    @persistent
    options = {
        some: true
    };
}

const item = new Item(jodit);
console.log(item.options); // {some: true}

item.options = {
 some: false
};

const item2 = new Item(jodit); // or reload page
console.log(item.options); // {some: false}
  • In UIInput added autocomplete, clearButton, icon options.

🐛 Bug Fix

🚀 New Feature

Jodit.atom

Jodit.Array and Jodit.Object marked as deprecated. In 3.5 they will be removed. Instead, use Jodit.atom.

const editor = Jodit.make('#editor', {
    buttons: Jodit.atom(['bold', 'italic']),
    popup: {
        img: Jodit.atom({
            // full rewrite
        })
    }
});
New option observer.maxHistoryLength: number = Infinity

Related with xdan#574. In some cases need to limit size of undo history.

New options in link.plugin
  • @property {"input"|"select"|""} link.modeClassName="input" Use an input text to ask the classname or a select or not ask
  • @property {boolean} link.selectMultipleClassName=true Allow multiple choises (to use with modeClassName="select")
  • @property {number} link.selectSizeClassName=3 The size of the select (to use with modeClassName="select")
  • @property {IUIOption[]} link.selectOptionsClassName=[] The list of the option for the select (to use with modeClassName="select")
  • ex: [
  •   	{ value: "", text: "" },
    
  •   	{ value: "val1", text: "text1" },
    
  •   	{ value: "val2", text: "text2" },
    
  •   	{ value: "val3", text: "text3" }
    
  •   ]
    

PR: xdan#577 Thanks @s-renier-taonix-fr

New option statusbar: boolean = true

Issue xdan#535

const editor = Jodit.make('#editor', {
   statusbar: false
});
console.log(editor.statusbar.isShown); // false
editor.statusbar.show();
console.log(editor.statusbar.isShown); // true
Buttons groups

The buttons option can contain named groups of buttons. Each plugin decides which button belongs to which group. Thus, if you turn off the plugin, then its buttons will not be shown either. Available groups: ["source", "font-style", "script", "list", "indent", "font", "color", "media", "state", "clipboard", "insert", "history", "search", "other", "info"];

const editor = Jodit.make('#editor', {
    buttons: [
        {
            group: "custom",
            buttons: []
        },
        "bold"
    ]
});

Jodit.defaultOptions.controls.someButton = {
    icon: 'pencil',
    command: 'selectall'
};

Jodit.plugins.add('somePlugin', function (editor) {
    editor.registerButton({
        name: 'someButton',
        group: 'custom'
    });
})
Hotkeys for BackSpace and Delete and remove part of text

Added hotkey settings for Delete and Backspace buttons. And added hotkey ctrl+backspace for removing left part of text. Issue: xdan#532

Jodit.make('#editor', {
    delete: Jodit.atom({
        hotkeys: {
            delete: ['delete', 'cmd+backspace'],
            deleteWord: ['ctrl+delete', 'cmd+alt+backspace', 'ctrl+alt+backspace'],
            backspace: ['backspace'],
            backspaceWord: ['ctrl+backspace']
        }
    })
});
Added one method in event system
const editor = Jodit.make('#editor');

editor.events
    .one('keydown', () => {
        console.log('Fire only one time');
    })
    .on('keydown', () => {
        console.log('Fire everytime');
    });

3.4.28

🐛 Bug Fix

🚀 New Feature

Added extraIcons option. By default, you can only install an icon from the Jodit suite. You can add your icon to the set using the Jodit.modules.Icon.set (name, svg Code) method. But for a declarative declaration, you can use this option.

Jodit.modules.Icon.set('someIcon', '<svg><path.../></svg>');
const editor = Jodit.make({
	extraButtons: [
		{
			name: 'someButton',
			icon: 'someIcon'
		}
	]
});
const editor = Jodit.make({
	extraIcons: {
		someIcon: '<svg><path.../></svg>'
	},
	extraButtons: [
		{
			name: 'someButton',
			icon: 'someIcon'
		}
	]
});
const editor = Jodit.make({
	extraButtons: [
		{
			name: 'someButton',
			icon: '<svg><path.../></svg>'
		}
	]
});

3.4.27

  • xdan#514 Run command insertUnorderedList & insertOrderedList should replace all headings (h1, h2, etc) to ul>li

3.4.26

🐛 Bug Fix

🚀 New Feature

  • xdan#513 allow set percentage and another points inside width and height inputs

3.4.25

Features

  • xdan#489 In textIcons - besides boolean, you can put function(key: string): boolean;
var editor = new Jodit('#editor', {
    textIcons: (key) => key !== 'bold'
})

3.4.24

Bug fixes

3.4.22

Features

Added maxHeight option.

const jodit = Jodit.make('#editor', {
    minHeight: 200,
    maxHeight: 500
});

3.4.18

3.4.16

Bug fixes

Features

  • Added Find and Preview buttons
  • xdan#417 Added defaultFontSizePoints options. Possible values pt or px. By default: px
const editor = new Jodit('#editor', {
    defaultFontSizePoints: 'pt'
});
  • xdan#449 Added showCharsCounter options.
const editor = new Jodit('#editor', {
    language: 'en',
    showCharsCounter: true,
    countHTMLChars: true
});

editor.value = '<p>Simple text</p><p>Simple text</p>';
const statusbar = editor.container.querySelector(
'.jodit-status-bar'
);

expect(
    statusbar.textContent.match(/Chars: 36/)
).is.not.null;

3.4.15

3.4.13

Bug fixes

3.4.12

Bug fixes

  • xdan#424 Fixed allowTabNavigation By default: false.
const jodit = new Jodit('#editor', {
    allowTabNavigation: true // enable tab navigation between toolbar's buttons
});

3.4.2

Bug fixes

xdan#359

3.4

Bug fixes

Features

  • All less variables were replaced to css custom properties for modern browsers.
  • Added WrapTextNodes plugin - it wrap all alone text node(or inline elements) inside options.enter element. You can disable this behaviour:
const editor = Jodit.make('#editor', {
    disablePlugins: ['WrapTextNodes']
})
  • Added shadowRoot option for ShadowDom support.

ACE source editor does not support Shadow Dom

<div id="editor"></div>
const app = document.getElementById("editor");
app.attachShadow({ mode: "open" });
const root = app.shadowRoot;

root.innerHTML = `
<link rel="stylesheet" href="./build/jodit.css"/>
<h1>Jodit example in Shadow DOM</h1>
<div id="edit"></div>
`;

var editor = new Jodit(root.getElementById("edit"), {
    globalFullSize: false,
    shadowRoot: root
});
editor.value = "<p>start</p>";
  • From NativeEvent.on method was removed selector argument. It was jQuery.live style. Example:
<div class="test">
    <button>1</button>
    <button>2</button>
</div>

Earlier, you can use something like this

editor.events.on(document.querySelector('div'), 'click', function () {
    alert(this.innerText);
}, 'button')

Now, you should use event.target

editor.events.on(document.querySelector('div'), 'click', function (e) {
    alert(e.target.innerText);
})
  • Select.applyCSS was renamed to Select.applyStyle
const editor = Jodit.make('#editor');
editor.s.applyStyle({color: 'red'}) // will add to all selection text - red color
  • FileBrowser, Dialog etc. modules which extend View has only one argument in the constructor - options. Before:
const editor = Jodit.make('#editor');
const fb = Jodit.modules.FileBrowser(editor, {
    ajax: {
        url: 'https://xdsoft.net'
    }
});
fb.open();
fb.close();

editor.destruct();
fb.open(); // error, fb is already destructed

Now:

const editor = Jodit.make('#editor');
const fb = Jodit.modules.FileBrowser({
    ajax: {
        url: 'https://xdsoft.net'
    }
});
fb.open();
fb.close();

editor.destruct();
fb.open(); // Normal

fb.destruct();
//or
editor.e.on('beforeDestruct', () => {
    fb.destruct();
});
  • Split table plugin on select-cells and resize-cells plugins. useTableProcessor was removed. Instead, use
Jodit.make('#editor', {table: {
	allowCellSelection: true,
	selectionCellStyle: 'border: 1px double #1e88e5 !important;',

	allowCellResize: true,
	useExtraClassesOptions: true
}});
  • All less files were moved near with TS. Class naming was changed closer to BEM.
  • Removed PopupList and Popup. Instead, use only PopupMenu.
  • Added ui.button and ui.list for working with buttons. toolbar.button extends ui.button. UIButton - is reactive:
const button = new UIButton();
button.state.activated = true; // will automatically change setAttribute('area-pressed', 'true')
button.state.icon = 'plus'; // will add `svg` icon in container

// or use `setState`
button
    .setState({
        text: "Click me"
    })
    .onAction(() => {
        Jodit.Alert('Click');
    })
    .appendTo(document.body); // will append it inside the body
  • In tsconfig added decorators supports. Methods that need binding binds with @autobind decorator.
  • Added watch decorator.
  • All filenames were renamed to kebab-case.
  • Added short aliases for. Can be used as chain - this.j.e.on
    • this.jodit => this.j
    • this.options => this.o
    • this.selection => this.s
    • this.create => this.c
    • this.events => this.e
    • this.ownerDocument => this.od
    • this.ownerWindow => this.ow
    • this.editorDocument => this.ed
    • this.editorWindow => this.ew
  • Change name Dialog.setTitle to Dialog.setHeader
  • Remove Create.inside field and instead added Jodit.createInside
  • In popups added position strategies: 'leftBottom' | 'rightBottom' | 'leftTop' | 'rightTop' etc.

3.3.24

BugFix

3.3.23

BugFix

Feature

  • Added Dom.isTag method
const editor = Jodit.make('#editor');

const a = editor.createInside.element('a');
const br = document.createElement('br');

Jodit.modules.Dom.isTag(a, 'a') // true
Jodit.modules.Dom.isTag(br, 'br') // true
  • Added Helpers.call method
const f = Math.random();
Jodit.modules.Helpers.call(f > 0.5 ? Math.ceil : Math.floor, f);
  • Added Helpers.position method - Helper function to get an element's exact position
console.log(Jodit.modules.Helpers.position(editor.editor.querySelector('p')));

3.3.19

BugFix

Feature

  • In link plugin added formTemplate and formClassName options #333
const editor = getJodit({
  link: {
    formTemplate: function() {
      return '<form class="form_url"><input ref="url_input" type="url"><button>save</button></form>';
    },
    formClassName: "some_class"
  }
});
  • Added deprecated mechanism. Some methods will not be removed and only will be marked as deprecated until major release. #330

3.3.16

Added createAttributes option #243 All elements which will be inserted in editor will be created with these attributes

const editor2 = Jodit.make('#editor', {
    createAttributes: {
      div: {
        class: 'test'
      },
      ul: function (ul) {
        ul.classList.add('ui-test');
      }
    }
});

const div2 = editor2.createInside.div();
expect(div2.className).equals('test');

const ul = editor2.createInside.element('ul');
expect(ul.className).equals('ui-test');

3.3.15

Bugfix

Fixed SPLIT_MODE

Feature

Added editHTMLDocumentMode in order to allow the user to edit the entire document #241.

Also added iframeTitle and iframeDoctype options

const editor = Jodit.make('#editor', {
	iframe: true,
	iframeTitle: 'Hello world!',
	iframeDoctype: '<!DOCTYPE html>',
	editHTMLDocumentMode: true,
	iframeStyle: ''
});

console.log(editor.value);

// <html dir="" class="jodit" lang="en" spellcheck="true" style="min-height: 113px;">
// <head>
//     <title>Hello world!</title>
// </head>
// <body class="jodit-wysiwyg" style="outline:none">test test <a href="#">test</a></body>
// </html>

3.3.14

Bugfix

Fixed xdan#316 Fixed bug when Jodit was initialized inside iframe.

const iframe = document.createElement('iframe');
document.body.appendChild(iframe);

const win = iframe.contentWindow;
const doc = win.document;
doc.open();
doc.write('<html><body><textarea id="editor"></textarea><' + 'script src="./build/jodit.js"><' + '/script></body></html>');
doc.close();

Jodit.make('#editor', {
	ownerWindow: win,
	ownerDocument: doc
});

Fixed bug with ProgressBar - it simply does not work(

Feature

Source plugin was separated on several classes. Now you can choose SourceEditor or make yourself (xdan#242)

Before

Jodit.make('#editor', {
	useAceEditor: true
});

Now

Jodit.make('#editor', {
	sourceEditor: 'area' || 'ace' // || 'mirror' in PRO
});

In PRO version you can choose mirrror&

  • Added Async module for control asynchronous operations
const editor = new Jodit('#editor');
setTimeout(() => {
	editor.s.insertHTML('Hello!')
}, 1000);

editor.async.setTimeout(() => {
	editor.s.insertHTML('World!')
}, 1000);

editor.destruct();

After destruct the first timeout will throw the error, but second will be cleared.

Added two methods setPanel and addPlace

<textarea id="editor"></textarea>
<textarea id="editor2"></textarea>
<textarea id="editor3"></textarea>
<div id="toolbar"></div>
const editor = new Jodit('#editor');
editor.setPanel('#toolbar');
//add id instance to editor
editor.addPlace('#editor2');
editor.addPlace('#editor3');

Events

Added afterRemoveNode event

const editor = new Jodit('#editor');
editor.events.on('afterRemoveNode', (node) => {
	if (node.nodeName === 'IMG') {
		fetch('delete.php', {image: node.src});
	}
});

3.3.8

Plugin system was changed

Before

Jodit.plugins.insertText = function (editor) {
    editor.events.on('someEvent', function (text) {
        editor.s.insertHTMl('Hello ' + text);
    });
};

Now

Jodit.plugins.add('insertText', function (editor) {
    editor.events.on('someEvent', function (text) {
        editor.s.insertHTMl('Hello ' + text);
    });
});
console.log(Jodit.plugins.get('insertText'));
Jodit.plugins.remove('insertText');

extraPlugins options

Inside plugin you can use several fields:

// emoji.js

class Emoji {
    hasStyle = true; //
    requires = ['autocomplete'];
    init(editor) {
        // this code will be execute only after autocomplete.init
    }
}

Jodit.plugins.add('emoji', Emoji);

And inside you init code

Jodit.make('#editor', {
	basePath: 'https://sitename.com/somepath/',
	extraPlugins: ['emoji']
});

It will try to download

https://sitename.com/somepath/plugins/emoji/emoji.js

hasStyle = true; means try download and include in page style file:

https://sitename.com/somepath/plugins/emoji/emoji.css

In plugins/example folder you can find an example.

extraPlugins option allows appending in editor extra plugins from npm, bower etc.

Build System

In Build system was added gulp subsystem to build extra plugins. You can make extra plugins like plugins/example and after build, this plugin will not be inside jodit.min.js file. It will be in separate folder (eg build/plugins/emoji/).

Also in root you can find make.js file for install your plugin in build system.


2.5.61

Added zIndex option

var editor = new Jodir('.editor', {
    zIndex: 10000
})

2.5.60

  • Fix table editor in iframe mode
  • Fix styles

2.5.57

  • Added useIframeResizer option for resize IFRAME tag Iframe resizer
  • Added offsetTopForAssix option. For example, in Joomla, the top menu bar closes Jodit toolbar when scrolling. Therefore, it is necessary to move the toolbar Jodit by this amount
var editor = new Jodit('#editor', {
    offsetTopForAssix: 74
});

Without affix offset Without affix With affix offset Withou affix

2.5.55

Added Embed video button. Added vimeo or youtube video embeded code.

2.5.54

When you insert text into the editor from another site, all the images are from a remote site. Before Jodit, it was quite uncomfortable: first I had to download the image from a remote resource, and then upload it to your site, then replace the image in the editor. In 2.5.54 it can be done in 3 clicks

Upload remote image

Note. Need update PHP Connector

2.5.53

Added Jodit.focus method

var editor = new Jodit('.redactor');
editor.focus();

2.5.52

Added OK button in Alert dialog

More About dialogs

Alert

Jodit.Alert("File was uploaded");
Jodit.Alert("File was uploaded", "Message");
Jodit.Alert("File was uploaded", function() {
   $('form').hide();
});
Jodit.Alert("File wasn't uploaded", "Error", function() {
   $('form').hide();
});

Promt

Promt dialog

Jodit.Promt("Enter your name", function (name) {
    if (name.length < 3) {
        Jodit.Alert("The name must be at least 3 letters");
        return false;
    }
    // do something
});
Jodit.Promt("Enter your name", "Promt Dialog", function (name) {
    if (name.length < 3) {
        Jodit.Alert("The name must be at least 3 letters");
        return false;
    }
    // do something
});

Confirm

Confirm dialog

Jodit.Confirm("Are you shure?", function (yes) {
    if (yes) {
        // do something
    }
});

2.5.49

First step for Mobile-friendly sizeLG,sizeMD,sizeSM and sets of buttons for different sizes editors.

Note. this is not the width of the device, the width of the editor

  • buttons The list of buttons that appear in the editor's toolbar on large places (≥ options.sizeLG).
  • buttonsMD The list of buttons that appear in the editor's toolbar on medium places (≥ options.sizeMD).
  • buttonsSM The list of buttons that appear in the editor's toolbar on small places (≥ options.sizeSM).
  • buttonsXS The list of buttons that appear in the editor's toolbar on extra small places (< options.sizeSM).
var editor = new Jodit('#some-editor', {
    sizeLG: 900,
    sizeMD: 700,
    sizeSM: 400,

    buttons: [
        'source', '|',
        'bold',
        'italic', '|',
        'ul',
        'ol', '|',
        'font',
        'fontsize',
        'brush',
        'paragraph', '|',
        'image',
        'table',
        'link', '|',
        'left',
        'center',
        'right',
        'justify', '|',
        'undo', 'redo', '|',
        'hr',
        'eraser',
        'fullsize',
        'about'
    ],
    buttonsMD: [
        'source', '|',
        'bold',
        'italic', '|',
        'ul',
        'ol', '|',
        'font',
        'fontsize',
        'brush',
        'paragraph', '|',
        'image',
        'table',
        'link', '|',
        'left',
        'center',
        'right',
        'justify', '|',
        'undo', 'redo', '|',
        'hr',
        'eraser',
        'fullsize'
    ],
    buttonsSM: [
        'bold',
        'italic', '|',
        'ul',
        'ol', '|',
        'fontsize',
        'brush',
        'paragraph', '|',
        'image',
        'table',
        'link', '|',
        'left',
        'center',
        'right', '|',
        'undo', 'redo', '|',
        'eraser',
        'fullsize'
    ],
    buttonsXS: [
        'bold',
        'image', '|',
        'brush',
        'paragraph', '|',
        'left',
        'center',
        'right', '|',
        'undo', 'redo', '|',
        'eraser'
    ],
});

2.5.46

  • More comfortable colorpicker

More comfortable colorpicker

2.5.45

  • Fixed bug in Image Resizer when border was less than Image
  • Rename Selection.setCursorTo to Selection.moveCursorTo
  • Fixed style for Dialog resizer

2.5.42

Fix a few bugs in JJE

2.5.40

  • In Helper module added [isHTML] method. Used plugin insertHTML
  • Added simple plugin insertHTML and him option askBeforePasteHTML - Ask before paste HTML in WYSIWYG mode. Try insert in WYSIWYG mode some HTML source
(function ($) {
    "use strict";
    Jodit.defaultOptions = $.extend(true, Jodit.defaultOptions, {
        /**
         * @property {boolean} askBeforePasteHTML=true Ask before paste HTML in WYSIWYG mode
         */
        askBeforePasteHTML: true
    });

    /**
     * Ask before paste HTML source
     *
     * @module insertHTML
     */
    Jodit.plugins.insertHTML = function (parent) {
        if (parent.options.askBeforePasteHTML) {
            parent.events.on('beforePaste', function (event) {
                if (event && event.clipboardData && event.clipboardData.getData && event.clipboardData.types[0] === 'text/plain') {
                    var html = event.clipboardData.getData('text/plain');
                    if (parent.helper.isHTML(html)) {
                        Jodit.Confirm('Your code is similar to HTML. Paste as HTML?', 'Paste as HTML', function (agree) {
                            if (agree) {
                                parent.s.insertHTML(html);
                            } else {
                                parent.s.insertHTML(parent.helper.htmlspecialchars(html));
                            }
                            parent.syncCode(true);
                        });
                        return false;
                    }
                }
            });
        }
    };
}(Jodit.modules.Dom));

2.5.39

Fix #issue 11 in file: mode CDN CodeMirror not working

2.5.38

  • Added Filter in FileBrowser
  • Added SortBy in FileBrowser

2.5.37

  • Fixed bug in Beautifier plugin. When in source mode, start comment enter <!-- Browser stops responding.
  • Added tiles and list switcher in filebrowser

2.5.36

  • In PHP FileBrowser connector added MaxFileSize option
  • Fixed popap error in filebrowser

2.5.30

Fix Splitmode autohaight Autoheight in Split mode Jodit Fix syncronize code in TableProcessor module

2.5.28

Fix bug in Dialog.Confirm

Jodit.Confirm("Are you shure?", "Confirm", function (success) {
    if (success) {
        alert("Agree");
    }
});

2.5.27

var editor = new Jodit("#example2_0", {
    textIcons: true,
    removeButtons: [
        "hr",
        "ol",
        "about",
        "italic",
        "format",
        "fullsize",
        "justify"
    ]
});

Text icons Text icons in filebrowser

2.5.26

Dom Module is now compatible with jQuery objects

var a = jQuery("<a href="#link">Link</a>");
jodit.modules.Dom('.selector').append(a);
jodit.modules.Dom(jQuery("#someid")).val();
jodit.modules.Dom("#someid").val();

But you must remember that Jodit.modules.Dom! = JQuery

2.5.23

2.5.20

2.5.19

Added cleanHTML.allowTags option.

var editor = Jodit('#editor', {
    allowTags: 'p,a[href],table,tr,td, img[src=1.png]' // allow only <p>,<a>,<table>,<tr>,<td>,<img> tags and for <a> allow only `href` attribute and <img> allow only `src` atrribute == '1.png'
});
editor.val('Sorry! <strong>Goodby</strong> <span>mr.</span> <a style="color:red" href="http://xsoft.net">Freeman</a>');
console.log(editor.val()); //Sorry! <a href="http://xsoft.net">Freeman</a>

Or you can use PlainObject. This code equivalent to the top

var editor = Jodit('#editor', {
    allowTags: {
        p: true,
        a: {
            href: true
        },
        table: true,
        tr: true,
        td: true,
        img: {
            src: '1.png'
        }
    }
});

2.5.18

Fixed bug in Image plugin

2.5.17

Fixed bug in JJE

2.5.16

  • Fixed a few styles

2.5.15

  • Fixed package.json

2.5.13

  • Added in FileBrowser sort options
  • Jodit.Promt and Jodit.Alert by default set focus to OK button
Jodit.Promt('Enter your name', function (name) {
    if (!name.length) {
        Jodit.Alert('You need enter 3 chars');
        return false;
    }
    //... some logic
});
  • Fix $config bug in JJE
  • Added a few options in JJE plugin

2.5.12

Added edit button in Image Properties Dialog Edit button

2.5.11

2.5.1

2.4.22

  • Added contextmenu module.
  • Added context menu in FileBrowser
  • Added preview in FilwBrowser

2.4.21

  • Fixed TableProcessor's bugs. In a situation did not appear resizer cells and the resizer throughout the table.

2.4.20

  • Fixed z-index Popap
  • Fixed behavior of selection table cells

2.4.17

Fixed copy-paste html behavior

2.4.16

Fixed bug on after type Enter

2.4.15

Fixed bug with insert OL tag and Fixed Dom module work with Text node

2.4.12

Added toolbarButtonSize Size of icons in the toolbar (can be "small", "middle", "large")

var editor  = new  Jodit("#editor", {
    toolbarButtonSize: "small"
});

2.4.10

var editor = new Jodit('.jodit'),
    node = editor.node.create('text', 'Hellow world');
editor.s.insertNode(node);

2.4.8

Fixed Base icons issue

2.4.6

Fast Fixed in JJE Fixed a lot of bugs in Jodit

2.4.1

  • Fixed a lot of bugs in Dom module
  • Fixed a lot of bugs in TableProcessor module
  • Replace PNG icon on SVG sprite
  • Added new module Icons
  • Added theme Dark
  • Fixed bug Popap's module
  • Divide one less file by modules

2.3.59

2.3.57

  • Fixed issue with input[type=checkbox] and Dom.attr method
  • Release Joomla Jodit Editor (JJE) Download JJE

2.3.53

2.3.49

Added iframeBaseUrl option - Base URL where the root directory for iframe mode

2.3.48

Added spellcheck option specifies whether the editor is to have its spelling and grammar checked or not

2.3.47

Added removeEmptyBlocks option - Remove empty blocks

var editor = new Jodit('#editor', {
   removeEmptyBlocks: false
});
editor.val(' ');// add space in editor
console.log(editor.val()); //<p>&nbsp;</p>

editor.options.removeEmptyBlocks = true;
editor.val(' ');
console.log(editor.val()); //''

2.3.46

  • Fixed critical bug in Safari (window.performance)
  • Fixed bug when editor can get selection from another place

2.3.44

Added direction option. The writing direction of the language which is used to create editor content. Allowed values are:

  • '' (an empty string) – Indicates that content direction will be the same as either the editor UI direction or the page element direction.
  • 'ltr' – Indicates a Left-To-Right text direction (like in English).
  • 'rtl' – Indicates a Right-To-Left text direction (like in Arabic).

2.3.43

Fixed styles bugs

2.3.41

When filebrowser.showFoldersPanel === false show 4 colums in filelist

2.3.40

2.3.39

Fixed Filebrowser uploader's options bug. Previously , you had to either use a general Uploader module settings , or override them completely

var editor = new Jodit('.redactor', {
    filebrowser: {
        uploader: null
    },
    uploader: {
        url: 'uploader.php',
        format: 'json',
    }
});

// or
var editor = new Jodit('.redactor', {
    filebrowser: {
        uploader:  {
            url: 'uploader.php',
            format: 'json',
            filesVariableName: 'fils',
            //... all options from [uploader](http://xdsoft.net/jodit/doc/Jodit.defaultOptions.html#uploader)
        }
    }
});

Now you can just override some of your settings

var editor = new Jodit('.redactor', {
    filebrowser: {
        uploader: {
            url: 'uploader2.php',
        }
    },
    uploader: {
        url: 'uploader.php',
    }
});

2.3.38

  • Fixed i18n bug
  • useSplitMode set default false
  • Fixed toolbar width after fullsize mode
  • Fixed #issue5

2.3.37

Fast fix

2.3.36

  • Added plugin Fullsize. Now you can change fullsize mode
var editor = new Jodit();
editor.events.fire('toggleFullsize');
editor.events.fire('toggleFullsize', [true]); // fullsize
editor.events.fire('toggleFullsize', [false]); // usual mode
  • Added globalFullsize (default true) if true, after fullsize - all parents element get jodit_fullsize_box class (z-index: 100000 !important;)
  • Fixed focus bug

2.3.35

  • Fixed placeholder style
  • Fixed Dom.css then
<div class="idclass" style="margin-top:20px;"></div>
Jodit.modules.Dom('.idclass').css('margin-top');//has returned string `20px`
Jodit.modules.Dom('.idclass').css('margin-top');//now it returns int `20`

2.3.33

2.3.32

Added uploader.data option. Data to be sent to the server like POST parameters

2.3.31

Added editorCssClass option - Class name that can be appended to the editor Fixed internacionalization

2.3.30

Added triggerChangeEvent option Fixed uploader's options - When the uploader is not configured, the editor still displays images upload button

2.3.29

Add Dom.defaultAjaxOptions.async By default, all requests are sent asynchronously (i.e. this is set to true by default). If you need synchronous requests, set this option to false

2.3.28

Added headers option in {@link module:FileBrowser|FileBrowser} and {@link module:Uploader|Uploader}. But primarily in {@link module:Dom|Dom}

var token = document.querySelector('meta[name="csrf-token"]').getAttribute('content'),
    editor = new Jodit("#redactor", {
        uploader: {
            url: '../connector/index.php?action=upload',
            headers: {
                'X-CSRF-Token': token
            }
        },
        filebrowser: {
            ajax: {
                url: '../connector/index.php',
                headers: {
                    'X-CSRF-Token': token
                }
            }
        },
    });
// or replace global options
Jodit.modules.Dom.defaultAjaxOptions.headers = {
    headers: {
        'X-CSRF-Token': token
    }
};
Jodit.modules.Dom.ajax({
    url: 'data.json',
    headers: {
        'Accept-Language': 'en-US,en;q=0.8,ru;q=0.6,de;q=0.4,ja;q=0.2'
    },
    success: function (resp) {
        console.log(resp)
    }
})

2.3.27

Fixed #issues1

2.3.24

Fixed dialog's module when was opened Promt window, after Enter submit the form and the page reloaded. Fixed connector's bugs Update Jodit.i18n method. Now it can be used staticly

var editor = new Jodit("#redactor", {
     langusage: 'ru'
});
console.log(editor.i18n('Cancel')) //Отмена;

Jodit.defaultOptions.language = 'ru';
console.log(Jodit.prototype.i18n('Cancel')) //Отмена

Jodit.lang.cs = {
   Cancel: 'Zrušit'
};
Jodit.defaultOptions.language = 'cs';
console.log(Jodit.prototype.i18n('Cancel')) //Zrušit

Jodit.lang.cs = {
   'Hello world': 'Hello 1$ Good 2$'
};
Jodit.defaultOptions.language = 'cs';
console.log(Jodit.prototype.i18n('Hello world', 'mr.Perkins', 'day')) //Hello mr.Perkins Good day

Fixed Jodit.destroy method

var editor = new Jodit('.jodit');
editor.destroy();

2.3.22

Fixed bug when Dialog module was used without Jodit context

Jodit.Alert('Hello world!!!');

2.3.20

Fixed dialog's module zIndex manage. Fixed Dom.css method bug. That example has not worked.

Jodit.modules.Dom('.someelement').css('z-index', 1000)

2.3.19

Fixed bug in Uploader module when http://sitename.net/jodit///files/fg.jpg was replaced http:/sitename.net/jodit/files/fg.jpg

2.3.18

Added afterInsertImage event - triggered after image was inserted selection.insertImage. This method can executed from Filebrowser or Uploader

var editor = new Jodit("#redactor");
editor.events.on('afterInsertImage', function (image) {
    image.className = 'bloghead4';
});

2.3.15

Fixed bug with inserting table

2.3.14

Work with table became faster

2.3.12

  • Fixed filbrowser bug. When a new file is uploaded file list has not been updated
  • Added dialog.zIndex option

2.3.11

Fixed toolbar width fot fullsize mode

2.3.10

  • Fixed CodeMirror bug on download XML parser
  • Fixed CodeMirror bug endless cycle
  • Fixed overflow behavior in fullsize mode

2.3.8

Fixed connector problem and Fixed item's style in filebrowser

2.3.3

Switched on FontAwesome icons

2.3.0

Added copy-paste image file for FireFox

2.2.6

Fixed copy-paste for FireFox

2.2.5

Added copy-paste support by clipboard image. Try paste print screen.

2.2.4

Added the ability in the file browser to obtain data about the file not as a string and as an object with parameters {file: 'name.jpg', thumb: '_thumbs/name.jpg'}

2.2.3

Fixed conflict between textProcessor and Beatyfier plugins

2.2.2

Fixed BACKSPACE entering behavior. And Fixed ie10 support

2.2.0

Added iframe, iframeStyle, iframeIncludeJoditStyle, iframeCSSLinks, width, height, minHeight. iframe by default false. When this option is enabled, the editor's content will be placed in an iframe and isolated from the rest of the page. width and height you can set size fot editor

2.1.0

Added internationalization. Read more http://xdsoft.net/jodit/doc/Jodit.defaultOptions.html#.language

2.0.9

Added Split mode. Added useSplitMode options (default true) Example here

2.0.8

Fixed dialog bug

2.0.4

Added CodeMirror plugin. Enable by default {@link defaultOptions~codeMirror.|options.codeMirror}

2.0.0

We got rid of jQuery

1.2.1

Fixed bug in filebrowser

1.2.0

Fixed bug when selection.insertHTML dosn't work without focus

1.1.0

Fixed bug with uploader and filebrowser

1.0.6

If source textarea has placeholder attribute then Jodit use it how placeholder

1.0.4

Added About button

1.0.1

First release