connected.vue 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. <template>
  2. <div>
  3. <van-row class="padding">
  4. <van-col span="5">
  5. <div class="device_bg flex flex-direction align-center justify-center">
  6. <img src="https://img.shuimuai.com/web/phone.png" alt="" class="device_phone">
  7. <view>
  8. <text class="text-gray device_text"> 我的手机</text>
  9. </view>
  10. </div>
  11. </van-col>
  12. <van-col span="3" offset="1">
  13. <div class="dot_container flex align-center">
  14. <div class="dot_wait">
  15. <img src="https://img.shuimuai.com/m_sign_gou%402x.png" alt="" class="moving_dot">
  16. </div>
  17. </div>
  18. </van-col>
  19. <van-col span="5" offset="0">
  20. <div class="device_bg flex flex-direction align-center justify-center">
  21. <!-- <text>{{ device_power }}%</text>-->
  22. <img src="https://img.shuimuai.com/web/sign_green.png" alt="" class="sign_green" v-if="device_bg == true">
  23. <img src="https://img.shuimuai.com/web/sign_red.png" class="sign_green" alt="" v-else>
  24. <img src="https://img.shuimuai.com/web/brain.png" alt="" class="device_brain">
  25. <view>
  26. <text class="text-gray device_text second_device_text"> 水母智脑环</text>
  27. </view>
  28. </div>
  29. </van-col>
  30. </van-row>
  31. <!-- 按钮组合-->
  32. <van-row>
  33. <van-col span="9" offset="1">
  34. <button class="cu-btn bg-red lg text-white" @click="change_status(0)">
  35. <img src="https://img.shuimuai.com/m_duankainaohuan.png" class="cut_brain_icon" alt="">
  36. <text class="padding-lr cut_text">断开脑环</text>
  37. </button>
  38. </van-col>
  39. <van-col span="12" offset="1">
  40. <button class="cu-btn bg-red lg cu-btn-primary" @click="open_choose_toy">
  41. <img src="https://img.shuimuai.com/m_xuanzewanju.png" alt="" class="cut_brain_icon">
  42. <text class="padding-lr cut_text">选择玩具</text>
  43. </button>
  44. </van-col>
  45. </van-row>
  46. <div class="boy_session padding">
  47. <text class="boy_session_text">点击选择你喜欢 的玩具类别就可 以开始玩囖!</text>
  48. </div>
  49. <img src="https://img.shuimuai.com/web/boy.png" alt="" class="connected_boy">
  50. </div>
  51. </template>
  52. <script>
  53. export default {
  54. name: "connected",
  55. props: ['device_bg', 'device_power'],
  56. methods: {
  57. open_choose_toy() {
  58. this.$emit('open_choose_toy')
  59. },
  60. change_status($status) {
  61. this.$emit('change_brain_status', $status)
  62. }
  63. }
  64. }
  65. </script>
  66. <style scoped>
  67. .cut_text {
  68. padding: 0px 5px;
  69. font-size: 11px;
  70. }
  71. </style>