Well all the action is in Bulma so let's override that
This commit is contained in:
parent
087c21c1df
commit
7e05e7354f
1 changed files with 46 additions and 6 deletions
|
@ -1,10 +1,50 @@
|
|||
{% extends '@bulma/block/block.html.twig' %}
|
||||
{% set view_mode = configuration['view_mode'] ?? null %}
|
||||
{% if view_mode is same as ('columnar') %}
|
||||
{% extends "@stable/block/block.html.twig" %}
|
||||
{# Child templates can override the default classes. #}
|
||||
{%
|
||||
set classes = [
|
||||
'column'
|
||||
set classes = classes ?? [
|
||||
'block',
|
||||
'block-' ~ configuration.provider|clean_class,
|
||||
'block-' ~ plugin_id|clean_class,
|
||||
'clearfix',
|
||||
]
|
||||
%}
|
||||
{% set attributes = attributes.addClass(classes) %}
|
||||
{# Footer blocks display in columns. #}
|
||||
{% if region == 'footer' %}
|
||||
{%
|
||||
set classes = classes|merge([
|
||||
'column',
|
||||
'is-narrow',
|
||||
])
|
||||
%}
|
||||
{% endif %}
|
||||
{% if block_panel_style %}
|
||||
{% set classes = classes|merge(['panel']) %}
|
||||
{%
|
||||
set title_classes = title_classes ?? []
|
||||
%}
|
||||
{%
|
||||
set title_classes = title_classes|merge([
|
||||
'panel-heading',
|
||||
])
|
||||
%}
|
||||
{% elseif not title_classes %}
|
||||
{%
|
||||
set title_classes = [
|
||||
'subtitle',
|
||||
'is-4',
|
||||
'is-uppercase'
|
||||
]
|
||||
%}
|
||||
{% endif %}
|
||||
{% set attributes = attributes.addClass(classes) %}
|
||||
{% set title_attributes = title_attributes.addClass(title_classes) %}
|
||||
{# Override the content block to conditionally add a panel wrapper. #}
|
||||
{% block content %}
|
||||
{% if block_panel_style %}
|
||||
<div class="panel-block">
|
||||
{% endif %}
|
||||
{{ content }}
|
||||
{% if block_panel_style %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
|
Loading…
Reference in a new issue