@wavemaker/app-ng-runtime 12.0.0-next.45032 → 12.0.0-next.45501

Sign up to get free protection for your applications and to get access to all the features.
Files changed (119) hide show
  1. app-ng-runtime/build-task/bundles/index.umd.js +405 -451
  2. app-ng-runtime/build-task/esm2022/data/form/form-field/form-field.build.mjs +2 -3
  3. app-ng-runtime/build-task/esm2022/public_api.mjs +1 -3
  4. app-ng-runtime/build-task/fesm2022/index.mjs +406 -454
  5. app-ng-runtime/build-task/fesm2022/index.mjs.map +1 -1
  6. app-ng-runtime/build-task/public_api.d.ts +0 -2
  7. app-ng-runtime/components/base/bundles/index.umd.js +14 -62
  8. app-ng-runtime/components/base/components.module.d.ts +11 -12
  9. app-ng-runtime/components/base/esm2022/components.module.mjs +1 -5
  10. app-ng-runtime/components/base/esm2022/public_api.mjs +1 -2
  11. app-ng-runtime/components/base/esm2022/widgets/common/base/base.component.mjs +15 -25
  12. app-ng-runtime/components/base/fesm2022/index.mjs +15 -62
  13. app-ng-runtime/components/base/fesm2022/index.mjs.map +1 -1
  14. app-ng-runtime/components/base/public_api.d.ts +0 -1
  15. app-ng-runtime/components/base/widgets/common/base/base.component.d.ts +5 -10
  16. app-ng-runtime/components/containers/wizard/bundles/index.umd.js +17 -0
  17. app-ng-runtime/components/containers/wizard/esm2022/wizard.component.mjs +18 -1
  18. app-ng-runtime/components/containers/wizard/fesm2022/index.mjs +17 -0
  19. app-ng-runtime/components/containers/wizard/fesm2022/index.mjs.map +1 -1
  20. app-ng-runtime/components/containers/wizard/wizard.component.d.ts +1 -0
  21. app-ng-runtime/components/data/form/esm2022/form-field/form-field.directive.mjs +1 -3
  22. app-ng-runtime/components/data/form/fesm2022/index.mjs +0 -2
  23. app-ng-runtime/components/data/form/fesm2022/index.mjs.map +1 -1
  24. app-ng-runtime/components/dialogs/default/bundles/index.umd.js +11 -0
  25. app-ng-runtime/components/dialogs/default/esm2022/base-dialog.mjs +12 -1
  26. app-ng-runtime/components/dialogs/default/fesm2022/index.mjs +11 -0
  27. app-ng-runtime/components/dialogs/default/fesm2022/index.mjs.map +1 -1
  28. app-ng-runtime/components/input/default/bundles/index.umd.js +63 -39
  29. app-ng-runtime/components/input/default/checkboxset/checkboxset.component.d.ts +0 -1
  30. app-ng-runtime/components/input/default/esm2022/checkboxset/checkboxset.component.mjs +5 -8
  31. app-ng-runtime/components/input/default/esm2022/radioset/radioset.component.mjs +5 -8
  32. app-ng-runtime/components/input/default/esm2022/select/select.component.mjs +57 -29
  33. app-ng-runtime/components/input/default/esm2022/text/base/base-input.mjs +1 -4
  34. app-ng-runtime/components/input/default/esm2022/text/locale/number-locale.mjs +2 -2
  35. app-ng-runtime/components/input/default/esm2022/textarea/textarea.component.mjs +4 -1
  36. app-ng-runtime/components/input/default/fesm2022/index.mjs +63 -39
  37. app-ng-runtime/components/input/default/fesm2022/index.mjs.map +1 -1
  38. app-ng-runtime/components/input/default/radioset/radioset.component.d.ts +0 -1
  39. app-ng-runtime/components/input/default/select/select.component.d.ts +2 -4
  40. app-ng-runtime/components/input/default/textarea/textarea.component.d.ts +3 -2
  41. app-ng-runtime/components/input/epoch/bundles/index.umd.js +3 -0
  42. app-ng-runtime/components/input/epoch/esm2022/date-time/date-time.component.mjs +4 -1
  43. app-ng-runtime/components/input/epoch/fesm2022/index.mjs +3 -0
  44. app-ng-runtime/components/input/epoch/fesm2022/index.mjs.map +1 -1
  45. app-ng-runtime/components/input/file-upload/bundles/index.umd.js +31 -5
  46. app-ng-runtime/components/input/file-upload/esm2022/file-upload.component.mjs +34 -8
  47. app-ng-runtime/components/input/file-upload/fesm2022/index.mjs +32 -6
  48. app-ng-runtime/components/input/file-upload/fesm2022/index.mjs.map +1 -1
  49. app-ng-runtime/components/input/file-upload/file-upload.component.d.ts +6 -2
  50. app-ng-runtime/components/navigation/menu/bundles/index.umd.js +2 -2
  51. app-ng-runtime/components/navigation/menu/esm2022/menu.component.mjs +2 -2
  52. app-ng-runtime/components/navigation/menu/esm2022/nav/nav.component.mjs +2 -2
  53. app-ng-runtime/components/navigation/menu/fesm2022/index.mjs +2 -2
  54. app-ng-runtime/components/navigation/menu/fesm2022/index.mjs.map +1 -1
  55. app-ng-runtime/core/bundles/index.umd.js +6 -16
  56. app-ng-runtime/core/enums/enums.d.ts +1 -2
  57. app-ng-runtime/core/esm2022/enums/enums.mjs +1 -2
  58. app-ng-runtime/core/esm2022/types/types.mjs +1 -4
  59. app-ng-runtime/core/esm2022/utils/build-utils.mjs +1 -6
  60. app-ng-runtime/core/esm2022/utils/utils.mjs +4 -3
  61. app-ng-runtime/core/fesm2022/index.mjs +4 -12
  62. app-ng-runtime/core/fesm2022/index.mjs.map +1 -1
  63. app-ng-runtime/core/types/types.d.ts +1 -5
  64. app-ng-runtime/core/utils/utils.d.ts +1 -0
  65. app-ng-runtime/mobile/core/bundles/index.umd.js +18 -2
  66. app-ng-runtime/mobile/core/esm2022/native.xhr.mjs +19 -3
  67. app-ng-runtime/mobile/core/fesm2022/index.mjs +18 -2
  68. app-ng-runtime/mobile/core/fesm2022/index.mjs.map +1 -1
  69. app-ng-runtime/package.json +1 -1
  70. app-ng-runtime/runtime/base/bundles/index.umd.js +5 -288
  71. app-ng-runtime/runtime/base/esm2022/public_api.mjs +1 -2
  72. app-ng-runtime/runtime/base/esm2022/runtime-base.module.mjs +1 -6
  73. app-ng-runtime/runtime/base/esm2022/services/i18n.service.mjs +2 -2
  74. app-ng-runtime/runtime/base/esm2022/types/types.mjs +1 -2
  75. app-ng-runtime/runtime/base/fesm2022/index.mjs +4 -287
  76. app-ng-runtime/runtime/base/fesm2022/index.mjs.map +1 -1
  77. app-ng-runtime/runtime/base/public_api.d.ts +0 -1
  78. app-ng-runtime/runtime/base/runtime-base.module.d.ts +8 -9
  79. app-ng-runtime/runtime/base/types/types.d.ts +1 -2
  80. app-ng-runtime/runtime/dynamic/bundles/index.umd.js +9 -27
  81. app-ng-runtime/runtime/dynamic/esm2022/app/app.module.mjs +2 -5
  82. app-ng-runtime/runtime/dynamic/esm2022/app/services/component-ref-provider.service.mjs +7 -23
  83. app-ng-runtime/runtime/dynamic/fesm2022/index.mjs +7 -26
  84. app-ng-runtime/runtime/dynamic/fesm2022/index.mjs.map +1 -1
  85. app-ng-runtime/scripts/@wavemaker/nvd3/build/nv.d3.min.js +1 -1
  86. app-ng-runtime/scripts/datatable/datatable.js +6 -3
  87. app-ng-runtime/scripts/summernote/dist/summernote-lite.min.js +2 -3
  88. app-ng-runtime/transpiler/bundles/index.umd.js +0 -5
  89. app-ng-runtime/transpiler/esm2022/build.mjs +1 -4
  90. app-ng-runtime/transpiler/esm2022/imports.mjs +1 -3
  91. app-ng-runtime/transpiler/fesm2022/index.mjs +0 -5
  92. app-ng-runtime/transpiler/fesm2022/index.mjs.map +1 -1
  93. app-ng-runtime/build-task/advanced/custom-widget-container/custom-widget-container.build.d.ts +0 -2
  94. app-ng-runtime/build-task/advanced/custom-widget-wrapper/custom-widget-wrapper.build.d.ts +0 -2
  95. app-ng-runtime/build-task/esm2022/advanced/custom-widget-container/custom-widget-container.build.mjs +0 -15
  96. app-ng-runtime/build-task/esm2022/advanced/custom-widget-wrapper/custom-widget-wrapper.build.mjs +0 -26
  97. app-ng-runtime/components/advanced/custom/.npmignore +0 -2
  98. app-ng-runtime/components/advanced/custom/bundles/index.umd.js +0 -232
  99. app-ng-runtime/components/advanced/custom/custom-widget-container/custom-widget-container.directive.d.ts +0 -19
  100. app-ng-runtime/components/advanced/custom/custom-widget-container/custom-widget.props.d.ts +0 -2
  101. app-ng-runtime/components/advanced/custom/custom-widget-prop.d.ts +0 -1
  102. app-ng-runtime/components/advanced/custom/custom-widget.directive.d.ts +0 -19
  103. app-ng-runtime/components/advanced/custom/custom-widget.module.d.ts +0 -10
  104. app-ng-runtime/components/advanced/custom/esm2022/custom-widget-container/custom-widget-container.directive.mjs +0 -102
  105. app-ng-runtime/components/advanced/custom/esm2022/custom-widget-container/custom-widget.props.mjs +0 -12
  106. app-ng-runtime/components/advanced/custom/esm2022/custom-widget-prop.mjs +0 -8
  107. app-ng-runtime/components/advanced/custom/esm2022/custom-widget.directive.mjs +0 -68
  108. app-ng-runtime/components/advanced/custom/esm2022/custom-widget.module.mjs +0 -32
  109. app-ng-runtime/components/advanced/custom/esm2022/index.mjs +0 -5
  110. app-ng-runtime/components/advanced/custom/esm2022/public_api.mjs +0 -4
  111. app-ng-runtime/components/advanced/custom/fesm2022/index.mjs +0 -215
  112. app-ng-runtime/components/advanced/custom/fesm2022/index.mjs.map +0 -1
  113. app-ng-runtime/components/advanced/custom/index.d.ts +0 -5
  114. app-ng-runtime/components/advanced/custom/package.json +0 -23
  115. app-ng-runtime/components/advanced/custom/public_api.d.ts +0 -3
  116. app-ng-runtime/components/base/esm2022/widgets/common/base/custom-widget-container.directive.mjs +0 -39
  117. app-ng-runtime/components/base/widgets/common/base/custom-widget-container.directive.d.ts +0 -14
  118. app-ng-runtime/runtime/base/components/base-custom-widget.component.d.ts +0 -72
  119. app-ng-runtime/runtime/base/esm2022/components/base-custom-widget.component.mjs +0 -288
