@pixldocs/canvas-renderer 0.5.32 → 0.5.33
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.cjs +4 -13
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +4 -13
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -12743,6 +12743,7 @@ class PixldocsRenderer {
|
|
|
12743
12743
|
return null;
|
|
12744
12744
|
}
|
|
12745
12745
|
async waitForStableTextMetrics(container, config) {
|
|
12746
|
+
var _a, _b, _c;
|
|
12746
12747
|
if (typeof document !== "undefined") {
|
|
12747
12748
|
void ensureFontsForResolvedConfig(config);
|
|
12748
12749
|
await this.waitForRelevantFonts(config);
|
|
@@ -12754,21 +12755,11 @@ class PixldocsRenderer {
|
|
|
12754
12755
|
clearFabricCharCache();
|
|
12755
12756
|
clearMeasurementCache();
|
|
12756
12757
|
};
|
|
12757
|
-
const reflowTextboxes = () => {
|
|
12758
|
-
var _a, _b, _c;
|
|
12759
|
-
clearFontCacheAndRerender(fabricInstance);
|
|
12760
|
-
(_a = fabricInstance.calcOffset) == null ? void 0 : _a.call(fabricInstance);
|
|
12761
|
-
(_b = fabricInstance.renderAll) == null ? void 0 : _b.call(fabricInstance);
|
|
12762
|
-
(_c = fabricInstance.requestRenderAll) == null ? void 0 : _c.call(fabricInstance);
|
|
12763
|
-
};
|
|
12764
|
-
clearTextMetricCaches();
|
|
12765
|
-
await waitForPaint();
|
|
12766
|
-
reflowTextboxes();
|
|
12767
|
-
await waitForPaint();
|
|
12768
12758
|
clearTextMetricCaches();
|
|
12769
|
-
reflowTextboxes();
|
|
12770
12759
|
await waitForPaint();
|
|
12771
|
-
|
|
12760
|
+
(_a = fabricInstance.calcOffset) == null ? void 0 : _a.call(fabricInstance);
|
|
12761
|
+
(_b = fabricInstance.renderAll) == null ? void 0 : _b.call(fabricInstance);
|
|
12762
|
+
(_c = fabricInstance.requestRenderAll) == null ? void 0 : _c.call(fabricInstance);
|
|
12772
12763
|
await waitForPaint();
|
|
12773
12764
|
}
|
|
12774
12765
|
}
|