You are here

function admin_menu_links_search in Administration menu 8.3

Same name and namespace in other branches
  1. 7.3 admin_menu.inc \admin_menu_links_search()

Build search widget.

See also

theme_admin_menu_links()

1 call to admin_menu_links_search()
admin_menu_output in ./admin_menu.module
Build the administration menu output.

File

./admin_menu.inc, line 593
Menu builder functions for Administration menu.

Code

function admin_menu_links_search() {
  $links = [
    '#theme' => 'admin_menu_links',
    '#wrapper_attributes' => [
      'id' => 'admin-menu-search',
    ],
    '#weight' => 180,
  ];
  $links['search'] = [
    '#type' => 'textfield',
    '#title' => t('Search'),
    '#title_display' => 'attribute',
    '#attributes' => [
      'placeholder' => t('Search'),
      'class' => [
        'admin-menu-search',
      ],
    ],
  ];
  return $links;
}