@dangl/angular-ava 1.3.0 → 1.3.1-beta0011

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.
@@ -248,12 +248,12 @@ var ModeViewType;
248
248
 
249
249
  // This file is automatically generated as part of the build process
250
250
  const version = {
251
- version: "1.3.0",
252
- commitInfo: "Branch.main.Sha.4693b1ba1a5dafd8bf76ae2c6c726078e427f401",
253
- commitDate: "2025-02-12",
254
- commitHash: "4693b1ba1a5dafd8bf76ae2c6c726078e427f401",
255
- informationalVersion: "1.3.0+Branch.main.Sha.4693b1ba1a5dafd8bf76ae2c6c726078e427f401",
256
- buildDateUtc: new Date(Date.UTC(2025, 1, 12, 19, 49, 28))
251
+ version: "1.3.1-beta0011",
252
+ commitInfo: "Branch.develop.Sha.b53c17846b82c3d323307bb4a88cd715e7f225f6",
253
+ commitDate: "2025-03-02",
254
+ commitHash: "b53c17846b82c3d323307bb4a88cd715e7f225f6",
255
+ informationalVersion: "1.3.1-beta.11+Branch.develop.Sha.b53c17846b82c3d323307bb4a88cd715e7f225f6",
256
+ buildDateUtc: new Date(Date.UTC(2025, 2, 2, 18, 30, 23))
257
257
  };
258
258
 
