Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
506cd1f
Adding firefox reset sample (#1389)
rismehta Sep 10, 2024
0947539
FORMS-16296 Adding fragment test and fixing rules issue inside fragme…
rismehta Sep 11, 2024
da0b04e
Fixing initialize in dispatch (#1393)
rismehta Sep 12, 2024
7bffb4f
Merge branch 'master' into devMaster12Sep
rismehta Sep 12, 2024
fc8a109
Merge pull request #1394 from adobe/devMaster12Sep
rismehta Sep 12, 2024
f31f595
@releng [maven-scm] :prepare release core-forms-components-reactor-3.…
rismehta Sep 12, 2024
f5ac860
@releng [maven-scm] :prepare for next development iteration
rismehta Sep 12, 2024
7b5978f
Update VERSIONS.md and README.md to include version 3.0.58
Sep 12, 2024
fccd1c9
panel label not updated on initialize (#1395)
rismehta Sep 12, 2024
e1a2739
FORMS-15478 Added localize success and error message for draft (#1396)
girotraapankaj Sep 13, 2024
a8f06f0
Upgrade cypress version (#1353)
rismehta Sep 16, 2024
9c582e4
Merge branch 'master' into devMaster16Sep
rismehta Sep 16, 2024
00a5da5
Merge pull request #1402 from adobe/devMaster16Sep
rismehta Sep 16, 2024
50ae601
@releng [maven-scm] :prepare release core-forms-components-reactor-3.…
rismehta Sep 16, 2024
8ddc08d
@releng [maven-scm] :prepare for next development iteration
rismehta Sep 16, 2024
78e2e41
@releng [maven-scm] :prepare release core-forms-components-reactor-3.…
rismehta Sep 16, 2024
2f9aff9
@releng [maven-scm] :prepare for next development iteration
rismehta Sep 16, 2024
68fb7a3
Merge branch 'release/650' into master6516Sep
rismehta Sep 16, 2024
aa75f42
Fixing versions
rismehta Sep 16, 2024
2407957
Fixing xml declaration
rismehta Sep 16, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ common:
# Supports 'Re-run failed tests only'. See this for more info: https://circleci.com/docs/rerun-failed-tests-only/
command: |
cd ui.tests/test-module
TESTFILES=$(circleci tests glob "specs/**/*.spec.js")
TESTFILES=$(circleci tests glob "specs/**/*.cy.js")
cd ../../
echo "false" >> TEST_EXECUTION_STATUS.txt
echo $TESTFILES | circleci tests run --command="xargs node .circleci/ci/it-tests.js" --verbose --split-by=timings
Expand Down Expand Up @@ -94,6 +94,13 @@ common:
# Save test results as artifacts
- store_artifacts:
path: ui.tests/test-module/target
- run:
name: Move .cy.json files to target directory of cypress
command: |
mkdir -p ui.tests/test-module/target/cy-json
find ui.tests/test-module -name "*.cy.json" -exec mv {} ui.tests/test-module/target/cy-json/ \;
- store_artifacts:
path: ui.tests/test-module/target/cy-json
# Save AEM logs as artifacts
- store_artifacts:
path: logs
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -67,3 +67,6 @@ ui.tests/test-module/reports
ui.tests/test-module/cypress

.java-version

# Ignore Cypress runtime JSON files
ui.tests/test-module/**/*.cy.json
2 changes: 0 additions & 2 deletions VERSIONS.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ See below for a full list of minimum system requirements for historical versions
| 1.1.48 | 2.24.6 | 6.5.20+ | 8, 11 | 3.3.9+ |
| 1.1.46 | 2.24.6 | 6.5.20+ | 8, 11 | 3.3.9+ |
| 1.1.40 | 2.24.4 | 6.5.20+ | 8, 11 | 3.3.9+ |
| 1.1.39-enumB004 | 2.24.6 | 6.5.20+ | 8, 11 | 3.3.9+ |
| 1.1.39-enumB010 | 2.24.6 | 6.5.20+ | 8, 11 | 3.3.9+ |
| 1.1.38 | 2.24.2 | 6.5.20+ | 8, 11 | 3.3.9+ |
| 1.1.36 | 2.24.2 | 6.5.20+ | 8, 11 | 3.3.9+ |
| 1.1.34 | 2.24.2 | 6.5.18+ | 8, 11 | 3.3.9+ |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -238,3 +238,39 @@ function customMessageUsingInvalidApi(field, globals) {
globals.functions.setProperty(field, {valid : true});
}
}


/**
* updatePanelLabel
* @name updatePanelLabel
* @param {object} repeatablePanel
* @param {scope} globals
*/
function updatePanelLabel(repeatablePanel, globals) {
var label = globals.field.who_lives_name.$label.value;//field is current field
var panelLabel = globals.field.$label.value;
var currentIndex = globals.field.$index; // to prevent unnecessary dom update

globals.functions.setProperty(globals.field,{label : {"value" : panelLabel + (globals.field.$index+1)}}); // on initialize panel label not working right now, will be fixed soon
globals.functions.setProperty(globals.field.who_lives_name,{label : {"value" : label+"<b>"+(globals.field.$index+1)+"</b>"}});
// walk through other instances and update their label
repeatablePanel.$parent.forEach(panel => {
if (currentIndex != panel.$index) {
globals.functions.setProperty(panel,{label : {"value" : panelLabel + (panel.$index+1)}});
globals.functions.setProperty(panel.who_lives_name,{label : {"value" : label+"<b>"+(panel.$index+1)+"</b>"}});
}
});
}



/**
* Tests add instance with dispatchEvent
* @name addPanelInstance
* @param {object} panel
* @param {scope} globals
*/
function addPanelInstance(panel,globals)
{
globals.functions.dispatchEvent(panel,'addInstance', globals.field.$parent.$index + 1);
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
<!--/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~ Copyright 2022 Adobe
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/-->

<div class="form"
data-sly-use.container="com.adobe.cq.forms.core.components.models.form.FormContainer"
data-sly-use.formstructparser="com.adobe.cq.forms.core.components.models.form.FormStructureParser"
data-sly-use.formUtil="com.adobe.cq.forms.core.components.models.form.HtlUtil"
data-sly-test.isEdgeDeliveryRequest="${formUtil.edgeDeliveryRequest}">
<div>
<div>
<pre>
<code>"${formstructparser.formDefinition @ context='jsonString'}"</code>
</pre>
</div>
</div>
</div>
<sly data-sly-test="${!isEdgeDeliveryRequest}">
<sly data-sly-test="${wcmmode.edit}" data-sly-use.allowed="com.day.cq.wcm.foundation.AllowedComponentList"></sly>

<form data-sly-use.configurationProvider="com.adobe.cq.forms.core.components.models.form.FormConfigurationProvider"
role="${container.roleAttribute}"
autocomplete="off"
data-sly-use.grid="com.day.cq.wcm.foundation.model.responsivegrid.ResponsiveGrid"
data-sly-use.templates="core/wcm/components/commons/v1/templates.html"
action="${container.metadata.action}"
id="${container.id}"
data-cmp-is="adaptiveFormContainer"
data-cmp-context-path="${request.contextPath}"
data-cmp-page-lang="${container.containingPageLang}"
data-cmp-path="${resource.path}"
class="cmp-adaptiveform-container cmp-container ${wcmmode.edit ? 'cmp-adaptiveform-container--edit' : ''}"
data-cmp-custom-functions-module-url="${configurationProvider.customFunctionModuleUrl}"
dir="${container.languageDirection}"
method="post">

<sly data-sly-test.isAllowedApplicable="${allowed.isApplicable}"
data-sly-use.allowedTemplate="allowedcomponents.html"
data-sly-call="${allowedTemplate.allowedcomponents @ title=allowed.title, components=allowed.components}"></sly>
<input type="hidden" name=":formstart" value="${resource.path}"/>
<input type="hidden" name="_charset_" value="utf-8"/>
<input data-sly-test="${container.redirectUrl}" type="hidden" name=":redirect" value="${container.redirectUrl}"/>
<div id="${container.id}-wrapper"
class="cmp-adaptiveform-container__wrapper ${grid.cssClass} ${allowed.cssClass}">
<sly data-sly-test="${!isAllowedApplicable}" data-sly-repeat.paragraph="${grid.paragraphs}"
data-sly-resource="${paragraph.path @ resourceType=paragraph.resourceType, decorationTagName='div', cssClassName=paragraph.cssClass}"></sly>
<sly data-sly-resource="${resource.path @ resourceType='wcm/foundation/components/responsivegrid/new', appendPath='/*', decorationTagName='div', cssClassName='new section aem-Grid-newComponent'}"
data-sly-test="${!isAllowedApplicable && (wcmmode.edit || wcmmode.preview)}"></sly>
<sly data-sly-use="${'removeattribute.js' @ referencedPage }"/>
</div>
</form>
<div data-cmp-adaptiveform-container-loader="${container.id}"></div>
</sly>
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<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"
jcr:primaryType="dam:Asset">
<jcr:content
cq:conf="\0"
jcr:lastModified="{Date}2024-09-12T05:06:37.740Z"
jcr:primaryType="dam:AssetContent"
sling:resourceType="fd/fm/af/render"
guide="1"
type="guide">
<metadata
fd:version="2.1"
jcr:language="en"
jcr:primaryType="nt:unstructured"
xmp:CreatorTool="AEM Forms AF Wizard"
allowedRenderFormat="HTML"
author="admin"
dorType="none"
formmodel="none"
themeRef="/libs/fd/af/themes/canvas"
title="RepeatedPanelCountAndUpdateLabel"/>
</jcr:content>
</jcr:root>
Original file line number Diff line number Diff line change
@@ -1,35 +1,48 @@
<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:nt="http://www.jcp.org/jcr/nt/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"
jcr:primaryType="cq:Page">
jcr:primaryType="cq:Page">
<jcr:content
cq:deviceGroups="[mobile/groups/responsive]"
cq:lastModified="{Date}2023-01-09T16:01:24.451+05:30"
cq:lastModifiedBy="admin"
cq:template="/conf/core-components-examples/settings/wcm/templates/af-blank-v2"
jcr:language="en"
jcr:primaryType="cq:PageContent"
jcr:title="Adaptive Form V2 (IT)"
sling:resourceType="forms-components-examples/components/page">
cq:deviceGroups="[mobile/groups/responsive]"
cq:lastModified="{Date}2024-09-10T14:57:01.796+05:30"
cq:lastModifiedBy="admin"
cq:template="/conf/core-components-examples/settings/wcm/templates/af-blank-v2"
jcr:language="en"
jcr:primaryType="cq:PageContent"
jcr:title="Adaptive Form V2 (IT)"
sling:resourceType="forms-components-examples/components/page">
<guideContainer
fd:version="2.1"
jcr:primaryType="nt:unstructured"
sling:resourceType="forms-components-examples/components/form/container"
dorType="none"
themeRef="/libs/fd/af/themes/canvas"
fieldType="form">
fd:version="2.1"
jcr:primaryType="nt:unstructured"
sling:resourceType="forms-components-examples/components/form/container"
dorType="none"
fieldType="form"
themeRef="/libs/fd/af/themes/canvas">
<fragment
jcr:lastModified="{Date}2023-06-02T12:34:24.990+05:30"
jcr:lastModifiedBy="admin"
jcr:primaryType="nt:unstructured"
jcr:title="Fragment"
sling:resourceType="forms-components-examples/components/form/fragment"
fieldType="panel"
fragmentPath="/content/forms/af/core-components-it/samples/fragment/test-fragment"
maxOccur="4"
minOccur="0"
name="fragment1685689465369"
repeatable="{Boolean}true"
wrapData="{Boolean}true"/>
<fragment1
jcr:lastModified="{Date}2023-06-02T12:34:24.990+05:30"
jcr:lastModifiedBy="admin"
jcr:primaryType="nt:unstructured"
jcr:title="Fragment"
jcr:title="Fragment 1"
sling:resourceType="forms-components-examples/components/form/fragment"
fieldType="panel"
fragmentPath="/content/forms/af/core-components-it/samples/fragment/test-fragment"
repeatable="{Boolean}true"
maxOccur="4"
minOccur="0"
name="fragment1685689465369"
name="fragment16856894653691"
repeatable="{Boolean}true"
wrapData="{Boolean}true"/>
</guideContainer>
</jcr:content>
</jcr:root>
</jcr:root>
56 changes: 43 additions & 13 deletions .../jcr_root/content/forms/af/core-components-it/samples/fragment/test-fragment/.content.xml
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
jcr:primaryType="cq:Page">
<jcr:content
cq:deviceGroups="[/etc/mobile/groups/responsive]"
cq:lastModified="{Date}2023-06-02T12:27:19.297+05:30"
cq:lastModified="{Date}2024-09-10T15:11:58.094+05:30"
cq:lastModifiedBy="admin"
cq:template="/conf/core-components-examples/settings/wcm/templates/af-blank-v2"
jcr:language="en"
Expand All @@ -12,15 +12,15 @@
sling:configRef="/conf/forms/core-components-it/af-v2-test/"
sling:resourceType="forms-components-examples/components/page">
<guideContainer
fd:version="2.1"
fd:type="fragment"
fd:version="2.1"
jcr:primaryType="nt:unstructured"
sling:resourceType="forms-components-examples/components/form/fragmentcontainer"
clientLibRef="x.y"
dorType="none"
fieldType="form"
thankYouOption="page"
themeRef="/libs/fd/af/themes/canvas"
clientLibRef="x.y"
title="AF Fragment (v2)">
<textinput
jcr:lastModified="{Date}2023-06-02T12:27:19.294+05:30"
Expand All @@ -31,20 +31,50 @@
fieldType="text-input"
name="fragmenttextinput"/>
<textinput1
jcr:created="{Date}2024-05-08T20:17:24.203+05:30"
jcr:lastModified="{Date}2024-05-08T20:17:24.203+05:30"
jcr:primaryType="nt:unstructured"
jcr:title="Responsive Text Input"
sling:resourceType="forms-components-examples/components/form/textinput"
fieldType="text-input"
name="textinput1715179644273">
jcr:created="{Date}2024-05-08T20:17:24.203+05:30"
jcr:lastModified="{Date}2024-05-08T20:17:24.203+05:30"
jcr:primaryType="nt:unstructured"
jcr:title="Responsive Text Input"
sling:resourceType="forms-components-examples/components/form/textinput"
fieldType="text-input"
name="textinput1715179644273">
<cq:responsive jcr:primaryType="nt:unstructured">
<default
jcr:primaryType="nt:unstructured"
offset="1"
width="9"/>
jcr:primaryType="nt:unstructured"
offset="1"
width="9"/>
</cq:responsive>
<fd:rules
fd:calc="[{&quot;nodeName&quot;:&quot;ROOT&quot;\,&quot;items&quot;:[{&quot;nodeName&quot;:&quot;STATEMENT&quot;\,&quot;choice&quot;:{&quot;nodeName&quot;:&quot;CALC_EXPRESSION&quot;\,&quot;items&quot;:[{&quot;nodeName&quot;:&quot;VALUE_FIELD&quot;\,&quot;value&quot;:{&quot;id&quot;:&quot;$form.textinput1715179644273&quot;\,&quot;type&quot;:&quot;STRING&quot;\,&quot;name&quot;:&quot;textinput1715179644273&quot;}}\,{&quot;nodeName&quot;:&quot;to&quot;\,&quot;value&quot;:null}\,{&quot;nodeName&quot;:&quot;EXPRESSION&quot;\,&quot;choice&quot;:{&quot;nodeName&quot;:&quot;COMPONENT&quot;\,&quot;value&quot;:{&quot;id&quot;:&quot;$form.fragmenttextinput&quot;\,&quot;displayName&quot;:&quot;Text Input&quot;\,&quot;type&quot;:&quot;STRING&quot;\,&quot;displayPath&quot;:&quot;FORM/Text Input/&quot;\,&quot;name&quot;:&quot;fragmenttextinput&quot;\,&quot;parent&quot;:&quot;$form&quot;}}}\,{&quot;nodeName&quot;:&quot;When&quot;\,&quot;value&quot;:null}\,{&quot;nodeName&quot;:&quot;CONDITIONORALWAYS&quot;\,&quot;choice&quot;:null}]}}]\,&quot;isValid&quot;:true\,&quot;enabled&quot;:true\,&quot;version&quot;:1\,&quot;script&quot;:&quot;fragmenttextinput.$value&quot;\,&quot;eventName&quot;:&quot;Calculate&quot;\,&quot;ruleType&quot;:&quot;&quot;\,&quot;description&quot;:&quot;&quot;}]"
fd:valueCommit="[{&quot;nodeName&quot;:&quot;ROOT&quot;\,&quot;items&quot;:[{&quot;nodeName&quot;:&quot;STATEMENT&quot;\,&quot;choice&quot;:{&quot;nodeName&quot;:&quot;EVENT_SCRIPTS&quot;\,&quot;items&quot;:[{&quot;nodeName&quot;:&quot;EVENT_CONDITION&quot;\,&quot;choice&quot;:{&quot;nodeName&quot;:&quot;EVENT_AND_COMPARISON&quot;\,&quot;items&quot;:[{&quot;nodeName&quot;:&quot;COMPONENT&quot;\,&quot;value&quot;:{&quot;id&quot;:&quot;$form.textinput1715179644273&quot;\,&quot;type&quot;:&quot;STRING&quot;\,&quot;name&quot;:&quot;textinput1715179644273&quot;}}\,{&quot;nodeName&quot;:&quot;EVENT_AND_COMPARISON_OPERATOR&quot;\,&quot;choice&quot;:{&quot;nodeName&quot;:&quot;is changed&quot;\,&quot;value&quot;:null}}\,{&quot;nodeName&quot;:&quot;PRIMITIVE_EXPRESSION&quot;\,&quot;choice&quot;:{&quot;nodeName&quot;:&quot;STRING_LITERAL&quot;\,&quot;value&quot;:null}}]}\,&quot;nested&quot;:false}\,{&quot;nodeName&quot;:&quot;Then&quot;\,&quot;value&quot;:null}\,{&quot;nodeName&quot;:&quot;BLOCK_STATEMENTS&quot;\,&quot;items&quot;:[{&quot;nodeName&quot;:&quot;BLOCK_STATEMENT&quot;\,&quot;choice&quot;:{&quot;nodeName&quot;:&quot;SET_VALUE_STATEMENT&quot;\,&quot;items&quot;:[{&quot;nodeName&quot;:&quot;VALUE_FIELD&quot;\,&quot;value&quot;:{&quot;id&quot;:&quot;$form.panelcontainer1725960550534.text1725960554387&quot;\,&quot;displayName&quot;:&quot;text1725960554387&quot;\,&quot;type&quot;:&quot;STRING&quot;\,&quot;displayPath&quot;:&quot;FORM/Panel/text1725960554387/&quot;\,&quot;name&quot;:&quot;text1725960554387&quot;\,&quot;parent&quot;:&quot;$form.panelcontainer1725960550534&quot;}}\,{&quot;nodeName&quot;:&quot;to&quot;\,&quot;value&quot;:null}\,{&quot;nodeName&quot;:&quot;EXPRESSION&quot;\,&quot;choice&quot;:{&quot;nodeName&quot;:&quot;STRING_LITERAL&quot;\,&quot;value&quot;:&quot;Thanks&quot;}}]}}]}]}}]\,&quot;isValid&quot;:true\,&quot;enabled&quot;:true\,&quot;version&quot;:1\,&quot;script&quot;:[&quot;dispatchEvent($form.panelcontainer1725960550534.text1725960554387\, 'custom:setProperty'\, {value : 'Thanks'})&quot;]\,&quot;eventName&quot;:&quot;Value Commit&quot;\,&quot;ruleType&quot;:&quot;&quot;\,&quot;description&quot;:&quot;&quot;}]"
jcr:primaryType="nt:unstructured"
validationStatus="valid"
value="fragmenttextinput.$value"/>
<fd:events
jcr:primaryType="nt:unstructured"
change="[if(contains($event.payload.changes[].propertyName\, 'value')\, dispatchEvent($form.panelcontainer1725960550534.text1725960554387\, 'custom:setProperty'\, {value : 'Thanks'})\, {})]"/>
</textinput1>
<panelcontainer
jcr:created="{Date}2024-09-10T14:59:10.484+05:30"
jcr:createdBy="admin"
jcr:lastModified="{Date}2024-09-10T14:59:10.484+05:30"
jcr:lastModifiedBy="admin"
jcr:primaryType="nt:unstructured"
jcr:title="Panel"
sling:resourceType="forms-components-examples/components/form/panelcontainer"
fieldType="panel"
name="panelcontainer1725960550534">
<text
jcr:created="{Date}2024-09-10T14:59:14.338+05:30"
jcr:createdBy="admin"
jcr:lastModified="{Date}2024-09-10T14:59:14.338+05:30"
jcr:lastModifiedBy="admin"
jcr:primaryType="nt:unstructured"
jcr:title="Text"
sling:resourceType="forms-components-examples/components/form/text"
fieldType="plain-text"
name="text1725960554387"/>
</panelcontainer>
</guideContainer>
</jcr:content>
</jcr:root>
Loading