@wavemaker/app-ng-runtime 11.14.1-1.6289 → 11.14.1-6.6324

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.
@@ -1,5 +1,5 @@
1
1
  import * as i1 from '@wm/core';
2
- import { FormWidgetType, checkIsCustomPipeExpression, $parseExpr, isValidWebURL, _WM_APP_PROJECT, encodeUrl, stringStartsWith, prettifyLabel, deHyphenate, initCaps, getClonedObject, DataSource, debounce, processFilterExpBindNode, isDefined, MatchMode, $parseEvent, isEqualWithFields, getFormattedDate, isAndroid, isNumberType, DataType, setCSS, IDGenerator, toBoolean, isChangeFromWatch, $unwatch, resetChangeFromWatch, isObject as isObject$1, toDimension, $appDigest, removeClass, addClass, setCSSFromObj, App, findParent, setAttr, switchClass, removeAttr, $invokeWatchers, $watch, findValueOf, validateAccessRoles, ComponentType, noop as noop$1, VALIDATOR, isIos, isMobile, hasOffsetStr, AbstractI18nService, CURRENCY_INFO, replace as replace$1, transformFileURI, isLargeTabletLandscape, isLargeTabletPortrait } from '@wm/core';
2
+ import { FormWidgetType, checkIsCustomPipeExpression, $parseExpr, isValidWebURL, _WM_APP_PROJECT, isValidImageUrl, encodeUrl, stringStartsWith, prettifyLabel, deHyphenate, initCaps, getClonedObject, DataSource, debounce, processFilterExpBindNode, isDefined, MatchMode, $parseEvent, isEqualWithFields, getFormattedDate, isAndroid, isNumberType, DataType, setCSS, IDGenerator, toBoolean, isChangeFromWatch, $unwatch, resetChangeFromWatch, isObject as isObject$1, toDimension, $appDigest, removeClass, addClass, setCSSFromObj, App, findParent, setAttr, switchClass, removeAttr, $invokeWatchers, $watch, findValueOf, validateAccessRoles, ComponentType, noop as noop$1, VALIDATOR, isIos, isMobile, hasOffsetStr, AbstractI18nService, CURRENCY_INFO, replace as replace$1, transformFileURI, isLargeTabletLandscape, isLargeTabletPortrait } from '@wm/core';
3
3
  import * as i0 from '@angular/core';
4
4
  import { InjectionToken, forwardRef, ElementRef, inject, ViewContainerRef, Injector, Injectable, Inject, Optional, Directive, Self, ContentChildren, Attribute, Input, Component, Pipe, SecurityContext } from '@angular/core';
5
5
  import { createFocusTrap } from '@wavemaker/focus-trap';
@@ -190,7 +190,7 @@ const getImageUrl = (urlString, shouldEncode, defaultUrl) => {
190
190
  urlString = (defaultUrl || 'resources/images/imagelists/default-image.png');
191
191
  }
192
192
  }
193
- if (urlString && !_WM_APP_PROJECT.isPreview && !isValidWebURL(urlString) && !urlString.startsWith(_WM_APP_PROJECT.cdnUrl)) {
193
+ if (urlString && !_WM_APP_PROJECT.isPreview && !isValidImageUrl(urlString) && !urlString.startsWith(_WM_APP_PROJECT.cdnUrl) && !urlString.startsWith('services')) {
194
194
  urlString = (_WM_APP_PROJECT.cdnUrl || '') + urlString;
195
195
  }
196
196
  urlString = shouldEncode ? encodeUrl(urlString) : urlString;
@@ -4315,14 +4315,14 @@ class ToDatePipe extends WmPipe {
4315
4315
  }
4316
4316
  return this.returnFn('', arguments, this.app.Variables);
4317
4317
  }
