Skip to content

Commit

Permalink
Merge branch 'release/6.1.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
markdaugherty committed Dec 13, 2018
2 parents 434fa94 + d18a2f4 commit 78953f5
Show file tree
Hide file tree
Showing 10 changed files with 142 additions and 94 deletions.
2 changes: 1 addition & 1 deletion cq-component-annotations/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>com.citytechinc.cq.cq-component-plugin</groupId>
<artifactId>cq-component-plugin</artifactId>
<version>6.0.0</version>
<version>6.1.0</version>
</parent>

<artifactId>cq-component-annotations</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,10 @@ public final TouchUIDialogElement make() throws ClassNotFoundException, InvalidC
parameters.setAdditionalProperties(getAdditionalPropertiesForField());
parameters.setShowOnCreate(getShowOnCreateForField());
parameters.setHideOnEdit(getHideOnEditForField());
parameters.setOrderBefore(getOrderBefore());

if (StringUtils.isNotEmpty(getOrderBefore())) {
parameters.setOrderBefore(getOrderBefore());
}

return make(parameters);

Expand Down
2 changes: 1 addition & 1 deletion cq-component-maven-plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>com.citytechinc.cq.cq-component-plugin</groupId>
<artifactId>cq-component-plugin</artifactId>
<version>6.0.0</version>
<version>6.1.0</version>
</parent>

