16 lines
436 B
Plaintext
16 lines
436 B
Plaintext
|
var funcA = function (e, ins) {
|
||
|
// console.log('source is', JSON.stringify(e))
|
||
|
var scrollTop = e.detail.scrollTop
|
||
|
if (scrollTop > 600) {
|
||
|
ins.selectComponent('.group').setStyle({
|
||
|
"background-color": 'rgba(77, 158, 233, 1)'
|
||
|
})
|
||
|
} else {
|
||
|
ins.selectComponent('.group').setStyle({
|
||
|
"background-color": 'rgba(77, 158, 233, ' + Math.max(0, (scrollTop) / 600) + ')'
|
||
|
})
|
||
|
}
|
||
|
}
|
||
|
module.exports = {
|
||
|
funcA: funcA
|
||
|
}
|