vue
<script setup lang="ts">
import { useRoute } from 'vue-router'

const route = useRoute()
const url = ref('')
const title = ref('')
onActivated(async () => {
  const path = route.query.p as string
  url.value = path || ''
  title.value = (route.query.t as string) || ''
})
</script>
<template>
  <div class="page">
    <BackBar class="back" :leftText="title" index />
    <iframe :src="url" allow="camera *;microphone *;speaker *"></iframe>
  </div>
</template>
<style lang="scss" scoped>
.page {
  width: 100%;
  height: 100%;
  overflow: hidden;
  .back {
    position: fixed;
    top: $space-1;
    left: $space-1;
    opacity: 0.8;
  }

  iframe {
    width: 100vw;
    height: 100vh;
    border: none;
  }
}
</style>
