<html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers"
	  xmlns:events="http://typo3.org/ns/GeorgRinger/Eventnews/ViewHelpers"
	  xmlns:n="http://typo3.org/ns/GeorgRinger/News/ViewHelpers"
	  data-namespace-typo3-fluid="true">

<n:excludeDisplayedNews newsItem="{newsItem}" />
<div class="text-bg-light p-4 mb-3">
	<div class="">
		<n:link newsItem="{newsItem}" settings="{settings}" title="{newsItem.title}">
			<f:if condition="{newsItem.mediaPreviews}">
				<f:then>
					<f:media class="img-responsive" file="{newsItem.mediaPreviews.0}" title="{mediaElement.originalResource.title}" alt="{mediaElement.originalResource.alternative}" width="{f:if(condition: settings.media.maxWidth, then: settings.media.maxWidth, else: settings.list.media.image.width)}" height="{f:if(condition: settings.media.maxHeight, then: settings.media.maxHeight, else:'')}" />
				</f:then>
				<f:else>
					<f:if condition="{settings.displayDummyIfNoMedia}">
						<f:image class="img-dummy img-responsive" src="{settings.list.media.dummyImage}" title="" alt="" maxWidth="{settings.list.media.image.maxWidth}" maxHeight="{settings.list.media.image.maxHeight}" />
					</f:if>
				</f:else>
			</f:if>
		</n:link>
	</div>

	<div class=" articletype-{newsItem.type}{f:if(condition: newsItem.istopnews, then: ' topnews')}" itemscope="itemscope" itemtype="http://schema.org/Article">
		<h3 itemprop="headline">
			<n:link newsItem="{newsItem}" settings="{settings}" title="{newsItem.title}">
				{newsItem.title}
			</n:link>
		</h3>

		<f:render partial="General/AdditionalInformation" arguments="{settings:settings,newsItem:newsItem}" />

		<!-- teaser -->
		<div class="lead" itemprop="description">
			<n:removeMediaTags>
				<f:if condition="{newsItem.teaser}">
					<f:then>
						{newsItem.teaser -> f:format.crop(maxCharacters: '{settings.cropMaxCharacters}', respectWordBoundaries:'1') -> f:format.html()}
					</f:then>
					<f:else>
						{newsItem.bodytext -> f:format.crop(maxCharacters: '{settings.cropMaxCharacters}', respectWordBoundaries:'1') -> f:format.html()}
					</f:else>
				</f:if>
			</n:removeMediaTags>
		</div>

		<n:link newsItem="{newsItem}" settings="{settings}" class="btn btn-default btn-read-more" title="{newsItem.title}">
			<f:translate key="more-link" />
		</n:link>
	</div>
</div>



</html>
