@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
@@ -10,13 +10,12 @@ import * as i2 from '@wm/security';
10
10
  import { SecurityModule } from '@wm/security';
11
11
  import * as i4 from '@wm/variables';
12
12
  import { CONSTANTS, routerService, $rootScope, VariablesService, appManager, httpService, VariablesModule } from '@wm/variables';
13
- import { trim, isEmpty, forEach, extend, get, merge, isUndefined, isObject, endsWith, each, isNil, capitalize, startsWith, split, includes, isString, isNumber, find, intersection, toLower, map, values, keys, findKey, isEqual, filter } from 'lodash-es';
13
+ import { trim, isEmpty, forEach, extend, get, merge, isUndefined, isObject, endsWith, each, isNil, startsWith, split, includes, isString, isNumber, find, intersection, toLower, map, values, keys, findKey, isEqual, filter } from 'lodash-es';
14
14
  import { SpaPageDirective, PageDirective, LayoutDirective, PageModule } from '@wm/components/page';
15
15
  import { Subject } from 'rxjs';
16
16
  import * as i3 from '@wm/components/base';
17
17
  import { WidgetRef, PartialDirective, FileIconClassPipe, FileExtensionFromMimePipe, StateClassPipe, FileSizePipe, FilterPipe, ToDatePipe, ToNumberPipe, ToCurrencyPipe, PrefixPipe, SuffixPipe, TimeFromNowPipe, NumberToStringPipe, StringToNumberPipe, CustomPipe, TrustAsPipe, SanitizePipe, WmComponentsModule } from '@wm/components/base';
18
18
  import { __param, __metadata, __decorate } from 'tslib';
19
- import { RadiosetComponent, CheckboxsetComponent, InputModule } from '@wm/components/input';
20
19
  import * as i2$3 from '@wm/components/prefab';
21
20
  import { PrefabContainerDirective, PrefabDirective as PrefabDirective$1, PrefabModule } from '@wm/components/prefab';
22
21
  import * as i1$5 from '@angular/common/http';
@@ -61,6 +60,7 @@ import { ColorPickerModule } from '@wm/components/input/color-picker';
61
60
  import { CurrencyModule } from '@wm/components/input/currency';
62
61
  import { EpochModule } from '@wm/components/input/epoch';
63
62
  import { FileUploadModule } from '@wm/components/input/file-upload';
63
+ import { InputModule } from '@wm/components/input';
64
64
  import { RatingModule } from '@wm/components/input/rating';
65
65
  import { SliderModule } from '@wm/components/input/slider';
66
66
  import { CardModule } from '@wm/components/data/card';
@@ -87,7 +87,6 @@ import { PopoverModule as PopoverModule$1 } from '@wm/components/navigation/popo
87
87
  import { CarouselModule as CarouselModule$1 } from '@wm/components/advanced/carousel';
88
88
  import { LoginModule } from '@wm/components/advanced/login';
89
89
  import { MarqueeModule } from '@wm/components/advanced/marquee';
90
- import { CustomModule } from '@wm/components/advanced/custom';
91
90
  import { TimepickerModule } from 'ngx-bootstrap/timepicker';
92
91
  import { BsDropdownModule } from 'ngx-bootstrap/dropdown';
93
92
  import { PaginationModule } from 'ngx-bootstrap/pagination';
@@ -103,7 +102,6 @@ var ComponentType;
103
102
  ComponentType[ComponentType["PAGE"] = 0] = "PAGE";
104
103
  ComponentType[ComponentType["PREFAB"] = 1] = "PREFAB";
105
104
  ComponentType[ComponentType["PARTIAL"] = 2] = "PARTIAL";
106
- ComponentType[ComponentType["WIDGET"] = 3] = "WIDGET";
107
105
  })(ComponentType || (ComponentType = {}));
108
106
  class ComponentRefProvider {
109
107
  clearComponentFactoryRefCache() { }
@@ -1443,283 +1441,6 @@ class BasePageComponent extends FragmentMonitor {
1443
1441
  args: ['window:beforeunload']
1444
1442
  }] }); })();
1445
1443
 
