From 99d35eb118388f11117d8e0dc49b7dd36a777648 Mon Sep 17 00:00:00 2001 From: Mark Daugherty Date: Thu, 13 Dec 2018 07:51:43 -0600 Subject: [PATCH 1/7] updated github urls. --- pom.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pom.xml b/pom.xml index 5e4a060a..8de7161d 100644 --- a/pom.xml +++ b/pom.xml @@ -42,9 +42,9 @@ - scm:git:git@github.com:Citytechinc/cq-component-maven-plugin.git - https://github.com/Citytechinc/cq-component-maven-plugin - scm:git:git@github.com:Citytechinc/cq-component-maven-plugin.git + scm:git:git@github.com:OlsonDigital/cq-component-maven-plugin.git + https://github.com/OlsonDigital/cq-component-maven-plugin + scm:git:git@github.com:OlsonDigital/cq-component-maven-plugin.git From b0bb5aa9c8da83effe2cdaefa6e551dd991c1609 Mon Sep 17 00:00:00 2001 From: Mark Daugherty Date: Thu, 13 Dec 2018 07:51:57 -0600 Subject: [PATCH 2/7] updated maven skin version. --- src/site/site.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/site/site.xml b/src/site/site.xml index 6fadab7e..806d9731 100644 --- a/src/site/site.xml +++ b/src/site/site.xml @@ -6,7 +6,7 @@ com.icfolson.maven icfolson-maven-skin - 1.0.0 + 1.1.0 From 9cce06233a0b180fba48e6f8a8030c0ab07a8c6d Mon Sep 17 00:00:00 2001 From: Mark Daugherty Date: Thu, 13 Dec 2018 08:04:07 -0600 Subject: [PATCH 3/7] updated site config. --- cq-component-annotations/pom.xml | 2 +- cq-component-maven-plugin/pom.xml | 2 +- pom.xml | 53 ++++++++-- src/site/markdown/index.md | 2 +- src/site/site.xml | 157 ++++++++++++++++-------------- 5 files changed, 130 insertions(+), 86 deletions(-) diff --git a/cq-component-annotations/pom.xml b/cq-component-annotations/pom.xml index ebce919d..f99980f0 100644 --- a/cq-component-annotations/pom.xml +++ b/cq-component-annotations/pom.xml @@ -6,7 +6,7 @@ com.citytechinc.cq.cq-component-plugin cq-component-plugin - 6.0.0 + 6.1.0-SNAPSHOT cq-component-annotations diff --git a/cq-component-maven-plugin/pom.xml b/cq-component-maven-plugin/pom.xml index 5e030584..eb2dd902 100644 --- a/cq-component-maven-plugin/pom.xml +++ b/cq-component-maven-plugin/pom.xml @@ -6,7 +6,7 @@ com.citytechinc.cq.cq-component-plugin cq-component-plugin - 6.0.0 + 6.1.0-SNAPSHOT cq-component-maven-plugin diff --git a/pom.xml b/pom.xml index 8de7161d..da87fffb 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ com.citytechinc.cq.cq-component-plugin cq-component-plugin pom - 6.0.0 + 6.1.0-SNAPSHOT CQ Component Plugin Plugin enabling annotation driven CQ5 Component development. @@ -77,6 +77,18 @@ + + + + org.codehaus.mojo + versions-maven-plugin + 2.2 + + false + + + + maven-javadoc-plugin @@ -149,15 +161,6 @@ - - - maven-javadoc-plugin - 2.9.1 - - true - - - true @@ -181,6 +184,36 @@ + + + + maven-project-info-reports-plugin + 2.8 + + + + maven-javadoc-plugin + 2.9.1 + + true + + + + + + github-site diff --git a/src/site/markdown/index.md b/src/site/markdown/index.md index 45e16278..3fe2ddc6 100644 --- a/src/site/markdown/index.md +++ b/src/site/markdown/index.md @@ -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 diff --git a/src/site/site.xml b/src/site/site.xml index 806d9731..5aa780a3 100644 --- a/src/site/site.xml +++ b/src/site/site.xml @@ -1,81 +1,92 @@ + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" +> - - com.icfolson.maven - icfolson-maven-skin - 1.1.0 - + + com.icfolson.maven + icfolson-maven-skin + 1.1.0 + - - CQ Component Plugin - index.html - + + CQ Component Plugin + index.html + - UA-928005-4 + UA-928005-4 - - - false - - false - true - %2$s | %1$s - true - github - - - CQ Component Plugin - - index.html - - A Plugin for CQ Components! - sidebar - Basics|Extending - - - - CQ Component Plugin - false - false - false - - 1 - - - - - - Main - Basics - Extending - - - + + + false + + false + true + %2$s | %1$s + true + github + + + CQ Component Plugin + + index.html + + A plugin for generating AEM component configuration files from annotated Java classes. + sidebar + Basics|Extending + + + + CQ Component Plugin + false + false + false + + 1 + + + + + + Main + Basics + Extending + + + - - - - - - - - - - - - - - - - - - - -
- + + + + + + + + + + + + + + + + + + + +
+
From f74b288bcd54eb47d2987bd033201887d3a249d6 Mon Sep 17 00:00:00 2001 From: Mark Daugherty Date: Thu, 13 Dec 2018 08:24:25 -0600 Subject: [PATCH 4/7] cleanup. --- pom.xml | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/pom.xml b/pom.xml index da87fffb..55b06686 100644 --- a/pom.xml +++ b/pom.xml @@ -189,26 +189,12 @@ maven-project-info-reports-plugin 2.8 - maven-javadoc-plugin 2.9.1 true - From 546790290a54ab22043cfd61353af7d2e0aa5bcf Mon Sep 17 00:00:00 2001 From: Mark Daugherty Date: Thu, 13 Dec 2018 08:24:52 -0600 Subject: [PATCH 5/7] updated to only set order before property when necessary. --- .../widget/maker/AbstractTouchUIWidgetMaker.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/cq-component-annotations/src/main/java/com/citytechinc/cq/component/touchuidialog/widget/maker/AbstractTouchUIWidgetMaker.java b/cq-component-annotations/src/main/java/com/citytechinc/cq/component/touchuidialog/widget/maker/AbstractTouchUIWidgetMaker.java index 2bf3c136..5a4e43b9 100644 --- a/cq-component-annotations/src/main/java/com/citytechinc/cq/component/touchuidialog/widget/maker/AbstractTouchUIWidgetMaker.java +++ b/cq-component-annotations/src/main/java/com/citytechinc/cq/component/touchuidialog/widget/maker/AbstractTouchUIWidgetMaker.java @@ -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); From acb2dcba066b386845113ef20c1670e7dce5d862 Mon Sep 17 00:00:00 2001 From: Mark Daugherty Date: Thu, 13 Dec 2018 08:55:30 -0600 Subject: [PATCH 6/7] updates for hide dialog field config. --- .../cq/component/dialog/factory/DialogFactory.java | 5 +++++ .../citytechinc/cq/component/dialog/util/DialogUtil.java | 4 ++++ .../component/touchuidialog/util/TouchUIDialogUtil.java | 6 ++++++ .../widget/factory/TouchUIWidgetFactory.java | 8 ++++---- 4 files changed, 19 insertions(+), 4 deletions(-) diff --git a/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/dialog/factory/DialogFactory.java b/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/dialog/factory/DialogFactory.java index 3434bc1b..5a5bba44 100644 --- a/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/dialog/factory/DialogFactory.java +++ b/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/dialog/factory/DialogFactory.java @@ -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; @@ -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); + } } } diff --git a/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/dialog/util/DialogUtil.java b/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/dialog/util/DialogUtil.java index f1b1fdae..486e66a9 100644 --- a/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/dialog/util/DialogUtil.java +++ b/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/dialog/util/DialogUtil.java @@ -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 diff --git a/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/touchuidialog/util/TouchUIDialogUtil.java b/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/touchuidialog/util/TouchUIDialogUtil.java index 01f393c0..9a534d95 100644 --- a/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/touchuidialog/util/TouchUIDialogUtil.java +++ b/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/touchuidialog/util/TouchUIDialogUtil.java @@ -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; @@ -116,12 +117,17 @@ public static List 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); + } } } diff --git a/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/touchuidialog/widget/factory/TouchUIWidgetFactory.java b/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/touchuidialog/widget/factory/TouchUIWidgetFactory.java index 5de197e4..5be24172 100644 --- a/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/touchuidialog/widget/factory/TouchUIWidgetFactory.java +++ b/cq-component-maven-plugin/src/main/java/com/citytechinc/cq/component/touchuidialog/widget/factory/TouchUIWidgetFactory.java @@ -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) { From d18a2f4e7ffb26d31f452170a29c6e8cc511d441 Mon Sep 17 00:00:00 2001 From: Mark Daugherty Date: Thu, 13 Dec 2018 09:12:34 -0600 Subject: [PATCH 7/7] version. --- cq-component-annotations/pom.xml | 2 +- cq-component-maven-plugin/pom.xml | 2 +- pom.xml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cq-component-annotations/pom.xml b/cq-component-annotations/pom.xml index f99980f0..9104e74b 100644 --- a/cq-component-annotations/pom.xml +++ b/cq-component-annotations/pom.xml @@ -6,7 +6,7 @@ com.citytechinc.cq.cq-component-plugin cq-component-plugin - 6.1.0-SNAPSHOT + 6.1.0 cq-component-annotations diff --git a/cq-component-maven-plugin/pom.xml b/cq-component-maven-plugin/pom.xml index eb2dd902..c01f6cc9 100644 --- a/cq-component-maven-plugin/pom.xml +++ b/cq-component-maven-plugin/pom.xml @@ -6,7 +6,7 @@ com.citytechinc.cq.cq-component-plugin cq-component-plugin - 6.1.0-SNAPSHOT + 6.1.0 cq-component-maven-plugin diff --git a/pom.xml b/pom.xml index 55b06686..73f2b221 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ com.citytechinc.cq.cq-component-plugin cq-component-plugin pom - 6.1.0-SNAPSHOT + 6.1.0 CQ Component Plugin Plugin enabling annotation driven CQ5 Component development.