Same name and namespace in other branches
  1. 7.x-1.x color_field.module \color_field_theme() 1 comment
  2. 7.x-2.x color_field.module \color_field_theme() 1 comment
  3. 8.x-2.x color_field.module \color_field_theme() 1 comment

Implements hook_theme().

File

./color_field.module, line 52

Code

function color_field_theme() : array {
    $theme = [];
    $theme['color_field_formatter_swatch'] = [
        'variables' => [
            'shape' => NULL,
            'color' => NULL,
            'width' => NULL,
            'height' => NULL,
            'attributes' => NULL,
        ],
    ];
    $theme['color_field_formatter_swatch_option'] = [
        'variables' => [
            'id' => NULL,
            'name' => NULL,
            'input_type' => NULL,
            'value' => NULL,
            'shape' => NULL,
            'color' => NULL,
            'width' => NULL,
            'height' => NULL,
            'attributes' => NULL,
        ],
    ];
    return $theme;
}