fast-vue-multi-pages-vite 1.3.0 → 1.3.2
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 +1 -1
- package/package.json +1 -1
- package/vite/index.js +13 -0
package/dist/index.js
CHANGED
|
@@ -431,8 +431,8 @@ var FastVueNative = class FastVueNative {
|
|
|
431
431
|
*/
|
|
432
432
|
static injectAppJsForNativeCall(fromWindow) {
|
|
433
433
|
if (!fromWindow) return;
|
|
434
|
-
if (fromWindow.top && fromWindow.top === fromWindow) return;
|
|
435
434
|
if (!fromWindow["appJs"]) fromWindow["appJs"] = FastVueNative;
|
|
435
|
+
if (fromWindow.top && fromWindow.top === fromWindow) return;
|
|
436
436
|
this.injectAppJsForNativeCall(fromWindow.top);
|
|
437
437
|
}
|
|
438
438
|
/**
|
package/package.json
CHANGED
package/vite/index.js
CHANGED
|
@@ -814,7 +814,20 @@ var FastViteTemplate = class {
|
|
|
814
814
|
document.body.style.height = minHeight + "px";
|
|
815
815
|
document.body.style.transform = "perspective(1px) scale("+scale+") translateZ(0)";
|
|
816
816
|
}
|
|
817
|
+
setWindowValue(window,'__PageScale',scale);
|
|
817
818
|
};
|
|
819
|
+
|
|
820
|
+
const setWindowValue=(obj,attr,value)=>{
|
|
821
|
+
try { if(obj){
|
|
822
|
+
obj[attr]=value
|
|
823
|
+
}
|
|
824
|
+
} catch(e) { }
|
|
825
|
+
for(let i = 0; i < obj.length; i++) {
|
|
826
|
+
setWindowValue(obj[i],attr,value)
|
|
827
|
+
}
|
|
828
|
+
}
|
|
829
|
+
|
|
830
|
+
|
|
818
831
|
initPage();
|
|
819
832
|
checkScale();
|
|
820
833
|
</script>
|