diff --git a/wire/core/Sanitizer.php b/wire/core/Sanitizer.php index d308b172..5b903d3c 100644 --- a/wire/core/Sanitizer.php +++ b/wire/core/Sanitizer.php @@ -4381,6 +4381,7 @@ class Sanitizer extends Wire { 'fieldName', 'fieldSubfield', 'filename', + 'flatArray', 'float', 'httpUrl', 'hyphenCase', @@ -4428,6 +4429,7 @@ class Sanitizer extends Wire { 'valid', 'validate', 'varName', + 'wordsArray', ); $results = array(); foreach($sanitizers as $method) { diff --git a/wire/core/Selector.php b/wire/core/Selector.php index 68ada21f..21e1916f 100644 --- a/wire/core/Selector.php +++ b/wire/core/Selector.php @@ -403,7 +403,7 @@ abstract class Selector extends WireData { } /** - * Get label that describes this Selector + * Get short label that describes this Selector * * @return string * @since 3.0.160 @@ -412,6 +412,17 @@ abstract class Selector extends WireData { public static function getLabel() { return ''; } + + /** + * Get longer description that describes this Selector + * + * @return string + * @since 3.0.160 + * + */ + public static function getDescription() { + return ''; + } /** * Does $value1 match $value2? diff --git a/wire/core/Selectors.php b/wire/core/Selectors.php index 4aca2151..118be9af 100644 --- a/wire/core/Selectors.php +++ b/wire/core/Selectors.php @@ -1176,8 +1176,8 @@ class Selectors extends WireArray { * - `operator` (string): Return info for only this operator. When specified, only value is returned (default=''). * - `compareType` (int): Return only operators matching given `Selector::compareType*` constant (default=0). * - `getIndexType` (string): Index type to use in returned array: 'operator', 'className' or 'class' (default='class') - * - `getValueType` (string): Value type to use in returned array: 'operator', 'class', 'className', 'label', 'compareType', 'verbose' (default='operator'). - * If 'verbose' option used then assoc array returned for each operator containing 'class', 'className', 'operator', 'compareType', 'label'. + * - `getValueType` (string): Value type to use in returned array: 'operator', 'class', 'className', 'label', 'description', 'compareType', 'verbose' (default='operator'). + * If 'verbose' option used then assoc array returned for each operator containing 'class', 'className', 'operator', 'compareType', 'label', 'description'. * @return array|string|int Returned array where both keys and values are operators (or values are requested 'valueType' option) * If 'operator' option specified, return value is string, int or array (requested 'valueType'), and there is no indexType. * @since 3.0.154 @@ -1215,6 +1215,8 @@ class Selectors extends WireArray { $value = $className; } else if($valueType === 'label') { $value = $className::getLabel(); + } else if($valueType === 'description') { + $value = $className::getDescription(); } else if($valueType === 'compareType') { $value = $className::getCompareType(); } else if($valueType === 'verbose') { @@ -1224,6 +1226,7 @@ class Selectors extends WireArray { 'className' => $className, 'compareType' => $className::getCompareType(), 'label' => $className::getLabel(), + 'description' => $className::getDescription(), ); } else { $value = $operator;