liyongli 4 år sedan
förälder
incheckning
38ec4d7018
3 ändrade filer med 8 tillägg och 9 borttagningar
  1. 1 2
      src/components/Detail/news.vue
  2. 1 1
      src/components/Detail/video.vue
  3. 6 6
      src/pages/robot/Index.vue

+ 1 - 2
src/components/Detail/news.vue

@@ -106,11 +106,9 @@ export default {
     margin: 0.05rem auto;
   }
   p {
-    min-height: 0.3rem;
     line-height: 1.5em;
     text-indent: 2em;
     margin: 0.2rem 0;
-    padding-left: 0.05rem;
     strong {
       font-weight: 450;
     }
@@ -122,6 +120,7 @@ export default {
 
   img {
     width: 100%;
+    display: block;
   }
 }
 </style>

+ 1 - 1
src/components/Detail/video.vue

@@ -134,7 +134,7 @@ export default {
   mounted() {
     this.playerOptions = {
       // videojs options
-      muted: true,
+      muted: false,
       width: "100%",
       aspectRatio: "16:9",
       language: "zh-CN",

+ 6 - 6
src/pages/robot/Index.vue

@@ -15,7 +15,7 @@
           <div
             class="msgBg"
             v-for="item in dialogueLst"
-            style="text-align: right;"
+            :style="'text-align: ' + (item.type === 'local' ? 'right' : 'left')"
             :key="item.text"
           >
             <div
@@ -28,9 +28,9 @@
       <div class="van-hairline--left van-hairline--right van-hairline--bottom">
         <van-field v-model="message" rows="1" autosize type="textarea" />
         <div style="text-align: right; padding: 0.1rem">
-          <van-button size="small" type="primary" @click="tomsg"
-            >发送</van-button
-          >
+          <van-button size="small" type="primary" @click="tomsg">
+            发送
+          </van-button>
         </div>
       </div>
       <van-cell title="控制机器人" value="" />
@@ -174,7 +174,7 @@ export default {
       this.scoket = new WebSocket(
         Config.robotBaseWss +
           "/ws/app/event?clientId=" +
-          Config.clientId +
+          Config.robotClientId +
           "&deviceId=" +
           this.deviceId +
           "&token=" +
@@ -214,7 +214,7 @@ export default {
       if (res.error_code !== 0) return Toast("机器人走丢了");
       this.robotToken = res.token || "";
       getRobotClient({
-        clientId: Config.clientId,
+        clientId: Config.robotClientId,
         token: this.robotToken
       }).then(r => {
         this.$refs.scroll.scrollTop = this.$refs.msgScroll.scrollHeight;