@wavemaker/angular-app 11.14.1-16.6419 → 11.14.1-17.6422

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.
@@ -99707,11 +99707,11 @@ const getRowActionAttrs = attrs => {
99707
99707
  return tmpl;
99708
99708
  };
99709
99709
 
99710
- const $RAF = window.requestAnimationFrame;
99710
+ const $RAF$1 = window.requestAnimationFrame;
99711
99711
  const $RAFQueue = [];
99712
99712
  const invokeLater = fn => {
99713
99713
  if (!$RAFQueue.length) {
99714
- $RAF(() => {
99714
+ $RAF$1(() => {
99715
99715
  $RAFQueue.forEach(f => f());
99716
99716
  $RAFQueue.length = 0;
99717
99717
  });
@@ -100253,223 +100253,70 @@ const getFnForEventExpr = (expr) => {
100253
100253
  return fnExecutor(expr, ExpressionType.Action);
100254
100254
  };
100255
100255
 
100256
- // Constants
100257
- const WIDGET_ID_REGEX = /^(widget-[^_]+)/;
100258
- const WIDGET_PROPERTY_REGEX = /^widget-[^_]+_(.+)$/;
100259
- const ARRAY_INDEX_PLACEHOLDER = '[$i]';
100260
- const ARRAY_INDEX_ZERO = '[0]';
100261
100256
  const registry = new Map();
100262
100257
  const watchIdGenerator = new IDGenerator('watch-id-');
100263
- const FIRST_TIME_WATCH = Object.freeze({});
100264
- /**
100265
- * Extracts widget ID from identifier (e.g., "widget-id23_eventsource" -> "widget-id23")
100266
- */
100267
- const getWidgetId = (identifier) => {
100268
- if (!identifier || typeof identifier !== 'string') {
100269
- return null;
100270
- }
100271
- const match = identifier.match(WIDGET_ID_REGEX);
100272
- return match ? match[1] : null;
100273
- };
100274
- /**
100275
- * Extracts property name from identifier (e.g., "widget-id23_eventsource" -> "eventsource")
100276
- */
100277
- const getPropertyName = (identifier) => {
100278
- if (!identifier || typeof identifier !== 'string') {
100279
- return identifier;
100280
- }
100281
- const match = identifier.match(WIDGET_PROPERTY_REGEX);
100282
- return match ? match[1] : identifier;
100283
- };
100284
- /**
100285
- * Array consumer wrapper for array-based expressions
100286
- */
100258
+ const FIRST_TIME_WATCH = {};
100259
+ Object.freeze(FIRST_TIME_WATCH);
100287
100260
  const arrayConsumer = (listenerFn, restExpr, newVal, oldVal) => {
100288
- if (!isArray(newVal)) {
100289
- return;
100290
- }
100291
- let formattedData = newVal.map(datum => findValueOf(datum, restExpr));
100292
- // Flatten if result is array of arrays
100293
- if (isArray(formattedData[0])) {
100294
- formattedData = flatten$1(formattedData);
100261
+ let data = newVal, formattedData;
100262
+ if (isArray(data)) {
100263
+ formattedData = data.map(function (datum) {
100264
+ return findValueOf(datum, restExpr);
100265
+ });
100266
+ // If resulting structure is an array of array, flatten it
100267
+ if (isArray(formattedData[0])) {
100268
+ formattedData = flatten$1(formattedData);
100269
+ }
100270
+ listenerFn(formattedData, oldVal);
100295
100271
  }
100296
- listenerFn(formattedData, oldVal);
100297
100272
  };
100298
- /**
100299
- * Updates watch info for array expressions
100300
- */
100301
- const getUpdatedWatchInfo = (expr, acceptsArray, listener) => {
100302
- const regex = /\[\$i\]/g;
100273
+ const getUpdatedWatcInfo = (expr, acceptsArray, listener) => {
100274
+ // listener doesn't accept array
100275
+ // replace all `[$i]` with `[0]` and return the expression
100276
+ let regex = /\[\$i\]/g, $I = '[$i]', $0 = '[0]';
100303
100277
  if (!acceptsArray) {
100304
100278
  return {
100305
- expr: expr.replace(regex, ARRAY_INDEX_ZERO),
100306
- listener
100279
+ 'expr': expr.replace(regex, $0),
100280
+ 'listener': listener
100307
100281
  };
100308
100282
  }
100309
- const lastIndex = expr.lastIndexOf(ARRAY_INDEX_PLACEHOLDER);
100310
- const baseExpr = expr.substring(0, lastIndex).replace(ARRAY_INDEX_PLACEHOLDER, ARRAY_INDEX_ZERO);
100311
- const restExpr = expr.substring(lastIndex + 5);
100312
- const arrayConsumerFn = restExpr
100313
- ? arrayConsumer.bind(undefined, listener, restExpr)
100314
- : listener;
100283
+ // listener accepts array
100284
+ // replace all except the last `[$i]` with `[0]` and return the expression.
100285
+ var index = expr.lastIndexOf($I), _expr = expr.substr(0, index).replace($I, $0), restExpr = expr.substr(index + 5), arrayConsumerFn = listener;
100286
+ if (restExpr) {
100287
+ arrayConsumerFn = arrayConsumer.bind(undefined, listener, restExpr);
100288
+ }
100315
100289
  return {
100316
- expr: baseExpr,
100317
- listener: arrayConsumerFn
100290
+ 'expr': _expr,
100291
+ 'listener': arrayConsumerFn
100318
100292
  };
100319
100293
  };
100320
- /**
100321
- * Determines if an expression is static (doesn't need to be watched)
100322
- */
100323
- const STATIC_EXPRESSION_NAMES = [
100324
- "row.getProperty('investment')",
100325
- "row.getProperty('factsheetLink')",
100326
- "row.getProperty('isRebalanceEligible')"
100327
- ];
100328
- const isStaticExpression = (expr) => {
100329
- if (typeof expr !== 'string') {
100330
- return false;
100331
- }
100332
- const trimmedExpr = expr.trim();
100333
- // Expressions that always evaluate to localization strings
100334
- // if (trimmedExpr.includes('appLocale')) {
100335
- // return true;
100336
- // }
100337
- // Hard-coded static expression names
100338
- if (STATIC_EXPRESSION_NAMES.includes(trimmedExpr)) {
100339
- return true;
100340
- }
100341
- return false;
100342
- };
100343
- /**
100344
- * Gets the scope type from the scope object
100345
- */
100346
- const getScopeType = ($scope) => {
100347
- if (!$scope) {
100348
- return null;
100349
- }
100350
- if ($scope.pageName)
100351
- return 'Page';
100352
- if ($scope.prefabName)
100353
- return 'Prefab';
100354
- if ($scope.partialName)
100355
- return 'Partial';
100356
- // Check for App scope
100357
- if ($scope.Variables !== undefined &&
100358
- $scope.Actions !== undefined &&
100359
- !$scope.pageName &&
100360
- !$scope.prefabName &&
100361
- !$scope.partialName) {
100362
- return 'App';
100363
- }
100364
- if ($scope.constructor?.name === 'AppRef') {
100365
- return 'App';
100366
- }
100367
- return null;
100368
- };
100369
- /**
100370
- * Gets scope name based on scope type
100371
- */
100372
- const getScopeName = ($scope, scopeType) => {
100373
- if (!scopeType || !$scope) {
100374
- return null;
100375
- }
100376
- switch (scopeType) {
100377
- case 'Prefab': return $scope.prefabName || null;
100378
- case 'Partial': return $scope.partialName || null;
100379
- case 'Page': return $scope.pageName || null;
100380
- default: return null;
100381
- }
100382
- };
100383
- /**
100384
- * Main watch function
100385
- */
100386
100294
  const $watch = (expr, $scope, $locals, listener, identifier = watchIdGenerator.nextUid(), doNotClone = false, config = {}, isMuted) => {
100387
- // Handle array expressions
100388
- if (expr.includes(ARRAY_INDEX_PLACEHOLDER)) {
100389
- const watchInfo = getUpdatedWatchInfo(expr, config.arrayType || config.isList || false, listener);
100295
+ if (expr.indexOf('[$i]') !== -1) {
100296
+ let watchInfo = getUpdatedWatcInfo(expr, config && (config.arrayType || config.isList), listener);
100390
100297
  expr = watchInfo.expr;
100391
100298
  listener = watchInfo.listener;
100392
100299
  }
100393
- // Handle static expressions
100394
- if (isStaticExpression(expr)) {
100395
- try {
100396
- const fn = $parseExpr(expr);
100397
- const staticValue = fn($scope, $locals);
100398
- listener(staticValue, FIRST_TIME_WATCH);
100399
- }
100400
- catch (e) {
100401
- console.warn(`Error evaluating static expression '${expr}':`, e);
100402
- listener(undefined, FIRST_TIME_WATCH);
100403
- }
100404
- return () => { }; // No-op unsubscribe
100405
- }
100406
100300
  const fn = $parseExpr();
100407
- const scopeType = getScopeType($scope);
100408
- const scopeName = getScopeName($scope, scopeType);
100409
- const destroyFn = () => $unwatch(identifier);
100410
- const watchInfo = {
100411
- fn: fn.bind(null, $scope, $locals),
100301
+ registry.set(identifier, {
100302
+ fn: fn.bind(expr, $scope, $locals),
100412
100303
  listener,
100413
100304
  expr,
100414
100305
  last: FIRST_TIME_WATCH,
100415
100306
  doNotClone,
100416
- isMuted,
100417
- scopeType,
100418
- scopeName,
100419
- destroyFn
100420
- };
100421
- // Store in registry
100422
- const widgetId = getWidgetId(identifier);
100423
- if (widgetId) {
100424
- const propertyName = getPropertyName(identifier);
100425
- if (!registry.has(widgetId)) {
100426
- registry.set(widgetId, {});
100427
- }
100428
- const widgetGroup = registry.get(widgetId);
100429
- widgetGroup[propertyName] = watchInfo;
100430
- }
100431
- else {
100432
- registry.set(identifier, watchInfo);
100433
- }
100434
- return destroyFn;
100435
- };
100436
- /**
100437
- * Unwatches a single identifier
100438
- */
100439
- const $unwatch = (identifier) => {
100440
- const widgetId = getWidgetId(identifier);
100441
- if (widgetId) {
100442
- const propertyName = getPropertyName(identifier);
100443
- const widgetGroup = registry.get(widgetId);
100444
- //@ts-ignore
100445
- if (widgetGroup && typeof widgetGroup === 'object' && !widgetGroup.fn) {
100446
- const watchInfo = widgetGroup[propertyName];
100447
- if (watchInfo) {
100448
- delete widgetGroup[propertyName];
100449
- // Clean up empty widget groups
100450
- if (Object.keys(widgetGroup).length === 0) {
100451
- registry.delete(widgetId);
100452
- }
100453
- return true;
100454
- }
100455
- }
100456
- }
100457
- // Fallback to direct lookup
100458
- if (registry.has(identifier)) {
100459
- registry.delete(identifier);
100460
- return true;
100461
- }
100462
- return false;
100307
+ isMuted: isMuted
100308
+ });
100309
+ return () => $unwatch(identifier);
100463
100310
  };
100311
+ const $unwatch = identifier => registry.delete(identifier);
100312
+ window.watchRegistry = registry;
100464
100313
  const $appDigest = (() => {
100465
- return (force = false) => {
100314
+ return (force) => {
100466
100315
  {
100467
100316
  return;
100468
100317
  }
100469
100318
  };
100470
100319
  })();
100471
- // Export registry for debugging
100472
- window.watchRegistry = registry;
100473
100320
 
100474
100321
  var ComponentType;
100475
100322
  (function (ComponentType) {
@@ -100540,7 +100387,6 @@ const REGEX = {
100540
100387
  SUPPORTED_AUDIO_FORMAT: /\.(mp3|ogg|webm|wma|3gp|wav|m4a)$/i,
100541
100388
  SUPPORTED_VIDEO_FORMAT: /\.(mp4|ogg|webm|wmv|mpeg|mpg|avi|mov)$/i,
100542
100389
  VALID_WEB_URL: /^(http[s]?:\/\/)(www\.){0,1}[a-zA-Z0-9=:?\/\.\-]+(\.[a-zA-Z]{2,5}[\.]{0,1})?/,
100543
- VALID_IMAGE_URL: /^(https?|blob|data|file|ftp):/i,
100544
100390
  REPLACE_PATTERN: /\$\{([^\}]+)\}/g,
100545
100391
  DATA_URL: /^\s*data:([a-z]+\/[a-z0-9-+.]+(;[a-z-]+=[a-z0-9-]+)?)?(;base64)?,([a-z0-9!$&',()*+;=\-._~:@\/?%\s]*)\s*$/i,
100546
100392
  ISO_DATE_FORMAT: /(\d{4}-\d{2}-\d{2})T(\d{2}:\d{2}:\d{2})(\.\d+)?([+-]\d{2}:?\d{2}|Z)$/
@@ -100763,9 +100609,6 @@ const isVideoFile = (fileName) => {
100763
100609
  const isValidWebURL = (url) => {
100764
100610
  return (REGEX.VALID_WEB_URL).test(url);
100765
100611
  };
100766
- const isValidImageUrl = (url) => {
100767
- return (REGEX.VALID_IMAGE_URL).test(url?.trim());
100768
- };
100769
100612
  /*This function returns the url to the resource after checking the validity of url*/
100770
100613
  const getResourceURL = (urlString) => {
100771
100614
  return urlString;
@@ -102019,7 +101862,6 @@ var Utils = /*#__PURE__*/Object.freeze({
102019
101862
  isPageable: isPageable,
102020
101863
  isSafari: isSafari,
102021
101864
  isTablet: isTablet,
102022
- isValidImageUrl: isValidImageUrl,
102023
101865
  isValidWebURL: isValidWebURL,
102024
101866
  isVideoFile: isVideoFile,
102025
101867
  loadScript: loadScript,
@@ -69,7 +69,7 @@
69
69
  <body>
70
70
  <div class="header">
71
71
  <h1>Angular Project Dependencies Report</h1>
72
- <p class="timestamp">Generated on: 2/24/2026, 10:52:31 AM</p>
72
+ <p class="timestamp">Generated on: 3/3/2026, 3:20:46 PM</p>
73
73
  </div>
74
74
 
75
75
  <div class="section">