From c01ac988d6e2753fd41aa6f4144fcafdbf67dab9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roland=20Schu=CC=88tz?= Date: Wed, 19 May 2021 18:48:34 +0200 Subject: [PATCH] TASK: Easier override of default behavior --- Resources/Private/Fusion/Prototypes/Tag.fusion | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Resources/Private/Fusion/Prototypes/Tag.fusion b/Resources/Private/Fusion/Prototypes/Tag.fusion index 7a00e12..3cb7e1f 100755 --- a/Resources/Private/Fusion/Prototypes/Tag.fusion +++ b/Resources/Private/Fusion/Prototypes/Tag.fusion @@ -5,7 +5,7 @@ prototype(CodeQ.Link:Tag) < prototype(Neos.Fusion:Component) { # tag rendering configuration renderDefaultTagIfNoLink = false defaultTagName = 'span' - content = false + content = ${this.linkSource.label} # any additional props will be applied as attributes # feel free to use e.g. id, class or download @@ -20,8 +20,8 @@ prototype(CodeQ.Link:Tag) < prototype(Neos.Fusion:Component) { href = ${props.shouldRenderLinkTag ? props.linkSource.link : false} rel = ${props.shouldRenderLinkTag ? props.linkSource.rel : false} target = ${props.shouldRenderLinkTag ? props.linkSource.target : false} - class = ${props.class == false ? props.attributes.class : String.trim(props.class + ' ' + props.attributes.class)} + class = ${Type.isString(props.class) ? String.trim(props.class) : props.class} } - content = ${props.content || props.linkSource.label} + content = ${props.content} } }