2025-11-14 11:39:33 +08:00
|
|
|
<template>
|
|
|
|
|
<view v-if="src">
|
2025-12-25 08:26:09 +08:00
|
|
|
<web-view :webview-styles="wbStyles" :src="src" :fullscreen="false" bindmessage="handleGetMessage"/>
|
2025-11-14 11:39:33 +08:00
|
|
|
</view>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
export default {
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
|
|
|
|
title: '',
|
|
|
|
|
src: '',
|
|
|
|
|
wbStyles: {
|
|
|
|
|
width: '100%',
|
|
|
|
|
height: '100%',
|
|
|
|
|
},
|
|
|
|
|
}
|
|
|
|
|
},
|
2025-12-25 08:26:09 +08:00
|
|
|
methods: {
|
|
|
|
|
handleGetMessage(e){
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
},
|
2025-11-14 11:39:33 +08:00
|
|
|
onLoad(option) {
|
|
|
|
|
console.log(option.title);
|
|
|
|
|
this.title = option?.title
|
|
|
|
|
this.src = option?.src
|
|
|
|
|
},
|
|
|
|
|
}
|
|
|
|
|
</script>
|