@flexem/fc-gui 3.0.0-alpha.125 → 3.0.0-alpha.127

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.
@@ -187,8 +187,7 @@ export class TextStateElement {
187
187
  targetLanguage = currentLanguage;
188
188
  }
189
189
  else {
190
- // 无法获取语种代码(可能是配置错误),返回空字符串
191
- return '';
190
+ targetLanguage = defaultLanguage;
192
191
  }
193
192
  }
194
193
  // 返回对应语种的文本,如果没有则返回空字符串
@@ -150,10 +150,16 @@ let WriteValueModalComponent = class WriteValueModalComponent {
150
150
  }
151
151
  // 转换为数字类型
152
152
  const languageId = value === '' || value == null ? null : Number(value);
153
- // 调用 GuiContext 的更新方法
153
+ // 调用 GuiContext 的语种切换方法
154
154
  this.args.guiContext.updateCurrentLanguageId(languageId).then(() => {
155
- // 更新成功,关闭弹窗
156
- this.bsModalRef.hide();
155
+ // 语种切换成功,调用 onClosed 回调,让数字显示元件也能更新
156
+ this.onClosed({
157
+ value: value,
158
+ showValue: value,
159
+ enableNumericalOperation: false,
160
+ isNumericalOperation: false,
161
+ variableRwType: 6
162
+ });
157
163
  }).catch(() => {
158
164
  this.showValidationErrorInfo(this.localization.loadFailed);
159
165
  this.isSubmitting = false;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "main": "bundles/fc-gui.umd.js",
3
- "version": "3.0.0-alpha.125",
3
+ "version": "3.0.0-alpha.127",
4
4
  "module": "public_api.js",
5
5
  "typings": "public_api.d.ts",
6
6
  "license": "UNLICENSED",