{ "version": 3, "sources": ["src/app/checkout-page/components/basket-summary/basket-summary.component.ts", "src/app/checkout-page/components/basket-summary/basket-summary.component.html"], "sourcesContent": ["import { CommonModule } from '@angular/common';\nimport { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnDestroy } from '@angular/core';\nimport { TranslateModule } from '@ngx-translate/core';\nimport { Subscription } from 'rxjs';\nimport { BasketReturnModel, Money } from 'src/business/services/client.generated';\nimport { PricePipe } from 'src/core-lib/pipes/price.pipe';\nimport { BasketService } from '../../services/basket.service';\n\n@Component({\n selector: 'app-basket-summary',\n templateUrl: './basket-summary.component.html',\n styleUrls: ['./basket-summary.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: true,\n imports: [CommonModule, TranslateModule,PricePipe]\n})\nexport class BasketSummaryComponent implements OnDestroy {\n prices: Array<{ text: string, price: Money }> = [];\n subscription: Subscription;\n\n @Input('basket')\n set _basket(basket: BasketReturnModel) {\n this.prices = [];\n if (basket != null) {\n this.prices.push({ text: 'total_ex_vat', price: { amount: (basket?.total?.amount ?? 0) - (basket?.totalVat?.amount ?? 0), currency: (basket?.total?.currency ?? 'XXX') } });\n // if (basket.totalDiscount.amount > 0)\n // this.prices.push({ text: 'total_shipping', price: basket.totalDiscount });\n // if (basket.totalDiscount.amount > 0)\n // this.prices.push({ text: 'total_enviroment', price: basket.totalDiscount });\n if (basket?.totalVat != null)\n this.prices.push({ text: 'total_vat', price: basket.totalVat });\n if (basket?.totalDiscount?.amount > 0)\n if (basket?.totalDiscount != null)\n this.prices.push({ text: 'total_discount', price: basket.totalDiscount });\n // if (basket.totalDiscount.amount > 0)\n // this.prices.push({ text: 'total_invoice_fee', price: basket.totalDiscount });\n this.prices.push({ text: 'line', price: { amount: 0, currency: 'XXX' } });\n if (basket?.total != null)\n this.prices.push({ text: 'total_in_vat', price: basket.total });\n }\n this._detector.markForCheck();\n }\n\n constructor(private basketService: BasketService, private _detector: ChangeDetectorRef) {\n this.subscription = this.basketService.basket$.subscribe(basket => this._basket = basket);\n }\n\n ngOnDestroy(): void {\n if (this.subscription != null && !this.subscription.closed)\n this.subscription.unsubscribe();\n }\n}\n", "@for(price of prices; track price.text) {\n @if(price.text === 'line') {\n