btAlert.vue 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. <template>
  2. <view class="bt-alert">
  3. <view class="box">
  4. <image class="img1" src="https://airsmart-photo1.oss-cn-shanghai.aliyuncs.com/wx/ic_bluetooth_permission.png" mode="aspectFit"/>
  5. <text class="text1">蓝牙权限</text>
  6. <text class="text2">请开启手机蓝牙功能进行连接</text>
  7. </view>
  8. <image class="ic-close" src="../../static/common/ic_close.svg" mode="aspectFit" @click.self="close"/>
  9. </view>
  10. </template>
  11. <script>
  12. export default {
  13. props: {},
  14. data: () => ({}),
  15. computed: {},
  16. methods: {
  17. close(){
  18. this.$emit('close')
  19. }
  20. },
  21. watch: {},
  22. // 组件周期函数--监听组件挂载完毕
  23. mounted() {},
  24. // 组件周期函数--监听组件激活(显示)
  25. activated() {},
  26. // 组件周期函数--监听组件停用(隐藏)
  27. deactivated() {},
  28. // 组件周期函数--监听组件销毁之前
  29. beforeDestroy() {},
  30. };
  31. </script>
  32. <style>
  33. .bt-alert {
  34. position: fixed;
  35. top: 0;
  36. left: 0;
  37. right: 0;
  38. bottom: 0;
  39. z-index: 999;
  40. background: rgba(0, 0, 0, 0.6);
  41. display: flex;
  42. flex-direction: column;
  43. align-items: center;
  44. }
  45. .box {
  46. margin-top: 14vh;
  47. width: 69.33vw;
  48. height: 70.4vw;
  49. border-radius: 16rpx;
  50. background: white;
  51. display: flex;
  52. flex-direction: column;
  53. align-items: center;
  54. }
  55. .img1 {
  56. width: 38.4vw;
  57. height: 39.7vw;
  58. margin-top: 50rpx;
  59. }
  60. .text1 {
  61. margin-top: 30rpx;
  62. font-size: 36rpx;
  63. font-family: PingFangSC-Semibold, PingFang SC;
  64. font-weight: 600;
  65. color: #353535;
  66. }
  67. .text2 {
  68. margin-top: 10rpx;
  69. font-size: 30rpx;
  70. font-family: PingFangSC-Regular, PingFang SC;
  71. font-weight: 400;
  72. color: #999999;
  73. }
  74. .ic-close{
  75. margin-top: 20rpx;
  76. width: 88rpx;
  77. height: 88rpx;
  78. }
  79. </style>