Skip to content

Commit

Permalink
feat: (CXSPA-8988) - Add missing labels for Combo boxes in Order Summ…
Browse files Browse the repository at this point in the history
…ary (#19659)
  • Loading branch information
petarmarkov9449 authored Dec 3, 2024
1 parent 66aaa74 commit 287bc44
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"recurrencePeriodType_MONTHLY": "Month",
"dayOfMonth": "On day",
"startOn": "Start on",
"repeatOnDays": "Repeat on the following days"
"repeatOnDays": "Repeat on the following days",
"duration": "Duration"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,20 @@
>
<div class="cx-replenishment-form-data-container">
<div *ngIf="!isMonthly" class="cx-days">
<span class="form-data-label">{{
'checkoutScheduledReplenishment.every' | cxTranslate
}}</span>
<span
class="form-data-label"
*cxFeature="'!a11yScheduleReplenishment'"
>{{ 'checkoutScheduledReplenishment.every' | cxTranslate }}</span
>
<label
class="form-data-label"
*cxFeature="'a11yScheduleReplenishment'"
for="order-replenishment-period-type"
>{{ 'checkoutScheduledReplenishment.every' | cxTranslate }}</label
>
<ng-container *ngIf="isWeekly; else isDaily">
<select
id="order-replenishment-period-type"
class="form-control"
(change)="changeNumberOfWeeks($event.target.value)"
>
Expand All @@ -71,6 +80,7 @@
</ng-container>
<ng-template #isDaily>
<select
id="order-replenishment-period-type"
class="form-control"
(change)="changeNumberOfDays($event.target.value)"
>
Expand All @@ -85,10 +95,29 @@
</ng-template>
</div>
<div class="cx-month">
<span *ngIf="isMonthly" class="form-data-label">{{
'checkoutScheduledReplenishment.every' | cxTranslate
}}</span>
<ng-container *cxFeature="'!a11yScheduleReplenishment'">
<span *ngIf="isMonthly" class="form-data-label">{{
'checkoutScheduledReplenishment.every' | cxTranslate
}}</span>
</ng-container>
<ng-container *cxFeature="'a11yScheduleReplenishment'">
<label
*ngIf="isMonthly"
class="form-data-label"
for="order-replenishment-recurrence-period"
>{{ 'checkoutScheduledReplenishment.every' | cxTranslate }}</label
>
<label
*ngIf="!isMonthly"
class="form-data-label"
for="order-replenishment-recurrence-period"
>{{
'checkoutScheduledReplenishment.duration' | cxTranslate
}}</label
>
</ng-container>
<select
id="order-replenishment-recurrence-period"
class="form-control"
(change)="changeRecurrencePeriodType($event.target.value)"
>
Expand All @@ -105,11 +134,22 @@
</select>
</div>
<div *ngIf="isMonthly" class="cx-dayMonth">
<span class="form-data-label">{{
'checkoutScheduledReplenishment.dayOfMonth' | cxTranslate
}}</span>
<span
class="form-data-label"
*cxFeature="'!a11yScheduleReplenishment'"
>{{ 'checkoutScheduledReplenishment.dayOfMonth' | cxTranslate }}</span
>
<label
class="form-data-label"
*cxFeature="'a11yScheduleReplenishment'"
for="order-replenishment-day-of-month"
>{{
'checkoutScheduledReplenishment.dayOfMonth' | cxTranslate
}}</label
>
<div class="cx-day-of-month">
<select
id="order-replenishment-day-of-month"
class="form-control"
(change)="changeDayOfTheMonth($event.target.value)"
>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ export interface FeatureTogglesInterface {
a11yPopoverFocus?: boolean;

/**
* Adds Datepicker label and corrects heading order for 'CheckoutScheduleReplenishmentOrderComponent'.
* Adds Datepicker and Combobox label and corrects heading order for 'CheckoutScheduleReplenishmentOrderComponent'.
*/
a11yScheduleReplenishment?: boolean;

Expand Down

0 comments on commit 287bc44

Please sign in to comment.