@canvas-harness/core 0.1.21 → 0.1.22
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 +3 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -4947,6 +4947,8 @@ var createRenderer = (opts) => {
|
|
|
4947
4947
|
paintBackground(surface.ctx, { viewport, zoom: camera.z, background });
|
|
4948
4948
|
const visible = visibleNodes(camera, viewport);
|
|
4949
4949
|
const isMoving2 = isMoving(interaction);
|
|
4950
|
+
const viewMotion = interaction.mode === "panning" || interaction.mode === "zooming" || interaction.mode === "marqueeing";
|
|
4951
|
+
const isStripRender = !fullRender;
|
|
4950
4952
|
const minOnScreen = MIN_ON_SCREEN_SIZE_PX;
|
|
4951
4953
|
const nextOverlaySet = /* @__PURE__ */ new Set();
|
|
4952
4954
|
let drawn = 0;
|
|
@@ -5035,7 +5037,7 @@ var createRenderer = (opts) => {
|
|
|
5035
5037
|
if (!def) continue;
|
|
5036
5038
|
if (node.w * camera.z < minOnScreen && node.h * camera.z < minOnScreen) continue;
|
|
5037
5039
|
if (camera.z < def.lod.minZoomForPlaceholder) continue;
|
|
5038
|
-
const preferCanvas = camera.z < def.lod.minZoomForReact ||
|
|
5040
|
+
const preferCanvas = camera.z < def.lod.minZoomForReact || viewMotion && isStripRender && !overlaySet.has(node.id);
|
|
5039
5041
|
if (preferCanvas) {
|
|
5040
5042
|
if (paintCustomCanvasFallback(surface.ctx, node, def, scale, renderEnv)) {
|
|
5041
5043
|
drawn++;
|