Browse Source

typo

pull/2078/head
Juan 7 years ago
parent
commit
2c2e2f8c8c
  1. 8
      src/rich_text_editor/index.js

8
src/rich_text_editor/index.js

@ -231,7 +231,7 @@ module.exports = () => {
* Triggered when the offset of the editor is changed
* @private
*/
udpatePosition() {
updatePosition() {
const un = 'px';
const canvas = config.em.get('Canvas');
const pos = canvas.getTargetToElementDim(toolbar, lastEl, {
@ -272,10 +272,10 @@ module.exports = () => {
rte = customRte ? customRte.enable(el, rte) : this.initRte(el).enable();
if (em) {
setTimeout(this.udpatePosition.bind(this), 0);
setTimeout(this.updatePosition.bind(this), 0);
const event = 'change:canvasOffset canvasScroll';
em.off(event, this.udpatePosition, this);
em.on(event, this.udpatePosition, this);
em.off(event, this.updatePosition, this);
em.on(event, this.updatePosition, this);
em.trigger('rte:enable', view, rte);
}

Loading…
Cancel
Save