Drupal UIKit admin toolbar z-index
Code
.uk-navbar-center:not(:only-child) {
z-index: 450;
}
.uk-navbar-center:not(:only-child) {
z-index: 450;
}
(function ($) {
Drupal.behaviors.funtzioIzen = {
attach: function (context, settings) {
/*
if(!$('#balio-modal-button').length) {
$('#edit-group-balioak legend').append('<button id="balio-modal-button">Balioak erakutsi</button>');
}*/
}
};
})(jQuery);
<?php
$terms = \Drupal::entityTypeManager()->getStorage('taxonomy_term')->loadTree('vid', 0, NULL, TRUE);
$current_langcode = \Drupal::languageManager()->getCurrentLanguage()->getId();
foreach ($terms as &$term) {
if ($term->hasTranslation($current_langcode)) {
$term = $term->getTranslation($current_langcode);
}
}
?>
<?php
// Link
use Drupal\Core\Link;
$link = Link::createFromRoute('This is a link', 'entity.node.canonical', ['node' => 1]);
// Url
use Drupal\Core\Link;
use Drupal\Core\Url;
$link = Link::fromTextAndUrl('This is a link', Url::fromRoute('entity.node.canonical', ['node' => 1]));
$link = Link::fromTextAndUrl('This is a link', Url::fromUri('base:robots.txt'));
// External links
$link = Link::fromTextAndUrl('This is a link', Url::fromUri('http://www.google.com'));
// links with only the fragment (without url)
$link = Link::fromTextAndUrl('This is a link', Url::fromUri('internal:#fragment'));
// Using the data provided by a user
$link = Link::fromTextAndUrl('This is a link', Url::fromUserInput('/node/1');
// The param passed to fromUserInput must start with /,#,? or it will throw an exception.
// Linking entities.
$link = Link::fromTextAndUrl('This is a link', Url::fromUri('entity:node/1'));
// Entities are a special case, and there are more ways to link them:
$node = Node::load(1);
$link = $node->toLink();
$link->setText('This is a link');
// And even using the route:
$link = Link::fromTextAndUrl('This is a link', Url::fromRoute('entity.node.canonical', ['node' => 1]));
// Drupal usually expects a render array if you are going to print the link, so the Link object has a method for that:
$link->toRenderable();
?>
// check for recommended installation
composer show drupal/core-recommended
// update
composer update drupal/core-recommended --with-dependencies