Browse Source

feat:添加AI Robot

AmandaG 7 months ago
parent
commit
41d82f142e

BIN
src/components/AIRobot/image/icon_ai_robot24_b@2x.png


BIN
src/components/AIRobot/image/icon_ai_robot36_b@2x.png


BIN
src/components/AIRobot/image/icon_ai_robot48_b@2x.png


BIN
src/components/AIRobot/image/icon_cancel_query_b@2x.png


BIN
src/components/AIRobot/image/icon_faq_b@2x.png


BIN
src/components/AIRobot/image/score_normal.png


+ 216 - 36
src/components/AIRobot/src/AIRobot.vue

@@ -1,49 +1,146 @@
 <script setup lang="ts">
-import { ref } from 'vue'
-import normalPng from '../image/score_normal.png'
+import { ref, onMounted } from 'vue'
+import normalPng from '../image/icon_ai_robot24_b@2x.png'
+import emitter from '@/utils/bus'
 
 const clickSrc = ref(normalPng)
 const visible = ref(false)
 const AIRobotHoverVisible = ref(false)
-const AIRobotClickVisible = ref(false)
 const clicked = ref(false)
+const isShowDefault = ref(false)
+const isShowAIRobotTop = ref(false)
+const DeQuestions = ref([
+  {
+    label: 'List shipments with ETA changes in the last 30 days.',
+    value: 'List shipments with ETA changes in the last 30 days.',
+    isLong: false
+  },
+  {
+    label: 'Shipments arriving in the next 7 days.',
+    value: 'Shipments arriving in the next 7 days.',
+    isLong: false
+  },
+  {
+    label: 'Show shipments delayed in the last 30 days.',
+    value: 'Show shipments delayed in the last 30 days.',
+    isLong: false
+  },
+  {
+    label: 'List shipments with milestone updates in the last 7 days.',
+    value: 'List shipments with milestone updates in the last 7 days.',
+    isLong: false
+  },
+  {
+    label: 'List shipments with milestone in the last 7 days2sdsa.',
+    value: 'List shipments with milestone in the last 7 days2sdsa.',
+    isLong: false
+  },
+  {
+    label: 'List shipments with milestone updates 7 days3fef.',
+    value: 'List shipments with milestone updates 7 days3fef.',
+    isLong: false
+  },
+  {
+    label: 'List shipments with ETA changes in the last 30 days11111111111111111111111111111111111.',
+    value: 'List shipments with ETA changes in the last 30 days11111111111111111111111111111111111.',
+    isLong: true
+  },
+  {
+    label: 'List shipments with ETA changes in the last 30 days1111111111111111111111111111111111122.',
+    value: 'List shipments with ETA changes in the last 30 days1111111111111111111111111111111111122.',
+    isLong: true
+  },
+  {
+    label: 'List shipments with ETA changes in the last 30 days1111111111111111111111111111111111133.',
+    value: 'List shipments with ETA changes in the last 30 days1111111111111111111111111111111111133.',
+    isLong: true
+  },
+])
+const itemGroups = ref([]);
+
 // 鼠标hover AIRobot图标
 const AvatarMouseEnter = () => {
-  if (!clicked.value) {
+  if (clicked.value) {
     AIRobotHoverVisible.value = true
     visible.value = true
   }
 }
 // 鼠标move AIRobot图标
 const AvatarMouseLeave = () => {
-  if (!clicked.value) {
+  if (clicked.value) {
     visible.value = false
     AIRobotHoverVisible.value = false
   }
 }
 // 点击AIRobot图标
 const AvatarClick = () => {
+  clicked.value = true
   AIRobotHoverVisible.value = false
-  if(AIRobotClickVisible.value == true && visible.value) {
-    AIRobotClickVisible.value = false
-    visible.value = false
-    clicked.value = false
-  } else {
-    visible.value = true 
-    AIRobotClickVisible.value = true
-    clicked.value = true
+  isShowDefault.value = false
+  isShowAIRobotTop.value = false
+}
+// 隐藏上方弹窗
+const HideAIRobotTop = () => {
+  isShowDefault.value = false
+}
+
+// 隐藏上方弹窗
+const HideAIRobotTopTwo = () => {
+  isShowAIRobotTop.value = false
+}
+
+// 随机显示方法
+const prepareGroups = () => {
+  const groups = [];
+  let currentGroup = [];
+  let currentHeight = 0;
+
+  DeQuestions.value.forEach(item => {
+    const itemHeight = item.isLong ? 2 : 1;
+    
+    if (currentHeight + itemHeight > 4) {
+      groups.push(currentGroup);
+      currentGroup = [];
+      currentHeight = 0;
+    }
+    
+    currentGroup.push(item);
+    currentHeight += itemHeight;
+  });
+
+  // 添加最后一组
+  if (currentGroup.length > 0) {
+    groups.push(currentGroup);
   }
+
+  itemGroups.value = groups;
 }
-const handlePopoverHide = () => {
-  clicked.value = false
-  AIRobotHoverVisible.value = false
-  AIRobotClickVisible.value = false
+
+const isShowLogin = () => {
+  isShowDefault.value = true
+  setTimeout(() => {
+    isShowDefault.value = false
+    isShowAIRobotTop.value = true
+  }, 5000);
 }
+
+onMounted(() => {
+  prepareGroups()
+  emitter.on('login-success', isShowLogin);
+});
+
+onUnmounted(() => {
+  emitter.off('login-success', isShowLogin);
+});
+
+defineExpose({
+  isShowLogin
+})
 </script>
 <template>
   <!-- 上方显示的弹窗 -->
-  <div class="AIRobot-top">
-    <div class="flex_end">
+  <div class="AIRobot-top" v-if="isShowDefault">
+    <div class="flex_end" @click="HideAIRobotTop">
       <div class="icon flex_center">
         <span class="iconfont_icon icon_dark">
             <svg class="iconfont" aria-hidden="true">
@@ -52,19 +149,55 @@ const handlePopoverHide = () => {
           </span>
       </div>
     </div>
-    <div class="dialogue_title">
-      Hi! I'm your Freight Assistant, always on call
+    <div class="flex_title">
+      <div class="AIAvator">
+        <img width="40px" src="../image/icon_ai_robot36_b@2x.png" />
+      </div>
+      <div class="dialogue_title">
+        Hi! I'm your Freight Assistant, always on call
+      </div>
     </div>
-    <div class="dialogue_content">
-      <div class="dialogue_content_title">
-        <div class="dialogue_title_left">
-          Frequently Asked Questions
-        </div>
-        <div class="dialogue_title_right">
-          Refresh Questions
+    <div class="flex_end">
+      <div class="dialogue_content ">
+        <div class="dialogue_content_title">
+          <div class="dialogue_title_left">
+            <img src="../image/icon_faq_b@2x.png" width="24px" />
+            Frequently Asked Questions
+          </div>
         </div>
+        <el-carousel class="carousel" :autoplay="false" height="190px" style="width: 452px;" >
+          <el-carousel-item 
+            v-for="(group, index) in itemGroups "
+            :key="index"
+          >
+            <div class="dialogue_container">
+              <div 
+                class="dialogue_content_item"
+                v-for="item in group"
+                :key="item.label"
+                :class="{ 'long_item': item.isLong }"
+              >
+                {{ item.label }}
+              </div>
+            </div>
+          </el-carousel-item>
+        </el-carousel>
+      </div>
+    </div>
+  </div>
+  <div class="AIRobot-top" v-if="isShowAIRobotTop">
+    <div class="flex_end" @click="HideAIRobotTopTwo">
+      <div class="icon flex_center">
+        <span class="iconfont_icon icon_dark">
+            <svg class="iconfont" aria-hidden="true">
+              <use xlink:href="#icon-icon_reject_b"></use>
+            </svg>
+          </span>
       </div>
     </div>
+    <div class="dialogue_title">
+      Hi! I'm your Freight Assistant, always on call
+    </div>
   </div>
   <!-- 悬浮icon -->
   <div class="AIRobot flex_center">
@@ -72,15 +205,12 @@ const handlePopoverHide = () => {
       :visible="visible"
       placement="top-end"
       width="auto"
-      @hide="handlePopoverHide"
     >
       <template #reference>
-        <el-avatar @click="AvatarClick" @mouseenter="AvatarMouseEnter" @mouseleave="AvatarMouseLeave" :size="46" shape="square" :src="clickSrc" />
+        <el-avatar @click="AvatarClick" @mouseenter="AvatarMouseEnter" @mouseleave="AvatarMouseLeave" :size="46" shape="square" class="avatar_bg" :src="clickSrc" />
       </template>
       <!-- hover时显示的对话框 -->
       <div v-if="AIRobotHoverVisible" class="AIRobot_dialog">Continue the conversation</div>
-      <!-- click时显示的对话框 -->
-      <div v-if="AIRobotClickVisible" class="AIRobot_dialog">Continue the conversation  156468482</div>
     </el-popover>
   </div>
 </template>
@@ -98,19 +228,24 @@ const handlePopoverHide = () => {
   display: flex;
   justify-content: end;
 }
+.flex_title {
+  display: flex;
+  align-items: center;
+  width: 500px;
+}
 .AIRobot-top {
   position: absolute;
   z-index: 2013;
-  right: 20px;
-  bottom: 250px;
+  right: 50px;
+  bottom: 230px;
 }
 .dialogue_content_title {
   display: flex;
   align-items: center;
   justify-content: space-between;
+  padding-left: 8px;
 }
 .dialogue_title_left {
-  margin-right: 80px;
   background: linear-gradient(90deg, #A71549 1.77%, #06256E 46.77%);
   -webkit-background-clip: text;
   background-clip: text;
@@ -118,12 +253,22 @@ const handlePopoverHide = () => {
   font-size: 14px;
   font-weight: 700;
 }
+.dialogue_title_right {
+  color: var(--color-theme);
+  cursor: pointer;
+  user-select: none;
+}
+.icon_theme {
+  fill: var(--color-theme);
+  cursor: pointer;
+}
 .icon {
   width: 24px;
   height: 24px;
   background-color: var(--management-bg-color);
   box-shadow: -2px 2px 12px rgba(0, 0, 0, 15%);
   border-radius: 6px;
+  cursor: pointer;
 }
 .AIRobot {
   width: 64px;
@@ -151,7 +296,42 @@ const handlePopoverHide = () => {
 }
 .dialogue_content {
   background: linear-gradient(92deg, #EAECFF 1.33%, #F1E3FB 99.63%);
-  padding: 8px;
+  padding: 8px 0 0 0;
   border-radius: 12px;
 }
+.AIAvator {
+  width: 40px;
+  height: 40px;
+  background: radial-gradient(50% 43% at 50% 54.79%, #D5B4F3 0%, #FFF9FC 100%);
+  border-radius: 12px;
+  margin-right: 8px;
+}
+.dialogue_container {
+  width: 420px;
+  height: 156px;
+  border-radius: 12px;
+  border: 1px solid #FFF;
+  padding: 8px;
+  background: rgba(255, 255, 255, 0.50);
+}
+.dialogue_content_item {
+  width: 404px;
+  height: 32px;
+  padding: 5.5px 8px;
+  height: 32px;
+  border-radius: 6px;
+  background-color: var(--color-dialogue-bg);
+  margin-bottom: 4px;
+  display: flex;
+  align-items: center;
+  word-break: break-word;
+  overflow: hidden;
+  transition: all 0.3s ease;
+}
+.itemLable { 
+  width: 100%;
+}
+.long_item {
+  height: 64px;
+}
 </style>

+ 37 - 0
src/styles/elementui.scss

@@ -785,3 +785,40 @@ div .DaterangeClass {
 div .el-radio__label {
   width: 100%;
 }
+
+div .avatar_bg {
+  background-color: transparent !important;
+}
+div .carousel .el-carousel__indicator--horizontal {
+  padding: 4px 8px;
+}
+div .carousel .el-carousel__button {
+  width: 6px;
+  height: 6px;
+  border-radius: 50%;
+  background-color: var(--color-system-card-bg);
+  opacity: 1;
+}
+div .carousel .el-carousel__indicator.is-active button {
+  background-color: var(--color-theme);
+}
+div .carousel .el-carousel__item--card, .el-carousel__item.is-animating {
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  padding-bottom: 15px;
+}
+div .carousel .el-carousel__arrow {
+  opacity: 1;
+  background-color: var(--color-system-card-bg);
+}
+div .carousel .el-carousel__arrow--left {
+  left: 0;
+}
+div .carousel .el-carousel__arrow--right {
+  right: 0;
+}
+div .carousel .el-icon {
+  fill: black;
+  color: black;
+}

+ 48 - 4
src/styles/icons/iconfont.css

@@ -1,9 +1,9 @@
 @font-face {
   font-family: "font_family"; /* Project id 4672385 */
-  src: url('iconfont.woff2?t=1740548496100') format('woff2'),
-       url('iconfont.woff?t=1740548496100') format('woff'),
-       url('iconfont.ttf?t=1740548496100') format('truetype'),
-       url('iconfont.svg?t=1740548496100#font_family') format('svg');
+  src: url('iconfont.woff2?t=1744960401055') format('woff2'),
+       url('iconfont.woff?t=1744960401055') format('woff'),
+       url('iconfont.ttf?t=1744960401055') format('truetype'),
+       url('iconfont.svg?t=1744960401055#font_family') format('svg');
 }
 
 .font_family {
@@ -14,6 +14,50 @@
   -moz-osx-font-smoothing: grayscale;
 }
 
+.icon-icon_send_b:before {
+  content: "\e712";
+}
+
+.icon-icon_sidebar__window_b:before {
+  content: "\e70f";
+}
+
+.icon-icon_maximized__window_b:before {
+  content: "\e710";
+}
+
+.icon-icon_collapsed__to_widget_b:before {
+  content: "\e711";
+}
+
+.icon-icon_theme_colors_b:before {
+  content: "\e70e";
+}
+
+.icon-icon_delay_b1:before {
+  content: "\e70b";
+}
+
+.icon-icon_collapse_b1:before {
+  content: "\e70c";
+}
+
+.icon-icon_cancel_b2:before {
+  content: "\e70d";
+}
+
+.icon-icon_ai_api_log_b:before {
+  content: "\e70a";
+}
+
+.icon-icon_collapse__sidebar_b:before {
+  content: "\e708";
+}
+
+.icon-icon_dashboard_title_b:before {
+  content: "\e709";
+}
+
 .icon-icon_collapse_b:before {
   content: "\e707";
 }

File diff suppressed because it is too large
+ 0 - 0
src/styles/icons/iconfont.js


+ 22 - 0
src/styles/icons/iconfont.svg

@@ -14,6 +14,28 @@
     />
       <missing-glyph />
       
+      <glyph glyph-name="icon_send_b" unicode="&#59154;" d="M678.272 424.256l-460.928 225.92 56.32-225.92h404.608z m-403.712-76.8l-57.216-229.568 468.352 229.568H274.56z m601.664 65.28a32 32 0 0 0 0-57.472L164.672 6.592a32 32 0 0 0-45.184 36.48l83.072 333.184a32 32 0 0 1 0 15.488L119.488 724.992a32 32 0 0 0 45.184 36.48L876.16 412.736z"  horiz-adv-x="1088" />
+      
+      <glyph glyph-name="icon_sidebar__window_b" unicode="&#59151;" d="M740.352 809.28h132.16v-76.8h-132.16v76.8z m-72.448-102.592a25.6 25.6 0 0 0 25.6 25.6v76.8H119.04a102.4 102.4 0 0 1-102.4-102.4v-645.376a102.4 102.4 0 0 1 102.4-102.4H693.504v76.8a25.6 25.6 0 0 0-25.6 25.6v80.64h-76.8v-80.64c0-8.832 1.088-17.408 3.2-25.6H119.04a25.6 25.6 0 0 0-25.6 25.6V706.688c0 14.08 11.456 25.6 25.6 25.6h475.264c-2.112-8.192-3.2-16.768-3.2-25.6v-80.64h76.8v80.64z m251.072 25.6a25.6 25.6 0 0 0 25.6-25.6v-80.64h76.8v80.64a102.4 102.4 0 0 1-102.4 102.4v-76.8zM667.904 410.88V572.16h-76.8v-161.28h76.8z m276.672 161.28v-161.28h76.8V572.16h-76.8z m-276.672-376.384v161.28h-76.8v-161.28h76.8z m276.672 161.28v-161.28h76.8v161.28h-76.8z m0-215.04v-80.64a25.6 25.6 0 0 0-25.6-25.6v-76.8a102.4 102.4 0 0 1 102.4 102.4v80.64h-76.8zM541.632 406.592L433.28 514.944l-45.248-45.248 53.76-53.76H186.88v-64h254.784l-53.696-53.696 45.248-45.248 108.352 108.352a32 32 0 0 1 0 45.248z m330.88-370.88h-132.16v-76.8h132.16v76.8z"  horiz-adv-x="1088" />
+      
+      <glyph glyph-name="icon_maximized__window_b" unicode="&#59152;" d="M944.64 706.688a25.6 25.6 0 0 1-25.6 25.6h-224.96a25.6 25.6 0 0 1-25.6-25.6v-645.376c0-14.08 11.52-25.6 25.6-25.6h224.896a25.6 25.6 0 0 1 25.6 25.6V706.688z m-25.6 102.4a102.4 102.4 0 0 0 102.4-102.4v-645.376a102.4 102.4 0 0 0-102.4-102.4h-224.96a102.4 102.4 0 0 0-102.4 102.4V706.688a102.4 102.4 0 0 0 102.4 102.4h224.896z m-490.624-76.8h148.352v76.8H428.416v-76.8z m-220.48 0h162.944v76.8H207.936v-76.8z m-88.96 0h36.544v76.8h-36.48a102.4 102.4 0 0 1-102.4-102.4v-80.64h76.8v80.64c0 14.08 11.456 25.6 25.6 25.6z m-25.6-321.408V572.16H16.64v-161.28h76.8z m0-215.104v161.28H16.64v-161.28h76.8z m0-134.4v80.64H16.64v-80.64a102.4 102.4 0 0 1 102.4-102.4h36.544v76.8h-36.48a25.6 25.6 0 0 0-25.6 25.6z m483.392-25.6H428.416v-76.8h148.352v76.8z m-205.952 0H208v-76.8h162.944v76.8zM164.352 406.528L272.64 514.944l45.248-45.248-53.696-53.76h254.784v-64H264.192l53.696-53.696-45.248-45.248-108.352 108.352a32 32 0 0 0 0 45.248z"  horiz-adv-x="1088" />
+      
+      <glyph glyph-name="icon_collapsed__to_widget_b" unicode="&#59153;" d="M928.768 813.504c55.488 0 100.48-44.992 100.48-100.48v-327.808h-75.392V712.96a25.152 25.152 0 0 1-25.088 25.152H111.744a25.152 25.152 0 0 1-25.152-25.152v-659.84c0-13.888 11.264-25.152 25.152-25.152h488.768v-75.456H111.744A100.544 100.544 0 0 0 11.2 53.12V712.96c0 55.552 44.992 100.544 100.544 100.544h817.024z m-216.832-571.84c0 15.616 12.672 28.288 28.288 28.288h62.848v69.12h-62.848c-53.76 0-97.408-43.648-97.408-97.408v-62.848h69.12v62.848z m153.984 28.288h62.848c15.616 0 28.224-12.672 28.224-28.288v-62.848h69.12v62.848c0 53.76-43.52 97.408-97.344 97.408h-62.848v-69.12z m-153.984-216.832v62.848h-69.12v-62.848c0-53.76 43.584-97.408 97.408-97.408h62.848v69.12h-62.848a28.288 28.288 0 0 0-28.288 28.288z m245.12 62.848v-62.848a28.288 28.288 0 0 0-28.288-28.288h-62.848v-69.12h62.848c53.76 0 97.408 43.584 97.408 97.408v62.848h-69.12z m-418.304 258.56a31.36 31.36 0 0 1-0.256 2.56l-19.2 154.048-62.4-7.808 9.92-79.104L260.416 604.8l-38.592-49.6L428.16 394.56l-79.104-9.856 7.808-62.4 152.96 19.136a31.36 31.36 0 0 1 28.928 32.96z"  horiz-adv-x="1088" />
+      
+      <glyph glyph-name="icon_theme_colors_b" unicode="&#59150;" d="M454.4 722.432L388.096 788.8l54.336 54.336 492.288-492.288-425.92-425.92-425.856 425.92L454.4 722.432z m54.4-54.336L191.424 350.848l317.248-317.312 317.312 317.312-317.312 317.248zM880.32 350.848L508.8-20.736 137.216 350.848l53.056 53.12h636.992l53.12-53.12zM1033.152 166.592a76.416 76.416 0 1 0-152.832 0c0 42.24 76.416 131.584 76.416 131.584s76.416-89.408 76.416-131.584z"  horiz-adv-x="1088" />
+      
+      <glyph glyph-name="icon_delay_b1" unicode="&#59147;" d="M487.04 676.032a64 64 0 0 0 108.224-0.192l324.544-515.456a64 64 0 0 0-54.144-98.112H213.76a64 64 0 0 0-54.016 98.304l327.296 515.456z m54.08-34.304L213.76 126.272h651.84L541.12 641.728z m30.528-165.12v-203.456h-64v203.52h64z m0-309.376v52.992h-64v-52.992h64z"  horiz-adv-x="1088" />
+      
+      <glyph glyph-name="icon_collapse_b1" unicode="&#59148;" d="M160 769.088a102.4 102.4 0 0 1-102.4-102.4v-565.376a102.4 102.4 0 0 1 102.4-102.4h704a102.4 102.4 0 0 1 102.4 102.4V666.688a102.4 102.4 0 0 1-102.4 102.4h-704z m-25.6-102.4c0 14.08 11.52 25.6 25.6 25.6h244.288v-616.576H160a25.6 25.6 0 0 0-25.6 25.6V666.688z m346.688-590.976V692.288H864c14.08 0 25.6-11.52 25.6-25.6v-565.376a25.6 25.6 0 0 0-25.6-25.6H481.088z"  horiz-adv-x="1024" />
+      
+      <glyph glyph-name="icon_cancel_b2" unicode="&#59149;" d="M201.152 743.936c0 14.08 11.52 25.6 25.6 25.6h554.56c14.08 0 25.6-11.52 25.6-25.6v-458.24h76.8v458.24a102.4 102.4 0 0 1-102.4 102.4H226.752a102.4 102.4 0 0 1-102.4-102.4v-704a102.4 102.4 0 0 1 102.4-102.4h277.312v76.8H226.752a25.6 25.6 0 0 0-25.6 25.6v704z m428.224-497.728l107.968-107.968 107.968 107.904 54.336-54.272-107.968-107.968 107.968-107.968-54.336-54.272-107.968 107.968-107.968-108.032-54.336 54.336 108.032 107.968-108.032 107.968 54.336 54.336z"  horiz-adv-x="1024" />
+      
+      <glyph glyph-name="icon_ai_api_log_b" unicode="&#59146;" d="M305.28 659.84h429.952v76.8H305.28v-76.8z m-51.84-513.28h532.544V543.36H253.44v-396.864zM176.64 556.16a64 64 0 0 0 64 64h558.144a64 64 0 0 0 64-64v-422.464a64 64 0 0 0-64-64H240.64a64 64 0 0 0-64 64V556.16z m164.8-262.4v102.4h128v-102.4h-128z m241.728 102.4v-102.4h128v102.4h-128z m313.408-136V430.272h76.8v-170.176h-76.8z m-832 170.112v-170.176h76.8V430.336h-76.8z"  horiz-adv-x="1088" />
+      
+      <glyph glyph-name="icon_collapse__sidebar_b" unicode="&#59144;" d="M142.08 769.088a38.4 38.4 0 0 1-38.4-38.4v-693.376a38.4 38.4 0 0 1 38.4-38.4h832a38.4 38.4 0 0 1 38.4 38.4V730.688a38.4 38.4 0 0 1-38.4 38.4h-832z m38.4-693.376V692.288h269.824v-616.576H180.48z m346.624 0V692.288h408.512v-616.576H527.104z"  horiz-adv-x="1088" />
+      
+      <glyph glyph-name="icon_dashboard_title_b" unicode="&#59145;" d="M863.2064 384c0-183.808-148.992-332.8-332.8-332.8s-332.8 148.992-332.8 332.8 148.992 332.8 332.8 332.8 332.8-148.992 332.8-332.8z m-332.8-1.6128l262.3232 60.4416C765.952 562.9952 658.6624 652.8 530.432 652.8v-270.4128z"  horiz-adv-x="1049" />
+      
       <glyph glyph-name="icon_collapse_b" unicode="&#59143;" d="M199.111111 726.300444a91.022222 91.022222 0 0 1-91.022222-91.022222v-502.556444a91.022222 91.022222 0 0 1 91.022222-91.022222h625.777778a91.022222 91.022222 0 0 1 91.022222 91.022222V635.278222a91.022222 91.022222 0 0 1-91.022222 91.022222h-625.777778z m-22.755555-91.022222c0 12.515556 10.24 22.755556 22.755555 22.755556h217.144889v-548.067556H199.111111a22.755556 22.755556 0 0 0-22.755555 22.755556V635.278222z m308.167111-525.312V658.033778H824.888889c12.515556 0 22.755556-10.24 22.755555-22.755556v-502.556444a22.755556 22.755556 0 0 0-22.755555-22.755556H484.522667z"  horiz-adv-x="1024" />
       
       <glyph glyph-name="icon_cancel_b1" unicode="&#59142;" d="M235.690667 704c0 12.515556 10.24 22.755556 22.755555 22.755556h492.942222c12.515556 0 22.755556-10.24 22.755556-22.755556v-407.324444h68.266667v407.324444a91.022222 91.022222 0 0 1-91.022223 91.022222H258.446222a91.022222 91.022222 0 0 1-91.022222-91.022222v-625.777778a91.022222 91.022222 0 0 1 91.022222-91.022222h246.499556v68.266667H258.446222a22.755556 22.755556 0 0 0-22.755555 22.755555v625.777778z m380.643555-442.424889l95.971556-96.028444 95.971555 95.971555 48.241778-48.241778-95.914667-95.971555 95.971556-95.971556-48.298667-48.241777-95.971555 95.914666-95.971556-95.971555-48.298666 48.298666 96.028444 95.971556-96.028444 95.971555 48.298666 48.298667z"  horiz-adv-x="1024" />

BIN
src/styles/icons/iconfont.ttf


BIN
src/styles/icons/iconfont.woff


BIN
src/styles/icons/iconfont.woff2


+ 4 - 0
src/styles/theme-g.scss

@@ -79,4 +79,8 @@
   --color-system-card-bg:#2B2F36;
   --color-system-border-1: #3F434A;
   --color-system-input-border: #656f7d;
+
+  
+  // AI Robot
+  --color-dialogue-bg: rgba(255,255,255,0.13);
 }

+ 3 - 0
src/styles/theme.scss

@@ -282,6 +282,9 @@
   --color-system-border-1: #e8eaee;
   --color-system-input-border: #e8eaee;
   --color-personal-preference-bg: #f5f7fa;
+
+  // AI Robot
+  --color-dialogue-bg: #fff;
 }
 
 :root.dark {

+ 1 - 1
src/views/Layout/src/LayoutView.vue

@@ -42,7 +42,7 @@ const handleMenuCollapse = (val: boolean) => {
         <router-view />
       </el-main>
     </el-container>
-    <!-- <AIRobot></AIRobot> -->
+    <AIRobot></AIRobot>
     <ScoringGrade></ScoringGrade>
   </el-container>
 </template>

+ 5 - 0
src/views/Layout/src/components/Menu/MenuView.vue

@@ -2,6 +2,7 @@
 import { useRoute, useRouter } from 'vue-router'
 import { useUserStore } from '@/stores/modules/user'
 import { CaretRight } from '@element-plus/icons-vue'
+import emitter from '@/utils/bus'
 
 const route = useRoute()
 const router = useRouter()
@@ -90,6 +91,10 @@ const changeRouter = (path: any) => {
   }
   sessionStorage.removeItem('trackingTablePageInfo')
   sessionStorage.removeItem('bookingTablePageInfo')
+  if (localStorage.getItem('loginAI')) {
+    localStorage.removeItem('loginAI')
+    emitter.emit('login-success');
+  }
   isVisible.value = false
   emits('changeVisible', isVisible.value)
   isVisible.value = false

+ 1 - 0
src/views/Login/src/loginView.vue

@@ -212,6 +212,7 @@ const handleResult = (res: any) => {
       })
     }
     localStorage.setItem('user_type', res.data.user_info.user_type)
+    localStorage.setItem('loginAI', 'loginAI')
     userStore.setUserInfo(res.data?.user_info || {})
     router.push('/')
   } else if (res.code === 400) {

Some files were not shown because too many files changed in this diff