6 changed files with 256 additions and 149 deletions
@ -0,0 +1,22 @@ |
|||
<template> |
|||
<div class="iframe-page"> |
|||
<iframe class="w-full h-full" :src="url"></iframe> |
|||
</div> |
|||
</template> |
|||
<script> |
|||
export default { |
|||
data() { |
|||
return { |
|||
url: "https://www.baidu.com", |
|||
}; |
|||
}, |
|||
created() {}, |
|||
methods: {}, |
|||
}; |
|||
</script> |
|||
<style scoped lang="scss"> |
|||
.iframe-page { |
|||
width: 100%; |
|||
height: 100%; |
|||
} |
|||
</style> |
@ -0,0 +1,85 @@ |
|||
<template> |
|||
<div class="app-wrapper"> |
|||
<div :class="{ 'fixed-header': true }"> |
|||
<navbar /> |
|||
</div> |
|||
<div class="wp"> |
|||
<iframe |
|||
class="w-full h-full" |
|||
:src="url" |
|||
frameborder="no" |
|||
style="border: none" |
|||
></iframe> |
|||
</div> |
|||
</div> |
|||
</template> |
|||
<script> |
|||
import { Navbar } from "./components"; |
|||
|
|||
export default { |
|||
components: { |
|||
Navbar, |
|||
}, |
|||
data() { |
|||
return {}; |
|||
}, |
|||
created() { |
|||
// console.log(this.$route); |
|||
}, |
|||
computed: { |
|||
url: function () { |
|||
if (this.$route.query.url) return atob(this.$route.query.url); |
|||
}, |
|||
}, |
|||
methods: {}, |
|||
}; |
|||
</script> |
|||
<style scoped lang="scss"> |
|||
@import "~@/assets/styles/mixin.scss"; |
|||
@import "~@/assets/styles/variables.scss"; |
|||
|
|||
.app-wrapper { |
|||
@include clearfix; |
|||
position: relative; |
|||
height: 100%; |
|||
width: 100%; |
|||
// background: #eef3ff; |
|||
background: #f4f9f7; |
|||
|
|||
&.mobile.openSidebar { |
|||
position: fixed; |
|||
top: 0; |
|||
} |
|||
|
|||
.wp { |
|||
padding-top: 56px; |
|||
} |
|||
} |
|||
|
|||
.drawer-bg { |
|||
background: #000; |
|||
opacity: 0.3; |
|||
width: 100%; |
|||
top: 0; |
|||
height: 100%; |
|||
position: absolute; |
|||
z-index: 999; |
|||
} |
|||
|
|||
.fixed-header { |
|||
position: fixed; |
|||
top: 0; |
|||
right: 0; |
|||
z-index: 9; |
|||
// width: calc(100% - #{$sideBarWidth}); |
|||
width: 100%; |
|||
transition: width 0.28s; |
|||
} |
|||
|
|||
.wp { |
|||
height: 100%; |
|||
.main-container { |
|||
height: 100%; |
|||
} |
|||
} |
|||
</style> |
Loading…
Reference in new issue