259
259
  class TreeHoverTooltipService {
@@ -2269,6 +2269,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.1", ngImpor
2269
2269
  class InvoiceLineItemsTableComponent {
2270
2270
  constructor() {
2271
2271
  this.lineItems = input([]);
2272
+ this.flatLineItems = [];
2272
2273
  this.configurationInvoiceService = inject(ConfigurationInvoiceService$1);
2273
2274
  this.textWords$ = this.configurationInvoiceService.getTextWordsFromConfig();
2274
2275
  this.pdfViewEnabled$ = this.configurationInvoiceService.getPdfViewEnabledFromConfig();
@@ -2276,6 +2277,9 @@ class InvoiceLineItemsTableComponent {
2276
2277
  this.displayedColumns = ['number', 'description', 'quantity', 'unit', 'netPrice', 'vat', 'discount', 'netAmount'];
2277
2278
  this.expandedElements = new Set();
2278
2279
  }
2280
+ ngOnInit() {
2281
+ this.flatLineItems = this.getFlatLineItems(this.lineItems(), 0);
2282
+ }
2279
2283
  toggleRow(row) {
2280
2284
  if (this.expandedElements.has(row)) {
2281
2285
  this.expandedElements.delete(row);
@@ -2287,8 +2291,17 @@ class InvoiceLineItemsTableComponent {
2287
2291
  isRowExpanded(row) {
2288
2292
  return this.expandedElements.has(row);
2289
2293
  }
2294
+ getFlatLineItems(lineItemsList, indentLevel) {
2295
+ return lineItemsList.reduce((acc, lineItem) => {
2296
+ acc.push({ ...lineItem, indentLevel });
2297
+ if (lineItem.subItems && lineItem.subItems.length) {
2298
+ acc.push(...this.getFlatLineItems(lineItem.subItems, indentLevel + 1));
2299
+ }
2300
+ return acc;
2301
+ }, []);
2302
+ }
2290
2303
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.1", ngImport: i0, type: InvoiceLineItemsTableComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
2291
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.0.1", type: InvoiceLineItemsTableComponent, isStandalone: true, selector: "ava-invoice-line-items-table", inputs: { lineItems: { classPropertyName: "lineItems", publicName: "lineItems", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "@if (textWords$ | async; as textWords) {\n @if ((colorSettings$ | async) || true; as colorSettings) {\n <table\n mat-table\n [dataSource]=\"lineItems()\"\n multiTemplateDataRows\n class=\"mat-elevation-z8 invoice-table\"\n >\n <ng-container matColumnDef=\"number\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n #\n </th>\n <td\n mat-cell\n *matCellDef=\"let element; let i = dataIndex\"\n >\n {{ i + 1 }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"description\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadDescription }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n >\n {{ element.itemInformation?.description }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"quantity\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadQuantity }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n >\n {{ element.quantity | numberPlus }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"unit\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadUnit }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n >\n {{ element.unitCode }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"netPrice\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadNetPrice }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n {{ element.priceDetails?.netPrice | currencyPlus }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"discount\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.lineItemDiscount }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n @if (element.priceDetails?.absoluteDiscountPerItem) {\n {{ element.priceDetails?.absoluteDiscountPerItem | percentPlus: '1.0-2' }}\n }\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"netAmount\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadNetAmount }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n {{ element.netAmount | currencyPlus }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"vat\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.vat }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n @if (element && element.vatInformation && element.vatInformation.length > 0) {\n {{ element.vatInformation[0].vatRate | percentPlus: '1.0-2' }}\n }\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"expandedDetail\">\n <td\n mat-cell\n *matCellDef=\"let element\"\n [attr.colspan]=\"displayedColumns.length\"\n >\n <div [@detailExpand]=\"isRowExpanded(element) ? 'expanded' : 'collapsed'\">\n <ava-invoice-line-item-additional-info [lineItem]=\"element\"></ava-invoice-line-item-additional-info>\n </div>\n </td>\n </ng-container>\n\n <tr\n mat-header-row\n *matHeaderRowDef=\"displayedColumns\"\n ></tr>\n\n <tr\n mat-row\n *matRowDef=\"let row; columns: displayedColumns\"\n (click)=\"toggleRow(row)\"\n [ngClass]=\"{ 'expanded-row': isRowExpanded(row) && colorSettings === true }\"\n [ngStyle]=\"{\n backgroundColor:\n colorSettings === true\n ? null\n : isRowExpanded(row)\n ? 'color-mix(in srgb,' + colorSettings?.backgroundColor + ', white 70%)'\n : null,\n }\"\n ></tr>\n\n <tr\n mat-row\n *matRowDef=\"let row; columns: ['expandedDetail']\"\n class=\"detail-row\"\n ></tr>\n </table>\n }\n}\n", styles: [".invoice-table{width:100%;border-collapse:collapse;margin:20px 0}.invoice-table th,.invoice-table td{text-align:left}.invoice-table th{background-color:var(--color-primary);font-weight:700;color:#fff}.currency-table-cell{text-align:right!important}.invoice-table tr.detail-row{height:0}tr{cursor:pointer}tr.expanded-row td{background-color:color-mix(in srgb,var(--color-primary),white 70%)}\n"], dependencies: [{ kind: "pipe", type: PercentPlusPipe$1, name: "percentPlus" }, { kind: "pipe", type: CurrencyPlusPipe$1, name: "currencyPlus" }, { kind: "pipe", type: NumberPlusPipe, name: "numberPlus" }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "ngmodule", type: MatTableModule }, { kind: "component", type: i4$1.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i4$1.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i4$1.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i4$1.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i4$1.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i4$1.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i4$1.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i4$1.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "component", type: i4$1.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i4$1.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: InvoiceLineItemAdditionalInfoComponent, selector: "ava-invoice-line-item-additional-info", inputs: ["lineItem"] }, { kind: "directive", type: NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }], animations: [
2304
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.0.1", type: InvoiceLineItemsTableComponent, isStandalone: true, selector: "ava-invoice-line-items-table", inputs: { lineItems: { classPropertyName: "lineItems", publicName: "lineItems", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "@if (textWords$ | async; as textWords) {\n @if ((colorSettings$ | async) || true; as colorSettings) {\n <table\n mat-table\n [dataSource]=\"flatLineItems\"\n multiTemplateDataRows\n class=\"mat-elevation-z8 invoice-table\"\n >\n <ng-container matColumnDef=\"number\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n #\n </th>\n <td\n mat-cell\n *matCellDef=\"let element; let i = dataIndex\"\n [class.children]=\"element.indentLevel\"\n >\n {{ element.identifier || element.objectIdentifier || i + 1 }}\n @if (element.indentLevel) {\n <div\n class=\"children-mark\"\n [style.width.px]=\"element.indentLevel * 8\"\n ></div>\n }\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"description\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadDescription }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n >\n {{ element.itemInformation?.description }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"quantity\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadQuantity }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n >\n {{ element.quantity | numberPlus }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"unit\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadUnit }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n >\n {{ element.unitCode }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"netPrice\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadNetPrice }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n {{ element.priceDetails?.netPrice | currencyPlus }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"discount\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.lineItemDiscount }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n @if (element.priceDetails?.absoluteDiscountPerItem) {\n {{ element.priceDetails?.absoluteDiscountPerItem | percentPlus: '1.0-2' }}\n }\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"netAmount\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadNetAmount }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n {{ element.netAmount | currencyPlus }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"vat\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.vat }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n @if (element && element.vatInformation && element.vatInformation.length > 0) {\n {{ element.vatInformation[0].vatRate | percentPlus: '1.0-2' }}\n }\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"expandedDetail\">\n <td\n mat-cell\n *matCellDef=\"let element\"\n [attr.colspan]=\"displayedColumns.length\"\n >\n <div [@detailExpand]=\"isRowExpanded(element) ? 'expanded' : 'collapsed'\">\n <ava-invoice-line-item-additional-info [lineItem]=\"element\"></ava-invoice-line-item-additional-info>\n </div>\n </td>\n </ng-container>\n\n <tr\n mat-header-row\n *matHeaderRowDef=\"displayedColumns\"\n ></tr>\n\n <tr\n mat-row\n *matRowDef=\"let row; columns: displayedColumns\"\n (click)=\"(row.allowances || row.charges) && toggleRow(row)\"\n [ngClass]=\"{ 'expanded-row': isRowExpanded(row) && colorSettings === true }\"\n [ngStyle]=\"{\n backgroundColor:\n colorSettings === true\n ? null\n : isRowExpanded(row)\n ? 'color-mix(in srgb,' + colorSettings?.backgroundColor + ', white 70%)'\n : null,\n }\"\n ></tr>\n\n <tr\n mat-row\n *matRowDef=\"let row; columns: ['expandedDetail']\"\n class=\"detail-row\"\n ></tr>\n </table>\n }\n}\n", styles: [".invoice-table{width:100%;border-collapse:collapse}.invoice-table th,.invoice-table td{text-align:left}.invoice-table th{background-color:var(--color-primary);font-weight:700;color:#fff}.currency-table-cell{text-align:right!important}.invoice-table tr.detail-row{height:0}tr{cursor:pointer}tr.expanded-row td{background-color:color-mix(in srgb,var(--color-primary),white 70%)}.children{position:relative}.children-mark{height:100%;background-color:#add8e6;position:absolute;left:0;top:0;z-index:200;opacity:.5}\n"], dependencies: [{ kind: "pipe", type: PercentPlusPipe$1, name: "percentPlus" }, { kind: "pipe", type: CurrencyPlusPipe$1, name: "currencyPlus" }, { kind: "pipe", type: NumberPlusPipe, name: "numberPlus" }, { kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "ngmodule", type: MatTableModule }, { kind: "component", type: i4$1.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i4$1.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i4$1.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i4$1.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i4$1.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i4$1.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i4$1.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i4$1.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "component", type: i4$1.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i4$1.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: InvoiceLineItemAdditionalInfoComponent, selector: "ava-invoice-line-item-additional-info", inputs: ["lineItem"] }, { kind: "directive", type: NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }], animations: [
2292
2305
  trigger('detailExpand', [
2293
2306
  state('collapsed,void', style({ height: '0px', minHeight: '0' })),
2294
2307
  state('expanded', style({ height: '*' })),
@@ -2314,7 +2327,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.1", ngImpor
2314
2327
  NgClass,
2315
2328
  InvoiceLineItemAdditionalInfoComponent,
2316
2329
  NgStyle
2317
- ], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (textWords$ | async; as textWords) {\n @if ((colorSettings$ | async) || true; as colorSettings) {\n <table\n mat-table\n [dataSource]=\"lineItems()\"\n multiTemplateDataRows\n class=\"mat-elevation-z8 invoice-table\"\n >\n <ng-container matColumnDef=\"number\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n #\n </th>\n <td\n mat-cell\n *matCellDef=\"let element; let i = dataIndex\"\n >\n {{ i + 1 }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"description\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadDescription }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n >\n {{ element.itemInformation?.description }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"quantity\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadQuantity }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n >\n {{ element.quantity | numberPlus }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"unit\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadUnit }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n >\n {{ element.unitCode }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"netPrice\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadNetPrice }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n {{ element.priceDetails?.netPrice | currencyPlus }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"discount\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.lineItemDiscount }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n @if (element.priceDetails?.absoluteDiscountPerItem) {\n {{ element.priceDetails?.absoluteDiscountPerItem | percentPlus: '1.0-2' }}\n }\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"netAmount\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadNetAmount }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n {{ element.netAmount | currencyPlus }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"vat\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.vat }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n @if (element && element.vatInformation && element.vatInformation.length > 0) {\n {{ element.vatInformation[0].vatRate | percentPlus: '1.0-2' }}\n }\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"expandedDetail\">\n <td\n mat-cell\n *matCellDef=\"let element\"\n [attr.colspan]=\"displayedColumns.length\"\n >\n <div [@detailExpand]=\"isRowExpanded(element) ? 'expanded' : 'collapsed'\">\n <ava-invoice-line-item-additional-info [lineItem]=\"element\"></ava-invoice-line-item-additional-info>\n </div>\n </td>\n </ng-container>\n\n <tr\n mat-header-row\n *matHeaderRowDef=\"displayedColumns\"\n ></tr>\n\n <tr\n mat-row\n *matRowDef=\"let row; columns: displayedColumns\"\n (click)=\"toggleRow(row)\"\n [ngClass]=\"{ 'expanded-row': isRowExpanded(row) && colorSettings === true }\"\n [ngStyle]=\"{\n backgroundColor:\n colorSettings === true\n ? null\n : isRowExpanded(row)\n ? 'color-mix(in srgb,' + colorSettings?.backgroundColor + ', white 70%)'\n : null,\n }\"\n ></tr>\n\n <tr\n mat-row\n *matRowDef=\"let row; columns: ['expandedDetail']\"\n class=\"detail-row\"\n ></tr>\n </table>\n }\n}\n", styles: [".invoice-table{width:100%;border-collapse:collapse;margin:20px 0}.invoice-table th,.invoice-table td{text-align:left}.invoice-table th{background-color:var(--color-primary);font-weight:700;color:#fff}.currency-table-cell{text-align:right!important}.invoice-table tr.detail-row{height:0}tr{cursor:pointer}tr.expanded-row td{background-color:color-mix(in srgb,var(--color-primary),white 70%)}\n"] }]
2330
+ ], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (textWords$ | async; as textWords) {\n @if ((colorSettings$ | async) || true; as colorSettings) {\n <table\n mat-table\n [dataSource]=\"flatLineItems\"\n multiTemplateDataRows\n class=\"mat-elevation-z8 invoice-table\"\n >\n <ng-container matColumnDef=\"number\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n #\n </th>\n <td\n mat-cell\n *matCellDef=\"let element; let i = dataIndex\"\n [class.children]=\"element.indentLevel\"\n >\n {{ element.identifier || element.objectIdentifier || i + 1 }}\n @if (element.indentLevel) {\n <div\n class=\"children-mark\"\n [style.width.px]=\"element.indentLevel * 8\"\n ></div>\n }\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"description\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadDescription }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n >\n {{ element.itemInformation?.description }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"quantity\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadQuantity }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n >\n {{ element.quantity | numberPlus }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"unit\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadUnit }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n >\n {{ element.unitCode }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"netPrice\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadNetPrice }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n {{ element.priceDetails?.netPrice | currencyPlus }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"discount\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.lineItemDiscount }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n @if (element.priceDetails?.absoluteDiscountPerItem) {\n {{ element.priceDetails?.absoluteDiscountPerItem | percentPlus: '1.0-2' }}\n }\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"netAmount\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.tableHeadNetAmount }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n {{ element.netAmount | currencyPlus }}\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"vat\">\n <th\n mat-header-cell\n *matHeaderCellDef\n [ngStyle]=\"{\n backgroundColor: colorSettings === true ? null : colorSettings?.backgroundColor,\n color: colorSettings === true ? null : colorSettings?.textColor,\n }\"\n >\n {{ textWords.vat }}\n </th>\n <td\n mat-cell\n *matCellDef=\"let element\"\n class=\"currency-table-cell\"\n >\n @if (element && element.vatInformation && element.vatInformation.length > 0) {\n {{ element.vatInformation[0].vatRate | percentPlus: '1.0-2' }}\n }\n </td>\n </ng-container>\n\n <ng-container matColumnDef=\"expandedDetail\">\n <td\n mat-cell\n *matCellDef=\"let element\"\n [attr.colspan]=\"displayedColumns.length\"\n >\n <div [@detailExpand]=\"isRowExpanded(element) ? 'expanded' : 'collapsed'\">\n <ava-invoice-line-item-additional-info [lineItem]=\"element\"></ava-invoice-line-item-additional-info>\n </div>\n </td>\n </ng-container>\n\n <tr\n mat-header-row\n *matHeaderRowDef=\"displayedColumns\"\n ></tr>\n\n <tr\n mat-row\n *matRowDef=\"let row; columns: displayedColumns\"\n (click)=\"(row.allowances || row.charges) && toggleRow(row)\"\n [ngClass]=\"{ 'expanded-row': isRowExpanded(row) && colorSettings === true }\"\n [ngStyle]=\"{\n backgroundColor:\n colorSettings === true\n ? null\n : isRowExpanded(row)\n ? 'color-mix(in srgb,' + colorSettings?.backgroundColor + ', white 70%)'\n : null,\n }\"\n ></tr>\n\n <tr\n mat-row\n *matRowDef=\"let row; columns: ['expandedDetail']\"\n class=\"detail-row\"\n ></tr>\n </table>\n }\n}\n", styles: [".invoice-table{width:100%;border-collapse:collapse}.invoice-table th,.invoice-table td{text-align:left}.invoice-table th{background-color:var(--color-primary);font-weight:700;color:#fff}.currency-table-cell{text-align:right!important}.invoice-table tr.detail-row{height:0}tr{cursor:pointer}tr.expanded-row td{background-color:color-mix(in srgb,var(--color-primary),white 70%)}.children{position:relative}.children-mark{height:100%;background-color:#add8e6;position:absolute;left:0;top:0;z-index:200;opacity:.5}\n"] }]
2318
2331
  }] });
2319
2332
 
2320
2333
  registerLocaleData(localeDe, 'de-DE', localeDeExtra);