style: apply prettier formatting
All checks were successful
PR Checks / prettier-autofix (pull_request) Successful in 9s
PR Checks / security-sast (pull_request) Successful in 30s
PR Checks / test-backend (pull_request) Successful in 27s
PR Checks / test-frontend (pull_request) Successful in 58s

This commit is contained in:
printcalc-ci
2026-03-14 14:15:10 +00:00
parent 46fd59ed71
commit 6f700c923a
9 changed files with 39 additions and 57 deletions

View File

@@ -1,6 +1,9 @@
import { HttpInterceptorFn } from '@angular/common/http'; import { HttpInterceptorFn } from '@angular/common/http';
import { inject, REQUEST } from '@angular/core'; import { inject, REQUEST } from '@angular/core';
import { RequestLike, resolveRequestOrigin } from '../../../core/request-origin'; import {
RequestLike,
resolveRequestOrigin,
} from '../../../core/request-origin';
function isAbsoluteUrl(url: string): boolean { function isAbsoluteUrl(url: string): boolean {
return /^[a-z][a-z\d+\-.]*:/i.test(url) || url.startsWith('//'); return /^[a-z][a-z\d+\-.]*:/i.test(url) || url.startsWith('//');

View File

@@ -105,9 +105,7 @@
[href]="languageService.localizedPath('/privacy')" [href]="languageService.localizedPath('/privacy')"
target="_blank" target="_blank"
rel="noopener" rel="noopener"
>{{ >{{ "LEGAL.CONSENT.UPLOAD_NOTICE_LINK" | translate }}</a
"LEGAL.CONSENT.UPLOAD_NOTICE_LINK" | translate
}}</a
>. >.
</p> </p>

View File

@@ -124,17 +124,14 @@
[href]="languageService.localizedPath('/terms')" [href]="languageService.localizedPath('/terms')"
target="_blank" target="_blank"
rel="noopener" rel="noopener"
>{{ >{{ "LEGAL.CONSENT.TERMS_LINK" | translate }}</a
"LEGAL.CONSENT.TERMS_LINK" | translate >
}}</a>
{{ "LEGAL.CONSENT.AND" | translate }} {{ "LEGAL.CONSENT.AND" | translate }}
<a <a
[href]="languageService.localizedPath('/privacy')" [href]="languageService.localizedPath('/privacy')"
target="_blank" target="_blank"
rel="noopener" rel="noopener"
>{{ >{{ "LEGAL.CONSENT.PRIVACY_LINK" | translate }}</a
"LEGAL.CONSENT.PRIVACY_LINK" | translate
}}</a
>. >.
</span> </span>
</label> </label>

View File

@@ -208,17 +208,14 @@
[href]="languageService.localizedPath('/terms')" [href]="languageService.localizedPath('/terms')"
target="_blank" target="_blank"
rel="noopener" rel="noopener"
>{{ >{{ "LEGAL.CONSENT.TERMS_LINK" | translate }}</a
"LEGAL.CONSENT.TERMS_LINK" | translate >
}}</a>
{{ "LEGAL.CONSENT.AND" | translate }} {{ "LEGAL.CONSENT.AND" | translate }}
<a <a
[href]="languageService.localizedPath('/privacy')" [href]="languageService.localizedPath('/privacy')"
target="_blank" target="_blank"
rel="noopener" rel="noopener"
>{{ >{{ "LEGAL.CONSENT.PRIVACY_LINK" | translate }}</a
"LEGAL.CONSENT.PRIVACY_LINK" | translate
}}</a
>. >.
</span> </span>
</label> </label>

View File

@@ -89,9 +89,7 @@
[href]="languageService.localizedPath('/privacy')" [href]="languageService.localizedPath('/privacy')"
target="_blank" target="_blank"
rel="noopener" rel="noopener"
>{{ >{{ "LEGAL.CONSENT.UPLOAD_NOTICE_LINK" | translate }}</a
"LEGAL.CONSENT.UPLOAD_NOTICE_LINK" | translate
}}</a
>. >.
</p> </p>
@@ -169,17 +167,14 @@
[href]="languageService.localizedPath('/terms')" [href]="languageService.localizedPath('/terms')"
target="_blank" target="_blank"
rel="noopener" rel="noopener"
>{{ >{{ "LEGAL.CONSENT.TERMS_LINK" | translate }}</a
"LEGAL.CONSENT.TERMS_LINK" | translate >
}}</a>
{{ "LEGAL.CONSENT.AND" | translate }} {{ "LEGAL.CONSENT.AND" | translate }}
<a <a
[href]="languageService.localizedPath('/privacy')" [href]="languageService.localizedPath('/privacy')"
target="_blank" target="_blank"
rel="noopener" rel="noopener"
>{{ >{{ "LEGAL.CONSENT.PRIVACY_LINK" | translate }}</a
"LEGAL.CONSENT.PRIVACY_LINK" | translate
}}</a
>. >.
</span> </span>
</label> </label>

View File

@@ -19,23 +19,17 @@
<app-button <app-button
variant="primary" variant="primary"
[routerLink]="languageService.localizedPath('/calculator/basic')" [routerLink]="languageService.localizedPath('/calculator/basic')"
>{{ >{{ "HOME.BTN_CALCULATE" | translate }}</app-button
"HOME.BTN_CALCULATE" | translate
}}</app-button
> >
<app-button <app-button
variant="outline" variant="outline"
[routerLink]="languageService.localizedPath('/shop')" [routerLink]="languageService.localizedPath('/shop')"
>{{ >{{ "HOME.BTN_SHOP" | translate }}</app-button
"HOME.BTN_SHOP" | translate
}}</app-button
> >
<app-button <app-button
variant="text" variant="text"
[routerLink]="languageService.localizedPath('/contact')" [routerLink]="languageService.localizedPath('/contact')"
>{{ >{{ "HOME.BTN_CONTACT" | translate }}</app-button
"HOME.BTN_CONTACT" | translate
}}</app-button
> >
</div> </div>
</div> </div>
@@ -182,16 +176,12 @@
<app-button <app-button
variant="primary" variant="primary"
[routerLink]="languageService.localizedPath('/shop')" [routerLink]="languageService.localizedPath('/shop')"
>{{ >{{ "HOME.BTN_DISCOVER" | translate }}</app-button
"HOME.BTN_DISCOVER" | translate
}}</app-button
> >
<app-button <app-button
variant="outline" variant="outline"
[routerLink]="languageService.localizedPath('/contact')" [routerLink]="languageService.localizedPath('/contact')"
>{{ >{{ "HOME.BTN_REQ_SOLUTION" | translate }}</app-button
"HOME.BTN_REQ_SOLUTION" | translate
}}</app-button
> >
</div> </div>
</div> </div>
@@ -260,16 +250,12 @@
<app-button <app-button
variant="primary" variant="primary"
[routerLink]="languageService.localizedPath('/about')" [routerLink]="languageService.localizedPath('/about')"
>{{ >{{ "HOME.SEC_ABOUT_TITLE" | translate }}</app-button
"HOME.SEC_ABOUT_TITLE" | translate
}}</app-button
> >
<app-button <app-button
variant="outline" variant="outline"
[routerLink]="languageService.localizedPath('/contact')" [routerLink]="languageService.localizedPath('/contact')"
>{{ >{{ "HOME.BTN_CONTACT" | translate }}</app-button
"HOME.BTN_CONTACT" | translate
}}</app-button
> >
</div> </div>
</div> </div>

View File

@@ -366,9 +366,12 @@ export class ProductDetailComponent {
if (!sessionId) { if (!sessionId) {
return; return;
} }
this.router.navigate(['/', this.languageService.selectedLang(), 'checkout'], { this.router.navigate(
['/', this.languageService.selectedLang(), 'checkout'],
{
queryParams: { session: sessionId }, queryParams: { session: sessionId },
}); },
);
} }
priceLabel(): number { priceLabel(): number {

View File

@@ -242,11 +242,14 @@ export class ShopPageComponent {
if (!sessionId) { if (!sessionId) {
return; return;
} }
this.router.navigate(['/', this.languageService.selectedLang(), 'checkout'], { this.router.navigate(
['/', this.languageService.selectedLang(), 'checkout'],
{
queryParams: { queryParams: {
session: sessionId, session: sessionId,
}, },
}); },
);
} }
trackByCategory(_index: number, item: ShopCategoryNavNode): string { trackByCategory(_index: number, item: ShopCategoryNavNode): string {

View File

@@ -4,9 +4,7 @@ export type RequestLike = {
headers?: Record<string, string | string[] | undefined>; headers?: Record<string, string | string[] | undefined>;
}; };
function firstHeaderValue( function firstHeaderValue(value: string | string[] | undefined): string | null {
value: string | string[] | undefined,
): string | null {
if (Array.isArray(value)) { if (Array.isArray(value)) {
return value[0] ?? null; return value[0] ?? null;
} }
@@ -29,7 +27,9 @@ function firstForwardedValue(
); );
} }
export function resolveRequestOrigin(request: RequestLike | null): string | null { export function resolveRequestOrigin(
request: RequestLike | null,
): string | null {
if (!request) { if (!request) {
return null; return null;
} }