@yomotech/view-toolkit 0.0.9 → 0.0.11

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.
@@ -797,7 +797,7 @@ class CardComponent {
797
797
  imageDetails = new EventEmitter();
798
798
  onPageSizeChange = new EventEmitter();
799
799
  onPageChange = new EventEmitter();
800
- cardPerRow = "col-12 md:col-6 lg:col-";
800
+ cardPerRow = "md:col-6 lg:col-";
801
801
  isLoading = false;
802
802
  layoutSchemaCopy = {};
803
803
  headerSchemaCopy = {};
@@ -817,7 +817,7 @@ class CardComponent {
817
817
  this.cardPerRow = "col-";
818
818
  }
819
819
  else {
820
- this.cardPerRow = "col-12 md:col-6 lg:col-";
820
+ this.cardPerRow = "md:col-6 lg:col-";
821
821
  }
822
822
  }
823
823
  ngOnChanges(changes) {
@@ -2504,7 +2504,6 @@ class Couchdb {
2504
2504
  const tenantKey = await this.utilityService.getStorage('tenantKey');
2505
2505
  const tenantName = await this.utilityService.getStorage('tenantName');
2506
2506
  if (tenantKey) {
2507
- console.log('tenantKey: ', tenantKey);
2508
2507
  if (typeof tenantKey !== 'string' || !tenantKey.trim()) {
2509
2508
  throw new Error('Missing tenantKey');
2510
2509
  }
@@ -2513,7 +2512,6 @@ class Couchdb {
2513
2512
  };
2514
2513
  }
2515
2514
  else {
2516
- console.log('tenantName: ', tenantName);
2517
2515
  if (typeof tenantName !== 'string' || !tenantName.trim()) {
2518
2516
  throw new Error('Missing tenantName');
2519
2517
  }
@@ -3022,24 +3020,27 @@ class SideMenuComponent {
3022
3020
  }
3023
3021
  }
3024
3022
  async setSettingImages() {
3025
- const tasks = [];
3026
- for (const menu of this.settings?.submenu) {
3027
- if (menu?.submenu?.length) {
3028
- for (const childMenu of menu.submenu) {
3029
- if (childMenu.options && childMenu.options.setImageUrl) {
3030
- tasks.push((async () => {
3031
- try {
3032
- childMenu.icon = await this.couchdbService.getFileContentFromCouchDb(`${this.tenantName}_${this.projectSeleted}`, `${childMenu.icon}`);
3033
- }
3034
- catch (err) {
3035
- console.error("Failed to fetch icon:", err);
3036
- }
3037
- })());
3023
+ if (this.settings && this.settings.length > 0) {
3024
+ const tasks = [];
3025
+ console.log('this.settings: ', this.settings);
3026
+ for (const menu of this.settings?.submenu) {
3027
+ if (menu?.submenu?.length) {
3028
+ for (const childMenu of menu.submenu) {
3029
+ if (childMenu.options && childMenu.options.setImageUrl) {
3030
+ tasks.push((async () => {
3031
+ try {
3032
+ childMenu.icon = await this.couchdbService.getFileContentFromCouchDb(`${this.tenantName}_${this.projectSeleted}`, `${childMenu.icon}`);
3033
+ }
3034
+ catch (err) {
3035
+ console.error("Failed to fetch icon:", err);
3036
+ }
3037
+ })());
3038
+ }
3038
3039
  }
3039
3040
  }
3040
3041
  }
3042
+ await Promise.all(tasks);
3041
3043
  }
3042
- await Promise.all(tasks);
3043
3044
  this.settingMenu = JSON.parse(JSON.stringify(this.settings));
3044
3045
  }
3045
3046
  isUrl(value) {