@smartbit4all/ng-client 1.0.27 → 1.0.29
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.
- package/esm2020/lib/session/smart-timer/smart-session-timer.component.mjs +1 -1
- package/esm2020/lib/view-context/smart-ui-action/ui-action.descriptor.service.mjs +12 -5
- package/fesm2015/smartbit4all-ng-client.mjs +10 -3
- package/fesm2015/smartbit4all-ng-client.mjs.map +1 -1
- package/fesm2020/smartbit4all-ng-client.mjs +10 -3
- package/fesm2020/smartbit4all-ng-client.mjs.map +1 -1
- package/lib/session/smart-timer/smart-session-timer.component.d.ts +1 -1
- package/package.json +1 -1
- package/smartbit4all-ng-client-1.0.29.tgz +0 -0
- package/smartbit4all-ng-client-1.0.27.tgz +0 -0
|
@@ -3093,15 +3093,22 @@ class UiActionDescriptorService {
|
|
|
3093
3093
|
this._destroy$.complete();
|
|
3094
3094
|
}
|
|
3095
3095
|
subscribeToTranslateService() {
|
|
3096
|
-
this.viewContext
|
|
3096
|
+
this.viewContext
|
|
3097
|
+
.translateService.onLangChange.pipe(takeUntil(this._destroy$))
|
|
3098
|
+
.subscribe(() => {
|
|
3097
3099
|
this.languageChanged.next();
|
|
3098
3100
|
});
|
|
3099
3101
|
}
|
|
3100
3102
|
async getActionDescriptor(uiAction) {
|
|
3101
3103
|
let code = uiAction.code;
|
|
3102
3104
|
let actionDescriptorFromDescriptors = this.viewContext.getActionDescriptors()?.get(code);
|
|
3103
|
-
let
|
|
3105
|
+
let isUnkown = false;
|
|
3106
|
+
let actionDescriptor;
|
|
3107
|
+
if (actionDescriptorFromDescriptors) {
|
|
3108
|
+
actionDescriptor = JSON.parse(JSON.stringify(actionDescriptorFromDescriptors));
|
|
3109
|
+
}
|
|
3104
3110
|
if (!actionDescriptor) {
|
|
3111
|
+
isUnkown = true;
|
|
3105
3112
|
actionDescriptor = this.basicActionDescriptors.get('UNKOWN');
|
|
3106
3113
|
actionDescriptor.title = code;
|
|
3107
3114
|
}
|
|
@@ -3111,7 +3118,7 @@ class UiActionDescriptorService {
|
|
|
3111
3118
|
if (!actionDescriptor.feedbackType && uiAction.submit) {
|
|
3112
3119
|
actionDescriptor.feedbackType = UiActionFeedbackType.Snackbar;
|
|
3113
3120
|
}
|
|
3114
|
-
if (this.viewContext.translateService && actionDescriptor) {
|
|
3121
|
+
if (this.viewContext.translateService && actionDescriptor && !isUnkown) {
|
|
3115
3122
|
actionDescriptor = await this.translateUiActionDescriptor(actionDescriptor);
|
|
3116
3123
|
}
|
|
3117
3124
|
return actionDescriptor;
|