Skip to content

Commit 910f4f6

Browse files
authored
Merge pull request #1698 from adobe/dev
DevToMaster 28 August 2025
2 parents 84b2898 + 17bdffb commit 910f4f6

File tree

9 files changed

+32
-15
lines changed

9 files changed

+32
-15
lines changed

ui.af.apps/src/main/content/jcr_root/apps/core/fd/components/form/button/v1/button/button.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
disabled="${!button.enabled}"
3838
title="${button.tooltipVisible ? '' : button.tooltipText}"
3939
data-cmp-data-layer="${button.data.json}"
40-
aria-label="${button.label.visible != false ? '' : button.label.value}">
40+
aria-label="${button.label.visible != false ? '' : button.label.value}" tabindex="0">
4141
<sly data-sly-call="${iconTemplate.icon @ icon=button.icon}"></sly>
4242
<span data-sly-test="${button.label.value && button.label.visible != false}" class="cmp-adaptiveform-button__text" data-richtext="${button.label.richText}">${button.label.value @ context = button.label.richText ? 'html' : 'text'}</span>
4343
</button>

ui.af.apps/src/main/content/jcr_root/apps/core/fd/components/form/checkbox/v1/checkbox/checkbox.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
title="${checkbox.tooltipVisible ? '' : checkbox.tooltipText}"
4343
name="${checkbox.name}"
4444
value="${checkbox.default[0]}"
45-
disabled="${!checkbox.enabled || checkbox.readOnly}" />
45+
disabled="${!checkbox.enabled || checkbox.readOnly}" tabindex="0" />
4646

4747
<div data-sly-call="${label.label @componentId=widgetId, labelValue=checkbox.label.value, labelVisible=checkbox.label.visible, labelRichText=checkbox.label.richText, bemBlock='cmp-adaptiveform-checkbox'}" data-sly-unwrap></div>
4848
</div>

ui.af.apps/src/main/content/jcr_root/apps/core/fd/components/form/checkboxgroup/v1/checkboxgroup/clientlibs/site/js/checkboxgroupview.js

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,8 @@
4040
errorDiv: `.${CheckBoxGroup.bemBlock}__errormessage`,
4141
tooltipDiv: `.${CheckBoxGroup.bemBlock}__shortdescription`,
4242
item: `.${CheckBoxGroup.bemBlock}-item`,
43-
optionLabel: `${CheckBoxGroup.bemBlock}__option-label`
43+
optionLabel: `${CheckBoxGroup.bemBlock}__option-label`,
44+
optionLink: `${CheckBoxGroup.bemBlock}__links`
4445
};
4546

4647
constructor(params) {
@@ -97,6 +98,16 @@
9798
this.setInactive();
9899
});
99100
})
101+
102+
let optionLinks = this.element.querySelectorAll(`.${CheckBoxGroup.selectors.optionLink}`);
103+
const actionKeys = ['Enter', ' ', 'Spacebar', 'Space'];
104+
optionLinks.forEach(optionLink => {
105+
optionLink.addEventListener('keydown', (e)=>{
106+
if(actionKeys.includes(e.key)) {
107+
optionLink.click();
108+
}
109+
});
110+
});
100111
}
101112

102113
#updateModelValue(widget) {

ui.af.apps/src/main/content/jcr_root/apps/core/fd/components/form/checkboxgroup/v1/checkboxgroup/widget.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
checked="${checkboxgroup.enums[itemList.index] in checkboxgroup.default }"
2626
disabled="${!checkboxgroup.enabled || checkboxgroup.readOnly}"
2727
aria-readonly="${checkboxgroup.readOnly ? 'true' : ''}"
28-
aria-label="${checkboxgroup.label.value}: ${checkboxgroup.enumNames[itemList.index]}"/>
28+
aria-label="${checkboxgroup.label.value}: ${checkboxgroup.enumNames[itemList.index]}" tabindex="0"/>
2929
<span>${checkboxgroup.enumNames[itemList.index] @ context = 'html'}</span>
3030
</label>
3131
</div>

