@yomotech/view-toolkit 1.0.81 → 1.0.82

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.
@@ -2,7 +2,7 @@ import * as i6 from '@angular/common';
2
2
  import { NgIf, NgStyle, NgTemplateOutlet, AsyncPipe, CommonModule, NgFor, NgClass, DatePipe } from '@angular/common';
3
3
  import * as i0 from '@angular/core';
4
4
  import { Pipe, EventEmitter, Output, Input, ChangeDetectionStrategy, Component, signal, Injectable, HostListener, Directive, Optional, SkipSelf, ViewChild, inject, ApplicationRef, EnvironmentInjector, createComponent, InjectionToken, Inject, ChangeDetectorRef, ElementRef, ViewChildren, HostBinding, NgZone, effect, untracked, NgModule, DestroyRef } from '@angular/core';
5
- import { effectiveControl, keyboardFor, styleValue, actionName, BROWSER_STORAGES, OLD_STORAGES, cssStyle, paginationFor, startPageFor, START_PAGE_KEYS, cardLayoutOf, stripeTestPaymentMethod, actionParams, WEEK_DAYS, openingStatus, validPlace, mapEmbedUrl, validAmount, formatPrice, maxLinesOf, enterKeyFor, CONTACT_ICONS, methodOf, waitsForFilter, translateCaptions, alignRowsOf, successMessageOf, readAppSettings, appSettingsMenu, appSettingsFooter } from '@yomotech/view-toolkit/catalog';
5
+ import { effectiveControl, keyboardFor, styleValue, actionName, BROWSER_STORAGES, OLD_STORAGES, cssStyle, paginationFor, startPageFor, START_PAGE_KEYS, cardLayoutOf, stripeTestPaymentMethod, actionParams, WEEK_DAYS, openingStatus, validPlace, mapEmbedUrl, validAmount, formatPrice, maxLinesOf, enterKeyFor, CONTACT_ICONS, methodOf, waitsForFilter, translateCaptions, alignRowsOf, buttonsColumnOf, successMessageOf, readAppSettings, appSettingsMenu, appSettingsFooter } from '@yomotech/view-toolkit/catalog';
6
6
  import * as catalog from '@yomotech/view-toolkit/catalog';
7
7
  export { catalog as FieldCatalog };
8
8
  import * as i15 from '@angular/cdk/drag-drop';
@@ -9855,6 +9855,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.2", ngImpor
9855
9855
  }]
9856
9856
  }], ctorParameters: () => [{ type: Couchdb }, { type: UtilityService }, { type: i1$2.Platform }] });
9857
9857
 
9858
+ // Faramarz Yousefian and Agent Toni (Claude Opus 5.5) 2026-11-18
9859
+ // - fix: the button column on the right only with center.option.buttonsColumn - the library moved every row's buttons
9860
+ // there by itself (luv2shop "Add to cart" squeezed to a circle, OFFENE-PUNKTE 238)
9858
9861
  // Faramarz Yousefian and Agent Toni (Claude Opus 5.5) 2026-11-17
9859
9862
  // - new: option.hideEmpty - an empty field takes no room on the card (hiddenEmpty)
9860
9863
  // - new: the buttons of card rows with fields - one narrow column on the right of the card (cardActionButtons)
@@ -10633,15 +10636,17 @@ class CardComponent {
10633
10636
  rowButtons(layout) {
10634
10637
  return (layout?.elements || []).filter((e) => !e?.scope?.reference);
10635
10638
  }
10636
- /** The buttons of all rows that also hold fields: one column on the right of the card (card.buttonsInRow). */
10639
+ /** The buttons of all rows that also hold fields: one column on the right - only with center.option.buttonsColumn (238). */
10637
10640
  cardActionButtons() {
10641
+ if (!buttonsColumnOf(this.itemInfo?.layoutSchema))
10642
+ return [];
10638
10643
  return (this.itemInfo?.layoutSchema?.cards || [])
10639
10644
  .filter((layout) => layout?.type === 'HorizontalLayout' && this.rowHasFieldsAndButtons(layout))
10640
10645
  .flatMap((layout) => this.rowButtons(layout));
10641
10646
  }
10642
- /** A row holding fields and buttons: drawn as fields | button group (card.buttonsInRow). */
10647
+ /** A row holding fields and buttons whose buttons go to the column (center.option.buttonsColumn); else a plain row (238). */
10643
10648
  rowHasFieldsAndButtons(layout) {
10644
- return this.rowFields(layout).length > 0 && this.rowButtons(layout).length > 0;
10649
+ return buttonsColumnOf(this.itemInfo?.layoutSchema) && this.rowFields(layout).length > 0 && this.rowButtons(layout).length > 0;
10645
10650
  }
10646
10651
  /** option.hideEmpty: a field whose value is empty in this record takes no room on the card (no "--" row). */
10647
10652
  hiddenEmpty(element, record) {