-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #63 from TACC/task/FP-862-load-branding-from-cms
Task/fp 862 load branding from cms
- Loading branch information
Showing
9 changed files
with
142 additions
and
78 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
{# WARNING: Some markup is duplicated in other repositories #} | ||
{# SEE: https://confluence.tacc.utexas.edu/x/LoCnCQ #} | ||
{# FAQ: Extra lines exist to ease CMS/Portal/Guide template comparison #} | ||
|
||
<!-- Sponsor Logos --> | ||
{% include "header_branding.html" %} | ||
|
||
<!-- Navigation Bar --> | ||
<nav id="s-header" class="s-header navbar {% if settings.PORTAL %}navbar-expand-xl{% else %}navbar-expand-lg{% endif %} navbar-dark"> | ||
<!-- Portal Logo --> | ||
{% include "header_logo.html" %} | ||
|
||
<!-- Navbar Accordian Toggle on Small Screens --> | ||
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarsExpandTarget" aria-controls="navbarsExpandTarget" aria-expanded="false" aria-label="Toggle navigation"> | ||
<span class="navbar-toggler-icon"></span> | ||
</button> | ||
|
||
<!-- Navbar Links --> | ||
<div class="collapse navbar-collapse" id="navbarsExpandTarget"> | ||
{# GL-6: Remove need for different `className` values #} | ||
{% if settings.PORTAL %} | ||
{# FAQ: If template were included with `only`, then it would NOT render `show_menu` #} | ||
{% include "nav_cms.html" with className="navbar-nav" %} | ||
|
||
{# NOTE: As of 2020-12, search is only available with a Portal #} | ||
{% include "nav_search.html" with className="form-inline ml-auto" only %} | ||
{% include "nav_portal.html" with className="navbar-nav" settings=settings only %} | ||
{% else %} | ||
{# FAQ: If template were included with `only`, then it would NOT render `show_menu` #} | ||
{% include "nav_cms.html" with className="navbar-nav ml-auto" %} | ||
{% endif %} | ||
</div> | ||
</nav> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{# @var brands, className #} | ||
{% load staticfiles custom_portal_settings %} | ||
|
||
{% with settings.BRANDING as brands %} | ||
<div id="header-branding" class="branding-header {{className}}"> | ||
{# DEBUG: #}{# <code>{{ brands|first }}</code> #} | ||
{% for brand in brands %} | ||
{% with filename=brand|index:1 selectors=brand|index:2 targeturl=brand|index:3 targetType=brand|index:4 accessibility=brand|index:5 corstype=brand|index:6 visibility=brand|index:7 %} | ||
{% if visibility == "True" %} | ||
{% if brand == brands|first %} | ||
<a href="{{ targeturl }}" target="{{ targettype }}"> | ||
<img class="branding-logo {{ selectors }}" src="{% static filename %}" crossorigin="{{ corstype }}" alt="{{ accessibility }}" > | ||
</a> | ||
{% elif brand != brands|first %} | ||
{# RFE: Use CSS to remove the need for `.branding-seperator` and `if` logic #} | ||
<span class="branding-seperator"></span> | ||
<a href="{{ targeturl }}" target="{{ targettype }}"> | ||
<img class="branding-logo {{ selectors }}" src="{% static filename %}" crossorigin="{{ corstype }}" alt="{{ accessibility }}" > | ||
</a> | ||
{% endif %} | ||
{% endif %} | ||
{% endwith %} | ||
{% endfor %} | ||
</div> | ||
{% endwith %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{# @var logo, className #} | ||
{% load staticfiles custom_portal_settings %} | ||
|
||
{% with settings.LOGO as logo %} | ||
{% with filename=logo|index:1 selectors=logo|index:2 targeturl=logo|index:3 targetType=logo|index:4 accessibility=logo|index:5 corstype=logo|index:6 visibility=logo|index:7 %} | ||
{% if visibility == "True" %} | ||
<a id="header-logo" class="navbar-brand {{className}}" href="{{ targeturl }}" target="{{ targettype }}"> | ||
<img class="portal-logo {{ selectors }}" src="{% static filename %}" crossorigin="{{ corstype }}" alt="{{ accessibility }}" > | ||
</a> | ||
{% endif %} | ||
{% endwith %} | ||
{% endwith %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters