fix(storefront): replace hardcoded strings with i18n, neutral empty-state wording

- Route aria-label/alt/title strings (rating, discount, carousel arrows,
  hero slides, dialog close, toast dismiss, QR code, bank payment iframe,
  guest checkout fallback) through the translate pipe/service instead of
  literal English.
- Drop the "Oops!"/"Упс!" apology framing from category/subcategory empty
  states (en/ru/hy) - zero results is not an error.
This commit is contained in:
sdarbinyan
2026-07-25 23:54:08 +04:00
parent 0982397d6b
commit 1163bfd88a
14 changed files with 68 additions and 18 deletions

View File

@@ -3,7 +3,7 @@
<div class="product-image">
<img [src]="getMainImage(item)" [alt]="title || item.name" loading="lazy" decoding="async" width="300" height="300" />
@if (showDiscountBadge && item.discount > 0) {
<div class="discount-badge" [attr.aria-label]="'Discount ' + item.discount + '%'">-{{ item.discount }}%</div>
<div class="discount-badge" [attr.aria-label]="'common.discountLabel' | translate:{ value: item.discount }">-{{ item.discount }}%</div>
}
@if (showStock && item.remainings) {
<span class="stock-badge" [class.out]="item.remainings.toLowerCase() === 'out'">{{ stockLabelKey(item.remainings) | translate }}</span>
@@ -43,7 +43,7 @@
}
@if (showRating) {
<div class="product-rating" [attr.aria-label]="'Rating ' + item.rating">
<div class="product-rating" [attr.aria-label]="'common.ratingLabel' | translate:{ value: item.rating }">
<span class="rating-stars">{{ item.rating | number:'1.1-1' }}</span>
<span class="rating-count">({{ item.callbacks?.length || item.comments?.length || 0 }})</span>
</div>