Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release/2.17 #1063

Merged
merged 75 commits into from
Mar 14, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
75 commits
Select commit Hold shift + click to select a range
c221a64
2.16.0
Jul 8, 2019
fdeae3f
[Refactor] Separate internal and external settings (#845)
gohabereg Jul 10, 2019
af581d3
Enable flipping tools via standalone class (#830)
khaydarov Jul 15, 2019
0d1c86c
fixed a link in readme.md (#856)
Jul 30, 2019
52669d7
Fix Block selection via CMD+A (#829)
khaydarov Jul 31, 2019
d22667d
Improve style of selected blocks (#858)
neSpecc Jul 31, 2019
e2ca2a6
Fix case when property 'observer' in modificationObserver is not defi…
VLZH Sep 7, 2019
1623839
Bump lodash.template from 4.4.0 to 4.5.0 (#885)
dependabot[bot] Sep 8, 2019
3ab0435
Bump eslint-utils from 1.3.1 to 1.4.2 (#886)
dependabot[bot] Sep 8, 2019
749894b
Bump mixin-deep from 1.3.1 to 1.3.2 (#887)
dependabot[bot] Sep 8, 2019
bbcc13a
update bundle and readme
neSpecc Sep 8, 2019
fc9e13a
Update README.md
neSpecc Sep 8, 2019
3bfaa20
upd codeowners, fix funding
neSpecc Sep 8, 2019
72ee05a
Merge branch 'master' into release/2.16
neSpecc Oct 3, 2019
56839f7
Minor Docs Fix according to main Readme (#916)
ChaituVR Oct 20, 2019
a438185
Inline Toolbar now contains Conversion Toolbar (#932)
neSpecc Nov 20, 2019
a9c4649
Block lifecycle hooks (#906)
gohabereg Nov 21, 2019
d086b6d
[Fix] Arrow selection (#964)
gohabereg Nov 30, 2019
ea3c767
[issue-926]: fix dom iterator leafing when items are empty (#958)
khaydarov Nov 30, 2019
461f9a5
Issue 869 (#963)
gohabereg Nov 30, 2019
3e2bf87
Fix issue 943 (#965)
gohabereg Nov 30, 2019
36f69f0
[Draft] Feature/tooltip enhancements (#907)
khaydarov Nov 30, 2019
b19cb06
[issue-779]: Grammarly conflicts (#956)
khaydarov Nov 30, 2019
2e9faf1
Submodule Header now on master
neSpecc Nov 30, 2019
0689c82
Submodule Marker now on master
neSpecc Nov 30, 2019
533512e
Submodule Paragraph now on master
neSpecc Nov 30, 2019
7547e11
Submodule InlineCode now on master
neSpecc Nov 30, 2019
0d54c94
Submodule Simple Image now on master
neSpecc Nov 30, 2019
fa4b282
[issue-868]: Deleting multiple blocks triggers back button in Firefox…
khaydarov Nov 30, 2019
729f2ea
pass options on removeEventListener (#904)
MarinaZadoyanchuk Nov 30, 2019
1e20882
[Fix] Selection rangecount (#968)
gohabereg Nov 30, 2019
bee449b
Fix #952 (#969)
neSpecc Nov 30, 2019
fdcedb2
Update codex.tooltips
neSpecc Nov 30, 2019
053e25e
Merge branch 'release/2.16' of https://github.com/codex-team/editor.j…
neSpecc Nov 30, 2019
2729f8f
Selection bugfix (#970)
khaydarov Nov 30, 2019
c6f5be6
remove inline toolbar closing on cross block selection mouse up due t…
khaydarov Nov 30, 2019
cff5434
[Feature] Log levels (#971)
gohabereg Nov 30, 2019
ba2fe25
Decrease margins (#973)
neSpecc Nov 30, 2019
9661916
Update src/components/domIterator.ts
neSpecc Nov 30, 2019
6682034
[Fix] Fix delete blocks api method (#974)
gohabereg Nov 30, 2019
f3f94e3
Update docs/usage.md
neSpecc Nov 30, 2019
5910fa8
rm unused
neSpecc Nov 30, 2019
630cb76
Update yarn.lock file
Nov 30, 2019
f50abf4
Merge branch 'release/2.16' of github.com:codex-team/editor.js into r…
Nov 30, 2019
755f429
upd bundle, changelog
neSpecc Nov 30, 2019
964652d
Resolve Firefox issues (#981)
neSpecc Dec 3, 2019
f262bd7
Set initial hidden Inline Toolbar position (#982)
neSpecc Dec 3, 2019
4a9c65d
[Fix] tooltip types (#986)
gohabereg Dec 7, 2019
22b6f80
Fix to set minHeight 0px (#987)
hata6502 Dec 7, 2019
952c148
[Fix] Selection issues (#988)
gohabereg Dec 7, 2019
3476413
[Dev] Update dependencies (#989)
gohabereg Dec 7, 2019
738019f
Merge branch 'master' into release/2.16
neSpecc Dec 7, 2019
a1917da
Delete codex.tooltips
neSpecc Dec 7, 2019
83fcf82
Update submodules
Dec 7, 2019
aae8ca6
Fix/hide conversion toolbar (#991)
khaydarov Dec 7, 2019
7525427
Update CHANGELOG.md
neSpecc Dec 7, 2019
5679fd1
fix some problems at example
neSpecc Mar 3, 2020
b1c2822
Update CHANGELOG.md
neSpecc Mar 3, 2020
e3a7d88
Fix: bind editor when calling onChange (#1048)
melbahja Mar 3, 2020
c8827b5
updated some wording. (#1044)
drbe4t Mar 3, 2020
84eeefa
Fix grammar in readme.md (#1008)
darrelfrancis Mar 3, 2020
9df986c
Merge branch 'master' into release/2.17
neSpecc Mar 3, 2020
0bb7141
Update editor.js
neSpecc Mar 3, 2020
74c7533
Paste listener on editors instead of document (#1025)
ponnex Mar 3, 2020
bc3e290
Bump acorn from 6.4.0 to 6.4.1 (#1059)
dependabot[bot] Mar 14, 2020
3a83a1d
Fix flipper activate/deactivate when conversionToolbarOpened (#1001)
aablinov Mar 14, 2020
e10da45
[Issue-1057]: open new window by clicking anchor with ctrl (#1062)
khaydarov Mar 14, 2020
92eab3b
Fix settings box-sizing (#1013)
hata6502 Mar 14, 2020
06d657c
Improvements: new Block Settings button style (#1064)
neSpecc Mar 14, 2020
3877380
[Feature] In-house copy paste (#1060)
gohabereg Mar 14, 2020
8b838bf
New block lifecycle hook and BlockToolAPI: "moved" (#1007)
natterstefan Mar 14, 2020
a5513a3
Change paste function of text/plain (#1014)
hata6502 Mar 14, 2020
c1860c9
Improve paste function of multiple lines (#1016)
hata6502 Mar 14, 2020
b7e4f91
2.17.0
gohabereg Mar 14, 2020
834930d
Update bundle
gohabereg Mar 14, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 25 additions & 31 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ If you like Editor.js you can support project improvements and development of ne

👉 [https://opencollective.com/editorjs](https://opencollective.com/editorjs)

👉 Bitcoin: `3DCCemgtE6GrzehVpU6Sa2RJHFUUh8iT9q`

### Sponsors

Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [[Become a sponsor](https://opencollective.com/editorjs#sponsor)]
Expand All @@ -36,11 +34,11 @@ Support this project by becoming a sponsor. Your logo will show up here with a l

This project exists thanks to all the people who contribute. <img src="https://opencollective.com/editorjs/contributors.svg?width=890&button=false" />

We are really welcome new contributors. If you want to make some code with us, please take a look at the [Good First Tasks](https://github.com/codex-team/editor.js/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+task%22). You can write to us on `[email protected]` or via special [Telegram chat](https://t.me/editorjsdev), or any other way.
We really welcome new contributors. If you want to make some code with us, please take a look at the [Good First Tasks](https://github.com/codex-team/editor.js/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+task%22). You can write to us on `[email protected]` or via special [Telegram chat](https://t.me/editorjsdev), or any other way.

## Documentation

Please, visit [https://editorjs.io/](https://editorjs.io) to view all documentation articles.
Please visit [https://editorjs.io/](https://editorjs.io) to view all documentation articles.

- [Base concepts](https://editorjs.io/base-concepts)
- [Getting started](https://editorjs.io/getting-started)
Expand All @@ -53,37 +51,37 @@ You can join a [Gitter-channel](https://gitter.im/codex-team/editor.js) or [Tele

## Changelog

See a whole [Changelog](/docs/CHANGELOG.md)
See the whole [Changelog](/docs/CHANGELOG.md)

## So how to use Editor.js
## How to use Editor.js

### Basics

Editor.js is a Block-Styled editor. Blocks are structural units, of which the Entry is composed.
For example, `Paragraph`, `Heading`, `Image`, `Video`, `List` are Blocks. Each Block is represented by Plugin.
We have [many](http://github.com/editor-js/) ready-to-use Plugins and a [simple API](https://editorjs.io/tools-api) for creating new ones.

So how to use the Editor after [Installation](https://editorjs.io/getting-started).
How to use the Editor after [Installation](https://editorjs.io/getting-started).

- Create new Blocks by Enter or with the Plus Button
- Create new Blocks by pressing Enter or clicking the Plus Button
- Press `TAB` or click on the Plus Button to view the Toolbox
- Press `TAB` again to leaf Toolbox and select a Block you need. Then press Enter.


![](https://github.com/editor-js/list/raw/master/assets/example.gif)

- Select text fragment and apply a style or insert a link from the Inline Toolbar
- Select a text fragment and apply a style or insert a link from the Inline Toolbar

![](https://capella.pics/7ccbcfcd-1c49-4674-bea7-71021468a1bd.jpg)

- Use «three-dots» button on the right to open Block Settings. From here, you can move and delete a Block
or apply Tool's settings, if it provided. For example, set a Heading level or List style.
- Use the «three-dots» button on the right to open Block Settings. From here, you can move and delete a Block
or apply a Tool's settings, if it provided. For example, you can set a Heading level or List style.

![](https://capella.pics/01a55381-46cd-47c7-b92e-34765434f2ca.jpg)

### Shortcuts

We really appreciate shortcuts. So there are few presets.
A few shortcuts are preset as available.

Shortcut | Action | Restrictions
-- | -- | --
Expand All @@ -94,7 +92,7 @@ Shortcut | Action | Restrictions
`CMD+I` | Italic style | On selection
`CMD+K` | Insert a link | On selection

Also we support shortcuts on the all type of Tools. Specify a shortcut with the Tools configuration. For example:
Each Tool can also have its own shortcuts. These are specified in the configuration of the Tool, for example:

```js
var editor = new EditorJS({
Expand Down Expand Up @@ -123,17 +121,17 @@ There are few steps to run Editor.js on your site.
2. [Load Tools](#load-tools)
3. [Initialize Editor's instance](#create-editor-instance)

### Load Editor's core
### Step 1. Load Editor's core

Firstly you need to get Editor.js itself. It is a [minified script](dist/editor.js) with Editor's core and some default must-have tools.
Get Editor.js itself. It is a [minified script](dist/editor.js) with Editor's core and some default must-have tools.

Choose the most usable method of getting Editor for you.

- Node package
- Source from CDN
- Local file from project

#### Node.js
##### Option A. NPM install

Install the package via NPM or Yarn

Expand All @@ -147,43 +145,39 @@ Include module in your application
const EditorJS = require('@editorjs/editorjs');
```

#### Use from CDN
##### Option B. Use a CDN

You can load specific version of package from [jsDelivr CDN](https://www.jsdelivr.com/package/npm/@editorjs/editorjs).
You can load EditorJS directly from from [jsDelivr CDN](https://www.jsdelivr.com/package/npm/@editorjs/editorjs).

`https://cdn.jsdelivr.net/npm/@editorjs/editorjs@latest`

Then require this script.
For example, place this in your HTML:

```html
<script src="..."></script>
<script src="https://cdn.jsdelivr.net/npm/@editorjs/editorjs@latest"></script>
```

#### Save sources to project
##### Option C. Save source within your project

Copy [editor.js](dist/editor.js) file to your project and load it.
Copy the [editor.js](dist/editor.js) file to your project and load it.

```html
<script src="editor.js"></script>
```

### Load Tools

Each Block at the Editor.js is represented by [Tools](docs/tools.md). There are simple external scripts with their own logic. Probably you want to use several Block Tools that should be connected.
### Step 2. Load the Tools that you want to make available

For example check out our [Header](https://github.com/editor-js/header) Tool that represents heading blocks.

You can install Header Tool by the same way as the Editor (Node.js, CDN, local file).

Check [Editor.js's community](https://github.com/editor-js/) to see more ready-to-use Tools.
Each Block is represented by a [Tool](docs/tools.md). Tools are simple external scripts with their own logic. For example, there is a [Header](https://github.com/editor-js/header) Tool into which you type your heading text. If you want to be able to use this, install the Header Tool the same way as the Editor (Node.js, CDN, local file).

**Example:** use Header from CDN

```html
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/bundle.js"></script>
```

### Create Editor instance
Check [Editor.js's community](https://github.com/editor-js/) to see more ready-to-use Tools.

### Step 3. Create Editor instance

Create an instance of Editor.js and pass [Configuration Object](types/configs/editor-config.d.ts) with `holderId` and tools list.

Expand Down
2 changes: 1 addition & 1 deletion dist/editor.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/editor.js.LICENSE
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*!
* Editor.js
*
* @version 2.16.1
* @version 2.17.0
*
* @licence Apache-2.0
* @author CodeX <https://codex.so>
Expand Down
11 changes: 5 additions & 6 deletions dist/sprite.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
54 changes: 34 additions & 20 deletions docs/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,45 @@
# Changelog

### 2.17

- `Improvements` - Editor's [onchange callback](https://editorjs.io/configuration#editor-modifications-callback) now accepts an API as a parameter
- `Fix` - Some mistakes are fixed in [installation.md](installation.md)
- `Fix` - Fixed multiple paste callback triggering in a case when several editors are instantiated [#1011](https://github.com/codex-team/editor.js/issues/1011)
- `Fix` - Fixed inline toolbar flipper activation on closing conversion toolbar [#995](https://github.com/codex-team/editor.js/issues/995)
- `Improvements` - New window tab is opened by clicking on anchor with ctrl [#1057](https://github.com/codex-team/editor.js/issues/1057)
- `Fix` - Fix block-tune buttons alignment in some CSS-resetors that forces `box-sizing: border-box` rule [#1003](https://github.com/codex-team/editor.js/issues/1003)
- `Improvements` - New style of a Block Settings button. Focused block background removed.
- `New` — Add in-house copy-paste support through `application/x-editor-js` mime-type
- `New` Block [lifecycle hook](tools.md#block-lifecycle-hooks) `moved`
- `Deprecated` — [`blocks.swap(fromIndex, toIndex)`](api.md) method is deprecated. Use `blocks.move(toIndex, fromIndex)` instead.
- `Fix` — Improve plain text paste [#1012](https://github.com/codex-team/editor.js/issues/1012)
- `Fix` — Fix multiline paste [#1015](https://github.com/codex-team/editor.js/issues/1015)

### 2.16.1

- `Fix` — Fix Firefox bug with incorrect height and cursor position of empty content editable elements [#947](https://github.com/codex-team/editor.js/issues/947) [#876](https://github.com/codex-team/editor.js/issues/876) [#608](https://github.com/codex-team/editor.js/issues/608) [#876](https://github.com/codex-team/editor.js/issues/876)
- `Fix` — Set initial hidden Inline Toolbar position [#979](https://github.com/codex-team/editor.js/issues/979)
- `Fix` — Fix issue with CodeX.Toolips TypeScript definitions [#978](https://github.com/codex-team/editor.js/issues/978)
- `Fix` — Set initial hidden Inline Toolbar position [#979](https://github.com/codex-team/editor.js/issues/979)
- `Fix` — Fix issue with CodeX.Toolips TypeScript definitions [#978](https://github.com/codex-team/editor.js/issues/978)
- `Fix` — Fix some issues with Inline and Tunes toolbars.
- `Fix` - Fix `minHeight` option with zero-value issue [#724](https://github.com/codex-team/editor.js/issues/724)
- `Improvements` — Disable Conversion Toolbar if there are no Tools to convert [#984](https://github.com/codex-team/editor.js/issues/984)
- `Improvements` — Disable Conversion Toolbar if there are no Tools to convert [#984](https://github.com/codex-team/editor.js/issues/984)

### 2.16

- `Improvements` — Inline Toolbar design improved
- `Improvements` — Conversion Toolbar now included in the Inline Toolbar [#853](https://github.com/codex-team/editor.js/issues/853)
- `Improvements` — All buttons now have beautiful Tooltips provided by [CodeX Tooltips](https://github.com/codex-team/codex.tooltips)
- `New` — new Tooltips API for displaying tooltips near your custom elements
- `New` — new Tooltips API for displaying tooltips near your custom elements
- `New` *API* — Block [lifecycle hooks](tools.md#block-lifecycle-hooks)
- `New` *Inline Tools API* — Ability to specify Tool's title via `title` static getter.
- `New` *Inline Tools API* — Ability to specify Tool's title via `title` static getter.
- `Fix` — On selection from end to start backspace is working as expected now [#869](https://github.com/codex-team/editor.js/issues/869)
- `Fix` — Fix flipper with empty dom iterator [#926](https://github.com/codex-team/editor.js/issues/926)
- `Fix` — Normalize node before walking through children at `isEmpty` method [#943](https://github.com/codex-team/editor.js/issues/943)
- `Fix` — Fixed Grammarly conflict [#779](https://github.com/codex-team/editor.js/issues/779)
- `Improvements` — Module Listeners now correctly removes events with options [#904](https://github.com/codex-team/editor.js/pull/904)
- `Improvements` — Styles API: `.cdx-block` default vertical margins decreased from 0.7 to 0.4 ems.
- `Fix` — Fixed History Back on block deletion by Backspace in Firefox [#967](https://github.com/codex-team/editor.js/pull/967)
- `Improvements` — Styles API: `.cdx-block` default vertical margins decreased from 0.7 to 0.4 ems.
- `Fix` — Fixed `getRangeCount` call if range count is 0 [#938](https://github.com/codex-team/editor.js/issues/938)
- `New` — Log levels now available to suppress Editor.js console messages [#962](https://github.com/codex-team/editor.js/issues/962)
- `New` — Log levels now available to suppress Editor.js console messages [#962](https://github.com/codex-team/editor.js/issues/962)
- `Fix` — Fixed wrong navigation on block deletion

### 2.15.1
Expand All @@ -38,10 +52,10 @@

### 2.15

- `New` — New [`blocks.insert()`](api.md) API method [#715](https://github.com/codex-team/editor.js/issues/715).
- `New` — New [`blocks.insert()`](api.md) API method [#715](https://github.com/codex-team/editor.js/issues/715).
- `New` *Conversion Toolbar* — Ability to convert one block to another [#704](https://github.com/codex-team/editor.js/issues/704)
- `New` *Cross-block selection* — Ability to select multiple blocks by mouse and with SHIFT+ARROWS [#703](https://github.com/codex-team/editor.js/issues/703)
- `Deprecated` — [`blocks.insertNewBlock()`](api.md) method is deprecated. Use `blocks.insert()` instead.
- `Deprecated` — [`blocks.insertNewBlock()`](api.md) method is deprecated. Use `blocks.insert()` instead.
- `Improvements` — Inline Toolbar now works on mobile devices [#706](https://github.com/codex-team/editor.js/issues/706)
- `Improvements` — Toolbar looks better on mobile devices [#706](https://github.com/codex-team/editor.js/issues/706)
- `Improvements` — Now `pasteConfig` can return `false` to disable paste handling on your Tool [#801](https://github.com/codex-team/editor.js/issues/801)
Expand All @@ -67,9 +81,9 @@
- `Deprecated` *Config* - `holderId` property now is deprecated and will removed in next major release. Use `holder` instead.
- `Fix` *Types* — Fixed error with `codex-notifier` package [#713](https://github.com/codex-team/editor.js/issues/713)
- `Improvements` — Close inline toolbar after creating a new link.
- `New` *Config* — Option `minHeight` for customizing Editor's bottom zone height added.
- `New` *Config* — Option `minHeight` for customizing Editor's bottom zone height added.

### 2.12.4
### 2.12.4

- `Improvements` — CodeX.Shortcuts version updated to the v1.1 [#684](https://github.com/codex-team/editor.js/issues/684)
- `Fix` — Do not start multi-block selection on Toolbox and Inline Toolbar [#646](https://github.com/codex-team/editor.js/issues/646)
Expand All @@ -82,15 +96,15 @@

### 2.12.2

- New *Inline Tools* — pass tool settings from configuration to Tool constructor
- New *Inline Tools* — pass tool settings from configuration to Tool constructor

### 2.12.1

- `Fix` — Fix processing `color-mod` function in styles

### 2.12.0
### 2.12.0

- `New` *API* - new `blocks` API method `renderFromHTML`
- `New` *API* - new `blocks` API method `renderFromHTML`

### 2.11.11

Expand All @@ -102,7 +116,7 @@

### 2.11.9

- `Fix` - Fix inline toolbar buttons margin. Update dependencies list. Update tools for example page.
- `Fix` - Fix inline toolbar buttons margin. Update dependencies list. Update tools for example page.

### 2.11.8

Expand Down Expand Up @@ -192,7 +206,7 @@

- `Fix` — cmd+x works only for custom selection now

### 2.7.28
### 2.7.28

- `New` [Tools Validation](https://github.com/codex-team/editor.js/blob/master/docs/tools.md#validate-optional) is added.

Expand Down Expand Up @@ -222,9 +236,9 @@
- `New` *Sanitize API* — [Sanitize Config](https://github.com/codex-team/editor.js/blob/master/docs/tools.md#automatic-sanitize) of `Block Tools` now automatically extends by tags of `Inline Tools` that is enabled by current Tool by `inlineToolbar` option. You don't need more to specify `a, b, mark, code` manually. This feature will be added to fields that supports inline markup.
- `New` *Block Selection* — Ability to select Block by `CMD+A`, and the whole Editor by double `CMD+A`. After that, you can copy (`CMD+C`), remove (`Backspace`) or clear (`Enter`) selected Blocks.
- `New` *[Styles API](https://github.com/codex-team/editor.js/blob/master/types/api/styles.d.ts)* — Added `button` class for stylization of any buttons provided by Tools with one unified style.
- `New` *[Notifier API](https://github.com/codex-team/editor.js/blob/master/docs/api.md#notifierapi)* — methods for showing user notifications: on success, errors, warnings, etc.
- `New` *Block Tool* — [Table](http://github.com/editor-js/table) constructor 💪
- `New` If one of the Tools is unavailable on Editor initialization, its Blocks will be rendered with *Dummy Block*, describing that user can not edit content of this Block. Dummy Blocks can be moved, removed and saved as normal Blocks. So saved data won't be lost if one of the Tools is failed
- `New` *[Notifier API](https://github.com/codex-team/editor.js/blob/master/docs/api.md#notifierapi)* — methods for showing user notifications: on success, errors, warnings, etc.
- `New` *Block Tool* — [Table](http://github.com/editor-js/table) constructor 💪
- `New` If one of the Tools is unavailable on Editor initialization, its Blocks will be rendered with *Dummy Block*, describing that user can not edit content of this Block. Dummy Blocks can be moved, removed and saved as normal Blocks. So saved data won't be lost if one of the Tools is failed
- `New` [Public TS-types](https://github.com/codex-team/editor.js/tree/master/types) are presented.
- `Changes` *Tools API* — options `irreplaceable` and `contentless` was removed.
- `Changes` *Tools API* — [Paste API](https://github.com/codex-team/editor.js/blob/master/docs/tools.md#paste-handling): tags, patterns and mime-types now should be specified by Tool's `pasteConfig` static property. Custom Paste Event should be handled by `onPaste(event)` that should not be static from now.
Expand Down
6 changes: 5 additions & 1 deletion docs/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,11 @@ Methods that working with Blocks

`renderFromHTML(data)` - parse and render passed HTML string (*not for production use*)

`swap(fromIndex, toIndex)` - swaps two Blocks by their positions
`swap(fromIndex, toIndex)` - swaps two Blocks by their positions (deprecated:
use 'move' instead)

`move(toIndex, fromIndex)` - moves block from one index to another position.
`fromIndex` will be the current block's index by default.

`delete(blockIndex?: Number)` - deletes Block with passed index

Expand Down
Loading