From d1993f00c180fc02908fdb89894fced8ac0cc3d2 Mon Sep 17 00:00:00 2001 From: Tim Bolender Date: Thu, 24 Apr 2014 12:49:37 +0200 Subject: [PATCH] Adjusted interface text for optional alpha channel --- Core/Frameworks/Baikal/Model/Calendar.php | 3 ++- Core/Frameworks/Formal/Form.php | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Core/Frameworks/Baikal/Model/Calendar.php b/Core/Frameworks/Baikal/Model/Calendar.php index 4b16898..c3e261d 100644 --- a/Core/Frameworks/Baikal/Model/Calendar.php +++ b/Core/Frameworks/Baikal/Model/Calendar.php @@ -169,7 +169,8 @@ class Calendar extends \Flake\Core\Model\Db { "popover" => array( "title" => "Calendar color", "content" => "This is the color that will be displayed in your CalDAV client.
". - "Must be supplied in format '#RRGGBBAA' with hexadecimal values. This value is optional.", + "Must be supplied in format '#RRGGBBAA' (alpha channel optional) with hexadecimal values.
". + "This value is optional.", ) ))); diff --git a/Core/Frameworks/Formal/Form.php b/Core/Frameworks/Formal/Form.php index afba56c..5283b2b 100644 --- a/Core/Frameworks/Formal/Form.php +++ b/Core/Frameworks/Formal/Form.php @@ -317,7 +317,7 @@ class Form { public function validateColor($sValue, \Formal\Form\Morphology $oMorpho, \Formal\Element $oElement) { if(!empty($sValue) && !preg_match("/^#[a-fA-F0-9]{6}([a-fA-F0-9]{2})?$/", $sValue)) { - return "" . $oElement->option("label") . " is not a valid color with format '#RRGGBBAA' in hexadecimal values."; + return "" . $oElement->option("label") . " is not a valid color with format '#RRGGBB' or '#RRGGBBAA' in hexadecimal values."; } return TRUE;