Răsfoiți Sursa

Merge branch 'dev' into dev_zyh

zhouyuhao 6 luni în urmă
părinte
comite
cd9bfcf287

+ 9 - 5
src/components/AIRobot/src/AIRobot.vue

@@ -9,7 +9,7 @@ const AIRobotHoverVisible = ref(false)
 const clicked = ref(false)
 const isShowDefault = ref(false)
 const isShowAIRobotTop = ref(false)
-const AIIconVisible = ref(true)
+const AIIconVisible = ref(false)
 const DeQuestions = ref([])
 const itemGroups = ref([])
 
@@ -81,13 +81,13 @@ const prepareGroups = () => {
   itemGroups.value = groups
 }
 const isShowLogin = () => {
-  const LoginDays = 0
+  const loginCount = JSON.parse(localStorage.getItem('userInfo')).loginCount
   let settimeouttime = 0
   AIIconVisible.value = true
   isShowDefault.value = true
-  if (LoginDays == 0) {
+  if (loginCount <= 0) {
     settimeouttime = 45000
-  } else if (LoginDays == 2) {
+  } else if (loginCount <= 2) {
     settimeouttime = 15000
   } else {
     settimeouttime = 10000
@@ -121,6 +121,9 @@ const handelClick = (item: any) => {
 }
 
 onMounted(() => {
+  if(localStorage.getItem('userInfo') != null) {
+    AIIconVisible.value = true
+  }
   AIRobotInit()
   emitter.on('login-success', isShowLogin)
   emitter.on('login-out', Logout)
@@ -151,7 +154,7 @@ defineExpose({
       <div class="dialogue_title">Hi! I'm your Freight Assistant, always on call</div>
     </div>
     <div class="flex_end">
-      <div class="dialogue_content">
+      <div class="dialogue_content"  style="box-shadow: -10px 10px 24px rgba(58, 0, 78, 0.15);">
         <div class="dialogue_content_title">
           <div class="dialogue_title_left">
             <img src="../image/icon_faq_b@2x.png" width="24px" />
@@ -288,6 +291,7 @@ defineExpose({
 }
 .dialogue_title {
   background: var(--color-dialogue-text-bg);
+  box-shadow: -10px 10px 24px rgba(58, 0, 78, 0.15);
   padding: 8px;
   border-radius: 12px;
   margin: 10px 0;

+ 2 - 2
src/styles/elementui.scss

@@ -815,7 +815,7 @@ div .avatar_bg {
   background-color: transparent !important;
 }
 div .carousel .el-carousel__indicator--horizontal {
-  padding: 4px 8px;
+  padding: 4px;
 }
 div .carousel .el-carousel__button {
   width: 6px;
@@ -831,7 +831,7 @@ div .carousel .el-carousel__item--card, .el-carousel__item.is-animating {
   display: flex;
   align-items: center;
   justify-content: center;
-  padding-bottom: 15px;
+  padding-bottom: 9px;
 }
 div .carousel .el-carousel__arrow {
   opacity: 1;

+ 6 - 2
src/views/AIRobotChat/src/components/AIQuestions.vue

@@ -120,7 +120,7 @@ const clickQuestion = (question) => {
         v-if="props.modalSize === 'large'"
         class="carousel large_carousel"
         :autoplay="false"
-        height="115px"
+        height="105px"
       >
         <el-carousel-item v-for="(page, index) in pages" :key="index">
           <div class="dialogue_container dialogue_container_large">
@@ -190,7 +190,7 @@ const clickQuestion = (question) => {
   color: transparent;
   font-size: 14px;
   font-weight: 700;
-  margin: 5px 0 0 55px;
+  margin: 1px 0 0 55px;
 }
 .small_carousel {
   width: 452px;
@@ -239,4 +239,8 @@ const clickQuestion = (question) => {
 :deep(.el-carousel__item--card, .el-carousel__item.is-animating) {
   padding-bottom: 0 !important;
 }
+:deep(.el-carousel__indicators--horizontal) {
+  bottom: -2px;
+  height: 16px;
+}
 </style>