1446
- // export const commonPartialWidgets = {};
1447
- class BaseCustomWidgetComponent extends FragmentMonitor {
1448
- constructor() {
1449
- super(...arguments);
1450
- this.BaseWidget = {};
1451
- this.compileContent = false;
1452
- this.destroy$ = new Subject();
1453
- this.viewInit$ = new Subject();
1454
- this.invokeEvent = (eventName) => {
1455
- this.events[eventName]();
1456
- };
1457
- }
1458
- getContainerWidgetInjector() {
1459
- return this.containerWidget.inj || this.containerWidget.injector;
1460
- }
1461
- init() {
1462
- let resolveFn;
1463
- const promise = new Promise((res) => resolveFn = res);
1464
- this.App = this.injector ? this.injector.get(App) : inject(App);
1465
- //making the code compatible in both the JIT and AOT modes
1466
- this.containerWidget = this.injector ? this.injector.get(WidgetRef) : inject(WidgetRef);
1467
- this.i18nService = this.injector ? this.injector.get(AbstractI18nService) : inject(AbstractI18nService);
1468
- this.scriptLoaderService = this.injector ? this.injector.get(ScriptLoaderService) : inject(ScriptLoaderService);
1469
- this.Viewport = this.injector ? this.injector.get(Viewport) : inject(Viewport);
1470
- // this.viewContainerRef = this.getContainerWidgetInjector().get(ViewContainerRef);
1471
- // Replacing this.getContainerWidgetInjector().view.component as viewParent
1472
- // this.viewParent = (this.viewContainerRef as any).parentInjector._lView[8];
1473
- this.viewParent = this.containerWidget.viewParent;
1474
- if (this.viewParent.registerFragment) {
1475
- this.viewParent.registerFragment();
1476
- }
1477
- // register functions for binding evaluation
1478
- this.registerExpressions();
1479
- this.initUserScript();
1480
- this.registerPropsInContainerWidget(resolveFn);
1481
- // Using promise to make sure the props are registered in the container widget before registering events, Otherwise no events will be registered
1482
- promise.then(() => this.registerEvents());
1483
- this.registerWidgets();
1484
- this.initVariables();
1485
- this.activePageName = this.App.activePageName; // Todo: remove this
1486
- this.registerProps();
1487
- this.defineI18nProps();
1488
- this.viewInit$.subscribe(noop$1, noop$1, () => {
1489
- this.props = this.containerWidget.props;
1490
- });
1491
- if (this.spa) {
1492
- this.pageDirective = this.injector ? this.injector.get(SpaPageDirective) : inject(SpaPageDirective);
1493
- }
1494
- else {
1495
- this.pageDirective = this.injector ? this.injector.get(PageDirective) : inject(PageDirective);
1496
- }
1497
- if (this.pageDirective) {
1498
- this.registerDestroyListener(this.pageDirective.subscribe('attach', data => this.ngOnAttach(data.refreshData)));
1499
- this.registerDestroyListener(this.pageDirective.subscribe('detach', () => this.ngOnDetach()));
1500
- }
1501
- super.init();
1502
- }
1503
- registerWidgets() {
1504
- // common partial widgets should be accessible from page
1505
- this.Widgets = Object.create(commonPartialWidgets);
1506
- // expose current page widgets on app
1507
- this.App.Widgets = Object.create(this.Widgets);
1508
- }
1509
- initializeComponentData(children) {
1510
- Array.from(children).forEach((child) => {
1511
- if (!child.hasAttribute('wmcustomwidget'))
1512
- this.initializeComponentData(child.children);
1513
- else {
1514
- let baseWidget, splitArr = child.getAttribute('as').split('-'), modifiedArr = [];
1515
- modifiedArr = splitArr.map((item) => {
1516
- item = item !== 'wm' ? capitalize(item) : item;
1517
- return item;
1518
- });
1519
- baseWidget = modifiedArr.join('');
1520
- switch (baseWidget) {
1521
- case 'wmCheckboxset':
1522
- this[baseWidget] = new CheckboxsetComponent(this.injector, undefined);
1523
- this[baseWidget]["_select"] = (item, $event) => {
1524
- const keys = [];
1525
- forEach(this[baseWidget].datasetItems, (datasetItem) => {
1526
- if (datasetItem.key === item.key)
1527
- datasetItem.selected = !datasetItem.selected;
1528
- if (datasetItem.selected)
1529
- keys.push(datasetItem.key);
1530
- });
1531
- this[baseWidget].triggerInvokeOnChange(keys, $event);
1532
- };
1533
- break;
1534
- case 'wmRadioset':
1535
- this[baseWidget] = new RadiosetComponent(this.injector, undefined);
1536
- this[baseWidget]["_select"] = (item, $event) => {
1537
- this[baseWidget].triggerInvokeOnChange(item.key, $event);
1538
- };
1539
- break;
1540
- }
1541
- for (let [key, value] of this.containerWidget.$attrs) {
1542
- if (key.startsWith('base-')) {
1543
- let modifiedKey = key.replace('base-', '');
1544
- this[baseWidget][modifiedKey] = value;
1545
- }
1546
- }
1547
- this[baseWidget].initDatasetItems();
1548
- this.containerWidget[baseWidget] = this[baseWidget];
1549
- }
1550
- });
1551
- }
1552
- registerBaseWidget() {
1553
- this.initializeComponentData(this.containerWidget.nativeElement.children);
1554
- }
1555
- registerEvents() {
1556
- this.events = {};
1557
- this.containerWidget.eventHandlers.forEach((callback, key) => {
1558
- this.events[key] = (...args) => {
1559
- this.containerWidget.invokeEventCallback(key, { $event: args[0], $data: args[1] });
1560
- };
1561
- });
1562
- }
1563
- registerDestroyListener(fn) {
1564
- this.destroy$.subscribe(noop$1, noop$1, () => fn());
1565
- }
1566
- registerChangeListeners() {
1567
- this.containerWidget.registerPropertyChangeListener(this.onPropertyChange);
1568
- this.containerWidget.registerStyleChangeListener(this.onPropertyChange);
1569
- }
1570
- initUserScript() {
1571
- try {
1572
- // partials inside prefab should have access to Prefab properties and events
1573
- if (this.viewParent.prefabName) {
1574
- // for partial within partial within prefabs, just assign the parent partial's prefab object
1575
- if (this.viewParent.Prefab) {
1576
- this.Prefab = this.viewParent.Prefab;
1577
- }
1578
- else {
1579
- this.Prefab = this.viewParent;
1580
- }
1581
- }
1582
- this.evalUserScript(this, this.App, this.injector ? this.injector.get(UtilsService) : inject(UtilsService));
1583
- }
1584
- catch (e) {
1585
- console.error(`Error in evaluating partial (${this.customWidgetName}) script\n`, e);
1586
- }
1587
- }
1588
- initVariables() {
1589
- const variablesService = this.injector ? this.injector.get(VariablesService) : inject(VariablesService);
1590
- // get variables and actions instances for the page
1591
- const variableCollection = variablesService.register(this.customWidgetName, this.getVariables(), this);
1592
- // create namespace for Variables nad Actions on page/partial, which inherits the Variables and Actions from App instance
1593
- this.Variables = Object.create(this.App.Variables);
1594
- this.Actions = Object.create(this.App.Actions);
1595
- this.containerWidget.Variables = this.Variables;
1596
- this.containerWidget.Actions = this.Actions;
1597
- // assign all the page variables to the pageInstance
1598
- Object.entries(variableCollection.Variables).forEach(([name, variable]) => this.Variables[name] = variable);
1599
- Object.entries(variableCollection.Actions).forEach(([name, action]) => this.Actions[name] = action);
1600
- this.viewInit$.subscribe(noop$1, noop$1, () => {
1601
- // TEMP: triggering watchers so variables watching over params are updated
1602
- $invokeWatchers(true, true);
1603
- variableCollection.callback(variableCollection.Variables).catch(noop$1);
1604
- variableCollection.callback(variableCollection.Actions);
1605
- });
1606
- }
1607
- /**
1608
- * function to register bind expressions generated in this partial instance
1609
- * getExpressions function is defined in the generated page.comp.ts file
1610
- * @param expressions, map of bind expression vs generated function
1611
- */
1612
- registerExpressions() {
1613
- const expressions = this.getExpressions();
1614
- _.each(expressions, (fn, expr) => {
1615
- registerFnByExpr(expr, fn[0], fn[1]);
1616
- });
1617
- }
1618
- registerProps() {
1619
- this.props = this.containerWidget.props;
1620
- }
1621
- defineI18nProps() {
1622
- this.appLocale = this.i18nService.getAppLocale();
1623
- }
1624
- invokeOnReady() {
1625
- let params;
1626
- if (this.containerWidget.userComponentParams) {
1627
- params = this.containerWidget.userComponentParams;
1628
- }
1629
- this.onReady(params);
1630
- if (this.viewParent.resolveFragment) {
1631
- this.viewParent.resolveFragment();
1632
- }
1633
- }
1634
- loadScripts() {
1635
- // return new Promise<void>((resolve) => {
1636
- // const scriptsRequired = this.partialDirective.$element.attr('scripts-to-load');
1637
- // if (scriptsRequired) {
1638
- // this.scriptLoaderService
1639
- // .load(...scriptsRequired.split(','))
1640
- // .then(resolve);
1641
- // } else {
1642
- // resolve();
1643
- // }
1644
- // });
1645
- }
1646
- registerPropsInContainerWidget(resolveFn) {
1647
- window['resourceCache'].get(`./custom-widgets/${this.customWidgetName}/page.min.json`).then(({ config }) => {
1648
- if (config) {
1649
- Object.entries((config.properties || {})).forEach(([key, prop]) => {
1650
- let expr;
1651
- const value = _.trim(prop.value);
1652
- if (_.startsWith(value, 'bind:')) {
1653
- expr = value.replace('bind:', '');
1654
- }
1655
- Object.defineProperty(this, key, {
1656
- get: () => this.containerWidget[key],
1657
- set: nv => this.containerWidget.widget[key] = nv
1658
- });
1659
- if (expr) {
1660
- //[Todo-CSP]: expr will be generated with prefab.comp.expr.ts
1661
- this.registerDestroyListener($watch(expr, this, {}, nv => this.containerWidget.widget[key] = nv));
1662
- }
1663
- });
1664
- }
1665
- this.containerWidget.setProps(config, resolveFn);
1666
- // Reassigning the proxy handler for prefab inbound properties as we
1667
- // will get them only after the prefab config call.
1668
- if (isIE()) {
1669
- this.containerWidget.widget = this.containerWidget.createProxy();
1670
- }
1671
- });
1672
- }
1673
- mute() {
1674
- const m = o => { o && o.mute && o.mute(); };
1675
- _.each(this.Widgets, m);
1676
- _.each(this.Variables, m);
1677
- _.each(this.Actions, m);
1678
- }
1679
- unmute() {
1680
- const um = o => { o && o.unmute && o.unmute(); };
1681
- _.each(this.Widgets, um);
1682
- _.each(this.Variables, um);
1683
- _.each(this.Actions, um);
1684
- }
1685
- // ngOnInit() {
1686
- // this.init();
1687
- // }
1688
- ngAfterViewInit() {
1689
- this.registerChangeListeners();
1690
- this.registerBaseWidget();
1691
- setTimeout(() => {
1692
- this.viewInit$.complete();
1693
- this.fragmentsLoaded$.subscribe(noop$1, noop$1, () => this.invokeOnReady());
1694
- }, 100);
1695
- }
1696
- ngOnDestroy() {
1697
- this.destroy$.complete();
1698
- }
1699
- ngOnAttach(refreshData) {
1700
- this.unmute();
1701
- if (refreshData) {
1702
- const refresh = v => { v && v.startUpdate && v.invoke && v.invoke(); };
1703
- _.each(this.Variables, refresh);
1704
- _.each(this.Actions, refresh);
1705
- }
1706
- _.each(this.Widgets, w => w && w.ngOnAttach && w.ngOnAttach());
1707
- }
1708
- ngOnDetach() {
1709
- this.mute();
1710
- _.each(this.Widgets, w => w && w.ngOnDetach && w.ngOnDetach());
1711
- }
1712
- // user overrides this
1713
- onPropertyChange() { }
1714
- onReady(params) {
1715
- }
1716
- static { this.ɵfac = /*@__PURE__*/ (() => { let ɵBaseCustomWidgetComponent_BaseFactory; return function BaseCustomWidgetComponent_Factory(t) { return (ɵBaseCustomWidgetComponent_BaseFactory || (ɵBaseCustomWidgetComponent_BaseFactory = i0.ɵɵgetInheritedFactory(BaseCustomWidgetComponent)))(t || BaseCustomWidgetComponent); }; })(); }
1717
- static { this.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: BaseCustomWidgetComponent, features: [i0.ɵɵInheritDefinitionFeature] }); }
1718
- }
1719
- (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(BaseCustomWidgetComponent, [{
1720
- type: Directive
1721
- }], null, null); })();
1722
-
1723
1444
  class BasePrefabComponent extends FragmentMonitor {
1724
1445
  constructor() {
1725
1446
  super(...arguments);
@@ -3190,7 +2911,7 @@ class I18nServiceImpl extends AbstractI18nService {
3190
2911
  return locale === moment.tz(timezoneName).format('Z');
3191
2912
  });
3192
2913
  }
