You are here

public function DefaultMp3Player::renderPlayer in AudioField 8

Renders the player.

Parameters

\Drupal\Core\Field\FieldItemListInterface $items: The uploaded item list.

string $langcode: The language code.

array $settings: An array of additional render settings.

Return value

array Returns the rendered array.

Overrides AudioFieldPluginBase::renderPlayer

File

src/Plugin/AudioPlayer/DefaultMp3Player.php, line 26

Class

DefaultMp3Player
Implements the Default HTML5 Audio Player plugin.

Namespace

Drupal\audiofield\Plugin\AudioPlayer

Code

public function renderPlayer(FieldItemListInterface $items, $langcode, array $settings) {

  // Simply return the default constructor.
  return $this
    ->renderDefaultPlayer($items, $settings);
}