瀏覽代碼

机器人链接嵌入

刘洋 1 年之前
父節點
當前提交
119fa00214
共有 4 個文件被更改,包括 40 次插入0 次删除
  1. 1 0
      src/App.vue
  2. 二進制
      src/assets/imgs/jiqiren.png
  3. 2 0
      src/components/global/index.js
  4. 37 0
      src/components/global/robot/index.vue

+ 1 - 0
src/App.vue

@@ -1,6 +1,7 @@
 <template>
   <t-config-provider :global-config="config">
     <router-view />
+    <Robot></Robot>
   </t-config-provider>
 </template>
 

二進制
src/assets/imgs/jiqiren.png


+ 2 - 0
src/components/global/index.js

@@ -24,6 +24,7 @@ import SearchForm from './search-form/index.vue';
 import MyDialog from './my-dialog/index.vue';
 import SButton from './s-buttons/index.vue';
 import ImageView from './image-viewer/index.vue';
+import Robot from './robot/index.vue';
 
 use([
   CanvasRenderer,
@@ -50,5 +51,6 @@ export default {
     Vue.component('MyDialog', MyDialog);
     Vue.component('SButton', SButton);
     Vue.component('ImageView', ImageView);
+    Vue.component('Robot', Robot);
   },
 };

+ 37 - 0
src/components/global/robot/index.vue

@@ -0,0 +1,37 @@
+<template>
+  <div class="robot">
+    <t-tooltip content="试试点我提问~" theme="light">
+      <img
+        class="robot-img"
+        src="../../../assets/imgs/jiqiren.png"
+        @click="visible = !visible"
+      />
+    </t-tooltip>
+    <t-dialog v-model:visible="visible" :footer="false" width="800">
+      <iframe
+        src="https://qmth.echo-isoftstone.com/visitors-ui/pc"
+        frameborder="0"
+        style="width: 740px; height: 580px"
+      ></iframe>
+    </t-dialog>
+  </div>
+</template>
+
+<script setup name="Robot">
+import { ref } from 'vue';
+const visible = ref(true);
+</script>
+
+<style lang="less" scoped>
+.robot {
+  .robot-img {
+    position: fixed;
+    width: 80px;
+    height: 80px;
+    right: 20px;
+    bottom: 20px;
+    z-index: 300;
+    cursor: pointer;
+  }
+}
+</style>