3193
- this.formatsByLocale.timezone = locale;
2914
+ moment.tz.setDefault(locale);
3194
2915
  const localeData = compInstance && compInstance.formatsByLocale ? compInstance.formatsByLocale : this.formatsByLocale;
3195
2916
  Object.assign(localeData, localeObj);
3196
2917
  resolve();
@@ -5022,7 +4743,6 @@ const REQUIRED_MODULES_FOR_DYNAMIC_COMPONENTS = [
5022
4743
  CarouselModule$1,
5023
4744
  LoginModule,
5024
4745
  MarqueeModule,
5025
- CustomModule,
5026
4746
  PageModule,
5027
4747
  FooterModule,
5028
4748
  HeaderModule,
@@ -5217,7 +4937,6 @@ class RuntimeBaseModule {
5217
4937
  CarouselModule$1,
5218
4938
  LoginModule,
5219
4939
  MarqueeModule,
5220
- CustomModule,
5221
4940
  PageModule,
5222
4941
  FooterModule,
5223
4942
  HeaderModule,
@@ -5348,7 +5067,6 @@ class RuntimeBaseModule {
5348
5067
  CarouselModule$1,
5349
5068
  LoginModule,
5350
5069
  MarqueeModule,
5351
- CustomModule,
5352
5070
  PageModule,
5353
5071
  FooterModule,
5354
5072
  HeaderModule,
@@ -5433,7 +5151,6 @@ class RuntimeBaseModule {
5433
5151
  CarouselModule$1,
5434
5152
  LoginModule,
5435
5153
  MarqueeModule,
5436
- CustomModule,
5437
5154
  PageModule,
5438
5155
  FooterModule,
5439
5156
  HeaderModule,
@@ -5522,5 +5239,5 @@ class SecurityConfigResolve {
5522
5239
  * Generated bundle index. Do not edit.
5523
5240
  */
5524
5241
 
5525
- export { AccessrolesDirective, AppComponent, AppDefaultsService, AppExtensionJSResolve, AppExtensionProvider, AppJSProvider, AppJSResolve, AppManagerService, AppRef, AppSpinnerComponent, AppVariablesProvider, AppVariablesResolve, AuthGuard, BaseCustomWidgetComponent, BaseLayoutComponent, BasePageComponent, BasePartialComponent, BasePrefabComponent, BaseSpaPageComponent, CACHE_PAGE, CanDeactivateNgPageGuard, CanDeactivatePageGuard, ComponentRefProvider, ComponentType, CustomToasterComponent, DynamicComponentRefProviderService, EmptyPageComponent, FragmentMonitor, HttpCallInterceptor, I18nResolve, I18nServiceImpl, InitializeApp, MAX_CACHE_AGE, MAX_CACHE_SIZE, MetadataResolve, NavigationServiceImpl, PageNotFoundGuard, PipeProvider, PipeService, PrefabConfigProvider, PrefabDirective, PrefabManagerService, PrefabPreviewComponent, REQUIRED_MODULES_FOR_DYNAMIC_COMPONENTS, RoleGuard, RuntimeBaseModule, SecurityConfigResolve, SpinnerServiceImpl, ToasterServiceImpl, WM_MODULES_FOR_ROOT, WmDefaultRouteReuseStrategy, WmNgRouteReuseStrategy, WmRouteReuseStrategy, commonPartialWidgets, getPrefabBaseUrl, getPrefabConfigUrl, getPrefabMinJsonUrl, getPrefabPartialJsonUrl, isPrefabInPreview, setAngularLocale };
5242
+ export { AccessrolesDirective, AppComponent, AppDefaultsService, AppExtensionJSResolve, AppExtensionProvider, AppJSProvider, AppJSResolve, AppManagerService, AppRef, AppSpinnerComponent, AppVariablesProvider, AppVariablesResolve, AuthGuard, BaseLayoutComponent, BasePageComponent, BasePartialComponent, BasePrefabComponent, BaseSpaPageComponent, CACHE_PAGE, CanDeactivateNgPageGuard, CanDeactivatePageGuard, ComponentRefProvider, ComponentType, CustomToasterComponent, DynamicComponentRefProviderService, EmptyPageComponent, FragmentMonitor, HttpCallInterceptor, I18nResolve, I18nServiceImpl, InitializeApp, MAX_CACHE_AGE, MAX_CACHE_SIZE, MetadataResolve, NavigationServiceImpl, PageNotFoundGuard, PipeProvider, PipeService, PrefabConfigProvider, PrefabDirective, PrefabManagerService, PrefabPreviewComponent, REQUIRED_MODULES_FOR_DYNAMIC_COMPONENTS, RoleGuard, RuntimeBaseModule, SecurityConfigResolve, SpinnerServiceImpl, ToasterServiceImpl, WM_MODULES_FOR_ROOT, WmDefaultRouteReuseStrategy, WmNgRouteReuseStrategy, WmRouteReuseStrategy, commonPartialWidgets, getPrefabBaseUrl, getPrefabConfigUrl, getPrefabMinJsonUrl, getPrefabPartialJsonUrl, isPrefabInPreview, setAngularLocale };
5526
5243
  //# sourceMappingURL=index.mjs.map