Skip to content
Snippets Groups Projects
Commit 89b33805 authored by Stefan Galinski's avatar Stefan Galinski :video_game:
Browse files

Merge branch 'task_bootstrap5' into 'master'

Draft: Bootstrap 5 Support

See merge request !16
parents 6cc6403e b6513e3e
No related branches found
No related tags found
1 merge request!16Bootstrap 5 Support
......@@ -165,3 +165,7 @@ plugin.tx_dftabs_plugin1 {
records =
}
}
[{$plugin.tx_project_theme.config.bootstrapVersion} == 5]
plugin.tx_dftabs_plugin1.view.templateRootPaths.10 = EXT:df_tabs/Resources/Private/Templates/Bootstrap5/
[end]
\ No newline at end of file
{namespace be=TYPO3\CMS\Backend\ViewHelpers}
{namespace core=TYPO3\CMS\Core\ViewHelpers}
<f:asset.css identifier="df_tabs-pluginpreview"
href="EXT:df_tabs/Resources/Public/StyleSheets/Backend/pluginpreview.css"></f:asset.css>
<h4>
<span class="badge text-bg-primary">
<f:translate key="{headerLabel}" />
</span>
</h4>
<br />
<table class="table table-striped table-bordered df_tabs-backend-preview-table">
<f:render partial="PluginDataTableHeader" />
<tbody>
<tr>
<th scope="row">
<f:translate
key="LLL:EXT:df_tabs/Resources/Private/Language/locallang.xlf:flexform.sheets.general.mode" />
</th>
<td>
<f:if condition="{data.tabs.0}">
<f:then>
<f:comment><!--Combined mode is forced.--></f:comment>
<f:translate
key="LLL:EXT:df_tabs/Resources/Private/Language/locallang.xlf:flexform.sheets.general.mode.combined" />
</f:then>
<f:else>
<f:translate
key="LLL:EXT:df_tabs/Resources/Private/Language/locallang.xlf:flexform.sheets.general.mode.{data.mode}" />
</f:else>
</f:if>
</td>
</tr>
<f:if condition="{data.tabs.0}">
<tr>
<th scope="row">
<f:translate
key="LLL:EXT:df_tabs/Resources/Private/Language/locallang.xlf:flexform.sheets.general.data" />
</th>
<td>
<f:for each="{data.tabs}" as="tab">
<f:switch expression="{tab.type}">
<f:case value="page">
<be:link.editRecord uid="{tab.uid}" table="pages">
<core:icon identifier="apps-pagetree-page-default" /> {tab.title} [{tab.uid}]
</be:link.editRecord>
</f:case>
<f:case value="content">
<be:link.editRecord uid="{tab.uid}" table="tt_content">
<core:icon identifier="content-header" /> {tab.title} [{tab.uid}]
</be:link.editRecord>
</f:case>
<f:defaultCase>
<core:icon identifier="default" /> {tab.title} [{tab.uid}]
</f:defaultCase>
</f:switch>
<br />
</f:for>
</td>
</tr>
</f:if>
<f:if condition="{data.titles.0}">
<tr>
<th scope="row">
<f:translate
key="LLL:EXT:df_tabs/Resources/Private/Language/locallang.xlf:flexform.sheets.general.titles" />
</th>
<td>
<f:for each="{data.titles}" as="title" iteration="iterator">
<f:format.raw>{title}</f:format.raw>
<br />
</f:for>
</td>
</tr>
</f:if>
<tr>
<th scope="row">
<f:translate
key="LLL:EXT:df_tabs/Resources/Private/Language/locallang.xlf:flexform.sheets.general.enableAutoPlayInterval" />
</th>
<td>
<f:if condition="{data.enableAutoPlay}">
<f:then>
<core:icon identifier="actions-check" />
</f:then>
<f:else>
<core:icon identifier="actions-close" />
</f:else>
</f:if>
</td>
</tr>
<f:if condition="{data.enableAutoPlay}">
<tr>
<th scope="row">
<f:translate
key="LLL:EXT:df_tabs/Resources/Private/Language/locallang.xlf:flexform.sheets.general.autoPlayInterval" />
</th>
<td>
{data.autoPlayInterval}
</td>
</tr>
</f:if>
<tr>
<th scope="row">
<f:translate
key="LLL:EXT:df_tabs/Resources/Private/Language/locallang.xlf:flexform.sheets.general.enableMouseOver" />
</th>
<td>
<f:if condition="{data.enableMouseOver}">
<f:then>
<core:icon identifier="actions-check" />
</f:then>
<f:else>
<core:icon identifier="actions-close" />
</f:else>
</f:if>
</td>
</tr>
<tr>
<th scope="row">
<f:translate
key="LLL:EXT:df_tabs/Resources/Private/Language/locallang.xlf:flexform.sheets.general.hash" />
</th>
<td>
{data.hashName}
</td>
</tr>
</tbody>
</table>
\ No newline at end of file
<ul class="nav nav-pills bg-light p-2 rounded-5 d-none d-sm-flex" id="pills-tab-df-tabs" role="tablist">
<f:for each="{tabElements}" as="data_item" iteration="iterator">
<li class="nav-item" role="presentation">
<button class="nav-link {f:if(condition: iterator.isFirst, then: 'active')}"
id="pills-{data_item.record}-{iterator.index}-tab" data-bs-toggle="pill"
data-bs-target="#pills-{data_item.record}-{iterator.index}" type="button" role="tab"
aria-controls="pills-{data_item.record}-{iterator.index}"
aria-selected="{f:if(condition: iterator.isFirst, then: 'true', else: 'false')}">
{data_item.title -> f:format.raw()}
</button>
</li>
</f:for>
</ul>
<div class="nav nav-pills dropdown d-block d-sm-none" role="tablist">
<a class="btn btn-light dropdown-toggle dropdown-toggle--no-caret w-100 fw-bold" data-toggle="dropdown" href="#"
aria-expanded="false">
<span class="dropdown-text">
{tabElements.0.title -> f:format.raw()}
</span>
<span class="caret"></span>
</a>
<ul class="dropdown-menu w-100">
<f:for each="{tabElements}" as="data_item" iteration="iterator">
<li>
<button class="dropdown-item {f:if(condition: iterator.isFirst, then: 'active')}"
id="pills-{data_item.record}-{iterator.index}-tab" data-bs-toggle="pill"
data-bs-target="#pills-{data_item.record}-{iterator.index}" type="button" role="tab"
aria-controls="pills-{data_item.record}-{iterator.index}"
aria-selected="{f:if(condition: iterator.isFirst, then: 'true', else: 'false')}">
{data_item.title -> f:format.raw()}
</button>
</li>
</f:for>
</ul>
</div>
<div class="tab-content pt-4">
<f:for each="{tabElements}" as="data_item" iteration="iterator">
<div class="tab-pane fade {f:if(condition: iterator.isFirst, then: 'show active')}"
id="pills-{data_item.record}-{iterator.index}" role="tabpanel"
aria-labelledby="pills-{data_item.record}-{iterator.index}-tab" tabindex="0">
{data_item.content -> f:format.raw()}
</div>
</f:for>
</div>
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment