sujectTwo.vue 959 B

1234567891011121314151617181920212223242526272829303132
  1. <template>
  2. <div class="container">
  3. <van-button class="my-button" type="primary">前往观看视频</van-button>
  4. <div v-html="wxHtml0"></div>
  5. </div>
  6. </template>
  7. <script lang="ts" setup>
  8. import { ref } from "vue";
  9. let sc = "script";
  10. let sty = "style";
  11. let wxHtml0 = ref(` <wx-open-launch-weapp style="display: block;text-align:center;width:75%;height:48px;border: none;position:absolute;top:0.66rem;z-index:9999;opacity:0" id="launch-btn" username="gh_a994fd2f498e" path="pages/lightMock/index.html?living_code=LIVING_CODE">
  12. <${sc} v-is="'script'" type="text/wxtag-template">
  13. <${sty} v-is="'style'">.openbtn{background-color:#38f;color:#f40;width:100px;height:40px;line-height:40px;}</${sty}>
  14. <div class="openbtn">跳转小程序</div>
  15. </${sc}>
  16. </wx-open-launch-weapp>`);
  17. </script>
  18. <style lang="scss" scoped>
  19. .container {
  20. width: 100%;
  21. display: flex;
  22. justify-content: center;
  23. }
  24. .my-button {
  25. margin-top: 25px;
  26. width: 75%;
  27. }
  28. </style>