You are here

ResponsiveImage.php in Zircon Profile 8.0

Same filename and directory in other branches
  1. 8 core/modules/responsive_image/src/Element/ResponsiveImage.php

File

core/modules/responsive_image/src/Element/ResponsiveImage.php
View source
<?php

/**
 * @file
 * Contains \Drupal\responsive_image\Element\ResponsiveImage.
 */
namespace Drupal\responsive_image\Element;

use Drupal\Core\Render\Element\RenderElement;

/**
 * Provides a responsive image element.
 *
 * @RenderElement("responsive_image")
 */
class ResponsiveImage extends RenderElement {

  /**
   * {@inheritdoc}
   */
  public function getInfo() {
    return [
      '#theme' => 'responsive_image',
      '#attached' => [
        'library' => [
          'core/picturefill',
        ],
      ],
    ];
  }

}

Classes

Namesort descending Description
ResponsiveImage Provides a responsive image element.