Arthur Bogaart pushed to branch feature/CHANNELMGR-1388 at cms-community / 
hippo-addon-channel-manager


Commits:
b8146d15 by Arthur Bogaart at 2018-03-06T12:07:56+01:00
CHANNELMGR-1388 Remove unused color variable

- - - - -
39a2bec4 by Arthur Bogaart at 2018-03-06T12:09:19+01:00
CHANNELMGR-1388 Place .check-hint in document-fields scope

Also fix lint error.

- - - - -
71654480 by Arthur Bogaart at 2018-03-06T12:09:51+01:00
CHANNELMGR-1388 Use commons boolean-utils

- - - - -


3 changed files:

- 
content-service/src/main/java/org/onehippo/cms/channelmanager/content/documenttype/field/type/BooleanFieldType.java
- 
frontend-ng/src/app/channel/sidePanels/rightSidePanel/contentEditor/fields/fields.scss
- frontend-ng/src/styles/_variables.scss


Changes:

=====================================
content-service/src/main/java/org/onehippo/cms/channelmanager/content/documenttype/field/type/BooleanFieldType.java
=====================================
--- 
a/content-service/src/main/java/org/onehippo/cms/channelmanager/content/documenttype/field/type/BooleanFieldType.java
+++ 
b/content-service/src/main/java/org/onehippo/cms/channelmanager/content/documenttype/field/type/BooleanFieldType.java
@@ -18,6 +18,8 @@ package 
org.onehippo.cms.channelmanager.content.documenttype.field.type;
 
 import javax.jcr.PropertyType;
 
+import org.apache.commons.lang.BooleanUtils;
+
 public class BooleanFieldType extends PrimitiveFieldType {
     private static final String DEFAULT_VALUE = "false";
 
@@ -37,9 +39,10 @@ public class BooleanFieldType extends PrimitiveFieldType {
 
     @Override
     protected String fieldSpecificConversion(final String input) {
-        if (!"true".equalsIgnoreCase(input) && 
!"false".equalsIgnoreCase(input)) {
+        final String output = 
BooleanUtils.toStringTrueFalse(BooleanUtils.toBooleanObject(input));
+        if (output == null) {
             throw new IllegalArgumentException("BooleanFieldType value must be 
'true' or 'false'.");
         }
-        return Boolean.parseBoolean(input) + "";
+        return output;
     }
 }


=====================================
frontend-ng/src/app/channel/sidePanels/rightSidePanel/contentEditor/fields/fields.scss
=====================================
--- 
a/frontend-ng/src/app/channel/sidePanels/rightSidePanel/contentEditor/fields/fields.scss
+++ 
b/frontend-ng/src/app/channel/sidePanels/rightSidePanel/contentEditor/fields/fields.scss
@@ -42,6 +42,15 @@ document-fields {
   md-icon {
     margin: 0 2px;
   }
+
+  .checkbox-hint {
+    font-size: 18px;
+    height: 18px;
+    min-height: 18px;
+    min-width: 18px;
+    vertical-align: baseline;
+    width: 18px;
+  }
 }
 
 primitive-field,
@@ -60,12 +69,3 @@ compound-field {
     padding-left: 0;
   }
 }
-
-.checkbox-hint {
-  font-size: 18px;
-  width: 18px;
-  min-width: 18px;
-  height: 18px;
-  min-height: 18px;
-  vertical-align: baseline;
-}
\ No newline at end of file


=====================================
frontend-ng/src/styles/_variables.scss
=====================================
--- a/frontend-ng/src/styles/_variables.scss
+++ b/frontend-ng/src/styles/_variables.scss
@@ -68,7 +68,6 @@ $grey-200: #e8e8ea;
 $grey-300: #d9d9dd;
 $grey-400: #b8bcbf;
 $grey-500: #92a0a5;
-$grey-550: #778188;
 $grey-600: #697279;
 $grey-700: #39434c;
 $grey-800: #22272f;



View it on GitLab: 
https://code.onehippo.org/cms-community/hippo-addon-channel-manager/compare/41f815ed6b3c35e8096296dff6c51c9cefb8b395...7165448062ca524c7571864d597cf44c38ece447

---
View it on GitLab: 
https://code.onehippo.org/cms-community/hippo-addon-channel-manager/compare/41f815ed6b3c35e8096296dff6c51c9cefb8b395...7165448062ca524c7571864d597cf44c38ece447
You're receiving this email because of your account on code.onehippo.org.
_______________________________________________
Hippocms-svn mailing list
Hippocms-svn@lists.onehippo.org
https://lists.onehippo.org/mailman/listinfo/hippocms-svn

Reply via email to