@wavemaker/app-runtime-wm-build 11.4.3-next.25756 → 11.4.3-next.30202
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.
|
@@ -4168,7 +4168,7 @@
|
|
|
4168
4168
|
EXCLUDEDAYS: "excludedays"
|
|
4169
4169
|
};
|
|
4170
4170
|
var transformFileURI = function(url) {
|
|
4171
|
-
if (url && hasCordova() && url.startsWith("file://")) {
|
|
4171
|
+
if (_.isString(url) && hasCordova() && url.startsWith("file://")) {
|
|
4172
4172
|
if (isIos()) {
|
|
4173
4173
|
return url.replace("file://", "/_app_file_");
|
|
4174
4174
|
} else if (isAndroid() && location.href.startsWith("http")) {
|
|
@@ -17071,9 +17071,7 @@
|
|
|
17071
17071
|
};
|
|
17072
17072
|
BaseFormCustomComponent.prototype.invokeOnChange = function(value, $event, valid) {
|
|
17073
17073
|
this._onChange(value);
|
|
17074
|
-
|
|
17075
|
-
_super.prototype.invokeOnChange.call(this, value, $event);
|
|
17076
|
-
}
|
|
17074
|
+
_super.prototype.invokeOnChange.call(this, value, $event);
|
|
17077
17075
|
};
|
|
17078
17076
|
BaseFormCustomComponent.prototype.invokeOnTouched = function($event) {
|
|
17079
17077
|
this._onTouched();
|
|
@@ -17281,6 +17279,9 @@
|
|
|
17281
17279
|
core$1.$appDigest();
|
|
17282
17280
|
}), 150);
|
|
17283
17281
|
_this.handleHeaderClick = core$1.noop;
|
|
17282
|
+
_this.cancelLocaleChangeSubscription = _this.getAppInstance().subscribe("locale-changed", (function() {
|
|
17283
|
+
_this._debouncedInitDatasetItems();
|
|
17284
|
+
}));
|
|
17284
17285
|
return _this;
|
|
17285
17286
|
}
|
|
17286
17287
|
Object.defineProperty(DatasetAwareFormComponent.prototype, "modelByKey", {
|
|
@@ -17493,6 +17494,11 @@
|
|
|
17493
17494
|
this.toggleAllHeaders = base.toggleAllHeaders.bind(undefined, this);
|
|
17494
17495
|
}
|
|
17495
17496
|
};
|
|
17497
|
+
DatasetAwareFormComponent.prototype.ngOnDestroy = function() {
|
|
17498
|
+
if (this.cancelLocaleChangeSubscription) {
|
|
17499
|
+
this.cancelLocaleChangeSubscription();
|
|
17500
|
+
}
|
|
17501
|
+
};
|
|
17496
17502
|
return DatasetAwareFormComponent;
|
|
17497
17503
|
}(BaseFormCustomComponent);
|
|
17498
17504
|
DatasetAwareFormComponent.decorators = [ {
|
|
@@ -24046,6 +24052,11 @@
|
|
|
24046
24052
|
i18nService.initCalendarLocale();
|
|
24047
24053
|
FullCalendar.__wm_locale_initialized = true;
|
|
24048
24054
|
}
|
|
24055
|
+
_this.cancelLocaleChangeSubscription = _this.getAppInstance().subscribe("locale-changed", (function(libLocale) {
|
|
24056
|
+
_this.setLocale();
|
|
24057
|
+
_this.applyCalendarOptions("option", "locale", libLocale.fullCalendar || "en");
|
|
24058
|
+
_this.redraw();
|
|
24059
|
+
}));
|
|
24049
24060
|
return _this;
|
|
24050
24061
|
}
|
|
24051
24062
|
CalendarComponent.prototype.selectDate = function() {
|
|
@@ -24508,6 +24519,11 @@
|
|
|
24508
24519
|
}));
|
|
24509
24520
|
}));
|
|
24510
24521
|
};
|
|
24522
|
+
CalendarComponent.prototype.ngOnDestroy = function() {
|
|
24523
|
+
if (this.cancelLocaleChangeSubscription) {
|
|
24524
|
+
this.cancelLocaleChangeSubscription();
|
|
24525
|
+
}
|
|
24526
|
+
};
|
|
24511
24527
|
return CalendarComponent;
|
|
24512
24528
|
}(base.StylableComponent);
|
|
24513
24529
|
CalendarComponent.initializeProps = registerProps();
|
|
@@ -27095,7 +27111,7 @@
|
|
|
27095
27111
|
type: core.Component,
|
|
27096
27112
|
args: [ {
|
|
27097
27113
|
selector: "wm-datetimepicker",
|
|
27098
|
-
template: '
|
|
27114
|
+
template: '\n <ng-template #datetimepickerTemplate>\n <div class="app-datetime-picker">\n <div class="modal-body">\n <div class="mobile-datetime-picker-options">\n\n </div>\n <bs-datepicker-inline\n [bsConfig]="bsDatepickerConfig"\n [datesDisabled]="excludedDatesToDisable"\n bsDatepicker\n [bsValue]="changedValue"\n (bsValueChange)="onDateUpdate($event)"\n *ngIf="mode === \'DATE_TIME\' || mode === \'DATE\'">\n </bs-datepicker-inline>\n <wm-timepicker\n [value]="changedValue"\n [min]="minTime"\n [max]="maxTime"\n (change)="onTimeUpdate($event)"\n *ngIf="mode === \'DATE_TIME\' || mode === \'TIME\'"></wm-timepicker>\n <span class="text-primary date-picker-value">\n {{getDateLabel()}}\n </span>\n </div>\n <div class="modal-footer">\n <button\n *ngIf="mode === \'DATE_TIME\' || mode === \'DATE\'"\n class="btn btn-secondary today-btn"\n (click)="setToday()">{{appLocale.LABEL_TODAY_DATE || "Today" }}</button>\n <button\n class="btn btn-primary pull-right ok-btn"\n *ngIf="mode === \'DATE_TIME\' || mode === \'TIME\'"\n (click)="onOkClick()">{{appLocale.LABEL_OK || "Ok" }}</button>\n <button\n class="btn btn-secondary pull-right clear-btn"\n (click)="clear()">{{appLocale.LABEL_CLEAR_DATE || "Clear" }}</button>\n </div>\n </div>\n </ng-template>\n '
|
|
27099
27115
|
} ]
|
|
27100
27116
|
} ];
|
|
27101
27117
|
DateTimePickerComponent.ctorParameters = function() {
|
|
@@ -27235,7 +27251,7 @@
|
|
|
27235
27251
|
type: core.Component,
|
|
27236
27252
|
args: [ {
|
|
27237
27253
|
selector: "wm-timepicker",
|
|
27238
|
-
template: '
|
|
27254
|
+
template: '\n <wm-pickergroup>\n <wm-picker\n [options]="options.hour"\n [selectedValue]="hour"\n (change)="set($event, \'HOUR\')"></wm-picker>\n <span class="app-time-separator">:</span>\n <wm-picker\n [options]="options.minute"\n [selectedValue]="minute"\n (change)="set($event, \'MINUTE\')"></wm-picker>\n <span class="app-time-separator">:</span>\n <wm-picker\n [options]="options.minute"\n [selectedValue]="second"\n (change)="set($event, \'SECOND\')"></wm-picker>\n </wm-pickergroup>\n '
|
|
27239
27255
|
} ]
|
|
27240
27256
|
} ];
|
|
27241
27257
|
TimePickerComponent.ctorParameters = function() {
|
|
@@ -27290,6 +27306,11 @@
|
|
|
27290
27306
|
_this._dateOptions.clearPosition = "right";
|
|
27291
27307
|
_this.meridians = common.getLocaleDayPeriods(_this.selectedLocale, common.FormStyle.Format, common.TranslationWidth.Abbreviated);
|
|
27292
27308
|
_this.loadNativeDateInput = core$1.isMobile() && !_this.showcustompicker;
|
|
27309
|
+
_this.cancelLocaleChangeSubscription = _this.getAppInstance().subscribe("locale-changed", (function(locale) {
|
|
27310
|
+
_this.datePipe.datePipe.locale = locale.angular;
|
|
27311
|
+
_this._dateOptions.todayButtonLabel = _this.i18nService.getLocalizedMessage("LABEL_TODAY_DATE");
|
|
27312
|
+
_this._dateOptions.clearButtonLabel = _this.i18nService.getLocalizedMessage("LABEL_CLEAR_DATE");
|
|
27313
|
+
}));
|
|
27293
27314
|
return _this;
|
|
27294
27315
|
}
|
|
27295
27316
|
Object.defineProperty(BaseDateTimeComponent.prototype, "timeZone", {
|
|
@@ -27510,6 +27531,8 @@
|
|
|
27510
27531
|
if (event.originalEvent) {
|
|
27511
27532
|
_this.setFocusForDate(-1);
|
|
27512
27533
|
}
|
|
27534
|
+
var prevMon = _this.getMonth(_this.activeDate, -1);
|
|
27535
|
+
$(".bs-datepicker-head .previous").prepend('<p aria-hidden="false" class="sr-only">Changed to Previous Month, ' + prevMon.fullMonth + " and year " + prevMon.date.getFullYear() + "</p>");
|
|
27513
27536
|
setTimeout((function() {
|
|
27514
27537
|
$(".bs-datepicker-head .previous").focus();
|
|
27515
27538
|
}));
|
|
@@ -27521,6 +27544,8 @@
|
|
|
27521
27544
|
if (event.originalEvent) {
|
|
27522
27545
|
_this.setFocusForDate(1);
|
|
27523
27546
|
}
|
|
27547
|
+
var nextMon = _this.getMonth(_this.activeDate, 1);
|
|
27548
|
+
$(".bs-datepicker-head .next").prepend('<p aria-hidden="false" class="sr-only">Changed to Next Month, ' + nextMon.fullMonth + " and year " + nextMon.date.getFullYear() + "</p>");
|
|
27524
27549
|
setTimeout((function() {
|
|
27525
27550
|
$(".bs-datepicker-head .next").focus();
|
|
27526
27551
|
}));
|
|
@@ -27536,21 +27561,10 @@
|
|
|
27536
27561
|
_this.setFocusForMonthOrDay();
|
|
27537
27562
|
}
|
|
27538
27563
|
}));
|
|
27539
|
-
|
|
27540
|
-
|
|
27541
|
-
|
|
27542
|
-
|
|
27543
|
-
var msg = "Changed to month ";
|
|
27544
|
-
datePickerHead.find(".current").attr("aria-live", "assertive").attr("aria-atomic", "false");
|
|
27545
|
-
if (_this.clicked) {
|
|
27546
|
-
if ($(currentNodes[0]).text()) {
|
|
27547
|
-
datePickerHead.find(".ng-star-inserted").prepend('<div class="sr-only">' + msg + "</div>");
|
|
27548
|
-
}
|
|
27549
|
-
if ($(currentNodes[1]).text()) {
|
|
27550
|
-
datePickerHead.find(".current").last().prepend('<div class="sr-only"> and year </div>');
|
|
27551
|
-
}
|
|
27552
|
-
}
|
|
27553
|
-
}));
|
|
27564
|
+
if (!this.clicked) {
|
|
27565
|
+
datePickerHead.find(".next").attr("aria-label", "Next Month, " + this.next.fullMonth + " " + this.next.date.getFullYear());
|
|
27566
|
+
datePickerHead.find(".previous").attr("aria-label", "Previous Month, " + this.prev.fullMonth + " " + this.prev.date.getFullYear());
|
|
27567
|
+
}
|
|
27554
27568
|
};
|
|
27555
27569
|
BaseDateTimeComponent.prototype.setFocusForMonthOrDay = function() {
|
|
27556
27570
|
var activeMonthOrYear = $(".bs-datepicker-head .current").first().text();
|
|
@@ -28070,6 +28084,9 @@
|
|
|
28070
28084
|
if (this.dateOnShowSubscription) {
|
|
28071
28085
|
this.dateOnShowSubscription.unsubscribe();
|
|
28072
28086
|
}
|
|
28087
|
+
if (this.cancelLocaleChangeSubscription) {
|
|
28088
|
+
this.cancelLocaleChangeSubscription();
|
|
28089
|
+
}
|
|
28073
28090
|
_super.prototype.ngOnDestroy.call(this);
|
|
28074
28091
|
};
|
|
28075
28092
|
BaseDateTimeComponent.prototype.ngOnDetach = function() {
|
|
@@ -28303,7 +28320,6 @@
|
|
|
28303
28320
|
this.invokeEventCallback("click", {
|
|
28304
28321
|
$event: $event
|
|
28305
28322
|
});
|
|
28306
|
-
this.focusOnInputEl();
|
|
28307
28323
|
}
|
|
28308
28324
|
if ($event.target && $($event.target).is("input") && !this.isDropDownDisplayEnabledOnInput(this.showdropdownon)) {
|
|
28309
28325
|
$event.stopPropagation();
|
|
@@ -28690,7 +28706,6 @@
|
|
|
28690
28706
|
this.invokeEventCallback("click", {
|
|
28691
28707
|
$event: $event
|
|
28692
28708
|
});
|
|
28693
|
-
this.focusOnInputEl();
|
|
28694
28709
|
}
|
|
28695
28710
|
if ($event.target && $($event.target).is("input") && !this.isDropDownDisplayEnabledOnInput(this.showdropdownon)) {
|
|
28696
28711
|
$event.stopPropagation();
|
|
@@ -29012,7 +29027,6 @@
|
|
|
29012
29027
|
this.invokeEventCallback("click", {
|
|
29013
29028
|
$event: $event
|
|
29014
29029
|
});
|
|
29015
|
-
this.focusOnInputEl();
|
|
29016
29030
|
}
|
|
29017
29031
|
if ($event.target && $($event.target).is("input") && !this.isDropDownDisplayEnabledOnInput(this.showdropdownon)) {
|
|
29018
29032
|
return;
|
|
@@ -82913,6 +82927,7 @@
|
|
|
82913
82927
|
timezone: "",
|
|
82914
82928
|
number: ""
|
|
82915
82929
|
};
|
|
82930
|
+
_this.bundleLoaded = {};
|
|
82916
82931
|
_this.appLocale = {};
|
|
82917
82932
|
_this.prefabLocale = new Map;
|
|
82918
82933
|
return _this;
|
|
@@ -82979,6 +82994,8 @@
|
|
|
82979
82994
|
_this.extendMessages(bundle.messages);
|
|
82980
82995
|
_this.extendPrefabMessages(bundle);
|
|
82981
82996
|
_this.appDefaults.setFormats(bundle.formats);
|
|
82997
|
+
_this.bundleLoaded.app = true;
|
|
82998
|
+
_this.notifyLocaleChanged();
|
|
82982
82999
|
}));
|
|
82983
83000
|
};
|
|
82984
83001
|
I18nServiceImpl.prototype.loadMomentLocaleBundle = function(momentLocale) {
|
|
@@ -82995,6 +83012,8 @@
|
|
|
82995
83012
|
_config = _config && _config._config;
|
|
82996
83013
|
chronos.defineLocale(_this.selectedLocale, _config);
|
|
82997
83014
|
_this.bsLocaleService.use(_this.getSelectedLocale() || _this.defaultSupportedLocale);
|
|
83015
|
+
_this.bundleLoaded.moment = true;
|
|
83016
|
+
_this.notifyLocaleChanged();
|
|
82998
83017
|
}));
|
|
82999
83018
|
};
|
|
83000
83019
|
I18nServiceImpl.prototype.loadAngularLocaleBundle = function(angLocale) {
|
|
@@ -83024,6 +83043,7 @@
|
|
|
83024
83043
|
return Promise.resolve();
|
|
83025
83044
|
}
|
|
83026
83045
|
if (!force && (i2.isMobile() || i2.isMobileApp() || this.selectedLocale === this.defaultSupportedLocale)) {
|
|
83046
|
+
this.bundleLoaded.fullCalendar = true;
|
|
83027
83047
|
return;
|
|
83028
83048
|
}
|
|
83029
83049
|
return i2.loadScripts([ path ], true);
|
|
@@ -83053,11 +83073,21 @@
|
|
|
83053
83073
|
}));
|
|
83054
83074
|
};
|
|
83055
83075
|
I18nServiceImpl.prototype.loadLocaleBundles = function(libLocale) {
|
|
83076
|
+
var _this = this;
|
|
83077
|
+
var _a;
|
|
83056
83078
|
if (libLocale.moment) {
|
|
83057
83079
|
this.loadMomentLocaleBundle(libLocale.moment);
|
|
83080
|
+
} else if (this.selectedLocale === this.defaultSupportedLocale) {
|
|
83081
|
+
this.bsLocaleService.use(this.getSelectedLocale() || this.defaultSupportedLocale);
|
|
83082
|
+
this.bundleLoaded.moment = true;
|
|
83058
83083
|
}
|
|
83059
83084
|
if (libLocale.fullCalendar && window["FullCalendar"]) {
|
|
83060
|
-
this.loadCalendarLocaleBundle(libLocale.fullCalendar)
|
|
83085
|
+
(_a = this.loadCalendarLocaleBundle(libLocale.fullCalendar)) === null || _a === void 0 ? void 0 : _a.then((function() {
|
|
83086
|
+
_this.bundleLoaded.fullCalendar = true;
|
|
83087
|
+
_this.notifyLocaleChanged();
|
|
83088
|
+
}));
|
|
83089
|
+
} else {
|
|
83090
|
+
this.bundleLoaded.fullCalendar = true;
|
|
83061
83091
|
}
|
|
83062
83092
|
if (libLocale.angular) {
|
|
83063
83093
|
this.loadAppLocaleBundle();
|
|
@@ -83097,8 +83127,15 @@
|
|
|
83097
83127
|
i2.setSessionStorageItem("selectedLocale", locale);
|
|
83098
83128
|
this.selectedLocale = locale;
|
|
83099
83129
|
this.init();
|
|
83130
|
+
this.bundleLoaded.moment = false;
|
|
83131
|
+
this.bundleLoaded.fullCalendar = false;
|
|
83132
|
+
this.bundleLoaded.app = false;
|
|
83133
|
+
this.bundleLoaded.angular = false;
|
|
83134
|
+
this.bundleLoaded.libLocale = libLocale;
|
|
83100
83135
|
return this.loadLocaleBundles(libLocale).then((function() {
|
|
83101
|
-
|
|
83136
|
+
_this.updateLocaleDirection();
|
|
83137
|
+
_this.bundleLoaded.angular = true;
|
|
83138
|
+
_this.notifyLocaleChanged();
|
|
83102
83139
|
}));
|
|
83103
83140
|
};
|
|
83104
83141
|
I18nServiceImpl.prototype.deduceAppLocale = function() {
|
|
@@ -83134,6 +83171,7 @@
|
|
|
83134
83171
|
return defaultLanguage;
|
|
83135
83172
|
};
|
|
83136
83173
|
I18nServiceImpl.prototype.loadDefaultLocale = function() {
|
|
83174
|
+
Date.prototype["month"] = Date.prototype.getMonth;
|
|
83137
83175
|
var locale = this.deduceAppLocale();
|
|
83138
83176
|
return this.setSelectedLocale(locale);
|
|
83139
83177
|
};
|
|
@@ -83171,6 +83209,11 @@
|
|
|
83171
83209
|
I18nServiceImpl.prototype.getwidgetLocale = function() {
|
|
83172
83210
|
return this.formatsByLocale;
|
|
83173
83211
|
};
|
|
83212
|
+
I18nServiceImpl.prototype.notifyLocaleChanged = function() {
|
|
83213
|
+
if (this.bundleLoaded.moment && this.bundleLoaded.fullCalendar && this.bundleLoaded.angular && this.bundleLoaded.app) {
|
|
83214
|
+
this.app.notify("locale-changed", this.bundleLoaded.libLocale);
|
|
83215
|
+
}
|
|
83216
|
+
};
|
|
83174
83217
|
return I18nServiceImpl;
|
|
83175
83218
|
}(i2.AbstractI18nService);
|
|
83176
83219
|
I18nServiceImpl.decorators = [ {
|