NEWSROOM-APP (component )

src/app/shared/components/newsroom-app/templates

Demo Section

Each variation will be presented in the following section.

News


Events List


Readme

newsroomApp (component)

Description

This blueprint is based on the blueprint of Veams.


Requirements

  • Veams#5.0.0

Installation

Installation with Veams from local machine

veams install bp absolute/filepath/to/newsroom-app


Fields

newsroom-app.hbs

Settings

Parameter Type Default Description
settings.newsroomAppClasses String '' Modifier classes for component
settings.newsroomAppContextClass String 'default' Context class of component

Content

Parameter Type Description
content.newsroomAppField String Please add a description!

SASS

Variables

There are multiple variables which you can change:

Variable Value Description
$newsroom-app-my-custom-var 0px Please add a description!

Modifier Classes

There are modifier classes you can add to c-newsroom-app:

Modifier Description
is-modifier Please add a description!

/* $CMS_SET(set_ft_imgTitle, “”) $$CMS_SET(set_ft_imgCopyrightTitle, “”)$

$CMS_IF(#global.context.getVariableNames().contains(“set_ft_image”))$$– –$$CMS_IF(!set_ft_image.isEmpty && !set_ft_image.isNull)$$– –$$CMS_IF(#global.context.getVariableNames().contains(“set_ft_imgDescriptionTitle”))$$– –$$CMS_IF(!set_ft_imgDescriptionTitle.isEmpty && !set_ft_imgDescriptionTitle.isNull && set_ft_imgDescriptionTitle != “”)$$– –$$CMS_ELSE$$– –$$CMS_SET(set_ft_imgDescriptionTitle,"")$$– –$$CMS_END_IF$$– –$$CMS_ELSE$$– –$$CMS_SET(set_ft_imgDescriptionTitle,"")$$– –$$CMS_END_IF$$–

	--$$CMS_IF(!ref(set_ft_image).meta("FS_0x8298","none").isEmpty && !ref(set_ft_image).meta("FS_0x8298","none").isNull && ref(set_ft_image).meta("FS_0x8298","none") != null && ref(set_ft_image).meta("FS_0x8298","none").toString != "")$$--
		--$$CMS_SET(set_ft_imgCopyrightTitle, ref(set_ft_image).meta("FS_0x8298","none").replaceAll("\"","").replaceAll("'","´").replaceAll("\n","").replaceAll("\r",""))$$--
	--$$CMS_ELSE$$--
		--$$CMS_SET(set_ft_imgCopyrightTitle, "")$$--
	--$$CMS_END_IF$$--

	--$$CMS_IF(set_ft_imgCopyrightTitle != "")$$--
		--$$CMS_IF(set_ft_imgDescriptionTitle.toString() != "")$$--
			--$$CMS_SET(set_ft_imgTitle, set_ft_imgDescriptionTitle + " | © " + set_ft_imgCopyrightTitle)$$--
		--$$CMS_ELSE$$--
			--$$CMS_SET(set_ft_imgTitle, "© " + set_ft_imgCopyrightTitle)$$--
		--$$CMS_END_IF$$--
	--$$CMS_ELSE$$--
		--$$CMS_IF(set_ft_imgDescriptionTitle != "")$$--
			--$$CMS_SET(set_ft_imgTitle, set_ft_imgDescriptionTitle)$$--
		--$$CMS_END_IF$$--
	--$$CMS_END_IF$$--
--$$CMS_END_IF$$--

–$$CMS_END_IF$$–

–$$CMS_VALUE(set_ft_imgTitle)$$– –$$CMS_SET(set_ft_image, null)$$– –$$CMS_SET(set_ft_imgdescriptionTitle, “”)$ */

Templates

newsroom-app.hbs

