<f:layout name="{f:if(condition: treeEnabled, then: 'ElementBrowserWithNavigation', else: 'ElementBrowser')}" />

<f:section name="Navigation">
    <f:if condition="{tree}">
        <f:then>
            <div class="element-browser-body">
                {tree -> f:format.raw()}
            </div>
        </f:then>
        <f:else if="{treeType} == 'page'">
            <typo3-backend-component-page-browser
                class="scaffold-content-navigation-component"
                tree-actions="{treeActions -> f:format.json()}"
                active-page="{activePage}">
            </typo3-backend-component-page-browser>
        </f:else>
        <f:else if="{treeType} == 'folder'">
            <typo3-backend-component-filestorage-browser
                class="scaffold-content-navigation-component"
                active-folder="{f:if(condition: activeFolder, then: activeFolder.combinedIdentifier, else: '') -> f:format.htmlentities()}"
            >
            </typo3-backend-component-filestorage-browser>
        </f:else>
    </f:if>
</f:section>

<f:section name="Content">
    <f:flashMessages queueIdentifier="{flashMessageQueueIdentifier}"/>
    <f:format.raw>{content}</f:format.raw>
</f:section>
