meilisearch/Resources/Private/Partials/Facets/Hierarchy.html

31 lines
1.4 KiB
HTML
Raw Normal View History

2021-04-17 00:26:33 +02:00
<html xmlns="http://www.w3.org/1999/xhtml" lang="en"
xmlns:f="http://typo3.org/ns/TYPO3/Fluid/ViewHelpers"
2021-04-17 21:20:54 +02:00
xmlns:s="http://typo3.org/ns/WapplerSystems/Meilisearch/ViewHelpers"
2021-04-17 00:26:33 +02:00
data-namespace-typo3-fluid="true"
>
<f:section name="hierarchyTree">
<f:for each="{node.childNodes}" as="childNode" iteration="iteration">
2021-04-17 21:20:54 +02:00
<div class="facet-option{f:if(condition:'{iteration.index} > 9', then:' tx-meilisearch-facet-hidden')} list-group-item" data-facet-item-value="{childNode.value}">
<a class="facet meilisearch-ajaxified" href="{s:uri.facet.addFacetItem(facet: facet, facetItem: childNode)}">{childNode.label}</a>
2021-04-17 00:26:33 +02:00
<span class="facet-result-count badge">{childNode.documentCount}</span>
</div>
<f:if condition="{childNode.childNodes}">
<div class="list-group-item list-group"><f:render section="hierarchyTree" arguments="{node: childNode, facet: facet}" /></div>
</f:if>
</f:for>
</f:section>
<div class="panel">
<div class="panel-heading">
<h3 class="facet-label panel-title">
<span class="glyphicon glyphicon-filter"></span>
<a data-toggle="collapse" data-parent="#facet-accordion{facet.name}" href="#facet{facet.name}">{facet.label}</a>
</h3>
</div>
<div class="facet-option-list facet-type-hierarchy fluidfacet list-group panel-collapse collapse" data-facet-name="{facet.name}" data-facet-label="{facet.label}" id="facet{facet.name}">
<f:render section="hierarchyTree" arguments="{node: facet, facet: facet}" />
</div>
</div>
2021-04-17 21:20:54 +02:00
</html>