Skip to content

Commit

Permalink
[FEATURE] Add the template to the text media element
Browse files Browse the repository at this point in the history
  • Loading branch information
DigitalZombies committed Apr 11, 2024
1 parent dc83b34 commit f2cfb83
Showing 1 changed file with 43 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,2 +1,43 @@
<h1>TEXTMEDIA</h1>
{_all -> f:debug()}
<html
data-namespace-typo3-fluid="true"
xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
>
<div class="background-secondary py-12">
<div class="container px-5 mx-auto">
<div class="grid gap-8 md:grid-cols-2">
<f:switch expression="{data.imageorient}">
<f:case value="1">
<f:render section="text" arguments="{data: data}"/>
<f:render section="media" arguments="{data: data}"/>
</f:case>
<f:defaultCase>
<f:render section="media" arguments="{data: data}"/>
<f:render section="text" arguments="{data: data}"/>
</f:defaultCase>
</f:switch>
</div>
</div>
</div>
<f:section name="text">
<div class="flex items-center">
<div>
<f:render partial="Content/Header"
arguments="{headerLayout: data.header_layout, headerStyle: data.header_style, header: data.header}"/>
<div class="rte">
<f:format.html>{data.bodytext}</f:format.html>
</div>
</div>
</div>
</f:section>
<f:section name="media">
<div class="md:flex justify-center items-center">
<div class="aspect-square rounded overflow-hidden rotate-left max-w-80">
<f:if condition="{data.assets}">
<f:for each="{data.assets}" as="media">
<f:image src="{media.uid}" treatIdAsReference="1" class="object-cover h-full w-full" width="400"/>
</f:for>
</f:if>
</div>
</div>
</f:section>
</html>

0 comments on commit f2cfb83

Please sign in to comment.