mirror of
https://gitee.com/vant-contrib/vant-weapp.git
synced 2025-04-06 03:58:05 +08:00
25 lines
506 B
XML
25 lines
506 B
XML
/* eslint-disable */
|
|
var style = require('../wxs/style.wxs');
|
|
|
|
function wrapStyle(data) {
|
|
return style({
|
|
transform: data.transform
|
|
? 'translate3d(0, ' + data.transform + 'px, 0)'
|
|
: '',
|
|
top: data.fixed ? data.offsetTop + 'px' : '',
|
|
'z-index': data.zIndex,
|
|
});
|
|
}
|
|
|
|
function containerStyle(data) {
|
|
return style({
|
|
height: data.fixed ? data.height + 'px' : '',
|
|
'z-index': data.zIndex,
|
|
});
|
|
}
|
|
|
|
module.exports = {
|
|
wrapStyle: wrapStyle,
|
|
containerStyle: containerStyle,
|
|
};
|