Skip to content

Commit 6db3fd8

Browse files
armaang1729Armaan Gupta
andauthored
FORMS-18211: Accessibility Issues with Checkboxgroup in Adaptive form Core component (#1761)
* made new version of the checkboxgroup component * added and modified the samples for the checkboxgroup and translation * added the samples for the custom functions * updated the path in examples for the checkboxgroup * added the specs for the checkbox group v1 and v2 * added chechboxenum test to be updated * updated the cypress test for the checkbox enum * added th dam asset for the populate-checkboxv2 * added the dam assets for the the checkboxgroup versions * modified the dam assets * added clientlibs for the newer version of the checkboxgroup * added the cypress testing to check for the fieldset and legend * modify the testcases * added check to ensure the aria-label is only added when the attribute exists * code refactoring * added collateral and cypress testing for dynamic options having newer versions of checkboxGroup and RadioButton * added customfooterlibs for the dynamicOptions tests * added README.md for the checkboxgroup v2 version * updated years for all the new files added --------- Co-authored-by: Armaan Gupta <armaang@Armaans-MacBook-Pro.local>
1 parent 554315d commit 6db3fd8

File tree

38 files changed

+2315
-22
lines changed

38 files changed

+2315
-22
lines changed

examples/ui.apps/src/main/content/jcr_root/apps/forms-components-examples/components/form/checkboxgroup/.content.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@
33
jcr:primaryType="cq:Component"
44
jcr:title="Adaptive Form CheckBox Group"
55
jcr:description="Add checkboxes to select one or more of the available options."
6-
sling:resourceSuperType="core/fd/components/form/checkboxgroup/v1/checkboxgroup"
6+
sling:resourceSuperType="core/fd/components/form/checkboxgroup/v2/checkboxgroup"
77
componentGroup="Core Components Examples - Adaptive Form"/>
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3+
~ Copyright 2026 Adobe
4+
~
5+
~ Licensed under the Apache License, Version 2.0 (the "License");
6+
~ you may not use this file except in compliance with the License.
7+
~ You may obtain a copy of the License at
8+
~
9+
~ http://www.apache.org/licenses/LICENSE-2.0
10+
~
11+
~ Unless required by applicable law or agreed to in writing, software
12+
~ distributed under the License is distributed on an "AS IS" BASIS,
13+
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
~ See the License for the specific language governing permissions and
15+
~ limitations under the License.
16+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
17+
<jcr:root xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:cq="http://www.day.com/jcr/cq/1.0" xmlns:jcr="http://www.jcp.org/jcr/1.0"
18+
jcr:description="Page Component for v1 Dynamic Options Testing"
19+
jcr:primaryType="cq:Component"
20+
jcr:title="Page - Dynamic Options V1"
21+
sling:resourceSuperType="forms-components-examples/components/page"
22+
componentGroup=".hidden"/>
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
<!--/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2+
~ Copyright 2026 Adobe
3+
~
4+
~ Licensed under the Apache License, Version 2.0 (the "License");
5+
~ you may not use this file except in compliance with the License.
6+
~ You may obtain a copy of the License at
7+
~
8+
~ http://www.apache.org/licenses/LICENSE-2.0
9+
~
10+
~ Unless required by applicable law or agreed to in writing, software
11+
~ distributed under the License is distributed on an "AS IS" BASIS,
12+
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
~ See the License for the specific language governing permissions and
14+
~ limitations under the License.
15+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/-->
16+
<sly data-sly-use.clientlib="core/wcm/components/commons/v1/templates/clientlib.html"
17+
data-sly-use.formclientlibmanager="com.adobe.cq.forms.core.components.models.form.FormClientLibManager">
18+
<sly data-sly-repeat="${formclientlibmanager.clientLibRefList}" data-sly-call="${clientlib.js @ categories=item, async=true}"/>
19+
</sly>
20+
<!-- Adding v1 component clientlibs for dynamic options test -->
21+
<!-- core.forms.components.radiobutton.v1.runtime and core.forms.components.checkboxgroup.v1.runtime are loaded explicitly -->
22+
<sly data-sly-use.clientlib="core/wcm/components/commons/v1/templates/clientlib.html">
23+
<sly data-sly-test="${!wcmmode.edit}" data-sly-call="${clientlib.js @ categories=['core.forms.components.runtime.base','core.forms.components.container.v2.runtime','core.forms.components.radiobutton.v1.runtime','core.forms.components.checkboxgroup.v1.runtime','core.forms.components.dropdown.v1.runtime','core.forms.components.button.v1.runtime'], async=false}"/>
24+
</sly>
25+
<sly data-sly-use.page="com.adobe.cq.wcm.core.components.models.Page">
26+
<sly data-sly-test="${page.data && page.dataLayerClientlibIncluded}" data-sly-call="${clientlib.js @ categories='core.forms.components.commons.v1.datalayer', async=true}"></sly>
27+
</sly>
28+
29+
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<jcr:root xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:rep="internal" xmlns:sling="http://sling.apache.org/jcr/sling/1.0"
3+
jcr:mixinTypes="[rep:AccessControllable]"
4+
jcr:primaryType="sling:Folder"
5+
lcFolder="{Long}0"
6+
type="lcFolder"/>

it/content/src/main/content/jcr_root/content/dam/formsanddocuments/core-components-it/samples/checkboxgroup/basic/.content.xml renamed to it/content/src/main/content/jcr_root/content/dam/formsanddocuments/core-components-it/samples/checkboxgroup/checkboxgroupv1/basic/.content.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<jcr:root xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:dam="http://www.day.com/dam/1.0" xmlns:nt="http://www.jcp.org/jcr/nt/1.0" xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:fd="http://www.adobe.com/aemfd/fd/1.0"
2+
<jcr:root xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:dam="http://www.day.com/dam/1.0" xmlns:nt="http://www.jcp.org/jcr/nt/1.0" xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:fd="http://www.adobe.com/aemfd/fd/1.0" xmlns:cq="http://www.day.com/jcr/cq/1.0"
33
jcr:primaryType="dam:Asset">
44
<jcr:content
5-
jcr:lastModified="{Date}2023-05-03T11:33:58.405+05:30"
5+
jcr:lastModified="{Date}2025-11-16T16:00:00.000+05:30"
66
jcr:primaryType="dam:AssetContent"
77
sling:resourceType="fd/fm/af/render"
88
guide="1"
@@ -16,6 +16,6 @@
1616
dorType="none"
1717
formmodel="none"
1818
hasCustomThumbnail="{Boolean}false"
19-
title="Adaptive Form V2 (IT)"/>
19+
title="basic"/>
2020
</jcr:content>
2121
</jcr:root>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<jcr:root xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:rep="internal" xmlns:sling="http://sling.apache.org/jcr/sling/1.0"
3+
jcr:mixinTypes="[rep:AccessControllable]"
4+
jcr:primaryType="sling:Folder"
5+
lcFolder="{Long}0"
6+
type="lcFolder"/>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<jcr:root xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:dam="http://www.day.com/dam/1.0" xmlns:nt="http://www.jcp.org/jcr/nt/1.0" xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:fd="http://www.adobe.com/aemfd/fd/1.0" xmlns:cq="http://www.day.com/jcr/cq/1.0"
3+
jcr:primaryType="dam:Asset">
4+
<jcr:content
5+
jcr:lastModified="{Date}2025-11-16T16:00:00.000+05:30"
6+
jcr:primaryType="dam:AssetContent"
7+
sling:resourceType="fd/fm/af/render"
8+
guide="1"
9+
type="guide">
10+
<metadata
11+
fd:version="2.1"
12+
jcr:primaryType="nt:unstructured"
13+
allowedRenderFormat="HTML"
14+
author="admin"
15+
availableInMobileApp="{Boolean}false"
16+
dorType="none"
17+
formmodel="none"
18+
hasCustomThumbnail="{Boolean}false"
19+
title="basic"/>
20+
</jcr:content>
21+
</jcr:root>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<jcr:root xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:dam="http://www.day.com/dam/1.0" xmlns:nt="http://www.jcp.org/jcr/nt/1.0" xmlns:xmp="http://ns.adobe.com/xap/1.0/" xmlns:cq="http://www.day.com/jcr/cq/1.0" xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:fd="http://www.adobe.com/aemfd/fd/1.0"
3+
jcr:primaryType="dam:Asset">
4+
<jcr:content
5+
jcr:lastModified="{Date}2025-11-16T16:00:00.000+05:30"
6+
jcr:primaryType="dam:AssetContent"
7+
sling:resourceType="fd/fm/af/render"
8+
guide="1"
9+
type="guide">
10+
<metadata
11+
fd:version="2.1"
12+
jcr:primaryType="nt:unstructured"
13+
xmp:CreatorTool="AEM Forms"
14+
allowedRenderFormat="HTML"
15+
author="admin"
16+
availableInMobileApp="{Boolean}false"
17+
dorTemplateChanged="Boolean"
18+
dorType="none"
19+
formmodel="none"
20+
themeRef="/libs/fd/af/themes/canvas"
21+
title="Populate-Checkboxv2"/>
22+
</jcr:content>
23+
</jcr:root>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<jcr:root xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:dam="http://www.day.com/dam/1.0" xmlns:nt="http://www.jcp.org/jcr/nt/1.0" xmlns:xmp="http://ns.adobe.com/xap/1.0/" xmlns:cq="http://www.day.com/jcr/cq/1.0" xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:fd="http://www.adobe.com/aemfd/fd/1.0"
3+
jcr:primaryType="dam:Asset">
4+
<jcr:content
5+
cq:conf="\0"
6+
jcr:lastModified="{Date}2025-01-09T12:00:00.000+05:30"
7+
jcr:primaryType="dam:AssetContent"
8+
sling:resourceType="fd/fm/af/render"
9+
guide="1"
10+
type="guide">
11+
<metadata
12+
fd:version="2.1"
13+
jcr:language="en"
14+
jcr:primaryType="nt:unstructured"
15+
xmp:CreatorTool="AEM Forms AF Wizard"
16+
allowedRenderFormat="HTML"
17+
author="admin"
18+
dorType="none"
19+
formmodel="none"
20+
themeRef="/libs/fd/af/themes/canvas"
21+
title="dynamicOptionsv2"/>
22+
</jcr:content>
23+
</jcr:root>

it/content/src/main/content/jcr_root/content/forms/af/core-components-it/samples/af2-form-translation/.content.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
jcr:lastModifiedBy="admin"
4545
jcr:primaryType="nt:unstructured"
4646
jcr:title="Check Box Group"
47-
sling:resourceType="forms-components-examples/components/form/checkboxgroup"
47+
sling:resourceType="core/fd/components/form/checkboxgroup/v1/checkboxgroup"
4848
enum="[0,1]"
4949
enumNames="[Item 1, Item 2]"
5050
fieldType="checkbox-group"
@@ -224,7 +224,7 @@
224224
jcr:lastModifiedBy="admin"
225225
jcr:primaryType="nt:unstructured"
226226
jcr:title="&lt;p>&lt;b>Select Animal&lt;/b>&lt;/p>"
227-
sling:resourceType="forms-components-examples/components/form/checkboxgroup"
227+
sling:resourceType="core/fd/components/form/checkboxgroup/v1/checkboxgroup"
228228
areOptionsRichText="true"
229229
enabled="{Boolean}true"
230230
enum="[0,1]"

0 commit comments

Comments
 (0)