mirror of
https://github.com/crmeb/CRMEB.git
synced 2026-03-26 07:13:10 +00:00
36 lines
623 B
Vue
36 lines
623 B
Vue
<template>
|
|
<web-view
|
|
class="web-view"
|
|
:webview-styles="webviewStyles"
|
|
:src="url"
|
|
:style="{ width: windowW + 'px', height: windowH + 'px' }"
|
|
></web-view>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
data() {
|
|
return {
|
|
windowH: 0,
|
|
windowW: 0,
|
|
webviewStyles: {
|
|
progress: {
|
|
color: "transparent",
|
|
},
|
|
},
|
|
url: "",
|
|
};
|
|
},
|
|
onLoad(option) {
|
|
this.url = option.url;
|
|
try {
|
|
const res = uni.getWindowInfo();
|
|
this.windowW = res.windowWidth;
|
|
this.windowH = res.windowHeight;
|
|
} catch (e) {
|
|
// error
|
|
}
|
|
},
|
|
};
|
|
</script>
|