You are here

function responsive_image_theme in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/responsive_image/responsive_image.module \responsive_image_theme()

Implements hook_theme().

File

core/modules/responsive_image/responsive_image.module, line 56
Responsive image display formatter for image fields.

Code

function responsive_image_theme() {
  return [
    'responsive_image' => [
      'variables' => [
        'uri' => NULL,
        'attributes' => [],
        'responsive_image_style_id' => [],
        'height' => NULL,
        'width' => NULL,
      ],
    ],
    'responsive_image_formatter' => [
      'variables' => [
        'item' => NULL,
        'item_attributes' => NULL,
        'url' => NULL,
        'responsive_image_style_id' => NULL,
      ],
    ],
  ];
}