You are here

function is_admin_theme_uikit_subtheme in UIkit Components 7.2

Determines whether the admin theme is a UIkit sub-theme.

Return value

bool Returns TRUE if the admin theme is a UIkit sub-theme, otherwise returns FALSE.

Deprecated

in UIkit Components 7.x-2.2, will be removed before 7.x-2.5.

See also

https://www.drupal.org/node/2893283

1 call to is_admin_theme_uikit_subtheme()
uikit_views_load_uikit_assets in uikit_views/templates/uikit_views.theme.inc
Loads UIkit CSS and JS assets.

File

uikit_views/templates/uikit_views.theme.inc, line 414
Preprocessors and helper functions to make theming easier.

Code

function is_admin_theme_uikit_subtheme() {
  $admin_theme = variable_get('admin_theme', 'none');
  $admin_theme_info_file = drupal_get_path('theme', $admin_theme) . "/{$admin_theme}.info";
  $admin_theme_info = drupal_parse_info_file($admin_theme_info_file);
  if (isset($admin_theme_info['base theme']) && $admin_theme_info['base theme'] == 'uikit') {
    return TRUE;
  }
  else {
    return FALSE;
  }
}