安装新版QQ时出现以下报错,重复下载安装包安装多遍无法解决次问题,该提醒中也无法知晓具体出了什么问题,希望有懂的朋友可以提供帮助
json
文件
{
"component": true,
"usingComponents": {}
}
wxml
文件
<view class="slide_page">
<!-- 侧边栏内容 -->
<view class="slide-slidebar">
侧边栏内容
</view>
<view
bind:touchmove="tap_drag"
bind:touchend="tap_end"
bind:touchstart="tap_start"
class="page-top {{open ? ['c-state','cover'] : ''}} ">
<slot name="main_content"/>
</view>
</view>
wxss
文件
.slide_page {
height: 100%;
font-family: 'PingFang SC',
'Helvetica Neue',
Helvetica,
'Droid Sans Fallback',
'Microsoft Yachei',
sans-serif;
}
.slide-slidebar {
height: 100%;
width: 371rpx;
position: fixed;
background-color:#FFFAFA;
z-index: 0;
}
.page-top {
height: 100%;
position: fixed;
width: 750rpx;
background-color:#FCFCFC;
z-index: 0;
transition: All 0.4s ease;
-webkit-transition: All 0.4s ease;
}
.cover{
width: 100%;
height: 100%;
background-color:rgb(88, 86, 86);
opacity: 0.5;
z-index: 9000;
}
.c-state {
transform: rotate(0deg) scale(1) translate(50%, 0%);
-webkit-transform: rotate(0deg) scale(1) translate(50%, 0%);
}
js
文件
// components/slide.js
Component({
options: {
multipleSlots: true
},
/**
* 组件的属性列表
*/
properties: {
},
/**
* 组件的初始数据
*/
data: {
open: false,
// mark 是指原点x轴坐标
mark: 0,
// newmark 是指移动的最新点的x轴坐标
newmark: 0,
istoright: true,
statusInfo: ['正在休息', '正在营业'],
info: '正在营业'
},
/**
* 组件的方法列表
*/
methods: {
tap_start: function (e) {
// touchstart事件
// 把手指触摸屏幕的那一个点的 x 轴坐标赋值给 mark 和 newmark
this.data.mark = this.data.newmark = e.touches[0].pageX;
},
tap_drag: function (e) {
// touchmove事件
this.data.newmark = e.touches[0].pageX;
// 手指从左向右移动
if (this.data.mark < this.data.newmark) {
this.istoright = true;
}
// 手指从右向左移动
if (this.data.mark > this.data.newmark) {
this.istoright = false;
}
this.data.mark = this.data.newmark;
},
tap_end: function (e) {
// touchend事件
this.data.mark = 0;
this.data.newmark = 0;
// 通过改变 opne 的值,让主页加上滑动的样式
if (this.istoright) {
this.setData({
open: true
});
} else {
this.setData({
open: false
});
}
}
}
})
我感觉用起来和微信没什么差别了,速度很快,但是不能贴边收起了