Skip to content

Commit

Permalink
Merge 6e87542 into 8920cc2
Browse files Browse the repository at this point in the history
  • Loading branch information
rstorey committed Apr 22, 2019
2 parents 8920cc2 + 6e87542 commit 190cda9
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 15 deletions.
2 changes: 2 additions & 0 deletions concordia/context_processors.py
@@ -1,4 +1,5 @@
from django.conf import settings
from flags.state import flag_enabled

from concordia.version import get_concordia_version

Expand All @@ -14,6 +15,7 @@ def system_configuration(request):
"S3_BUCKET_NAME": getattr(settings, "S3_BUCKET_NAME", None),
"APPLICATION_VERSION": get_concordia_version(),
"RAVEN_CONFIG": settings.RAVEN_CONFIG,
"NEW_CAROUSEL_SLIDE": flag_enabled("NEW_CAROUSEL_SLIDE", request=request),
}


Expand Down
2 changes: 1 addition & 1 deletion concordia/settings_template.py
Expand Up @@ -309,4 +309,4 @@
DEFAULT_PAGE_TTL = 5 * 60

# Feature flag for social share
FLAGS = {"SOCIAL_SHARE": []}
FLAGS = {"SOCIAL_SHARE": [], "NEW_CAROUSEL_SLIDE": []}
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
55 changes: 41 additions & 14 deletions concordia/templates/home.html
Expand Up @@ -11,21 +11,40 @@
<div class="row no-gutters px-sm-3">
<div class="col-12">
<div id="homepage-carousel" class="carousel slide" data-ride="carousel" data-pause="hover">

