@anu3ev/fabric-image-editor 0.8.24 → 0.8.25
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/main.js +5 -5
- package/package.json +1 -1
package/dist/main.js
CHANGED
|
@@ -7254,7 +7254,7 @@ var Si = class {
|
|
|
7254
7254
|
}, this._handleTextChanged = (e) => {
|
|
7255
7255
|
if (!(e.target instanceof v)) return;
|
|
7256
7256
|
let t = e.target;
|
|
7257
|
-
U(t.group) && this.runtime.syncShapeTextLayoutAfterTextMutation({ textNode: t }) && this.runtime.editor.canvas.requestRenderAll();
|
|
7257
|
+
U(t.group) && (this.runtime.editor.textManager.syncLineStylesWithText({ textbox: t }), this.runtime.syncShapeTextLayoutAfterTextMutation({ textNode: t }) && this.runtime.editor.canvas.requestRenderAll());
|
|
7258
7258
|
}, this._handleBeforeTextUpdated = (e) => {
|
|
7259
7259
|
let { textbox: t, style: n } = e;
|
|
7260
7260
|
if (!(t instanceof v)) return;
|
|
@@ -11179,10 +11179,10 @@ var Wa = class {
|
|
|
11179
11179
|
e !== i && n.set({ text: e }), n.textCaseRaw = l;
|
|
11180
11180
|
} else n.textCaseRaw = i;
|
|
11181
11181
|
if (!r && o === void 0 && (n.autoExpand = !0), r) {
|
|
11182
|
-
this.
|
|
11182
|
+
this.syncLineStylesWithText({ textbox: n });
|
|
11183
11183
|
return;
|
|
11184
11184
|
}
|
|
11185
|
-
this.
|
|
11185
|
+
this.syncLineStylesWithText({ textbox: n }), this._normalizeTextboxAfterContentChange({
|
|
11186
11186
|
textbox: n,
|
|
11187
11187
|
placement: u,
|
|
11188
11188
|
shouldAutoExpand: c,
|
|
@@ -11237,7 +11237,7 @@ var Wa = class {
|
|
|
11237
11237
|
resolveTextObject: (e) => this._resolveTextObject(e),
|
|
11238
11238
|
normalizeTextboxAfterContentChange: (e) => this._normalizeTextboxAfterContentChange(e),
|
|
11239
11239
|
restoreTextboxContentPlacement: (e) => this._restoreTextboxContentPlacement(e),
|
|
11240
|
-
syncLineStylesWithText: (e) => this.
|
|
11240
|
+
syncLineStylesWithText: (e) => this.syncLineStylesWithText(e),
|
|
11241
11241
|
getSnapshot: (t) => e._getSnapshot(t)
|
|
11242
11242
|
} }), this.editingPlacementState = /* @__PURE__ */ new WeakMap(), this.isTextEditingActive = !1, this._bindEvents(), Ia();
|
|
11243
11243
|
}
|
|
@@ -11414,7 +11414,7 @@ var Wa = class {
|
|
|
11414
11414
|
let { canvas: e } = this;
|
|
11415
11415
|
e.on("object:scaling", this.scalingController.handleObjectScaling), e.on("object:resizing", this._handleObjectResizing), e.on("object:modified", this.scalingController.handleObjectModified), e.on("mouse:move", this.scalingController.handleMouseMove), e.on("text:editing:entered", this._handleTextEditingEntered), e.on("text:editing:exited", this._handleTextEditingExited), e.on("text:changed", this._handleTextChanged);
|
|
11416
11416
|
}
|
|
11417
|
-
|
|
11417
|
+
syncLineStylesWithText({ textbox: e, previousText: t, currentText: n }) {
|
|
11418
11418
|
let r = n ?? e.text ?? "", i = Xi({
|
|
11419
11419
|
textbox: e,
|
|
11420
11420
|
previousText: t ?? e.__lineDefaultsPrevText ?? r,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@anu3ev/fabric-image-editor",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.25",
|
|
4
4
|
"description": "TypeScript image editor library built on FabricJS, allowing you to create instances with an integrated montage area and providing an API to modify and manage state.",
|
|
5
5
|
"module": "dist/main.js",
|
|
6
6
|
"files": [
|