@@ -8,7 +8,6 @@ export declare class RadiosetComponent extends DatasetAwareFormComponent {
8
8
  itemsperrow: string;
9
9
  private itemsPerRowClass;
10
10
  constructor(inj: Injector, explicitContext: any);
11
- triggerInvokeOnChange(key: any, $event: any): void;
12
11
  /**
13
12
  * On click of the option, update the datavalue
14
13
  */
@@ -1,5 +1,4 @@
1
1
  import { AfterViewInit, ElementRef, Injector } from '@angular/core';
2
- import { App } from '@wm/core';
3
2
  import { DatasetAwareFormComponent } from '../dataset-aware-form.component';
4
3
  import * as i0 from "@angular/core";
5
4
  export declare class SelectComponent extends DatasetAwareFormComponent implements AfterViewInit {
@@ -14,10 +13,9 @@ export declare class SelectComponent extends DatasetAwareFormComponent implement
14
13
  name: string;
15
14
  autofocus: boolean;
16
15
  hint: string;
17
- private app;
18
16
  selectEl: ElementRef;
19
17
  set datasource(ds: any);
20
- constructor(inj: Injector, app: App, explicitContext: any);
18
+ constructor(inj: Injector, explicitContext: any);
21
19
  ngAfterViewInit(): void;
22
20
  protected handleEvent(node: HTMLElement, eventName: string, eventCallback: Function, locals: any): void;
23
21
  onSelectValueChange($event: any): void;
@@ -30,6 +28,6 @@ export declare class SelectComponent extends DatasetAwareFormComponent implement
30
28
  */
31
29
  checkForFloatingLabel($event: any): void;
32
30
  private removePlaceholderOption;
33
- static ɵfac: i0.ɵɵFactoryDeclaration<SelectComponent, [null, null, { optional: true; }]>;
31
+ static ɵfac: i0.ɵɵFactoryDeclaration<SelectComponent, [null, { optional: true; }]>;
34
32
  static ɵcmp: i0.ɵɵComponentDeclaration<SelectComponent, "wm-select", never, {}, {}, never, never, false, never>;
35
33
  }
@@ -1,8 +1,8 @@
1
- import { ElementRef, Injector } from '@angular/core';
1
+ import { AfterViewChecked, ElementRef, Injector } from '@angular/core';
2
2
  import { NgModel } from '@angular/forms';
3
3
  import { BaseInput } from '../text/base/base-input';
4
4
  import * as i0 from "@angular/core";
5
- export declare class TextareaComponent extends BaseInput {
5
+ export declare class TextareaComponent extends BaseInput implements AfterViewChecked {
6
6
  static initializeProps: void;
7
7
  required: boolean;
8
8
  maxchars: number;
@@ -22,6 +22,7 @@ export declare class TextareaComponent extends BaseInput {
22
22
  ngModel: NgModel;
23
23
  constructor(inj: Injector, explicitContext: any);
24
24
  onInputChange(): void;
25
+ ngAfterViewChecked(): void;
25
26
  static ɵfac: i0.ɵɵFactoryDeclaration<TextareaComponent, [null, { optional: true; }]>;
26
27
  static ɵcmp: i0.ɵɵComponentDeclaration<TextareaComponent, "wm-textarea", never, {}, {}, never, never, false, never>;
27
28
  }
@@ -2399,6 +2399,9 @@
2399
2399
  $(this.nativeElement).find('.display-input').val(this.displayValue);
2400
2400
  }
2401
2401
  }
2402
+ if (newVal && !this.bsDateValue && this.timeZone) {
2403
+ newVal = i1$1.getMomentLocaleObject(this.timeZone, newVal);
2404
+ }
2402
2405
  // min date and max date validation in web.
2403
2406
  // if invalid dates are entered, device is showing validation message.
2404
2407
  this.minDateMaxDateValidationOnInput(newVal);
@@ -230,6 +230,9 @@ export class DatetimeComponent extends BaseDateTimeComponent {
230
230
  $(this.nativeElement).find('.display-input').val(this.displayValue);
231
231
  }
232
232
  }
