Mercurial > hg > cmmr2012-drupal-site
comparison core/modules/toolbar/toolbar.module @ 5:12f9dff5fda9 tip
Update to Drupal core 8.7.1
author | Chris Cannam |
---|---|
date | Thu, 09 May 2019 15:34:47 +0100 |
parents | c75dbcec494b |
children |
comparison
equal
deleted
inserted
replaced
4:a9cd425dd02b | 5:12f9dff5fda9 |
---|---|
281 */ | 281 */ |
282 function toolbar_preprocess_html(&$variables) { | 282 function toolbar_preprocess_html(&$variables) { |
283 if (!\Drupal::currentUser()->hasPermission('access toolbar')) { | 283 if (!\Drupal::currentUser()->hasPermission('access toolbar')) { |
284 return; | 284 return; |
285 } | 285 } |
286 | 286 $variables['attributes']['class'][] = 'toolbar-tray-open'; |
287 $variables['attributes'] = new Attribute($variables['attributes']); | 287 $variables['attributes']['class'][] = 'toolbar-horizontal'; |
288 $variables['attributes']->addClass(['toolbar-tray-open', 'toolbar-horizontal', 'toolbar-fixed', 'toolbar-loading']); | 288 $variables['attributes']['class'][] = 'toolbar-fixed'; |
289 $variables['attributes']['class'][] = 'toolbar-loading'; | |
289 } | 290 } |
290 | 291 |
291 /** | 292 /** |
292 * Returns the rendered subtree of each top-level toolbar link. | 293 * Returns the rendered subtree of each top-level toolbar link. |
293 * | 294 * |