From 9e496e56aa171665aa19db0e6d78cd26619d4596 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Wr=C3=B3blewski?= Date: Fri, 29 Nov 2024 21:03:59 +0100 Subject: [PATCH] Fix missing `theme` variable in `block` calls for proper theme inheritance (#154) --- src/Resources/views/themes/base.html.twig | 24 +++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/Resources/views/themes/base.html.twig b/src/Resources/views/themes/base.html.twig index fb6787e9..ce627be3 100755 --- a/src/Resources/views/themes/base.html.twig +++ b/src/Resources/views/themes/base.html.twig @@ -14,8 +14,8 @@ data-controller="{{ stimulus_controllers|join(' ') }}" data-kreyu--data-table-bundle--state-url-query-parameters-value="{{ url_query_parameters|default({})|json_encode }}" > - {{ block('action_bar') }} - {{ block('table') }} + {{ block('action_bar', theme) }} + {{ block('table', theme) }} {% if pagination_enabled %} {{ data_table_pagination(pagination) }} @@ -38,10 +38,10 @@ data-controller="{{ stimulus_controllers|join(' ') }}" data-kreyu--data-table-bundle--state-url-query-parameters-value="{{ url_query_parameters|default({})|json_encode }}" > - {{ block('action_bar') }} + {{ block('action_bar', theme) }} {{ form_start(form, form_variables) }} - {{ block('table') }} + {{ block('table', theme) }} {{ form_end(form, { render_rest: false }) }} {% if pagination_enabled %} @@ -52,24 +52,24 @@ {% endblock %} {% block kreyu_data_table_table %} - {{ block('table') }} + {{ block('table', theme) }} {% endblock %} {% block kreyu_data_table_action_bar %} - {{ block('action_bar') }} + {{ block('action_bar', theme) }} {% endblock %} {% block action_bar %}{% endblock %} {% block table %} - {{ block('table_head') }} - {{ block('table_body') }} + {{ block('table_head', theme) }} + {{ block('table_body', theme) }}
{% endblock %} {% block table_head %} - {{ block('table_head_row') }} + {{ block('table_head_row', theme) }} {% endblock %} {% block table_head_row %} @@ -77,14 +77,14 @@ {% endblock %} {% block table_body %} - {{ block('table_body_row') }} + {{ block('table_body_row', theme) }} {% endblock %} {% block table_body_row %} {% if value_rows|length > 0 %} - {{ block('table_body_row_results') }} + {{ block('table_body_row_results', theme) }} {% else %} - {{ block('table_body_row_no_results') }} + {{ block('table_body_row_no_results', theme) }} {% endif %} {% endblock %}