You are here

function block_skinr_theme_hooks in Skinr 8.2

Same name and namespace in other branches
  1. 7.2 modules/block.skinr.inc \block_skinr_theme_hooks()

Implements hook_skinr_theme_hooks().

File

modules/block.skinr.inc, line 120
Implements Skinr hooks for block.module.

Code

function block_skinr_theme_hooks($module, $element) {
  $theme_hooks = array();
  if ($module == 'block') {
    if ($block = Block::load($element)) {
      $settings = $block
        ->getPlugin()
        ->getConfiguration();
      $theme_hooks[] = 'block__' . $settings['provider'];
    }
    $theme_hooks[] = 'block';
  }
  return $theme_hooks;
}