Skip to content

Commit

Permalink
Changes for forms core components
Browse files Browse the repository at this point in the history
* adding core dependencies in all
* proxy components for wizard and title
* using the same proxy formcontainer as headless for v2 container
* updating versions of wcm and forms components
* review comments: changing cmp group, added formscommunicationportal components
* upgrade wcm examples if forms included, review comments closed
* Update thumbnails for af2
* include core components if includeForms, use headless flag to only include headless spa
* check for cloud version
* check for headless for react clientlibs
* template changes on par with core components it
* separate  adaptive form and portal components
* adaptive form submit button
* associate af v2 canvas theme with template
* include core components in cloud only
*  update adaptive form json path
*  remove unnecessary versioning & redundant names for proxy components

Related AEM issue: CQ-4348367

Co-authored-by: barshatr <barshatr@adobe.com>
Co-authored-by: Vlad <vlad@bailescu.ro>
Co-authored-by: Rishi Mehta <69448117+rismehta@users.noreply.github.com>
  • Loading branch information
4 people committed Jan 16, 2023
1 parent ebfcdd9 commit 0867f0a
Show file tree
Hide file tree
Showing 65 changed files with 601 additions and 148 deletions.
73 changes: 43 additions & 30 deletions src/main/archetype/all/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -174,32 +174,32 @@
<target>/apps/${appId}-vendor-packages/application/install</target>
</embedded>
#end
#if ( ($includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y") and $aemVersion != "cloud" )
#if ( ($includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y") and $aemVersion == "cloud")
<embedded>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-apps</artifactId>
<artifactId>core-forms-components-af-apps</artifactId>
<type>zip</type>
<target>/apps/${appId}-vendor-packages/application/install</target>
</embedded>
<embedded>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-core</artifactId>
<target>/apps/${appId}-vendor-packages/application/install</target>
</embedded>
#end
#if ( $includeExamples == "y" and ( ($includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y") and $aemVersion == "cloud" ) )
<embedded>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-examples-apps</artifactId>
<type>zip</type>
<target>/apps/${appId}-vendor-packages/application/install</target>
</embedded>
<embedded>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-examples-content</artifactId>
<type>zip</type>
<artifactId>core-forms-components-af-core</artifactId>
<target>/apps/${appId}-vendor-packages/application/install</target>
</embedded>
#if ($includeExamples == "y")
<embedded>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-examples-apps</artifactId>
<type>zip</type>
<target>/apps/${appId}-vendor-packages/application/install</target>
</embedded>
<embedded>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-examples-content</artifactId>
<type>zip</type>
<target>/apps/${appId}-vendor-packages/application/install</target>
</embedded>
#end
#end
</embeddeds>
</configuration>
Expand Down Expand Up @@ -396,13 +396,38 @@
<type>zip</type>
</dependency>
#end
#if ( ($includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y") and $aemVersion != "cloud" )
#if ( ($includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y") and $aemVersion == "cloud" )
<!-- AEM Forms Dependencies -->
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-apps</artifactId>
<type>zip</type>
</dependency>
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-core</artifactId>
</dependency>
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-af-apps</artifactId>
<type>zip</type>
</dependency>
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-af-core</artifactId>
</dependency>
#if ($includeExamples == "y")
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-examples-apps</artifactId>
<type>zip</type>
</dependency>
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-examples-content</artifactId>
<type>zip</type>
</dependency>
#end
#end
#if ( $includeExamples == "y" )
<dependency>
Expand All @@ -420,18 +445,6 @@
<artifactId>core.wcm.components.examples.ui.content</artifactId>
<type>zip</type>
</dependency>
#end
#if ( $includeExamples == "y" and ( ($includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y") and $aemVersion == "cloud" ) )
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-examples-apps</artifactId>
<type>zip</type>
</dependency>
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-examples-content</artifactId>
<type>zip</type>
</dependency>
#end
</dependencies>
</project>
8 changes: 5 additions & 3 deletions src/main/archetype/core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -198,18 +198,20 @@ Import-Package: javax.annotation;version=0.0.0,*
</dependency>
#end

