protected function WebformAutocomplete::defineDefaultProperties in Webform 6.x
Same name and namespace in other branches
- 8.5 src/Plugin/WebformElement/WebformAutocomplete.php \Drupal\webform\Plugin\WebformElement\WebformAutocomplete::defineDefaultProperties()
Define an element's default properties.
Return value
array An associative array contain an the element's default properties.
Overrides TextField::defineDefaultProperties
File
- src/
Plugin/ WebformElement/ WebformAutocomplete.php, line 40
Class
- WebformAutocomplete
- Provides a 'autocomplete' element.
Namespace
Drupal\webform\Plugin\WebformElementCode
protected function defineDefaultProperties() {
$properties = [
// Autocomplete settings.
'autocomplete_existing' => FALSE,
'autocomplete_items' => [],
'autocomplete_limit' => 10,
'autocomplete_match' => 3,
'autocomplete_match_operator' => 'CONTAINS',
] + parent::defineDefaultProperties() + $this
->defineDefaultMultipleProperties();
// Remove autocomplete property which is not applicable to
// this autocomplete element.
unset($properties['autocomplete']);
return $properties;
}