vishalp's blog

[D8]: Adding a class to more link of a view

In case you are looking for adding a css class to more link(displayed in footer) of a view in drupal 8, you can do it by implementing template_preprocess_views_view() in your theme under THEMENAME.theme file as shown below:

/**
 * Implements template_preprocess_views_view()
 * @param array $vars
 */
function THEMENAME_preprocess_views_view(&$vars){
  if(YOUR CONDITION FOR ADDING A CLASS){
    $vars['more']['#options']['attributes']['class'] = array(
      ENTER YOUR CLASSES AS ARRAY ELEMENTS
    );
  }
}

 

[D8]: Setting default logo path in a theme

If a custom logo is not specified, Drupal will search in the active theme for a default logo image file. This has been changed from a PNG file to a SVG file.

Themes that were providing a default logo.png will need to provide a logo.svg. PNG logos, or other image formats, can always be used by uploading the logo as a custom logo.

Themers can create extra custom settings in their themes to give support to non-SVG default logos.