Snog
Well-known member
I'm not a style guru and I've forgotten what they are called. But, it would be nice if style designers could add a comment in the PAGE_CONTAINER template if they change the header section of the template.
Original XF default code:
With comment:
Or if you want to take that into the two sections something like this:
Adding those would greatly improve compatibility between styles and add-ons if everyone did it. It could be accounted for in template modifications much easier that way.
There are probably more places they could be added, but that one is the biggest thorn right now.
Original XF default code:
Code:
<xf:if is="$headerHtml is not empty">
<div class="p-body-header">
{$headerHtml|raw}
</div>
<xf:elseif contentcheck="true" />
<div class="p-body-header">
<xf:contentcheck>
<xf:if contentcheck="true">
<div class="p-title {{ $noH1 ? 'p-title--noH1' : '' }}">
<xf:contentcheck>
<xf:if is="!$noH1">
<h1 class="p-title-value">{$h1}</h1>
</xf:if>
<xf:if contentcheck="true">
<div class="p-title-pageAction"><xf:contentcheck><xf:pageaction /></xf:contentcheck></div>
</xf:if>
</xf:contentcheck>
</div>
</xf:if>
<xf:if is="$description is not empty">
<div class="p-description">{$description}</div>
</xf:if>
</xf:contentcheck>
</div>
</xf:if>
With comment:
Code:
<!--[header]-->
<xf:if is="$headerHtml is not empty">
<div class="p-body-header">
{$headerHtml|raw}
</div>
<xf:elseif contentcheck="true" />
<div class="p-body-header">
<xf:contentcheck>
<xf:if contentcheck="true">
<div class="p-title {{ $noH1 ? 'p-title--noH1' : '' }}">
<xf:contentcheck>
<xf:if is="!$noH1">
<h1 class="p-title-value">{$h1}</h1>
</xf:if>
<xf:if contentcheck="true">
<div class="p-title-pageAction"><xf:contentcheck><xf:pageaction /></xf:contentcheck></div>
</xf:if>
</xf:contentcheck>
</div>
</xf:if>
<xf:if is="$description is not empty">
<div class="p-description">{$description}</div>
</xf:if>
</xf:contentcheck>
</div>
</xf:if>
<!--[/header]-->
Or if you want to take that into the two sections something like this:
Code:
<!--[header]-->
<xf:if is="$headerHtml is not empty">
<!--[headerHtml]-->
<div class="p-body-header">
{$headerHtml|raw}
</div>
<!--[/headerHtml]-->
<xf:elseif contentcheck="true" />
<!--[headerContent]-->
<div class="p-body-header">
<xf:contentcheck>
<xf:if contentcheck="true">
<div class="p-title {{ $noH1 ? 'p-title--noH1' : '' }}">
<xf:contentcheck>
<xf:if is="!$noH1">
<h1 class="p-title-value">{$h1}</h1>
</xf:if>
<xf:if contentcheck="true">
<div class="p-title-pageAction"><xf:contentcheck><xf:pageaction /></xf:contentcheck></div>
</xf:if>
</xf:contentcheck>
</div>
</xf:if>
<xf:if is="$description is not empty">
<div class="p-description">{$description}</div>
</xf:if>
</xf:contentcheck>
</div>
<!--[/headerContent]-->
</xf:if>
<!--[/header]-->
Adding those would greatly improve compatibility between styles and add-ons if everyone did it. It could be accounted for in template modifications much easier that way.
There are probably more places they could be added, but that one is the biggest thorn right now.