Merge branch 'release/2.16' of github.com:codex-team/editor.js into release/2.16

This commit is contained in:
Yegor Berizhnoi 2019-11-30 23:31:10 +03:00
commit f50abf4636
7 changed files with 8 additions and 28 deletions

6
dist/editor.js vendored

File diff suppressed because one or more lines are too long

View file

@ -16,6 +16,7 @@
`Fix` — Fixed History Back on block deletion by Backspace in Firefox [#967](https://github.com/codex-team/editor.js/pull/967)
- `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)
- `Fix` — Fixed wrong navigation on block deletion
### 2.15.1

View file

@ -106,7 +106,7 @@ If you are using your custom `Initial Block`, `placeholder` property is passed i
## Log level
You can specify log level for Editor.js console messages via `logLevel' property of configuration:
You can specify log level for Editor.js console messages via `logLevel` property of configuration:
```js
var editor = new EditorJS({

View file

@ -17,10 +17,8 @@ export default class DeleteTune implements BlockTune {
/**
* Styles
* @type {{wrapper: string}}
*/
private CSS = {
wrapper: 'ass',
button: 'ce-settings__button',
buttonDelete: 'ce-settings__button--delete',
buttonConfirm: 'ce-settings__button--confirm',

View file

@ -97,7 +97,7 @@ export default class DomIterator {
*/
private leafNodesAndReturnIndex(direction: string): number {
/**
* if items is empty then there is nothing to leaf
* if items are empty then there is nothing to leaf
*/
if (this.items.length === 0) {
return this.cursor;

View file

@ -87,13 +87,9 @@ export default class BlocksAPI extends Module {
}
/**
* In case of deletion first block we need to set caret to the current Block
* After Block deletion currentBlock is updated
*/
if (this.Editor.BlockManager.currentBlockIndex === 0) {
this.Editor.Caret.setToBlock(this.Editor.BlockManager.currentBlock);
} else {
this.Editor.Caret.navigatePrevious(true);
}
this.Editor.Caret.setToBlock(this.Editor.BlockManager.currentBlock, this.Editor.Caret.positions.END);
this.Editor.Toolbar.close();
}

View file

@ -67,21 +67,6 @@
border-bottom-color: #d5d7db;
}
&::before {
//content: '';
width: 10px;
height: 10px;
position: absolute;
top: -6px;
left: 50%;
margin-left: -6px;
transform: rotate(-45deg);
background-color: #fff;
z-index: -1;
border: 1px solid #EAEAEA;
border-width: 1px 1px 0 0;
}
&--left-oriented {
&::before {
left: 15px;