<artifactId>cq-component-maven-plugin</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import com.citytechinc.cq.component.annotations.Component;
import com.citytechinc.cq.component.annotations.DialogField;
import com.citytechinc.cq.component.annotations.HideDialogField;
import com.citytechinc.cq.component.annotations.IgnoreDialogField;
import com.citytechinc.cq.component.annotations.Listener;
import com.citytechinc.cq.component.dialog.Dialog;
Expand Down Expand Up @@ -121,6 +122,10 @@ public static Dialog make(CtClass componentClass, WidgetRegistry widgetRegistry,
if (member.hasAnnotation(DialogField.class)) {
dialogFieldConfig =
new DialogFieldConfig((DialogField) member.getAnnotation(DialogField.class), member);

if (member.hasAnnotation(HideDialogField.class)) {
dialogFieldConfig.setHideDialogField(true);
}
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,10 @@ public static DialogFieldConfig getDialogFieldFromSuperClasses(CtMethod method)
dialogFieldConfig =
new DialogFieldConfig((DialogField) superClassMethod.getAnnotation(DialogField.class),
superClassMethod);

if (superClassMethod.hasAnnotation(HideDialogField.class)) {
dialogFieldConfig.setHideDialogField(true);
}
} else if (superClassMethod.hasAnnotation(DialogFieldOverride.class)) {
mergeDialogFields(dialogFieldConfig, superClassMethod);
//TODO: Evaluate if we want to allow overriding of an already hidden field
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import com.citytechinc.cq.component.annotations.Component;
import com.citytechinc.cq.component.annotations.DialogField;
import com.citytechinc.cq.component.annotations.HideDialogField;
import com.citytechinc.cq.component.annotations.IgnoreDialogField;
import com.citytechinc.cq.component.annotations.widgets.Selection;
import com.citytechinc.cq.component.dialog.ComponentNameTransformer;
Expand Down Expand Up @@ -116,12 +117,17 @@ public static List<TouchUIWidgetMakerParameters> getWidgetMakerParametersForComp
for (CtMember member : fieldsAndMethods) {
if (!member.hasAnnotation(IgnoreDialogField.class)) {
DialogFieldConfig dialogFieldConfig = null;

if (member instanceof CtMethod) {
dialogFieldConfig = DialogUtil.getDialogFieldFromSuperClasses((CtMethod) member);
} else {
if (member.hasAnnotation(DialogField.class)) {
dialogFieldConfig =
new DialogFieldConfig((DialogField) member.getAnnotation(DialogField.class), member);

if (member.hasAnnotation(HideDialogField.class)) {
dialogFieldConfig.setHideDialogField(true);
}
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,15 +36,15 @@ public static TouchUIDialogElement make(TouchUIWidgetMakerParameters widgetMaker
}

public static TouchUIWidgetMakerContext getWidgetMakerForMemberParameters(TouchUIWidgetMakerParameters parameters,
int rankingCeiling) throws InvalidComponentFieldException {
TouchUIWidgetConfigHolder widgetConfig = getWidgetConfigForParameters(parameters, rankingCeiling);

int rankingCeiling) {
// If the widget is intended to be hidden by an inheriting component dialog
// use the HideDialogFieldWidgetMaker
if (widgetConfig != null && parameters.getDialogFieldConfig().isHideDialogField()) {
if (parameters.getDialogFieldConfig().isHideDialogField()) {
return new TouchUIWidgetMakerContext(HideDialogFieldWidgetMaker.class, "");
}

TouchUIWidgetConfigHolder widgetConfig = getWidgetConfigForParameters(parameters, rankingCeiling);

// If we were able to lookup a widget configuration with a valid maker
// class return it
if (widgetConfig != null && widgetConfig.getMakerClass() != null) {
Expand Down
45 changes: 32 additions & 13 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<groupId>com.citytechinc.cq.cq-component-plugin</groupId>
<artifactId>cq-component-plugin</artifactId>
<packaging>pom</packaging>
<version>6.0.0</version>
<version>6.1.0</version>
<name>CQ Component Plugin</name>
<description>Plugin enabling annotation driven CQ5 Component development.</description>

Expand Down Expand Up @@ -42,9 +42,9 @@
</licenses>

<scm>
<connection>scm:git:[email protected]:Citytechinc/cq-component-maven-plugin.git</connection>
<url>https://github.com/Citytechinc/cq-component-maven-plugin</url>
<developerConnection>scm:git:[email protected]:Citytechinc/cq-component-maven-plugin.git</developerConnection>
<connection>scm:git:[email protected]:OlsonDigital/cq-component-maven-plugin.git</connection>
<url>https://github.com/OlsonDigital/cq-component-maven-plugin</url>
<developerConnection>scm:git:[email protected]:OlsonDigital/cq-component-maven-plugin.git</developerConnection>
</scm>

<distributionManagement>
Expand Down Expand Up @@ -77,6 +77,18 @@
</properties>

<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>versions-maven-plugin</artifactId>
<version>2.2</version>
<configuration>
<generateBackupPoms>false</generateBackupPoms>
</configuration>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
Expand Down Expand Up @@ -149,15 +161,6 @@
</dependency>
</dependencies>
<configuration>
<reportPlugins>
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.9.1</version>
<configuration>
<aggregate>true</aggregate>
</configuration>
</plugin>
</reportPlugins>
<skipDeploy>true</skipDeploy>
</configuration>
</plugin>
Expand All @@ -181,6 +184,22 @@
</plugins>
</build>

<reporting>
<plugins>
<plugin>
<artifactId>maven-project-info-reports-plugin</artifactId>
<version>2.8</version>
</plugin>
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.9.1</version>
<configuration>
<aggregate>true</aggregate>
</configuration>
</plugin>
</plugins>
</reporting>

<profiles>
<profile>
<id>github-site</id>
Expand Down
2 changes: 1 addition & 1 deletion src/site/markdown/index.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
##Introduction

The CQ Component Plugin mitigates the effort required in Adobe CQ component development by generating, at built time, .content.xml, _cq_editConfig.xml, _cq_dialog.xml, and dialog.xml files for your components, leaving you free to focus on functionality.
The CQ Component Plugin mitigates the effort required in Adobe CQ component development by generating, at build time, .content.xml, _cq_editConfig.xml, _cq_dialog.xml, and dialog.xml files for your components, leaving you free to focus on functionality.

##Motivations

Expand Down
157 changes: 84 additions & 73 deletions src/site/site.xml
Original file line number Diff line number Diff line change
@@ -1,81 +1,92 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/DECORATION/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/DECORATION/1.3.0 http://maven.apache.org/xsd/decoration-1.3.0.xsd">
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>

<skin>
<groupId>com.icfolson.maven</groupId>
<artifactId>icfolson-maven-skin</artifactId>
<version>1.0.0</version>
</skin>
<skin>
<groupId>com.icfolson.maven</groupId>
<artifactId>icfolson-maven-skin</artifactId>
<version>1.1.0</version>
</skin>

<bannerRight>
<name>CQ Component Plugin</name>
<href>index.html</href>
</bannerRight>
<bannerRight>
<name>CQ Component Plugin</name>
<href>index.html</href>
</bannerRight>

<googleAnalyticsAccountId>UA-928005-4</googleAnalyticsAccountId>
<googleAnalyticsAccountId>UA-928005-4</googleAnalyticsAccountId>

<custom>
<reflowSkin>
<skinAttribution>false</skinAttribution>
<!-- Make this to 'false' for local development, i.e. file:// URLs -->
<protocolRelativeURLs>false</protocolRelativeURLs>
<smoothScroll>true</smoothScroll>
<titleTemplate>%2$s | %1$s</titleTemplate>
<highlightJs>true</highlightJs>
<highlightJsTheme>github</highlightJsTheme>
<brand>
<name>
CQ Component Plugin
</name>
<href>index.html</href>
</brand>
<slogan>A Plugin for CQ Components!</slogan>
<toc>sidebar</toc>
<topNav>Basics|Extending</topNav>
<body />
<pages>
<index project="cq-component-plugin">
<titleTemplate>CQ Component Plugin</titleTemplate>
<breadcrumbs>false</breadcrumbs>
<toc>false</toc>
<markPageHeader>false</markPageHeader>
<sections>
<columns>1</columns>
<body />
</sections>
</index>
</pages>
<bottomNav maxSpan="9">
<column>Main</column>
<column>Basics</column>
<column>Extending</column>
</bottomNav>
</reflowSkin>
</custom>
<custom>
<reflowSkin>
<skinAttribution>false</skinAttribution>
<!-- Make this to 'false' for local development, i.e. file:// URLs -->
<protocolRelativeURLs>false</protocolRelativeURLs>
<smoothScroll>true</smoothScroll>
<titleTemplate>%2$s | %1$s</titleTemplate>
<highlightJs>true</highlightJs>
<highlightJsTheme>github</highlightJsTheme>
<brand>
<name>
CQ Component Plugin
</name>
<href>index.html</href>
</brand>
<slogan>A plugin for generating AEM component configuration files from annotated Java classes.</slogan>
<toc>sidebar</toc>
<topNav>Basics|Extending</topNav>
<body/>
<pages>
<index project="cq-component-plugin">
<titleTemplate>CQ Component Plugin</titleTemplate>
<breadcrumbs>false</breadcrumbs>
<toc>false</toc>
<markPageHeader>false</markPageHeader>
<sections>
<columns>1</columns>
<body/>
</sections>
</index>
</pages>
<bottomNav maxSpan="9">
<column>Main</column>
<column>Basics</column>
<column>Extending</column>
</bottomNav>
</reflowSkin>
</custom>

<body>
<links>
<item name="GitHub"
href="https://github.com/Citytechinc/cq-component-maven-plugin/" />
</links>
<menu name="Main" inherit="top">
<item name="Home" href="index.html" />
<item name="GitHub"
href="https://github.com/Citytechinc/cq-component-maven-plugin/" />
<item name="Java Doc" href="apidocs/index.html" />
<item name="ICF Olson" href="http://www.icfolson.com" />
</menu>
<menu name="Basics" inherit="bottom">
<item name="Configuration" href="configuration.html" />
<item name="Usage" href="usage.html" />
<item name="Additional Features" href="additional-features.html" />
</menu>
<menu name="Extending" inherit="bottom">
<item name="Adding a Widget" href="adding-a-widget.html" />
<item name="Adding a Transformer" href="adding-a-transformer.html" />
</menu>
<footer></footer>
</body>
<body>
<links>
<item name="GitHub"
href="https://github.com/OlsonDigital/cq-component-maven-plugin/"/>
</links>
<menu name="Main"
inherit="top">
<item name="Home"
href="index.html"/>
<item name="GitHub"
href="https://github.com/OlsonDigital/cq-component-maven-plugin/"/>
<item name="Javadocs"
href="apidocs/index.html"/>
<item name="ICF Olson"
href="http://www.icfolson.com"/>
</menu>
<menu name="Basics"
inherit="bottom">
<item name="Configuration"
href="configuration.html"/>
<item name="Usage"
href="usage.html"/>
<item name="Additional Features"
href="additional-features.html"/>
</menu>
<menu name="Extending"
inherit="bottom">
<item name="Adding a Widget"
href="adding-a-widget.html"/>
<item name="Adding a Transformer"
href="adding-a-transformer.html"/>
</menu>
<footer></footer>
</body>
</project>

0 comments on commit 78953f5

Please sign in to comment.