<html
    xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
    xmlns:core="http://typo3.org/ns/TYPO3/CMS/Core/ViewHelpers"
    data-namespace-typo3-fluid="true"
>

<div class="panel panel-default">
    <div class="panel-heading">
        <h3 class="panel-title" id="template-analyzer-{type}-tree-heading">
            <a href="#" class="collapsed" data-bs-toggle="collapse" data-bs-target="#template-analyzer-{type}-tree-body" aria-expanded="false" aria-controls="template-analyzer-{type}-tree-body">
                <span class="caret"></span>
                <strong><f:translate key="LLL:EXT:tstemplate/Resources/Private/Language/locallang_analyzer.xlf:{type}Tree"/></strong>
            </a>
        </h3>
    </div>
    <div id="template-analyzer-{type}-tree-body" class="panel-collapse collapse" data-persist-collapse-state="true" aria-labelledby="template-analyzer-{type}-tree-heading">
        <div class="table-fit mb-0">
            <table class="table table-striped table-hover">
                <thead>
                    <tr>
                        <th><f:translate key="LLL:EXT:tstemplate/Resources/Private/Language/locallang_analyzer.xlf:title"/></th>
                        <th><f:translate key="LLL:EXT:tstemplate/Resources/Private/Language/locallang_analyzer.xlf:type"/></th>
                        <th><f:translate key="LLL:EXT:tstemplate/Resources/Private/Language/locallang_analyzer.xlf:rootlevel"/></th>
                        <th><f:translate key="LLL:EXT:tstemplate/Resources/Private/Language/locallang_analyzer.xlf:clear"/></th>
                        <th><f:translate key="LLL:EXT:tstemplate/Resources/Private/Language/locallang_analyzer.xlf:pid"/></th>
                    </tr>
                </thead>
                <tbody>
                    <f:render
                        partial="AnalyzerTree"
                        arguments="{
                            type: type,
                            pageUid: pageUid,
                            tree: tree,
                            depth: 1,
                            restrictIncludesToMatchingConditionsEnabled: restrictIncludesToMatchingConditionsEnabled
                        }"
                    />
                    <tr>
                        <td>
                            <core:icon identifier="mimetypes-x-content-template-static" size="small" />
                            <f:be.link route="web_typoscript_analyzer" parameters="{id: pageUid, includeType: type, includeIdentifier: tree.identifier}">
                                <f:translate key="LLL:EXT:tstemplate/Resources/Private/Language/locallang_analyzer.xlf:root"/>
                            </f:be.link>
                        </td>
                        <td>{tree.type}</td>
                        <td></td>
                        <td></td>
                        <td></td>
                    </tr>
                </tbody>
            </table>
        </div>
    </div>
</div>

</html>
