public static function ChosenFormRender::preRenderDateCombo in Chosen 3.0.x
Same name and namespace in other branches
- 8.2 src/ChosenFormRender.php \Drupal\chosen\ChosenFormRender::preRenderDateCombo()
Render API callback: Apply Chosen to a date_combo element.
Parameters
array $element: The element.
Return value
array The element.
File
- src/
ChosenFormRender.php, line 105
Class
Namespace
Drupal\chosenCode
public static function preRenderDateCombo($element) {
// Because the date_combo field contains many different select elements, we
// need to recurse down and apply the FAPI property to each one.
if (isset($element['#chosen'])) {
chosen_element_apply_property_recursive($element, $element['#chosen']);
}
return $element;
}