#if ($includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y")
#if ( ($includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y") and $aemVersion == "cloud")
<!-- AEM Forms Dependencies -->
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>aem-forms-sdk-api</artifactId>
</dependency>
#if ($aemVersion != "cloud")
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-core</artifactId>
</dependency>
#end
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-af-core</artifactId>
</dependency>
#end
<!-- Testing -->
<dependency>
Expand Down
23 changes: 20 additions & 3 deletions src/main/archetype/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -74,15 +74,20 @@
<aio.runtime.namespace>${env.AIO_RUNTIME_NAMESPACE}</aio.runtime.namespace>
<aio.runtime.auth>${env.AIO_RUNTIME_AUTH}</aio.runtime.auth>
#end
#if ( $includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y" )
<core.wcm.components.version>2.21.2</core.wcm.components.version>
#else
<core.wcm.components.version>2.19.0</core.wcm.components.version>
#end
#if ( $includeCommerce == "y" )
<core.cif.components.version>2.12.0</core.cif.components.version>
<magento.graphql.version>9.1.0-magento242ee</magento.graphql.version>
<aem.cif.sdk.api>2022.08.02.00</aem.cif.sdk.api>
#end

#if ( ($includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y") and $aemVersion == "cloud" )
<core.forms.components.version>1.0.14</core.forms.components.version>
<core.forms.components.version>1.0.56</core.forms.components.version>
<core.forms.components.af.version>1.0.56</core.forms.components.af.version>
<aem.forms.sdk.api>SDK_FORMS_VERSION</aem.forms.sdk.api>
#end
<bnd.version>5.1.2</bnd.version>
Expand Down Expand Up @@ -877,8 +882,19 @@ Bundle-DocURL:
<artifactId>core-forms-components-core</artifactId>
<version>${core.forms.components.version}</version>
</dependency>
#end
#if ( $includeExamples == "y" and ( ($includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y") and $aemVersion == "cloud" ) )
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-af-apps</artifactId>
<type>zip</type>
<version>${core.forms.components.af.version}</version>
</dependency>
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-af-core</artifactId>
<version>${core.forms.components.af.version}</version>
</dependency>

#if ($includeExamples == "y")
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-examples-apps</artifactId>
Expand All @@ -891,6 +907,7 @@ Bundle-DocURL:
<type>zip</type>
<version>${core.forms.components.version}</version>
</dependency>
#end
#end

