升级package, 以及更新声明文件
This commit is contained in:
@@ -11,13 +11,13 @@ module.exports = {
|
||||
return classNames.join(' ');
|
||||
},
|
||||
|
||||
getSize: function (size = 'medium', systemInfo) {
|
||||
getSize: function (size = 'medium', windowWidth) {
|
||||
var res = getRegExp('^([0-9]+)(px|rpx)$').exec(size);
|
||||
|
||||
if (res && res.length >= 3) {
|
||||
var px = res[1];
|
||||
if (res[2] === 'rpx') {
|
||||
px = Math.floor((systemInfo.windowWidth * res[1]) / 750);
|
||||
px = Math.floor((windowWidth * res[1]) / 750);
|
||||
}
|
||||
|
||||
return 'width:' + size + ';height:' + size + ';font-size:' + ((px / 8) * 3 + 2) + 'px';
|
||||
|
||||
Reference in New Issue
Block a user