@ones-editor/editor 0.0.7-beta.55 → 0.0.7-beta.57
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js
CHANGED
|
@@ -33375,6 +33375,9 @@ var __publicField = (obj, key, value) => {
|
|
|
33375
33375
|
this.ws.addEventListener(event, callback);
|
|
33376
33376
|
}
|
|
33377
33377
|
}
|
|
33378
|
+
onAuthError(callback) {
|
|
33379
|
+
this.events.addListener("error", callback);
|
|
33380
|
+
}
|
|
33378
33381
|
onWriteConflictError(callback) {
|
|
33379
33382
|
this.events.addListener("writeConflictError", callback);
|
|
33380
33383
|
}
|
|
@@ -33485,6 +33488,9 @@ var __publicField = (obj, key, value) => {
|
|
|
33485
33488
|
}
|
|
33486
33489
|
});
|
|
33487
33490
|
}
|
|
33491
|
+
onAuthError(callback) {
|
|
33492
|
+
this.connection.onAuthError(callback);
|
|
33493
|
+
}
|
|
33488
33494
|
onWriteConflictError(callback) {
|
|
33489
33495
|
this.connection.onWriteConflictError(callback);
|
|
33490
33496
|
}
|
|
@@ -34592,6 +34598,12 @@ var __publicField = (obj, key, value) => {
|
|
|
34592
34598
|
this.doc.on("nothing pending", this.handleNothingPending);
|
|
34593
34599
|
this.doc.on("create", this.handleCreate);
|
|
34594
34600
|
this.doc.on("del", this.handleDel);
|
|
34601
|
+
this.client.onAuthError((err) => {
|
|
34602
|
+
this.callbacks.forEach((cb) => {
|
|
34603
|
+
var _a;
|
|
34604
|
+
return (_a = cb.onError) == null ? void 0 : _a.call(cb, err);
|
|
34605
|
+
});
|
|
34606
|
+
});
|
|
34595
34607
|
this.client.onWriteConflictError(this.handleWriteConflictError);
|
|
34596
34608
|
}
|
|
34597
34609
|
clearEvents() {
|
|
@@ -53115,7 +53127,9 @@ ${codeText}
|
|
|
53115
53127
|
enable(block) {
|
|
53116
53128
|
if (isImageBlock(block)) {
|
|
53117
53129
|
const object = ImageObject.getImageObject(this.editor, block);
|
|
53118
|
-
|
|
53130
|
+
if (this.editor.isBlockWritable(block)) {
|
|
53131
|
+
object.tryEnableResizer();
|
|
53132
|
+
}
|
|
53119
53133
|
}
|
|
53120
53134
|
}
|
|
53121
53135
|
}
|