Django multi-level template extending

I have 3 templates in my code. first one is the base.html, second one is toolbar.html and the third is toolbar_content.html.

so I wanted to include the toolbar inside base and use the third inside content blocks by extending base.html.

here is an example: my base.html:

<div class="d-flex flex-column flex-column-fluid">
     {% include 'components/toolbar.html' %}
</div

my toolbar:

<div class="d-flex align-items-center gap-2 gap-lg-3">
    {% block toolbar_content %}{% endblock %}
</div>

and my toolbar content:

{% extends 'base.html' %}
{% block toolbar_content %}

    <a href="#" class="btn btn-sm fw-bold btn-primary" data-bs-toggle="modal"
           data-bs-target="#concept_create">Create New Concept</a>
{% endblock %}

I both tried to test this example and also I tried to extend the toolbar page instead of base in my toolbar content template but its not working. toolbar is successfully included in base but the content is not showing. could you help me work this out?

<div class="d-flex flex-column flex-column-fluid">
    {% block toolbar %}
    <div class="d-flex align-items-center gap-2 gap-lg-3">
        {% block toolbar_content %}
        <a href="#" class="btn btn-sm fw-bold btn-primary" data-bs-toggle="modal" data-bs-target="#concept_create">
            Create New Concept
        </a>
        {% endblock %}
    </div>
    {% endblock %}
</div>
Вернуться на верх