text.vue 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. <template>
  2. <div class="tag-layer" @click.stop>
  3. <div class="tag-header">
  4. <span> </span>
  5. <ui-icon class="close" @click.stop="close" type="player_close"></ui-icon>
  6. </div>
  7. <div class="txtcon">
  8. <div class="txtbody" v-html="metadata.description">
  9. </div>
  10. </div>
  11. </div>
  12. </template>
  13. <script setup>
  14. import { reactive, defineEmits, onBeforeMount, onMounted, ref, watchEffect, computed, watch, nextTick } from "vue";
  15. import { useStore } from "vuex";
  16. const store = useStore();
  17. const metadata = computed(() => store.getters["scene/metadata"]);
  18. const close = () => {
  19. store.commit("functions/setShowIntroduce", false);
  20. };
  21. </script>
  22. <style lang="scss" scoped>
  23. .tag-layer {
  24. width: 100vw;
  25. height: 100vh;
  26. z-index: 10000;
  27. top: 0;
  28. position: fixed;
  29. left: 0;
  30. background: rgba(27, 27, 28, 0.8);
  31. box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.3);
  32. backdrop-filter: blur(4px);
  33. .tag-header {
  34. display: flex;
  35. width: 100%;
  36. padding: 0 20px;
  37. justify-content: space-between;
  38. align-items: center;
  39. height: 50px;
  40. border-bottom: solid 1px rgba(255, 255, 255, 0.16);
  41. font-size: 18px;
  42. .close {
  43. color: rgba(255, 255, 255, 0.6);
  44. z-index: 999;
  45. }
  46. }
  47. .txtcon {
  48. display: flex;
  49. align-items: flex-start;
  50. justify-content: center;
  51. height: 100%;
  52. width: 100%;
  53. :deep(p) {
  54. line-height: 24px;
  55. }
  56. .txtbody {
  57. width: 100%;
  58. border-radius: 10px;
  59. font-size: 14px;
  60. color: #fff;
  61. padding: 20px;
  62. max-height: calc(100vh - 60px);
  63. overflow-y: auto;
  64. }
  65. }
  66. }
  67. </style>