<div id="{{settings.newsroomAppId}}"
	class="c-newsroom-app{{#if settings.newsroomAppContextClass}}--{{settings.newsroomAppContextClass}}{{else}}--default{{/if}}{{#if settings.newsroomAppClasses}} {{settings.newsroomAppClasses}}{{/if}}"
	data-css="c-newsroom-app"
	data-config='{
		"baseURL": "{{content.baseURL}}",
		"baseURL_v3": "{{content.baseURL_v3}}",
		"document": "{{content.document}}",
		"document_v3": "{{content.document_v3}}",
		"mediaMasterDocument": "{{content.mediaMasterDocument}}",
		"eventDurationFilter": "{{content.eventDurationFilter}}",
		"filters": {{#if content.filters}}{{{json content.filters}}}{{else}}[]{{/if}},
		"frontendpath": "{{content.frontendpath}}",
		"cdnpath": "{{content.cdnpath}}",
		"lng": "{{content.lng}}",
		"translatedlng": "{{content.translatedlng}}",
		"thema": "{{content.thema}}",
		"stage": "{{content.stage}}",
		"format": "{{content.format}}",
		{{#if content.pageSize}}"pageSize": {{content.pageSize}},
		{{/if}}
		"version3": {{#if content.version3}}true{{else}}false{{/if}},
		"categoryHeadline": "{{content.categoryHeadline}}"
	}'
	data-lmu-app="newsroom-app"
	>
	<newsroom-app>
		<!-- Integrieren von Kleeblatt-Lösung der Startseite hier  -->
	</newsroom-app>
</div>

Data File

newsroom-app.hjson

{
	"variations": {
		"news": {
			"docs": {
				"variationName": "News"
			},
			"settings": {
				"newsroomAppContextClass": "default",
				"newsroomAppClasses": "",
				"newsroomAppId": "newsroom-1"
			},
			"content": {
				"baseURL": "https://newsroom.uni-muenchen.de/api/public",
				"baseURL_v3": "https://www.lmu.de/api/caas/error",		
				"document": "/prod_newsroom_public/data_all",
				"document_v3": "30lmu.release.content",		
				"mediaMasterDocument": "00mm.release.content",		
				"filters": ["news", "events"],
				"frontendpath": "https://cms-cdn.uni-muenchen.de/assets",
				"cdnpath": "https://cms-cdn.lmu.de/media",
				"pathAdditionToHosturl": "www.lmu.de",
				"lng": "DE",
				"translatedlng": "DE",		
				"thema": "news",		
				"format": "nr",
				"version3": true,
				"categoryHeadline": "News",
				"pageSize": 5
			}
		},
		"eventfilter": {
			"docs":{
				"variationName": "Events List"
			},
			"settings":{
				"newsroomAppContextClass": "default",
				"newsroomAppClasses":"",
				"newsroomAppId": "newsroom-2"
			},
			"content":{
				"baseURL" : "https://www.lmu.de/api/public",
				"baseURL_v3" : "https://www.lmu.de/api/caas",
				"document" : "/prod_newsroom_public/data_all",
				"document_v3" : "30lmu.release.content",
				"mediaMasterDocument" : "00mm.release.content",
				"frontendpath" : "https://cms-cdn.lmu.de/assets",
				"cdnpath" : "https://cms-cdn.lmu.de/media",					
				"lng" : "DE",
				"thema" : "events",
				"translatedlng" : "DE",
				"format" : "nr",
				"version3" : true,
				"categoryHeadline" : "Event",
				"pathAdditionToHosturl" : "www.lmu.de",
				"eventDurationFilter" : "single",
				"pageSize": 5
			}
		}
	}
}

Styles

newsroom-app.scss

/* ===================================================
component: newsroom-app
=================================================== */

/* ---------------------------------------------------
Global Styles
--------------------------------------------------- */
[data-css="c-newsroom-app"] {
}

/* ---------------------------------------------------
Context: Default
--------------------------------------------------- */
.c-newsroom-app--default {}

HTML Output

News

<div id="newsroom-1" class="c-newsroom-app--default" data-css="c-newsroom-app" data-config='{
		"baseURL": "https://newsroom.uni-muenchen.de/api/public",
		"baseURL_v3": "https://www.lmu.de/api/caas/error",
		"document": "/prod_newsroom_public/data_all",
		"document_v3": "30lmu.release.content",
		"mediaMasterDocument": "00mm.release.content",
		"eventDurationFilter": "",
		"filters": ["news","events"],
		"frontendpath": "https://cms-cdn.uni-muenchen.de/assets",
		"cdnpath": "https://cms-cdn.lmu.de/media",
		"lng": "DE",
		"translatedlng": "DE",
		"thema": "news",
		"stage": "",
		"format": "nr",
		"pageSize": 5,
		"version3": true,
		"categoryHeadline": "News"
	}' data-lmu-app="newsroom-app">
	<newsroom-app>
		<!-- Integrieren von Kleeblatt-Lösung der Startseite hier  -->
	</newsroom-app>
</div>

Events List

<div id="newsroom-2" class="c-newsroom-app--default" data-css="c-newsroom-app" data-config='{
		"baseURL": "https://www.lmu.de/api/public",
		"baseURL_v3": "https://www.lmu.de/api/caas",
		"document": "/prod_newsroom_public/data_all",
		"document_v3": "30lmu.release.content",
		"mediaMasterDocument": "00mm.release.content",
		"eventDurationFilter": "single",
		"filters": [],
		"frontendpath": "https://cms-cdn.lmu.de/assets",
		"cdnpath": "https://cms-cdn.lmu.de/media",
		"lng": "DE",
		"translatedlng": "DE",
		"thema": "events",
		"stage": "",
		"format": "nr",
		"pageSize": 5,
		"version3": true,
		"categoryHeadline": "Event"
	}' data-lmu-app="newsroom-app">
	<newsroom-app>
		<!-- Integrieren von Kleeblatt-Lösung der Startseite hier  -->
	</newsroom-app>
</div>

Wonach suchst du?