4318
- constructor(datePipe, i18nService, customPipeManager) {
4318
+ constructor(datePipe, i18nService, app, customPipeManager) {
4319
4319
  super('toDate', customPipeManager);
4320
4320
  this.datePipe = datePipe;
4321
4321
  this.i18nService = i18nService;
4322
+ this.app = app;
4322
4323
  this.customPipeManager = customPipeManager;
4323
- this.app = inject(App);
4324
4324
  }
4325
- static { this.ɵfac = function ToDatePipe_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || ToDatePipe)(i0.ɵɵdirectiveInject(i1$1.DatePipe, 16), i0.ɵɵdirectiveInject(i1.AbstractI18nService, 16), i0.ɵɵdirectiveInject(i1.CustomPipeManager, 16)); }; }
4325
+ static { this.ɵfac = function ToDatePipe_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || ToDatePipe)(i0.ɵɵdirectiveInject(i1$1.DatePipe, 16), i0.ɵɵdirectiveInject(i1.AbstractI18nService, 16), i0.ɵɵdirectiveInject(i1.App, 16), i0.ɵɵdirectiveInject(i1.CustomPipeManager, 16)); }; }
4326
4326
  static { this.ɵpipe = /*@__PURE__*/ i0.ɵɵdefinePipe({ name: "toDate", type: ToDatePipe, pure: true, standalone: true }); }
4327
4327
  }
4328
4328
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ToDatePipe, [{
@@ -4331,7 +4331,7 @@ class ToDatePipe extends WmPipe {
4331
4331
  standalone: true,
4332
4332
  name: 'toDate'
4333
4333
  }]
4334
- }], () => [{ type: i1$1.DatePipe }, { type: i1.AbstractI18nService }, { type: i1.CustomPipeManager }], null); })();
4334
+ }], () => [{ type: i1$1.DatePipe }, { type: i1.AbstractI18nService }, { type: i1.App }, { type: i1.CustomPipeManager }], null); })();
4335
4335
  class ToNumberPipe {
4336
4336
  transform(data, fracSize) {
4337
4337
  if (fracSize && !String(fracSize).match(/^(\d+)?\.((\d+)(-(\d+))?)?$/)) {
@@ -4419,9 +4419,9 @@ class SuffixPipe {
4419
4419
  * Custom pipe: It is work as interceptor between the user custom pipe function and angular pipe
4420
4420
  */
4421
4421
  class CustomPipe {
4422
- constructor(custmeUserPipe) {
4422
+ constructor(app, custmeUserPipe) {
4423
+ this.app = app;
4423
4424
  this.custmeUserPipe = custmeUserPipe;
4424
- this.app = inject(App);
4425
4425
  }
4426
4426
  transform(data, pipename) {
4427
4427
  let argumentArr = [];
@@ -4441,7 +4441,7 @@ class CustomPipe {
4441
4441
  return data;
4442
4442
  }
4443
4443
  }
4444
- static { this.ɵfac = function CustomPipe_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || CustomPipe)(i0.ɵɵdirectiveInject(i1.CustomPipeManager, 16)); }; }
4444
+ static { this.ɵfac = function CustomPipe_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || CustomPipe)(i0.ɵɵdirectiveInject(i1.App, 16), i0.ɵɵdirectiveInject(i1.CustomPipeManager, 16)); }; }
4445
4445
  static { this.ɵpipe = /*@__PURE__*/ i0.ɵɵdefinePipe({ name: "custom", type: CustomPipe, pure: true, standalone: true }); }
4446
4446
  }
4447
4447
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(CustomPipe, [{
@@ -4450,7 +4450,7 @@ class CustomPipe {
4450
4450
  standalone: true,
4451
4451
  name: 'custom'
4452
4452
  }]
4453
- }], () => [{ type: i1.CustomPipeManager }], null); })();
4453
+ }], () => [{ type: i1.App }, { type: i1.CustomPipeManager }], null); })();
4454
4454
  class TimeFromNowPipe {
4455
4455
  transform(data) {
4456
4456
  let timestamp;
@@ -5024,7 +5024,9 @@ class LazyLoadDirective {
5024
5024
  });
5025
5025
  }
5026
5026
  ngOnDestroy() {
5027
- this.unSubscribeFn();
5027
+ if (this.unSubscribeFn && typeof this.unSubscribeFn === 'function') {
5028
+ this.unSubscribeFn();
5029
+ }
5028
5030
  }
5029
5031
  static { this.ɵfac = function LazyLoadDirective_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || LazyLoadDirective)(i0.ɵɵdirectiveInject(i0.Injector), i0.ɵɵdirectiveInject(i0.TemplateRef), i0.ɵɵdirectiveInject(i0.ViewContainerRef), i0.ɵɵdirectiveInject('EXPLICIT_CONTEXT', 8)); }; }
5030
5032
  static { this.ɵdir = /*@__PURE__*/ i0.ɵɵdefineDirective({ type: LazyLoadDirective, selectors: [["", "lazyLoad", ""]], inputs: { lazyLoad: "lazyLoad" }, standalone: true }); }