add initial news design
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
<div class="article news-list-item">
|
||||
<f:if condition="{newsItem.media}">
|
||||
<f:image image="{newsItem.media.0}" class="news-item-grid-image" alt="{newsItem.title}" />
|
||||
</f:if>
|
||||
<div class="news-item-content">
|
||||
<f:if condition="{newsItem.firstCategory}">
|
||||
<div class="news-item-category">{newsItem.firstCategory.title}</div>
|
||||
</f:if>
|
||||
<h5 class="news-item-title">{newsItem.title}</h5>
|
||||
<f:link.page pageUid="{newsItem.link}" class="news-item-link"></f:link.page>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,45 @@
|
||||
<ul class="f3-widget-paginator">
|
||||
<f:if condition="{pagination.previousPageNumber} && {pagination.previousPageNumber} >= {pagination.firstPageNumber}">
|
||||
<li class="previous">
|
||||
<a href="{f:uri.action(action:actionName, arguments:{currentPage: pagination.previousPageNumber},addQueryString:'untrusted')}" title="{f:translate(key:'pagination.previous')}">
|
||||
<i class="ci ci-angle-left"></i>
|
||||
</a>
|
||||
</li>
|
||||
</f:if>
|
||||
<f:if condition="{pagination.previousPageNumber} && {pagination.previousPageNumber} > {pagination.firstPageNumber}">
|
||||
<li class="first">
|
||||
<a href="{f:uri.action(action:actionName, arguments:{currentPage: 1},addQueryString:'untrusted')}" title="{f:translate(key:'pagination.first')}">
|
||||
{pagination.firstPageNumber}
|
||||
</a>
|
||||
</li>
|
||||
</f:if>
|
||||
<f:if condition="{pagination.previousPageNumber} && {pagination.previousPageNumber} > {pagination.firstPageNumber + 1}">
|
||||
<li class="dots">
|
||||
<span>...</span>
|
||||
</li>
|
||||
</f:if>
|
||||
<f:for each="{pagination.allPageNumbers}" as="page">
|
||||
<li class="{f:if(condition: '{page} == {paginator.currentPageNumber}', then:'current')}">
|
||||
<a href="{f:uri.action(action:actionName, arguments:{currentPage: page},addQueryString:'untrusted')}">{page}</a>
|
||||
</li>
|
||||
</f:for>
|
||||
<f:if condition="{pagination.nextPageNumber} && {pagination.nextPageNumber} < {pagination.lastPageNumber - 1}">
|
||||
<li class="dots">
|
||||
<span>...</span>
|
||||
</li>
|
||||
</f:if>
|
||||
<f:if condition="{pagination.nextPageNumber} && {pagination.nextPageNumber} < {pagination.lastPageNumber}">
|
||||
<li class="last">
|
||||
<a href="{f:uri.action(action:actionName, arguments:{currentPage: pagination.lastPageNumber},addQueryString:'untrusted')}" title="{f:translate(key:'pagination.last')}">
|
||||
{pagination.lastPageNumber}
|
||||
</a>
|
||||
</li>
|
||||
</f:if>
|
||||
<f:if condition="{pagination.nextPageNumber} && {pagination.nextPageNumber} <= {pagination.lastPageNumber}">
|
||||
<li class="next">
|
||||
<a href="{f:uri.action(action:actionName, arguments:{currentPage: pagination.nextPageNumber},addQueryString:'untrusted')}" title="{f:translate(key:'pagination.next')}">
|
||||
<i class="ci ci-angle-right"></i>
|
||||
</a>
|
||||
</li>
|
||||
</f:if>
|
||||
</ul>
|
||||
@@ -1,13 +0,0 @@
|
||||
<div class="news-item-featured">
|
||||
<f:if condition="{newsItem.media}">
|
||||
<f:image image="{newsItem.media.0}" class="news-item-featured-image" alt="{newsItem.title}" />
|
||||
</f:if>
|
||||
<div class="news-item-featured-content">
|
||||
<!-- Category and Title -->
|
||||
<f:if condition="{newsItem.firstCategory}">
|
||||
<div class="news-item-category">{newsItem.firstCategory.title}</div>
|
||||
</f:if>
|
||||
<h3 class="news-item-title">{newsItem.title}</h3>
|
||||
<f:link.page pageUid="{newsItem.link}" class="news-item-link"> </f:link.page>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1,12 +0,0 @@
|
||||
<div class="news-item-grid">
|
||||
<f:if condition="{newsItem.media}">
|
||||
<f:image image="{newsItem.media.0}" class="news-item-grid-image" alt="{newsItem.title}" />
|
||||
</f:if>
|
||||
<div class="news-item-grid-content">
|
||||
<f:if condition="{newsItem.firstCategory}">
|
||||
<div class="news-item-category">{newsItem.firstCategory.title}</div>
|
||||
</f:if>
|
||||
<h5 class="news-item-title">{newsItem.title}</h5>
|
||||
<f:link.page pageUid="{newsItem.link}" class="news-item-link"> </f:link.page>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1,12 +0,0 @@
|
||||
<div class="news-item-side">
|
||||
<f:if condition="{newsItem.media}">
|
||||
<f:image image="{newsItem.media.0}" class="news-item-side-image" alt="{newsItem.title}" />
|
||||
</f:if>
|
||||
<div class="news-item-side-content">
|
||||
<f:if condition="{newsItem.firstCategory}">
|
||||
<div class="news-item-category">{newsItem.firstCategory.title}</div>
|
||||
</f:if>
|
||||
<h4 class="news-item-title">{newsItem.title}</h4>
|
||||
<f:link.page pageUid="{newsItem.link}" class="news-item-link"> </f:link.page>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1,55 +1,65 @@
|
||||
<html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
|
||||
xmlns:n="http://typo3.org/ns/GeorgRinger/News/ViewHelpers"
|
||||
data-namespace-typo3-fluid="true">
|
||||
<f:layout name="General" />
|
||||
<f:section name="content">
|
||||
<f:if condition="{news}">
|
||||
<f:then>
|
||||
<div class="news-list-container">
|
||||
<!-- First 4 items: 1 large on the left and 3 stacked on the right -->
|
||||
<f:if condition="{news -> f:count()} > 0">
|
||||
<div class="news-featured-wrapper">
|
||||
<div class="news-featured-item">
|
||||
<f:for each="{news}" as="item" iteration="iterator">
|
||||
<f:if condition="{iterator.index} == 0">
|
||||
<f:then>
|
||||
<f:render partial="News/ItemFeatured" arguments="{newsItem: item}" />
|
||||
</f:then>
|
||||
</f:if>
|
||||
</f:for>
|
||||
</div>
|
||||
<div class="news-side-items">
|
||||
<f:for each="{news}" as="item" iteration="iterator">
|
||||
<f:if condition="{iterator.index} > 0 && {iterator.index} < 4">
|
||||
<f:then>
|
||||
<f:render partial="News/ItemSide" arguments="{newsItem: item}" />
|
||||
</f:then>
|
||||
</f:if>
|
||||
</f:for>
|
||||
</div>
|
||||
</div>
|
||||
</f:if>
|
||||
<!--
|
||||
=====================
|
||||
Templates/News/List.html
|
||||
-->
|
||||
|
||||
<!-- Remaining items in a responsive grid of 3 columns -->
|
||||
<f:if condition="{news -> f:count()} > 4">
|
||||
<div class="news-list-grid">
|
||||
<f:for each="{news}" as="item" iteration="iterator">
|
||||
<f:if condition="{iterator.index} >= 4">
|
||||
<f:then>
|
||||
<f:render partial="News/ItemGrid" arguments="{newsItem: item}" />
|
||||
</f:then>
|
||||
</f:if>
|
||||
</f:for>
|
||||
</div>
|
||||
</f:if>
|
||||
<f:section name="Header" />
|
||||
|
||||
<!-- "Alle anzeigen" button if listPid is set -->
|
||||
<f:if condition="{settings.listPid}">
|
||||
<div class="news-show-all">
|
||||
<f:link.page pageUid="{settings.listPid}" class="btn-show-all">Alle anzeigen</f:link.page>
|
||||
</div>
|
||||
<f:section name="news-item">
|
||||
<f:switch expression="{settings.templateLayout}">
|
||||
<f:defaultCase>
|
||||
<f:if condition="{iterator.isFirst}">
|
||||
<f:then>
|
||||
<f:render partial="List/Item" arguments="{newsItem: newsItem,settings:settings,iterator:iterator}" />
|
||||
</f:then>
|
||||
<f:else>
|
||||
<f:render partial="List/Item" arguments="{newsItem: newsItem,settings:settings,iterator:iterator}" />
|
||||
</f:else>
|
||||
</f:if>
|
||||
</div>
|
||||
</f:then>
|
||||
<f:else>
|
||||
<p>No news available.</p>
|
||||
</f:else>
|
||||
</f:if>
|
||||
</f:defaultCase>
|
||||
</f:switch>
|
||||
</f:section>
|
||||
|
||||
<f:section name="content">
|
||||
<div class="header">
|
||||
<div class="title">
|
||||
<h2>{contentObjectData.header}</h2>
|
||||
</div>
|
||||
<f:if condition="{settings.listPid}">
|
||||
<f:link.page title="Alle Artikel" pageUid="{settings.listPid}" class="btn">Alle Artikel</f:link.page>
|
||||
</f:if>
|
||||
</div>
|
||||
<!--TYPO3SEARCH_end-->
|
||||
<f:if condition="{news}">
|
||||
<f:then>
|
||||
<div class="news-list-view news-list-{settings.templateLayout}" id="news-container-{contentObjectData.uid}">
|
||||
<f:if condition="{settings.hidePagination}">
|
||||
<f:then>
|
||||
<f:for each="{news}" as="newsItem" iteration="iterator">
|
||||
<f:render section="news-item" arguments="{_all}" />
|
||||
</f:for>
|
||||
</f:then>
|
||||
<f:else>
|
||||
<f:for each="{pagination.paginator.paginatedItems}" as="newsItem" iteration="iterator">
|
||||
<f:render section="news-item" arguments="{_all}" />
|
||||
</f:for>
|
||||
<f:if condition="{settings.list.paginate.insertBelow}">
|
||||
<f:render partial="List/Pagination" arguments="{pagination: pagination.pagination, paginator: pagination.paginator}" />
|
||||
</f:if>
|
||||
</f:else>
|
||||
</f:if>
|
||||
</div>
|
||||
</f:then>
|
||||
<f:else>
|
||||
<div class="no-news-found">
|
||||
<f:translate key="list_nonewsfound" />
|
||||
</div>
|
||||
</f:else>
|
||||
</f:if>
|
||||
<!--TYPO3SEARCH_begin-->
|
||||
</f:section>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user