233
+ if (newVal && !this.bsDateValue && this.timeZone) {
234
+ newVal = getMomentLocaleObject(this.timeZone, newVal);
235
+ }
233
236
  // min date and max date validation in web.
234
237
  // if invalid dates are entered, device is showing validation message.
235
238
  this.minDateMaxDateValidationOnInput(newVal);
@@ -505,4 +508,4 @@ export class DatetimeComponent extends BaseDateTimeComponent {
505
508
  args: [BsDatepickerDirective]
506
509
  }] }); })();
507
510
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(DatetimeComponent, { className: "DatetimeComponent", filePath: "date-time/date-time.component.ts", lineNumber: 56 }); })();
508
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZGF0ZS10aW1lLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL2NvbXBvbmVudHMvd2lkZ2V0cy9pbnB1dC9lcG9jaC9zcmMvZGF0ZS10aW1lL2RhdGUtdGltZS5jb21wb25lbnQudHMiLCIuLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9jb21wb25lbnRzL3dpZGdldHMvaW5wdXQvZXBvY2gvc3JjL2RhdGUtdGltZS9kYXRlLXRpbWUuY29tcG9uZW50Lmh0bWwiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUVILGlCQUFpQixFQUNqQixTQUFTLEVBQ1QsTUFBTSxFQUNOLFFBQVEsRUFDUixNQUFNLEVBRU4sUUFBUSxFQUNSLFNBQVMsRUFDWixNQUFNLGVBQWUsQ0FBQztBQUN2QixPQUFPLEVBQUUsaUJBQWlCLEVBQUUsYUFBYSxFQUFFLE1BQU0sZ0JBQWdCLENBQUM7QUFDbEUsT0FBTyxFQUFFLHFCQUFx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BnZXRNb21lbnRMb2NhbGVPYmplY3QodGhpcy50aW1lWm9uZSkgOiBuZXcgRGF0ZSgpO1xuICAgICAgICAgICAgdGhpcy5vbk1vZGVsVXBkYXRlKGN1cnJlbnRUaW1lKTtcbiAgICAgICAgfSwgMTAwMCk7XG4gICAgfVxuXG4gICAgLyoqXG4gICAgICogVGhpcyBpcyBhbiBpbnRlcm5hbCBtZXRob2QgdXNlZCB0byBjbGVhciB0aGUgdGltZSBpbnRlcnZhbCBjcmVhdGVkXG4gICAgICovXG4gICAgcHJpdmF0ZSBjbGVhclRpbWVJbnRlcnZhbCgpIHtcbiAgICAgICAgaWYgKHRoaXMudGltZWludGVydmFsKSB7XG4gICAgICAgICAgICBjbGVhckludGVydmFsKHRoaXMudGltZWludGVydmFsKTtcbiAgICAgICAgICAgIHRoaXMudGltZWludGVydmFsID0gbnVsbDtcbiAgICAgICAgfVxuICAgIH1cblxuICAgIC8qKlxuICAgICAqIFRoaXMgaXMgYW4gaW50ZXJuYWwgbWV0aG9kIHRvIHRvZ2dsZSB0aGUgdGltZSBwaWNrZXJcbiAgICAgKi9cbiAgICBwdWJsaWMgdG9nZ2xlVGltZVBpY2tlcihuZXdWYWwsICRldmVudD86IGFueSkge1xuICAgICAgICBpZiAodGhpcy5sb2FkTmF0aXZlRGF0ZUlucHV0KSB7XG4gICAgICAgICAgICB0aGlzLm9uRGF0ZVRpbWVJbnB1dEZvY3VzKCk7XG4gICAgICAgICAgICByZXR1cm47XG4gICAgICAgIH1cbiAgICAgICAgdGhpcy5pc1RpbWVPcGVuID0gbmV3VmFsO1xuICAgICAgICBpZiAoJGV2ZW50ICYmICRldmVudC50eXBlID09PSAnY2xpY2snKSB7XG4gICAgICAgICAgICB0aGlzLmludm9rZUV2ZW50Q2FsbGJhY2soJ2NsaWNrJywgeyAkZXZlbnQ6ICRldmVudCB9KTtcbiAgICAgICAgfVxuICAgICAgICB0aGlzLmFkZFRpbWVwaWNrZXJDbGlja0xpc3RlbmVyKHRoaX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ZGF0YXZhbHVlLCBldmVudCwgZmFsc2UpO1xuICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgIHRoaXMuaW52YWxpZERhdGVUaW1lRm9ybWF0ID0gZmFsc2U7XG4gICAgICAgICAgICAgICAgICAgIHRoaXMuaXNFbnRlclByZXNzZWRPbkRhdGVJbnB1dCA9IHRydWU7XG4gICAgICAgICAgICAgICAgICAgIHRoaXMuYnNEYXRlUGlja2VyRGlyZWN0aXZlLmJzVmFsdWUgPSBuZXdWYWw7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIHRoaXMudG9nZ2xlRHBEcm9wZG93bihldmVudCk7XG4gICAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgICAgIHRoaXMuaGlkZURhdGVwaWNrZXJEcm9wZG93bigpO1xuICAgICAgICAgICAgICAgIHRoaXMuaGlkZVRpbWVwaWNrZXJEcm9wZG93bigpO1xuICAgICAgICAgICAgfVxuICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgdGhpcy5oaWRlRGF0ZXBpY2tlckRyb3Bkb3duKCk7XG4gICAgICAgICAgICB0aGlzLmhpZGVUaW1lcGlja2VyRHJvcGRvd24oKTtcbiAgICAgICAgfVxuICAgIH1cblxuICAgIHByaXZhdGUgaXNWYWxpZChldmVudCkge1xuICAgICAgICBpZiAoIWV2ZW50KSB7XG4gICAgICAgICAgICBjb25zdCBlbnRlcmVkRGF0ZSA9ICQodGhpcy5uYXRpdmVFbGVtZW50KS5maW5kKCdpbnB1dCcpLnZhbCgpO1xuICAgICAgICAgICAgY29uc3QgbmV3VmFsID0gZ2V0TmF0aXZlRGF0ZU9iamVjdChlbnRlcmVkRGF0ZSwge3BhdHRlcm46IHRoaXMubG9hZE5hdGl2ZURhdGVJbnB1dCA/IHRoaXMub3V0cHV0Zm9ybWF0IDogdGhpcy5kYXRlcGF0dGVybiwgbWVyaWRpYW5zOiB0aGlzLm1lcmlkaWFucywga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Aob25TaG93bik9XCJvblRpbWVwaWNrZXJPcGVuKClcIlxuICAgICAgICBzdHlsZT1cImRpc3BsYXk6IGluaGVyaXQ7XCI+XG4gICAgICAgIDxpbnB1dCBjbGFzcz1cImZvcm0tY29udHJvbCBhcHAtdGV4dGJveCBkaXNwbGF5LWlucHV0XCJcbiAgICAgICAgICAgIFthdHRyLmFyaWEtbGFiZWxdPVwiaGludFwiXG4gICAgICAgICAgICBmb2N1cy10YXJnZXRcbiAgICAgICAgICAgIFtuYW1lXT1cIm5hbWVcIlxuICAgICAgICAgICAgW3RhYmluZGV4XT1cImxvYWROYXRpdmVEYXRlSW5wdXQgPyAnLTEnIDogdGFiaW5kZXhcIlxuICAgICAgICAgICAgW2F0dHIuYXJpYS1oaWRkZW5dPVwiISFsb2FkTmF0aXZlRGF0ZUlucHV0XCJcbiAgICAgICAgICAgIHR5cGU9XCJ0ZXh0XCJcbiAgICAgICAgICAgIFt2YWx1ZV09XCJkaXNwbGF5VmFsdWVcIlxuICAgICAgICAgICAgKGNsaWNrKT1cInRvZ2dsZURwRHJvcGRvd24oJGV2ZW50LCB0cnVlKVwiXG4gICAgICAgICAgICAoZm9jdXMpPVwib25EYXRlVGltZUlucHV0Rm9jdXMoKTsgaW52b2tlT25Gb2N1cygkZXZlbnQpO1wiXG4gICAgICAgICAgICAoYmx1cik9XCJvbklucHV0Qmx1cigkZXZlbnQpXCJcbiAgICAgICAgICAgIChjaGFuZ2UpPVwib25EYXRlQ2hhbmdlKCRldmVudClcIlxuICAgICAgICAgICAgW2F1dG9mb2N1c109XCJhdXRvZm9jdXNcIlxuICAgICAgICAgICAgW2Rpc2FibGVkXT1cImRpc2FibGVkIHx8IHJlYWRvbmx5IHx8IGlzQ3VycmVudERhdGVcIlxuICAgICAgICAgICAgW3JlcXVpcmVkXT1cInJlcXVpcmVkXCJcbiAgICAgICAgICAgIFtyZWFkT25seV09XCJpc1JlYWRPbmx5XCJcbiAgICAgICAgICAgIFthdHRyLnBsYWNlaG9s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lbmRhclwiPjwvaT5cbiAgICAgICAgICAgIDwvYnV0dG9uPlxuICAgICAgICAgICAgPGJ1dHRvbiB0eXBlPVwiYnV0dG9uXCJcbiAgICAgICAgICAgICAgICBjbGFzcz1cImJ0biBidG4tZGVmYXVsdCBidG4tdGltZVwiXG4gICAgICAgICAgICAgICAgW3RhYmluZGV4XT1cImxvYWROYXRpdmVEYXRlSW5wdXQgPyAnLTEnIDogdGFiaW5kZXhcIlxuICAgICAgICAgICAgICAgIFthdHRyLmFyaWEtaGlkZGVuXT1cIiEhbG9hZE5hdGl2ZURhdGVJbnB1dFwiXG4gICAgICAgICAgICAgICAgW2Rpc2FibGVkXT1cImRpc2FibGVkIHx8IHJlYWRvbmx5IHx8IGlzQ3VycmVudERhdGVcIlxuICAgICAgICAgICAgICAgIGFyaWEtbGFiZWw9XCJTZWxlY3QgdGltZVwiXG4gICAgICAgICAgICAgICAgYXJpYS1oYXNwb3B1cD1cInRydWVcIlxuICAgICAgICAgICAgICAgIGFyaWEtZXhwYW5kZWQ9XCJmYWxzZVwiXG4gICAgICAgICAgICAgICAgKGNsaWNrKT1cInRvZ2dsZVRpbWVQaWNrZXIoIWlzVGltZU9wZW4sICRldmVudClcIj5cbiAgICAgICAgICAgICAgICA8aSBhcmlhLWhpZGRlbj1cInRydWVcIlxuICAgICAgICAgICAgICAgICAgICBjbGFzcz1cImFwcC1pY29uIHdtLXNsLWwgc2wtdGltZVwiPjwvaT5cbiAgICAgICAgICAgIDwvYnV0dG9uPlxuICAgICAgICA8L3NwYW4+XG4gICAgICAgIDxkaXYgc3R5bGU9XCJ3aWR0aDogMDtkaXNwbGF5OiBpbmxpbmUtYmxvY2s7XCI+XG4gICAgICAgIDxpbnB1dCBjbGFzcz1cIm1vZGVsLWhvbGRlclwiXG4gICAgICAgICAgICBhcmlhLWxhYmVsPVwiZGF0ZXBpY2tlciBkcm9wZG93bm1lbnVcIlxuICAgICAgICAgICAgYXJpYS1jb250cm9scz1cImRhdGVcIlxuICAg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NrZXIgZHJvcGRvd25cIlxuICAgICAgICAgICAgYXJpYS1jb250cm9scz1cInRpbWVcIlxuICAgICAgICAgICAgKGNsaWNrKT1cInByZXZlbnRUcENsb3NlKCRldmVudClcIj5cbiAgICAgICAgICAgIDx0aW1lcGlja2VyIGNsYXNzPVwibW9kZWwtaG9sZGVyXCJcbiAgICAgICAgICAgICAgICBbc2hvd01lcmlkaWFuXT1cImlzbWVyaWRpYW5cIlxuICAgICAgICAgICAgICAgIFtyZWFkb25seUlucHV0XT1cImRpc2FibGVkIHx8IHJlYWRvbmx5IHx8IGlzQ3VycmVudERhdGVcIlxuICAgICAgICAgICAgICAgIFsobmdNb2RlbCldPVwiYnNUaW1lVmFsdWVcIlxuICAgICAgICAgICAgICAgICAgICAgICAgW25nTW9kZWxPcHRpb25zXT1cIntzdGFuZGFsb25lOiB0cnVlfVwiXG4gICAgICAgICAgICAgICAgW21pbl09XCJtaW5UaW1lXCJcbiAgICAgICAgICAgICAgICBbbWF4XT1cIm1heFRpbWVcIlxuICAgICAgICAgICAgICAgIFtob3VyU3RlcF09XCJob3Vyc3RlcFwiXG4gICAgICAgICAgICAgICAgW21pbnV0ZVN0ZXBdPVwibWludXRlc3RlcFwiXG4gICAgICAgICAgICAgICAgW3NlY29uZHNTdGVwXT1cInNlY29uZHNzdGVwXCJcbiAgICAgICAgICAgICAgICBbbW91c2V3aGVlbF09XCJ0cnVlXCJcbiAgICAgICAgICAgICAgICBbYXJyb3drZXlzXT1cInRydWVcIlxuICAgICAgICAgICAgICAgIChpc1ZhbGlkKT1cImlzVmFsaWQoJGV2ZW50KVwiXG4gICAgICAgICAgICAgICAgW3Nob3dTZWNvbmRzXT1cInNob3dzZWNvbmRzXCJcbiAgICAgICAgICAgICAgICAobmdNb2RlbENoYW5nZSk9XCJvbk1vZGVsVXBkYXRlKCRldmVudCwgJ3RpbWUnKVwiPjwvdGltZXBpY2tlcj5cbiAgICAgICAgPC9kaXY+XG4gICAgPC9kaXY+XG48bmctdGVt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1vZGVsVXBkYXRlKGN1cnJlbnRUaW1lKTtcbiAgICAgICAgfSwgMTAwMCk7XG4gICAgfVxuXG4gICAgLyoqXG4gICAgICogVGhpcyBpcyBhbiBpbnRlcm5hbCBtZXRob2QgdXNlZCB0byBjbGVhciB0aGUgdGltZSBpbnRlcnZhbCBjcmVhdGVkXG4gICAgICovXG4gICAgcHJpdmF0ZSBjbGVhclRpbWVJbnRlcnZhbCgpIHtcbiAgICAgICAgaWYgKHRoaXMudGltZWludGVydmFsKSB7XG4gICAgICAgICAgICBjbGVhckludGVydmFsKHRoaXMudGltZWludGVydmFsKTtcbiAgICAgICAgICAgIHRoaXMudGltZWludGVydmFsID0gbnVsbDtcbiAgICAgICAgfVxuICAgIH1cblxuICAgIC8qKlxuICAgICAqIFRoaXMgaXMgYW4gaW50ZXJuYWwgbWV0aG9kIHRvIHRvZ2dsZSB0aGUgdGltZSBwaWNrZXJcbiAgICAgKi9cbiAgICBwdWJsaWMgdG9nZ2xlVGltZVBpY2tlcihuZXdWYWwsICRldmVudD86IGFueSkge1xuICAgICAgICBpZiAodGhpcy5sb2FkTmF0aXZlRGF0ZUlucHV0KSB7XG4gICAgICAgICAgICB0aGlzLm9uRGF0ZVRpbWVJbnB1dEZvY3VzKCk7XG4gICAgICAgICAgICByZXR1cm47XG4gICAgICAgIH1cbiAgICAgICAgdGhpcy5pc1RpbWVPcGVuID0gbmV3VmFsO1xuICAgICAgICBpZiAoJGV2ZW50ICYmICRldmVudC50eXBlID09PSAnY2xpY2snKSB7XG4gICAgICAgICAgICB0aGlzLmludm9rZUV2ZW50Q2FsbGJhY2soJ2NsaWNrJywgeyAkZXZlbnQ6ICRldmVudCB9KTtcbiAgICAgICAgfVxuICAgICAgICB0aGlzLmFkZFRpbWVwaWNrZXJDbGlja0xpc3RlbmVyKHRoaXMuaXNUaW1lT3Blbik7XG4gICAgfVxuXG4gICAgcHJpdmF0ZSBhZGRUaW1lcGlja2VyQ2xpY2tMaXN0ZW5lcihza2lwTG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ZVRpbWVGb3JtYXQgPSB0cnVlO1xuICAgICAgICAgICAgICAgICAgICB0aGlzLmludm9rZU9uQ2hhbmdlKHRoaXMuZGF0YXZhbHVlLCBldmVudCwgZmFsc2UpO1xuICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgIHRoaXMuaW52YWxpZERhdGVUaW1lRm9ybWF0ID0gZmFsc2U7XG4gICAgICAgICAgICAgICAgICAgIHRoaXMuaXNFbnRlclByZXNzZWRPbkRhdGVJbnB1dCA9IHRydWU7XG4gICAgICAgICAgICAgICAgICAgIHRoaXMuYnNEYXRlUGlja2VyRGlyZWN0aXZlLmJzVmFsdWUgPSBuZXdWYWw7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIHRoaXMudG9nZ2xlRHBEcm9wZG93bihldmVudCk7XG4gICAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgICAgIHRoaXMuaGlkZURhdGVwaWNrZXJEcm9wZG93bigpO1xuICAgICAgICAgICAgICAgIHRoaXMuaGlkZVRpbWVwaWNrZXJEcm9wZG93bigpO1xuICAgICAgICAgICAgfVxuICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgdGhpcy5oaWRlRGF0ZXBpY2tlckRyb3Bkb3duKCk7XG4gICAgICAgICAgICB0aGlzLmhpZGVUaW1lcGlja2VyRHJvcGRvd24oKTtcbiAgICAgICAgfVxuICAgIH1cblxuICAgIHByaXZhdGUgaXNWYWxpZChldmVudCkge1xuICAgICAgICBpZiAoIWV2ZW50KSB7XG4gICAgICAgICAgICBjb25zdCBlbnRlcmVkRGF0ZSA9ICQodGhpcy5uYXRpdmVFbGVtZW50KS5maW5kKCdpbnB1dCcpLnZhbCgpO1xuICAgICAgICAgICAgY29uc3QgbmV3VmFsID0gZ2V0TmF0aXZlRGF0ZU9iamVjdChlbnRlcmVkRGF0ZSwge3BhdHRlcm46IHRoaXMubG9hZE5hdGl2ZURhdGVJbnB1dCA/IHRo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4gICAgICAgIGF1dG9DbG9zZT1cImZhbHNlXCJcbiAgICAgICAgW2NvbnRhaW5lcl09XCInYm9keSdcIlxuICAgICAgICAob25TaG93bik9XCJvblRpbWVwaWNrZXJPcGVuKClcIlxuICAgICAgICBzdHlsZT1cImRpc3BsYXk6IGluaGVyaXQ7XCI+XG4gICAgICAgIDxpbnB1dCBjbGFzcz1cImZvcm0tY29udHJvbCBhcHAtdGV4dGJveCBkaXNwbGF5LWlucHV0XCJcbiAgICAgICAgICAgIFthdHRyLmFyaWEtbGFiZWxdPVwiaGludFwiXG4gICAgICAgICAgICBmb2N1cy10YXJnZXRcbiAgICAgICAgICAgIFtuYW1lXT1cIm5hbWVcIlxuICAgICAgICAgICAgW3RhYmluZGV4XT1cImxvYWROYXRpdmVEYXRlSW5wdXQgPyAnLTEnIDogdGFiaW5kZXhcIlxuICAgICAgICAgICAgW2F0dHIuYXJpYS1oaWRkZW5dPVwiISFsb2FkTmF0aXZlRGF0ZUlucHV0XCJcbiAgICAgICAgICAgIHR5cGU9XCJ0ZXh0XCJcbiAgICAgICAgICAgIFt2YWx1ZV09XCJkaXNwbGF5VmFsdWVcIlxuICAgICAgICAgICAgKGNsaWNrKT1cInRvZ2dsZURwRHJvcGRvd24oJGV2ZW50LCB0cnVlKVwiXG4gICAgICAgICAgICAoZm9jdXMpPVwib25EYXRlVGltZUlucHV0Rm9jdXMoKTsgaW52b2tlT25Gb2N1cygkZXZlbnQpO1wiXG4gICAgICAgICAgICAoYmx1cik9XCJvbklucHV0Qmx1cigkZXZlbnQpXCJcbiAgICAgICAgICAgIChjaGFuZ2UpPVwib25EYXRlQ2hhbmdlKCRldmVudClcIlxuICAgICAgICAgICAgW2F1dG9mb2N1c109XCJhdXRvZm9jdXNcIlxuICAgICAgICAgICAgW2Rpc2FibGVkXT1cImRpc2FibGVkIHx8IHJlYWRvbmx5IHx8IGlzQ3VycmVudERhdGVcIlxuICAgICAgICAgICAgW3JlcXVpcmVkXT1cInJlcXVpcmVkX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lkZGVuPVwidHJ1ZVwiXG4gICAgICAgICAgICAgICAgICAgIGNsYXNzPVwiYXBwLWljb24gd20tc2wtbCBzbC1jYWxlbmRhclwiPjwvaT5cbiAgICAgICAgICAgIDwvYnV0dG9uPlxuICAgICAgICAgICAgPGJ1dHRvbiB0eXBlPVwiYnV0dG9uXCJcbiAgICAgICAgICAgICAgICBjbGFzcz1cImJ0biBidG4tZGVmYXVsdCBidG4tdGltZVwiXG4gICAgICAgICAgICAgICAgW3RhYmluZGV4XT1cImxvYWROYXRpdmVEYXRlSW5wdXQgPyAnLTEnIDogdGFiaW5kZXhcIlxuICAgICAgICAgICAgICAgIFthdHRyLmFyaWEtaGlkZGVuXT1cIiEhbG9hZE5hdGl2ZURhdGVJbnB1dFwiXG4gICAgICAgICAgICAgICAgW2Rpc2FibGVkXT1cImRpc2FibGVkIHx8IHJlYWRvbmx5IHx8IGlzQ3VycmVudERhdGVcIlxuICAgICAgICAgICAgICAgIGFyaWEtbGFiZWw9XCJTZWxlY3QgdGltZVwiXG4gICAgICAgICAgICAgICAgYXJpYS1oYXNwb3B1cD1cInRydWVcIlxuICAgICAgICAgICAgICAgIGFyaWEtZXhwYW5kZWQ9XCJmYWxzZVwiXG4gICAgICAgICAgICAgICAgKGNsaWNrKT1cInRvZ2dsZVRpbWVQaWNrZXIoIWlzVGltZU9wZW4sICRldmVudClcIj5cbiAgICAgICAgICAgICAgICA8aSBhcmlhLWhpZGRlbj1cInRydWVcIlxuICAgICAgICAgICAgICAgICAgICBjbGFzcz1cImFwcC1pY29uIHdtLXNsLWwgc2wtdGltZVwiPjwvaT5cbiAgICAgICAgICAgIDwvYnV0dG9uPlxuICAgICAgICA8L3NwYW4+XG4gICAgICAgIDxkaXYgc3R5bGU9XCJ3aWR0aDogMDtkaXNwbGF5OiBpbmxpbmUtYmxvY2s7XCI+XG4gICAgICAgIDxpbnB1dCBjbGFzcz1cIm1vZGVsLWhvbGRlclwiXG4gICAgICAgICAgICBhcmlhLWxhYmVsP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gICAgICAgICAgICBjbGFzcz1cImRyb3Bkb3duLW1lbnVcIlxuICAgICAgICAgICAgYXJpYS1sYWJlbD1cInRpbWVwaWNrZXIgZHJvcGRvd25cIlxuICAgICAgICAgICAgYXJpYS1jb250cm9scz1cInRpbWVcIlxuICAgICAgICAgICAgKGNsaWNrKT1cInByZXZlbnRUcENsb3NlKCRldmVudClcIj5cbiAgICAgICAgICAgIDx0aW1lcGlja2VyIGNsYXNzPVwibW9kZWwtaG9sZGVyXCJcbiAgICAgICAgICAgICAgICBbc2hvd01lcmlkaWFuXT1cImlzbWVyaWRpYW5cIlxuICAgICAgICAgICAgICAgIFtyZWFkb25seUlucHV0XT1cImRpc2FibGVkIHx8IHJlYWRvbmx5IHx8IGlzQ3VycmVudERhdGVcIlxuICAgICAgICAgICAgICAgIFsobmdNb2RlbCldPVwiYnNUaW1lVmFsdWVcIlxuICAgICAgICAgICAgICAgICAgICAgICAgW25nTW9kZWxPcHRpb25zXT1cIntzdGFuZGFsb25lOiB0cnVlfVwiXG4gICAgICAgICAgICAgICAgW21pbl09XCJtaW5UaW1lXCJcbiAgICAgICAgICAgICAgICBbbWF4XT1cIm1heFRpbWVcIlxuICAgICAgICAgICAgICAgIFtob3VyU3RlcF09XCJob3Vyc3RlcFwiXG4gICAgICAgICAgICAgICAgW21pbnV0ZVN0ZXBdPVwibWludXRlc3RlcFwiXG4gICAgICAgICAgICAgICAgW3NlY29uZHNTdGVwXT1cInNlY29uZHNzdGVwXCJcbiAgICAgICAgICAgICAgICBbbW91c2V3aGVlbF09XCJ0cnVlXCJcbiAgICAgICAgICAgICAgICBbYXJyb3drZXlzXT1cInRydWVcIlxuICAgICAgICAgICAgICAgIChpc1ZhbGlkKT1cImlzVmFsaWQoJGV2ZW50KVwiXG4gICAgICAgICAgICAgICAgW3Nob3dTZWNvbmRzXT1cInNob3dzZWNvbmRzXCJcbiAgICAgICAgICAgICAgICAobmdNb2RlbENoYW5nZSk9XCJvbk1vZGVsVXBkYXRlKCRld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RydWUpOyBpbnZva2VPbkZvY3VzKCRldmVudClcIlxuICAgICAgICAoYmx1cik9XCJvbkRhdGVUaW1lSW5wdXRCbHVyKCk7IGludm9rZU9uVG91Y2hlZCgkZXZlbnQpXCJcbiAgICAgICAgIHJvbGU9XCJidXR0b25cIj5cbiAgICA8L2Rpdj5cbjwvbmctdGVtcGxhdGU+XG4iXX0=
@@ -2388,6 +2388,9 @@ class DatetimeComponent extends BaseDateTimeComponent {
2388
2388
  $(this.nativeElement).find('.display-input').val(this.displayValue);
2389
2389
  }
2390
2390
  }
2391
+ if (newVal && !this.bsDateValue && this.timeZone) {
2392
+ newVal = getMomentLocaleObject(this.timeZone, newVal);
2393
+ }
2391
2394
  // min date and max date validation in web.
2392
2395
  // if invalid dates are entered, device is showing validation message.
2393
2396
  this.minDateMaxDateValidationOnInput(newVal);