You are here

function panopoly_search_theme_suggestions_form in Panopoly 8.2

Implements hook_theme_suggestions_HOOK().

File

modules/panopoly/panopoly_search/panopoly_search.module, line 55
Hooks for the panopoly_search module.

Code

function panopoly_search_theme_suggestions_form(array $variables) {
  $suggestions = [];

  // Use the same template suggestions as the Drupal core search block.
  // This applies the default styling in Bartik, and may work for other
  // themes that have custom styled the search form.
  $form_id = $variables['element']['#form_id'];
  if ($form_id === 'panopoly_search_box_form') {
    $suggestions[] = 'form__search_block_form';
  }
  return $suggestions;
}