{% import "/common/macros.twig" as icwp_macros %}

{% block inner_page_header %}

	{% if strings.inner_page_title|default('') is not empty %}
		<div class="row border-bottom mb-2 inner-page-header">
			<div class="col">
				<h4 class="mb-2 inner-page-header-title d-flex align-items-center">
					{{ imgs.inner_page_title_icon|default('')|raw }}
					<div class="d-inline-block">
						{% for breadcrumb in hrefs.breadcrumbs %}
							<a href="{{ breadcrumb.href }}"
							   title="{{ breadcrumb.title|default('') }}"
							   class="border-bottom">{{ breadcrumb.text }}</a>
							<span class="mx-1 fs-6" style="line-height: inherit">&raquo;</span>
						{% endfor %}
						{{ strings.inner_page_title|default('No inner page title set') }}
					</div>
					{% block inner_page_title_after %}{% endblock %}
				</h4>
				{% if strings.inner_page_subtitle|default('') is not empty %}
					<p class="mb-2">
						<small class="inner-page-subtitle">
						{{ strings.inner_page_subtitle|default('') }}
						</small>
					</p>
				{% endif %}

			</div>
			<div class="col-2 text-end inner-page-config">

				{% if hrefs.inner_page_contextual_hrefs|default([]) is not empty %}

					<div class="btn-group dropstart tour-navigation_v1"
						 data-introtitle="Action Menu"
						 data-introposition="left"
						 data-intro="Certain pages have their own specific actions. Use this menu for shortcuts to useful tools and options."
					>
						<button type="button"
								class="btn btn-link dropdown-toggle"
								data-bs-toggle="dropdown"
								aria-expanded="false">{{ imgs.svgs.menu|raw }}</button>
							<ul class="dropdown-menu">
								{% for item in hrefs.inner_page_contextual_hrefs %}
									<li>
										{{ icwp_macros.tagAnchor(
											item.href,
											item.title,
											item.id|default(''),
											item.classes|default([])|merge(['dropdown-item']),
											item.new_window|default(false),
											item.data|default([]),
											item.disabled|default(false)
										) }}
									</li>
								{% endfor %}
							</ul>
						</div>

				{% endif %}
			</div>
		</div>
	{% endif %}

{% endblock %}

{% block inner_page_body %}
	{% for element in content|default([]) %}
		{{ element|raw }}
	{% endfor %}
{% endblock %}