ssm41471/src/main/webapp/front/components/uni-ui/lib/uni-swipe-action/mp.js
(开头部分) 1KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
export default {
data () {
return {
position: [],
button: []
}
},
computed: {
pos () {
return JSON.stringify(this.position)
},
btn () {
return JSON.stringify(this.button)
}
},
watch: {
show (newVal) {
if (this.autoClose) return
let valueObj = this.position[0]
if (!valueObj) return
valueObj.show = newVal
this.$set(this.position, 0, valueObj)
}
},
// #ifdef H5
mounted () {
this.init()
this.getSize()
this.getButtonSize()
},
// #endif
// #ifndef H5
onReady () {
this.init()
this.getSize()
this.getButtonSize()
},
// #endif
methods: {
init () {
uni.$on('__uni__swipe__event', (res) => {
if (res !== this && this.autoClose) {
let valueObj = this.position[0]
valueObj.show = false
this.$set(this.position, 0, valueObj)
}
})
},
openSwipe () {
uni.$emit('__uni__swipe__event', this)
},
change (e) {
this.$emit('change', e.open)
let valueObj = this.position[0]
valueObj.show = e.open
this.$set(this.position, 0, valueObj)
// console.log('改变', e);
},
onClick (index, item) {
this.$emit('click', {
后面还有 29 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
