@eqproject/eqp-dynamic-module 2.8.20 → 2.8.21

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.
@@ -6378,10 +6378,35 @@ class ListViewFormRecordComponent {
6378
6378
  });
6379
6379
  //console.log("TABELLAR VALUES", this.form, this.tabellarColumns, this.tabellarFields, this.tabellarValues);
6380
6380
  this.tabellarConditionLoaded = true;
6381
- var heightValue = this.tabellarColumns.length * 60;
6381
+ if (this.tabellarValues.length == 0) {
6382
+ this.tabellarColumns = [];
6383
+ }
6382
6384
  setTimeout(() => {
6383
- document.querySelectorAll("#tabellar table")[0].setAttribute("height", heightValue + "px");
6384
- }, 100);
6385
+ // Non serve cercare i MAX, li setta CSS in automatico con la regola max-content
6386
+ document.querySelectorAll("#tabellar table tbody tr:first-child td").forEach((el, index) => {
6387
+ document.querySelectorAll("#tabellar table tbody tr:first-child td")[index].style.height = el.clientHeight + "px";
6388
+ if (el.clientHeight > 68) {
6389
+ document.querySelectorAll("#tabellar table thead tr:first-child th")[index].style.height = (el.clientHeight + 1) + "px";
6390
+ document.querySelectorAll("#tabellar table thead tr:first-child th")[index].style.minHeight = (el.clientHeight + 1) + "px";
6391
+ }
6392
+ else {
6393
+ document.querySelectorAll("#tabellar table tbody tr:first-child td")[index].style.height = "68px";
6394
+ document.querySelectorAll("#tabellar table tbody tr:first-child td")[index].style.minHeight = "68px";
6395
+ document.querySelectorAll("#tabellar table thead tr:first-child th")[index].style.height = "68px";
6396
+ document.querySelectorAll("#tabellar table thead tr:first-child th")[index].style.minHeight = "68px";
6397
+ }
6398
+ document.querySelectorAll("#tabellar table tbody tr:nth-child(n+2) td:nth-child(" + (index + 1) + ")").forEach((el2) => {
6399
+ el2.style.height = el.clientHeight + "px";
6400
+ if (el.clientHeight > 68) {
6401
+ el2.style.height = el.clientHeight + "px";
6402
+ }
6403
+ else {
6404
+ el2.style.height = "68px";
6405
+ el2.style.minHeight = "68px";
6406
+ }
6407
+ });
6408
+ });
6409
+ }, 300);
6385
6410
  }, 100);
6386
6411
  }
6387
6412
  configureListviewButtons() {