<ol class="carousel-indicators d-none d-lg-flex">
<li data-target="#homepage-carousel" data-slide-to="0" class="active"></li>
<li data-target="#homepage-carousel" data-slide-to="1"></li>
<li data-target="#homepage-carousel" data-slide-to="2"></li>
{% if NEW_CAROUSEL_SLIDE %}
<li data-target="#homepage-carousel" data-slide-to="3"></li>
{% endif %}
</ol>
<div class="carousel-inner">
<div class="carousel-item active" data-title="Jump in!" data-hero-text="Transcription uncovers our shared history and makes documents more searchable for everyone." data-link-url="{% url 'transcriptions:redirect-to-next-transcribable-asset' 'mary-church-terrell-advocate-for-african-americans-and-women' %}">
<img class="d-block w-100" src="{% static 'img/homepage-carousel/crowd-home.jpg' %}" alt="A crowd of young women cheering and waving handkerchiefs">
</div>
<div class="carousel-item" data-overlay-position="top-right" data-title="Review Now" data-hero-text="Approve or correct other volunteers' transcriptions to help them cross the finish line." data-link-url="{% url 'transcriptions:redirect-to-next-reviewable-asset' 'mary-church-terrell-advocate-for-african-americans-and-women' %}">
<img class="d-block w-100" src="{% static 'img/homepage-carousel/review.jpg' %}" alt="Close up of hand-written text of Mary Church Terrell's first speech to the NAACP">
</div>
<div class="carousel-item" data-title="Where to start?" data-hero-text="Find instructions and help to get started in our Welcome Guide" data-link-url="{% url 'welcome-guide' %}">
<img class="d-block w-100" src="{% static 'img/homepage-carousel/welcome-guide.jpg' %}" alt="Collection of typed report pages by baseball scout Branch Rickey">
</div>
{% if NEW_CAROUSEL_SLIDE %}
<div class="carousel-item active" data-title="Walt Whitman at 200" data-hero-text="Transcribe and review poetry, letters, and writings of Walt Whitman. Discover how he wrote and lived for yourself." data-link-url="{% url 'transcriptions:redirect-to-next-transcribable-asset' 'walt-whitman' %}">
<img class="d-block w-100" src="{% static 'img/homepage-carousel/whitman.jpg' %}" alt="Walt Whitman in his younger years, a black and white engraving. Whitman with his right hand on his hip and his left in his pocket wearing a black rimmed hat.">
</div>
<div class="carousel-item" data-overlay-position="top-right" data-title="Review Now" data-hero-text="Approve or correct other volunteers' transcriptions to help them cross the finish line." data-link-url="{% url 'transcriptions:redirect-to-next-reviewable-asset' 'mary-church-terrell-advocate-for-african-americans-and-women' %}">
<img class="d-block w-100" src="{% static 'img/homepage-carousel/review.jpg' %}" alt="Close up of hand-written text of Mary Church Terrell's first speech to the NAACP">
</div>
<div class="carousel-item" data-title="Where to start?" data-hero-text="Find instructions and help to get started in our Welcome Guide" data-link-url="{% url 'welcome-guide' %}">
<img class="d-block w-100" src="{% static 'img/homepage-carousel/welcome-guide.jpg' %}" alt="Collection of typed report pages by baseball scout Branch Rickey">
</div>
<div class="carousel-item" data-overlay-position="top-right" data-title="Jump in!" data-hero-text="Transcription uncovers our shared history and makes documents more searchable for everyone." data-link-url="{% url 'transcriptions:redirect-to-next-transcribable-asset' 'mary-church-terrell-advocate-for-african-americans-and-women' %}">
<img class="d-block w-100" src="{% static 'img/homepage-carousel/crowd-home.jpg' %}" alt="A crowd of young women cheering and waving handkerchiefs">
</div>
{% else %}
<div class="carousel-item active" data-title="Jump in!" data-hero-text="Transcription uncovers our shared history and makes documents more searchable for everyone." data-link-url="{% url 'transcriptions:redirect-to-next-transcribable-asset' 'mary-church-terrell-advocate-for-african-americans-and-women' %}">
<img class="d-block w-100" src="{% static 'img/homepage-carousel/crowd-home.jpg' %}" alt="A crowd of young women cheering and waving handkerchiefs">
</div>
<div class="carousel-item" data-overlay-position="top-right" data-title="Review Now" data-hero-text="Approve or correct other volunteers' transcriptions to help them cross the finish line." data-link-url="{% url 'transcriptions:redirect-to-next-reviewable-asset' 'mary-church-terrell-advocate-for-african-americans-and-women' %}">
<img class="d-block w-100" src="{% static 'img/homepage-carousel/review.jpg' %}" alt="Close up of hand-written text of Mary Church Terrell's first speech to the NAACP">
</div>
<div class="carousel-item" data-title="Where to start?" data-hero-text="Find instructions and help to get started in our Welcome Guide" data-link-url="{% url 'welcome-guide' %}">
<img class="d-block w-100" src="{% static 'img/homepage-carousel/welcome-guide.jpg' %}" alt="Collection of typed report pages by baseball scout Branch Rickey">
</div>
{% endif %}
</div>
<a class="carousel-control-prev" href="#homepage-carousel" role="button" data-slide="prev">
<span class="carousel-control-prev-icon" aria-hidden="true"></span>
Expand All @@ -35,11 +54,19 @@
<span class="carousel-control-next-icon" aria-hidden="true"></span>
<span class="sr-only">Next</span>
</a>
<div class="carousel-overlay text-center d-flex flex-column justify-content-around align-items-center">
<h1 class="title">Jump in!</h1>
<p class="hero-text mx-auto">Transcription uncovers our shared history and makes documents more searchable for everyone.</p>
<a class="btn btn-primary btn-lg" href="{% url 'transcriptions:redirect-to-next-transcribable-asset' 'mary-church-terrell-advocate-for-african-americans-and-women' %}">LET'S GO!</a>
</div>
{% if NEW_CAROUSEL_SLIDE %}
<div class="carousel-overlay text-center d-flex flex-column justify-content-around align-items-center">
<h1 class="title">Walt Whitman at 200</h1>
<p class="hero-text mx-auto">Transcribe and review poetry, letters, and writings of Walt Whitman. Discover how he wrote and lived for yourself.</p>
<a class="btn btn-primary btn-lg" href="{% url 'transcriptions:redirect-to-next-transcribable-asset' 'walt-whitman' %}">LET'S GO!</a>
</div>
{% else %}
<div class="carousel-overlay text-center d-flex flex-column justify-content-around align-items-center">
<h1 class="title">Jump in!</h1>
<p class="hero-text mx-auto">Transcription uncovers our shared history and makes documents more searchable for everyone.</p>
<a class="btn btn-primary btn-lg" href="{% url 'transcriptions:redirect-to-next-transcribable-asset' 'mary-church-terrell-advocate-for-african-americans-and-women' %}">LET'S GO!</a>
</div>
{% endif %}
</div>
</div>
</div>
Expand Down

0 comments on commit 190cda9

Please sign in to comment.