mol_plot_all 1.2.235 → 1.2.238
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/node.d.ts +2 -2
- package/node.deps.json +1 -1
- package/node.esm.js.map +1 -1
- package/node.js.map +1 -1
- package/node.test.js.map +1 -1
- package/package.json +1 -1
- package/web.d.ts +2 -2
- package/web.deps.json +1 -1
- package/web.esm.js +10 -1
- package/web.esm.js.map +1 -1
- package/web.js +10 -1
- package/web.js.map +1 -1
package/web.js
CHANGED
|
@@ -2116,7 +2116,16 @@ var $;
|
|
|
2116
2116
|
function $mol_view_watch() {
|
|
2117
2117
|
new $mol_after_frame($mol_view_watch);
|
|
2118
2118
|
for (const view of $mol_view.watchers) {
|
|
2119
|
-
view.view_rect_cache(
|
|
2119
|
+
const prev = view.view_rect_cache();
|
|
2120
|
+
const next = view.dom_node().getBoundingClientRect();
|
|
2121
|
+
if (next.left === 0 && next.right === 0 && next.width === 0) {
|
|
2122
|
+
if (prev)
|
|
2123
|
+
view.view_rect_cache(null);
|
|
2124
|
+
continue;
|
|
2125
|
+
}
|
|
2126
|
+
if (!prev || prev.x !== next.x || prev.y !== next.y || prev.width !== next.width || prev.height !== next.height) {
|
|
2127
|
+
view.view_rect_cache(next);
|
|
2128
|
+
}
|
|
2120
2129
|
}
|
|
2121
2130
|
}
|
|
2122
2131
|
$mol_view_watch();
|