@tuya-sat/micro-script 2.2.30 → 2.3.0-rc.1
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,7 +106,8 @@ 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")
|
|
109
|
+
require("@tuya-sat/micro-dev-loader")
|
|
110
|
+
.changeTuyaSatComponentImport,
|
|
110
111
|
].filter(Boolean)),
|
|
111
112
|
},
|
|
112
113
|
{
|
|
@@ -173,6 +174,7 @@ function getCommonConfig({ isDev, isBuild, }) {
|
|
|
173
174
|
chunkFilename: "static/css/[name].[contenthash:8].chunk.css",
|
|
174
175
|
}),
|
|
175
176
|
isBuild && enableThemeCompile && new micro_dev_loader_1.ThemePlugin(),
|
|
177
|
+
isBuild && new micro_dev_loader_1.LocalesPlugin(),
|
|
176
178
|
].filter((value) => Boolean(value)),
|
|
177
179
|
};
|
|
178
180
|
}
|
|
@@ -96,10 +96,14 @@ 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
|
-
|
|
99
|
+
themeConfig.config_value_json = JSON.stringify(Object.assign(Object.assign(Object.assign({}, JSON.parse(themeConfig.config_value_json)), (theme
|
|
100
|
+
? {
|
|
101
|
+
supportedTheme: theme,
|
|
102
|
+
}
|
|
103
|
+
: {})), readThemeConfig()));
|
|
102
104
|
overrideNotification(saas);
|
|
105
|
+
// 本地开发态多语言剥离多语言平台,走本地多语言兜底逻辑
|
|
106
|
+
_SDF.saas.saas_locales = {};
|
|
103
107
|
$("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)};
|
|
104
108
|
localStorage.setItem('theme',${JSON.stringify(process.env.MICRO_THEME)});
|
|
105
109
|
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
|
+
"version": "2.3.0-rc.1",
|
|
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.
|
|
24
|
-
"@tuya-sat/micro-dev-proxy": "2.
|
|
25
|
-
"@tuya-sat/micro-utils": "2.
|
|
23
|
+
"@tuya-sat/micro-dev-loader": "2.3.0-rc.1",
|
|
24
|
+
"@tuya-sat/micro-dev-proxy": "2.3.0-rc.1",
|
|
25
|
+
"@tuya-sat/micro-utils": "2.3.0-rc.1",
|
|
26
26
|
"babel-loader": "8.2.4",
|
|
27
27
|
"babel-plugin-import": "1.13.3",
|
|
28
28
|
"chalk": "4.1.2",
|
|
@@ -75,5 +75,6 @@
|
|
|
75
75
|
"saas",
|
|
76
76
|
"cloud",
|
|
77
77
|
"tuya"
|
|
78
|
-
]
|
|
78
|
+
],
|
|
79
|
+
"stableVersion": "2.2.30"
|
|
79
80
|
}
|