ui.af.apps/src/main/content/jcr_root/apps/core/fd/components/form/fileinput/v4/fileinput/fileinput.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
<div class="cmp-adaptiveform-fileinput__dragarea">
4343
<div class="cmp-adaptiveform-fileinput__icon"></div>
4444
<div class="cmp-adaptiveform-fileinput__dragtext">${file.dragDropText @context='html'}</div>
45-
<button type="button" data-sly-test="${file.buttonText}" class="cmp-adaptiveform-fileinput__widgetlabel">${file.buttonText}</button>
45+
<button type="button" data-sly-test="${file.buttonText}" class="cmp-adaptiveform-fileinput__widgetlabel" tabindex="0">${file.buttonText}</button>
4646
<input class="cmp-adaptiveform-fileinput__widget"
4747
data-sly-attribute.multiple="${file.isMultiple ? 'multiple' : ''}"
4848
style="${file.buttonText ? 'display:none' : '' @ context='styleString'}"

ui.af.apps/src/main/content/jcr_root/apps/core/fd/components/form/radiobutton/v1/radiobutton/radiobutton.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
value="${item.toString}"
5050
disabled="${!radioButton.enabled || radioButton.readOnly}"
5151
checked="${radioButton.enums[itemList.index] == radioButton.default[0]}"
52-
aria-label="${radioButton.label.value}: ${radioButton.enumNames[itemList.index]}"/>
52+
aria-label="${radioButton.label.value}: ${radioButton.enumNames[itemList.index]}" tabindex="0"/>
5353
<span>${radioButton.enumNames[itemList.index] @ context = 'html'}</span>
5454
</label>
5555
</div>

ui.af.apps/src/main/content/jcr_root/apps/core/fd/components/form/switch/v1/switch/switch.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848
aria-label="${switch.label.value}"
4949
disabled="${!switch.enabled || switch.readOnly}"
5050
value="${switch.default}"
51-
aria-readonly="${switch.readOnly ? 'true' : ''}">
51+
aria-readonly="${switch.readOnly ? 'true' : ''}" tabindex="0">
5252
<div class="cmp-adaptiveform-switch__widget-slider">
5353
<div class="cmp-adaptiveform-switch__circle-indicator"></div>
5454
</div>

ui.af.apps/src/main/content/jcr_root/apps/core/fd/components/form/wizard/v1/wizard/clientlibs/site/js/wizardview.js

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -127,14 +127,20 @@
127127
*/
128128
#bindEvents() {
129129
const _self = this;
130-
this.getNextButtonDiv().addEventListener("click", function (event) {
131-
_self.#navigateToNextTab();
132-
})
133-
this.getPreviousButtonDiv().addEventListener("click", function (event) {
134-
_self.#navigateToPreviousTab();
135-
})
136-
130+
const actionKeys = ['Enter', ' ', 'Spacebar', 'Space'];
137131

132+
["click", "keydown"].forEach(function(event){
133+
_self.getNextButtonDiv().addEventListener(event, function(event){
134+
if (event.type ==='click' || (event.type === 'keydown' && actionKeys.includes(event.key))) {
135+
_self.#navigateToNextTab();
136+
}
137+
});
138+
_self.getPreviousButtonDiv().addEventListener(event, function(event){
139+
if (event.type ==='click' || (event.type === 'keydown' && actionKeys.includes(event.key))) {
140+
_self.#navigateToPreviousTab();
141+
}
142+
});
143+
})
138144
}
139145

140146
/**

ui.frontend/src/view/FormFieldBase.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ class FormFieldBase extends FormField {
249249
this.#syncLabel()
250250
this.#syncWidget()
251251
this.#syncShortDesc()
252-
this. #syncLongDesc()
252+
this.#syncLongDesc()
253253
this.#syncAriaDescribedBy()
254254
this.#syncError()
255255
this.#syncAriaLabel()

0 commit comments

Comments
 (0)