You are here

function system_theme_suggestions_field in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/system/system.module \system_theme_suggestions_field()

Implements hook_theme_suggestions_HOOK().

File

core/modules/system/system.module, line 304
Configuration system that lets administrators modify the workings of the site.

Code

function system_theme_suggestions_field(array $variables) {
  $suggestions = array();
  $element = $variables['element'];
  $suggestions[] = 'field__' . $element['#field_type'];
  $suggestions[] = 'field__' . $element['#field_name'];
  $suggestions[] = 'field__' . $element['#entity_type'] . '__' . $element['#bundle'];
  $suggestions[] = 'field__' . $element['#entity_type'] . '__' . $element['#field_name'];
  $suggestions[] = 'field__' . $element['#entity_type'] . '__' . $element['#field_name'] . '__' . $element['#bundle'];
  return $suggestions;
}