upgraded custom modules D10 compatibility
This commit is contained in:
@@ -2,7 +2,7 @@ name: edlp
|
||||
description: 'EDLP Drupal 8 theme with gulp'
|
||||
type: theme
|
||||
base theme: classy
|
||||
core_version_requirement: ^8 || ^9
|
||||
core_version_requirement: ^8 || ^9 || ^10
|
||||
libraries:
|
||||
- core/normalize
|
||||
- edlptheme/redirect-js
|
||||
|
||||
@@ -8,7 +8,7 @@ redirect-js:
|
||||
version: VERSION
|
||||
header: true
|
||||
js:
|
||||
assets/dist/scripts/redirect.min.js: { weight:-998, preprocess: false, minified: true }
|
||||
assets/dist/scripts/redirect.min.js: { weight: -998, preprocess: false, minified: true }
|
||||
|
||||
global-js:
|
||||
version: VERSION
|
||||
|
||||
@@ -199,7 +199,7 @@ function edlptheme_prepare_audio_link(&$vars){
|
||||
$son_url = null;
|
||||
if($son_file){
|
||||
$son_uri = $son_file->getFileUri();
|
||||
$son_url = file_create_url($son_uri);
|
||||
$son_url = \Drupal::service('file_url_generator')->generateAbsoluteString($son_uri);
|
||||
}
|
||||
|
||||
$vars['link_attributes'] = new Attribute(array(
|
||||
@@ -264,7 +264,7 @@ function edlptheme_preprocess_node__enregistrement__player_cartel(&$vars){
|
||||
$son_file = \Drupal\file\Entity\File::load($son_fid);
|
||||
if($son_file){
|
||||
$son_uri = $son_file->getFileUri();
|
||||
$son_url = file_create_url($son_uri);
|
||||
$son_url = \Drupal::service('file_url_generator')->generateAbsoluteString($son_uri);
|
||||
|
||||
$base = log($son_file->getSize(), 1024);
|
||||
$suffixes = array('', 'K', 'M', 'G', 'T');
|
||||
|
||||
+1
-1
@@ -91,7 +91,7 @@
|
||||
</h2>
|
||||
<div class="entrees">
|
||||
{# THIS IS REALLY DIRTY !! #}
|
||||
{% for key, child in content.field_entrees if key|first != '#' %}
|
||||
{% for key, child in content.field_entrees|filter((value, key) => key|first != '#') %}
|
||||
{% set tid = child['#cache']['tags'][0]|replace({'taxonomy_term:':''}) %}
|
||||
<span class="entree" tid="{{ tid }}" title="{{ child }}"></span>
|
||||
{% endfor %}
|
||||
|
||||
+1
-1
@@ -84,7 +84,7 @@
|
||||
<article{{ attributes.addClass(classes) }}>
|
||||
<div class="entrees">
|
||||
{# THIS IS REALLY DIRTY !! #}
|
||||
{% for key, child in content.field_entrees if key|first != '#' %}
|
||||
{% for key, child in content.field_entrees|filter((value, key) => key|first != '#') %}
|
||||
{% set tid = child['#cache']['tags'][0]|replace({'taxonomy_term:':''}) %}
|
||||
<span class="entree" tid="{{ tid }}" title="{{ child }}"></span>
|
||||
{% endfor %}
|
||||
|
||||
+1
-1
@@ -84,7 +84,7 @@
|
||||
<article{{ attributes.addClass(classes) }}>
|
||||
<div class="entrees">
|
||||
{# THIS IS REALLY DIRTY !! #}
|
||||
{% for key, child in content.field_entrees if key|first != '#' %}
|
||||
{% for key, child in content.field_entrees|filter((value, key) => key|first != '#') %}
|
||||
{% set tid = child['#cache']['tags'][0]|replace({'taxonomy_term:':''}) %}
|
||||
<span class="entree" tid="{{ tid }}" title="{{ child }}"></span>
|
||||
{% endfor %}
|
||||
|
||||
+1
-1
@@ -91,7 +91,7 @@
|
||||
<section class="first-cartel">
|
||||
<div class="entrees">
|
||||
{# THIS IS REALLY DIRTY !! #}
|
||||
{% for key, child in content.field_entrees if key|first != '#' %}
|
||||
{% for key, child in content.field_entrees|filter((value, key) => key|first != '#') %}
|
||||
{% set tid = child['#cache']['tags'][0]|replace({'taxonomy_term:':''}) %}
|
||||
<span class="entree" tid="{{ tid }}" title="{{ child }}"></span>
|
||||
{% endfor %}
|
||||
|
||||
+1
-1
@@ -84,7 +84,7 @@
|
||||
<article{{ attributes.addClass(classes) }}>
|
||||
<div class="entrees">
|
||||
{# THIS IS REALLY DIRTY !! #}
|
||||
{% for key, child in content.field_entrees if key|first != '#' %}
|
||||
{% for key, child in content.field_entrees|filter((value, key) => key|first != '#') %}
|
||||
{% set tid = child['#cache']['tags'][0]|replace({'taxonomy_term:':''}) %}
|
||||
<span class="entree" tid="{{ tid }}" title="{{ child }}"></span>
|
||||
{% endfor %}
|
||||
|
||||
Reference in New Issue
Block a user