@tuya-sat/micro-script 2.3.0-rc.1 → 2.3.0
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.
|
@@ -62,7 +62,7 @@ function getCommonConfig({ isDev, isBuild, }) {
|
|
|
62
62
|
importLoaders: loadersBeforeCssLoader.length,
|
|
63
63
|
},
|
|
64
64
|
},
|
|
65
|
-
...loadersBeforeCssLoader
|
|
65
|
+
...loadersBeforeCssLoader
|
|
66
66
|
].filter(Boolean);
|
|
67
67
|
return loaders;
|
|
68
68
|
};
|
|
@@ -106,8 +106,7 @@ function getCommonConfig({ isDev, isBuild, }) {
|
|
|
106
106
|
enableThemeCompile &&
|
|
107
107
|
require("@tuya-sat/micro-dev-loader").changeAntdGlobalImport,
|
|
108
108
|
enableThemeCompile &&
|
|
109
|
-
require("@tuya-sat/micro-dev-loader")
|
|
110
|
-
.changeTuyaSatComponentImport,
|
|
109
|
+
require("@tuya-sat/micro-dev-loader").changeTuyaSatComponentImport
|
|
111
110
|
].filter(Boolean)),
|
|
112
111
|
},
|
|
113
112
|
{
|
|
@@ -174,7 +173,6 @@ function getCommonConfig({ isDev, isBuild, }) {
|
|
|
174
173
|
chunkFilename: "static/css/[name].[contenthash:8].chunk.css",
|
|
175
174
|
}),
|
|
176
175
|
isBuild && enableThemeCompile && new micro_dev_loader_1.ThemePlugin(),
|
|
177
|
-
isBuild && new micro_dev_loader_1.LocalesPlugin(),
|
|
178
176
|
].filter((value) => Boolean(value)),
|
|
179
177
|
};
|
|
180
178
|
}
|
|
@@ -96,14 +96,10 @@ function insertScript($, debuggerConfig) {
|
|
|
96
96
|
return item.config_key === "dynamic_theme";
|
|
97
97
|
}) || initalCustom_configs(saas);
|
|
98
98
|
const theme = (0, webpack_common_1.validateMicroTheme)();
|
|
99
|
-
themeConfig.config_value_json = JSON.stringify(Object.assign(Object.assign(Object.assign({}, JSON.parse(themeConfig.config_value_json)), (theme
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
}
|
|
103
|
-
: {})), readThemeConfig()));
|
|
99
|
+
themeConfig.config_value_json = JSON.stringify(Object.assign(Object.assign(Object.assign({}, JSON.parse(themeConfig.config_value_json)), (theme ? {
|
|
100
|
+
supportedTheme: theme,
|
|
101
|
+
} : {})), readThemeConfig()));
|
|
104
102
|
overrideNotification(saas);
|
|
105
|
-
// 本地开发态多语言剥离多语言平台,走本地多语言兜底逻辑
|
|
106
|
-
_SDF.saas.saas_locales = {};
|
|
107
103
|
$("head").append($("<script>").text(`window._SDF_CONFIG=${JSON.stringify(_SDF_CONFIG)};window._SDF=${JSON.stringify(_SDF)};window.__MAIN_APP_PUBLIC_PATH=${JSON.stringify(__MAIN_APP_PUBLIC_PATH)};
|
|
108
104
|
localStorage.setItem('theme',${JSON.stringify(process.env.MICRO_THEME)});
|
|
109
105
|
localStorage.setItem('isDebugger','true')
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tuya-sat/micro-script",
|
|
3
|
-
"version": "2.3.0
|
|
3
|
+
"version": "2.3.0",
|
|
4
4
|
"bin": "./dist/bin/cli.js",
|
|
5
5
|
"type": "commonjs",
|
|
6
6
|
"license": "MIT",
|
|
@@ -20,9 +20,9 @@
|
|
|
20
20
|
"@babel/preset-react": "7.16.7",
|
|
21
21
|
"@babel/preset-typescript": "7.16.7",
|
|
22
22
|
"@pmmmwh/react-refresh-webpack-plugin": "0.5.4",
|
|
23
|
-
"@tuya-sat/micro-dev-loader": "2.3.0
|
|
24
|
-
"@tuya-sat/micro-dev-proxy": "2.3.0
|
|
25
|
-
"@tuya-sat/micro-utils": "2.3.0
|
|
23
|
+
"@tuya-sat/micro-dev-loader": "2.3.0",
|
|
24
|
+
"@tuya-sat/micro-dev-proxy": "2.3.0",
|
|
25
|
+
"@tuya-sat/micro-utils": "2.3.0",
|
|
26
26
|
"babel-loader": "8.2.4",
|
|
27
27
|
"babel-plugin-import": "1.13.3",
|
|
28
28
|
"chalk": "4.1.2",
|
|
@@ -75,6 +75,5 @@
|
|
|
75
75
|
"saas",
|
|
76
76
|
"cloud",
|
|
77
77
|
"tuya"
|
|
78
|
-
]
|
|
79
|
-
"stableVersion": "2.2.30"
|
|
78
|
+
]
|
|
80
79
|
}
|