paragraph id
This commit is contained in:
@@ -59,11 +59,18 @@
|
||||
'first_part_home',
|
||||
]
|
||||
%}
|
||||
{%
|
||||
{# {%
|
||||
set id_titre = [
|
||||
'id' ~ paragraph_id|clean_id,
|
||||
'id-' ~ paragraph|clean_id,
|
||||
'block-' ~ plugin_id|clean_class,
|
||||
key.value,
|
||||
'id-' ~ counter,
|
||||
]
|
||||
%} #}
|
||||
{%
|
||||
set id_hook = [
|
||||
'hook-id-' ~ paragraph.id()|clean_id,
|
||||
'paragraph-id--' ~ paragraph.id()|clean_id,
|
||||
]
|
||||
%}
|
||||
|
||||
@@ -82,7 +89,9 @@
|
||||
{# <span> {{index}}</span> #}
|
||||
{# <span id="{{item[key].value }}"></span> #}
|
||||
{# <span>{{counter}}</span> #}
|
||||
<div {{ attributes.addClass(classes, 'field__item').setAttribute('id', id_titre) }}>{{ item.content }}</div>
|
||||
{# <div {{ attributes.addClass(classes, 'field__item') }}>{{ item.content }}</div> #}
|
||||
|
||||
<div {{ attributes.addClass(classes, 'field__item').setAttribute('id', id_hook) }}>{{ item.content }}</div>
|
||||
|
||||
{# {% endfor %} #}
|
||||
{% endfor %}
|
||||
|
||||
@@ -47,7 +47,8 @@
|
||||
]
|
||||
%}
|
||||
{% block paragraph %}
|
||||
<div{{ attributes.addClass(classes) }}>
|
||||
{# <div{{ attributes.addClass(classes) }}> #}
|
||||
<div{{ attributes.addClass(classes).setAttribute('id', 'paragraph-id--' ~ paragraph.id()) }}>
|
||||
{% block content %}
|
||||
{{ content }}
|
||||
{% endblock %}
|
||||
|
||||
Reference in New Issue
Block a user