@wavemaker/app-ng-runtime 11.5.0-next.26236 → 11.5.0-next.26239

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.
@@ -1328,7 +1328,7 @@ class BaseComponent {
1328
1328
  getAttributes() {
1329
1329
  let _tNodeAttrs = this.inj._tNode.attrs, actualAttrs = Array.from(this.nativeElement.attributes).map(attr => attr.name);
1330
1330
  if (_tNodeAttrs === null) {
1331
- return actualAttrs;
1331
+ return actualAttrs.sort();
1332
1332
  }
1333
1333
  _.forEach(_tNodeAttrs, (attr, i) => {
1334
1334
  if (typeof attr === 'number') {
@@ -1342,15 +1342,20 @@ class BaseComponent {
1342
1342
  }
1343
1343
  }
1344
1344
  });
1345
- return actualAttrs;
1345
+ /*
1346
+ Sorting attributes as properties like placeholder is not working when it is bound.
1347
+ placeholder and placeholder.bind two properties are coming in Array.
1348
+ When array is not sorted, initially placeholder.bind value is set then placeholder default value is updated.
1349
+ If array is sorted, placeholder.bind value will be set finally.
1350
+ This is caused because of the way we are storing attribute names in watcher registry map
1351
+ */
1352
+ return actualAttrs.sort();
1346
1353
  }
1347
1354
  /**
1348
1355
  * Process the attributes
1349
1356
  */
1350
1357
  processAttrs() {
1351
- const attrs = this.getAttributes();
1352
- let i = 0;
1353
- _.map(attrs, (attrName) => {
1358
+ _.map(this.getAttributes(), (attrName) => {
1354
1359
  let attrValue = this.nativeElement.attributes[attrName].value;
1355
1360
  this.$attrs.set(attrName, attrValue);
1356
1361
  this.processAttr(attrName, attrValue);