yxl
2025-02-07 cea709ad1c7bd45aa45972174bd528b15bf4ae6b
src/components/Chat/chatList.vue
@@ -111,6 +111,12 @@
                      >
                    </div>
                  </div>
                  <div v-else-if="res.type == 'stream'">
                    <div
                      v-html="res.val"
                      class="markdown-container"
                    ></div>
                  </div>
                  <div v-else-if="res.type == 'table'">
                    <table class="contTable">
                      <thead>
@@ -190,7 +196,7 @@
  arr: [],
  components: {
    VueMarkdown,
    affairs
    affairs,
  },
  filters: {
    setWidth(value) {
@@ -202,19 +208,19 @@
        return "99vh";
      }
      return width;
    }
    },
  },
  props: {
    pageConfig: {
      type: Object,
      default: () => ({
        width: "100vw"
      })
        width: "100vw",
      }),
    },
    list: {
      type: Array,
      default: () => []
    }
      default: () => [],
    },
  },
  data() {
    return {
@@ -223,7 +229,7 @@
      imgSrc: "",
      videoSrc: "",
      audioSrc: "",
      isDisabled: true
      isDisabled: true,
    };
  },
  watch: {
@@ -234,7 +240,7 @@
          this.load = false;
        });
      }
    }
    },
  },
  mounted() {
    setTimeout(() => {
@@ -256,7 +262,7 @@
    setDownLoadFile(res) {
      // 使用marked将Markdown转换为HTML
      const blob = new Blob([res.val], {
        type: "text/markdown"
        type: "text/markdown",
      });
      // 使用HTML5的Blob生成链接,让用户可以下载生成的Word文档
      const link = URL.createObjectURL(blob);
@@ -374,8 +380,8 @@
      this.videoSrc = undefined;
      this.audioSrc = undefined;
      done();
    }
  }
    },
  },
};
</script>
<style scoped>
@@ -421,6 +427,10 @@
  text-align: center;
  font-size: 14px;
}
.markdown-container {
  padding: 10px;
  white-space: pre-wrap;
}
</style>
<style scoped>
.webBody {