@aiot-toolkit/aiotpack 2.0.2-beta.14 → 2.0.2-beta.16

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.
@@ -31,6 +31,20 @@ class WrapPlugin {
31
31
  var clearTimeout = global.clearTimeout;
32
32
  var clearInterval = global.clearInterval;
33
33
  var $app_require$ = global.$app_require$ || org_app_require
34
+
35
+ // 转换动态 style 的函数
36
+ var $translateStyle$ = function (value) {
37
+ if (typeof value === 'string') {
38
+ return Object.fromEntries(value.split(';').filter(item => Boolean(item && item.trim())).map(
39
+ item => {
40
+ const matchs = item.match(/([^:]+):(.*)/)
41
+ if (matchs && matchs.lenth> 2) {
42
+ return [matchs[1].trim().replace(/-([a-z])/g, (_, match) => match.toUpperCase()), matchs[2].trim()]
43
+ }
44
+ return []
45
+ }))}
46
+ return value
47
+ }
34
48
 
35
49
  var createPageHandler = function() {
36
50
  return `, source, `
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aiot-toolkit/aiotpack",
3
- "version": "2.0.2-beta.14",
3
+ "version": "2.0.2-beta.16",
4
4
  "description": "The process tool for packaging aiot projects.",
5
5
  "keywords": [
6
6
  "aiotpack"
@@ -19,16 +19,16 @@
19
19
  "test": "node ./__tests__/aiotpack.test.js"
20
20
  },
21
21
  "dependencies": {
22
- "@aiot-toolkit/generator": "2.0.2-beta.14",
23
- "@aiot-toolkit/parser": "2.0.2-beta.14",
24
- "@aiot-toolkit/shared-utils": "2.0.2-beta.14",
22
+ "@aiot-toolkit/generator": "2.0.2-beta.16",
23
+ "@aiot-toolkit/parser": "2.0.2-beta.16",
24
+ "@aiot-toolkit/shared-utils": "2.0.2-beta.16",
25
25
  "@hap-toolkit/aaptjs": "^2.0.0",
26
26
  "aiot-parse5": "^1.0.0",
27
27
  "archiver": "^6.0.1",
28
28
  "babel-loader": "^9.1.3",
29
29
  "del": "^4.1.1",
30
30
  "fast-glob": "^3.3.2",
31
- "file-lane": "2.0.2-beta.14",
31
+ "file-lane": "2.0.2-beta.16",
32
32
  "file-loader": "^6.2.0",
33
33
  "fs-extra": "^11.2.0",
34
34
  "jsrsasign": "^7.2.2",
@@ -46,5 +46,5 @@
46
46
  "@types/jsrsasign": "^10.5.12",
47
47
  "@types/webpack-sources": "^3.2.3"
48
48
  },
49
- "gitHead": "c6093733d0267d2d1359fec0af8f7a253955e3e3"
49
+ "gitHead": "785701c64914f50acd18ab71ea41b2f5a2cd161c"
50
50
  }