#if ( $isSpaProject )
Expand Down
37 changes: 19 additions & 18 deletions src/main/archetype/ui.apps/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -83,12 +83,6 @@
<groupId>com.adobe.commerce.cif</groupId>
<artifactId>core-cif-components-apps</artifactId>
</dependency>
#end
#if ( ($includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y") and $aemVersion != "cloud" )
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-apps</artifactId>
</dependency>
#end
</dependencies>
</configuration>
Expand Down Expand Up @@ -326,23 +320,30 @@ Require-Capability: osgi.extender;filter:="(&(osgi.extender=sling.scripting)(ver
<scope>provided</scope>
</dependency>
#end
#if ($includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y")
#if ( ($includeForms == "y" or $includeFormsenrollment == "y" or $includeFormscommunications == "y" or $includeFormsheadless == "y") and $aemVersion == "cloud")
<!-- AEM Forms Dependencies -->
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>aem-forms-sdk-api</artifactId>
</dependency>
#if ($aemVersion != "cloud")
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-apps</artifactId>
<type>zip</type>
</dependency>
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-core</artifactId>
</dependency>
#end
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-apps</artifactId>
<type>zip</type>
</dependency>
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-core</artifactId>
</dependency>
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-af-apps</artifactId>
<type>zip</type>
</dependency>
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>core-forms-components-af-core</artifactId>
</dependency>
#end
<!-- HTL dependencies needed for the HTL Maven Plugin source code generation -->
<dependency>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<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"
jcr:description="Adaptive Form Accordion (v1) component"
jcr:primaryType="cq:Component"
jcr:title="Adaptive Form Accordion"
sling:resourceSuperType="core/fd/components/form/accordion/v1/accordion"
componentGroup="${appTitle} - Adaptive Form"/>
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:nt="http://www.jcp.org/jcr/nt/1.0" xmlns:cq="http://www.day.com/jcr/cq/1.0"
xmlns:jcr="http://www.jcp.org/jcr/1.0" jcr:primaryType="nt:unstructured"
fieldType="panel"
jcr:title="Accordion"/>

Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<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"
cq:icon="publish"
jcr:primaryType="cq:Component"
jcr:title="Adaptive Form Submit Button"
jcr:description="Add an interactive button for invoking a Submit action."
sling:resourceSuperType="core/fd/components/form/button/v1/button"
componentGroup="${appTitle} - Adaptive Form"/>
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:fd="http://www.adobe.com/aemfd/fd/1.0" xmlns:nt="http://www.jcp.org/jcr/nt/1.0" xmlns:cq="http://www.day.com/jcr/cq/1.0"
jcr:primaryType="nt:unstructured"
jcr:title="Submit"
fieldType="button"
buttonType="submit"
dorExclusion="true">
<fd:rules
fd:click="[{&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.button1667450213112&quot;\,&quot;type&quot;:&quot;BUTTON&quot;\,&quot;name&quot;:&quot;button1667450213112&quot;}}\,{&quot;nodeName&quot;:&quot;EVENT_AND_COMPARISON_OPERATOR&quot;\,&quot;choice&quot;:{&quot;nodeName&quot;:&quot;is clicked&quot;\,&quot;value&quot;:null}}\,{&quot;nodeName&quot;:&quot;PRIMITIVE_EXPRESSION&quot;\,&quot;choice&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;SUBMIT_FORM&quot;\,&quot;items&quot;:[]}}]}]}}]\,&quot;isValid&quot;:true\,&quot;enabled&quot;:true\,&quot;version&quot;:1\,&quot;script&quot;:[&quot;submitForm('custom:submitSuccess'\, 'custom:submitError')&quot;]\,&quot;eventName&quot;:&quot;Click&quot;\,&quot;ruleType&quot;:&quot;&quot;\,&quot;description&quot;:&quot;&quot;}]"
jcr:primaryType="nt:unstructured"/>
<fd:events
jcr:primaryType="nt:unstructured"
click="[submitForm('custom:submitSuccess'\, 'custom:submitError')]"/>
</jcr:root>
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<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"
jcr:description="Adaptive Form Button (v1) component"
jcr:primaryType="cq:Component"
jcr:title="Adaptive Form Button"
sling:resourceSuperType="core/fd/components/form/button/v1/button"
componentGroup="${appTitle} - Adaptive Form"/>
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?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"
jcr:primaryType="nt:unstructured"
jcr:title="Button"
fieldType="button"/>
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<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"
jcr:description="Adaptive Form Check Box Group (v1) component"
jcr:primaryType="cq:Component"
jcr:title="Adaptive Form Check Box Group"
sling:resourceSuperType="core/fd/components/form/checkboxgroup/v1/checkboxgroup"
componentGroup="${appTitle} - Adaptive Form"/>
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?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"
jcr:primaryType="nt:unstructured"
jcr:title="Check Box Group"
fieldType="checkbox-group"
type="number[]"
enum="[0,1]"
enumNames="[Item 1, Item 2]"/>
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<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"
jcr:description="Adaptive Form Date Picker (v1) component"
jcr:primaryType="cq:Component"
jcr:title="Adaptive Form Date Picker"
sling:resourceSuperType="core/fd/components/form/datepicker/v1/datepicker"
componentGroup="${appTitle} - Adaptive Form"/>
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?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"
jcr:primaryType="nt:unstructured"
jcr:title="Date Input"
fieldType="date-input"/>
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<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"
jcr:description="Adaptive Form Drop-down List (v1) component"
jcr:primaryType="cq:Component"
jcr:title="Adaptive Form Drop-down List"
sling:resourceSuperType="core/fd/components/form/dropdown/v1/dropdown"
componentGroup="${appTitle} - Adaptive Form"/>
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?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"
jcr:primaryType="nt:unstructured"
jcr:title="Dropdown"
fieldType="drop-down"/>
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<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"
jcr:description="Adaptive Form File Attachment (v1) component"
jcr:primaryType="cq:Component"
jcr:title="Adaptive Form File Attachment"
sling:resourceSuperType="core/fd/components/form/fileinput/v1/fileinput"
componentGroup="${appTitle} - Adaptive Form"/>
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?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"
jcr:primaryType="nt:unstructured"
jcr:title="File Attachment"
buttonText="Attach"
fieldType="file-input"
accept="[audio/*, video/*, image/*, text/*, application/pdf]">
</jcr:root>
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<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"
jcr:description="Adaptive Form Footer (v1) component"
jcr:primaryType="cq:Component"
jcr:title="Adaptive Form Footer"
sling:resourceSuperType="core/fd/components/form/footer/v1/footer"
componentGroup="${appTitle} - Adaptive Form"/>
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:granite="http://www.adobe.com/jcr/granite/1.0" xmlns:cq="http://www.day.com/jcr/cq/1.0" xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:nt="http://www.jcp.org/jcr/nt/1.0"
jcr:primaryType="nt:unstructured"
jcr:title="Footer">
<text
jcr:primaryType="nt:unstructured"
jcr:title="Footer"
text="© YYYY Company name | All rights reserved"
css="footerText"
sling:resourceType="wcm/foundation/components/text"/>
</jcr:root>

0 comments on commit 0867f0a

Please sign in to comment.