@aks-dev/easyui 1.0.86 → 1.0.87

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/screen/px2sp.ts +9 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aks-dev/easyui",
3
- "version": "1.0.86",
3
+ "version": "1.0.87",
4
4
  "description": "移动端App开发工具包",
5
5
  "main": "./src/index.ts",
6
6
  "typings": "./src/index.d.ts",
package/screen/px2sp.ts CHANGED
@@ -1,3 +1,10 @@
1
+ /*
2
+ * @Author: shiguo
3
+ * @Date: 2021-04-27 10:40:36
4
+ * @LastEditors: shiguo
5
+ * @LastEditTime: 2022-07-18 11:27:22
6
+ * @FilePath: /@aks-dev/easyui/screen/px2sp.ts
7
+ */
1
8
  import { Dimensions, PixelRatio } from 'react-native';
2
9
  const pixelRatio = PixelRatio.get();
3
10
  const width = Dimensions.get('window').width; //设备的宽度
@@ -54,7 +61,8 @@ export const px2sp = (size: number) => {
54
61
  return size * 1.25;
55
62
  }
56
63
  // catch larger phablet devices
57
- return size * 1.4;
64
+
65
+ return size * 1.3;
58
66
  }
59
67
  // if older device ie pixelRatio !== 2 || 3 || 3.5
60
68
  return size;