Skip to content
Merged
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@
#set($themeObj = $themeDoc.getObject('FlamingoThemesCode.ThemeClass'))
#if($themeObj)
#set($logoname = $themeObj.getValue('logo'))
#set($logoalt = $themeObj.getValue('logo-description'))
#else
## Retrieve the value from the old color theme used.
#set($themeObj = $themeDoc.getObject('ColorThemes.ColorThemeClass'))
#set($logoname = $themeObj.getValue('logoImage'))
#end
Expand All @@ -45,12 +47,15 @@
#set($logourl = $prefdoc.getAttachmentURL($logo.filename))
#end
#end
#if("$!{logoalt}" == '')
#set($logoalt = $services.localization.render('core.document.header.logo.image.text'))
#end
<div id="companylogo">
<a href="$!xwiki.getURL($services.wiki.currentWikiDescriptor.mainPageReference)" rel="home" ##
title="$escapetool.xml($services.localization.render('core.document.header.logo.anchor.text'))" ##
#if(!$displayPageHeader)class="navbar-brand"#end>##
<span class="sr-only">$services.localization.render('core.document.header.logo.anchor.text')</span>
<img src="$!logourl" ##
alt="$escapetool.xml($services.localization.render('core.document.header.logo.image.text'))"/>##
alt="$escapetool.xml($logoalt)"/>##
</a>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -644,6 +644,19 @@
<validationRegExp/>
<classType>com.xpn.xwiki.objects.classes.StringClass</classType>
</logo>
<logo-description>
<customDisplay/>
<disabled>0</disabled>
<name>logo-description</name>
<number>63</number>
<picker>0</picker>
<prettyName>logo-description</prettyName>
<size>100</size>
<unmodifiable>0</unmodifiable>
<validationMessage/>
<validationRegExp/>
<classType>com.xpn.xwiki.objects.classes.StringClass</classType>
</logo-description>
<navbar-default-bg>
<customDisplay/>
<disabled>0</disabled>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,8 @@
############################
#set($variables = {
"logos": {
"logo": "image"
"logo": "image",
"logo-description": "text"
},
"base-colors": {
"text-color": "color",
Expand Down Expand Up @@ -235,8 +236,16 @@
#foreach($var in $catVar.keySet())
#set($varName = $var)
#set($varType = $catVar.get($varName))
#set($hintKey = "${obj.xWikiClass.name}_${varName}.hint")
#set($hint = $services.localization.render($hintKey))
#if($hint == $hintKey)
#set($hint = $NULL)
#end
&lt;div class="form-group"&gt;
&lt;label for="var-$varName" class="col-xs-12"&gt;@$varName&lt;/label&gt;
#if ($hint)
&lt;span class="col-xs-12 xHint"&gt;$escapetool.xml($hint)&lt;/span&gt;
#end
&lt;div class="col-xs-12"&gt;
#if($varType == 'image')
#fieldImage($varName, $obj)
Expand Down Expand Up @@ -745,6 +754,14 @@ require(['jquery', 'xwiki-l10n!xwiki-flamingo-theme-messages', 'bootstrap'], fun

#iframe {
height: 400px;
}

/* When reworking the DOM of this form, use the standard vertical form structure to avoid hard-coding styles like
this. */
#panel-theme-variables .xHint {
color: $theme.textSecondaryColor;
font-size: smaller;
margin: 0.3em 0;
}</code>
</property>
<property>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ platform.flamingo.themes.defaultvalue=Default
platform.flamingo.themes.lessCode.description=In this field, you can directly write LESS code which will be added into the skin.
platform.flamingo.themes.local=Local
platform.flamingo.themes.global=Global
FlamingoThemesCode.ThemeClass_logo-description.hint=Alternative text for the logo. It should describe the logo's meaning. The localized value associated to the key "core.document.header.logo.image.text" is used by default.

###############################################################################
## Deprecated
Expand Down
Loading