Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

landing page: final changes #1412

Merged
merged 7 commits into from
Jun 8, 2018
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 14 additions & 1 deletion app/assets/v2/css/base.css
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,29 @@ span {

.nav_avatar {
cursor: pointer;
border-radius: 50%;
}

.dropdown-menu{
#navbarDropdown {
text-transform: none;
}

.dropdown-menu {
z-index: 9999999999;
}

.navbar-nav .nav-link {
border-radius: 2px;
}

.nav_avatar,
.navbar__cta,
.nav-item.dropdown,
.navbar-nav .nav-link {
margin-top: auto;
margin-bottom: auto;
}

.nav-link.login i {
font-size: 1.5em;
position: relative;
Expand Down
3 changes: 3 additions & 0 deletions app/assets/v2/css/bounty.css
Original file line number Diff line number Diff line change
Expand Up @@ -366,6 +366,9 @@ a.btn {
max-height: 30rem;
max-width: 30rem;
cursor: pointer;
display: block;
margin-top: 1rem;
margin-bottom: 1rem;
}

#bounty_details #issue_description h1,
Expand Down
38 changes: 29 additions & 9 deletions app/assets/v2/css/landing_page.css
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,10 @@ body {
display: none !important;
}

.navbar-nav .nav-link:last-child {
padding-right: 0 !important;
}

.banner--green {
background-color:#0ECF7C;
}

.landing__newsletter {
width: 100%;
margin: auto;
}

.youtube iframe {
max-width: 100%;
}
Expand Down Expand Up @@ -195,6 +186,22 @@ body {
padding-bottom: 1rem;
}

.landing__newsletter {
width: 100%;
margin: auto;
}

.landing__newsletter .newsletter {
border-top: none;
margin-top: 0;
}

.landing__newsletter .newsletter h4 {
padding-top: 1.25rem;
padding-bottom: 0.5rem;
font-weight: normal;
}

.pilot_container {
background: white;
}
Expand Down Expand Up @@ -373,6 +380,7 @@ body {
opacity: 0;
display: none;
transition: opacity .3s;
padding-right: 1rem;
}

.navbar.following .navbar__cta {
Expand Down Expand Up @@ -482,6 +490,18 @@ body {
margin-left: 10rem;
margin-right: 10rem;
}

.newsletter #newsletter-input {
padding: 10px !important;
min-width: 18rem !important;
font-size: 16px !important;
border: 1px solid #888 !important;
}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@SaptakS this only changes the border for larger devices :P


#newsletter-subscribe {
height: 46px;
top: -1px;
}
}

@media (max-width: 575.98px) {
Expand Down
2 changes: 1 addition & 1 deletion app/dashboard/templates/shared/nav_auth.html
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@
</a>
</div>
</div>
<img class="nav_avatar" width=50 height=50
<img class="nav_avatar" width=40 height=40
src="/static/avatar/{% if user and user.username %}{{ user.username }}{% else %}Self{% endif %}">
{% else %}
<a class="nav-link login" href="{% url 'social:begin' 'github' %}?next={{ request.get_full_path }}"
Expand Down
11 changes: 7 additions & 4 deletions app/dashboard/templates/shared/newsletter.html
Original file line number Diff line number Diff line change
Expand Up @@ -25,17 +25,20 @@ <h4 class="col-12" id="newsletter-title">
{% if newsletter_headline %}
{{ newsletter_headline }}
{% else %}
{% trans "Join Our Newsletter !" %}
{% trans "Join Our Newsletter!" %}
{% endif %}
</h4>
<label for="newsletter-input">({% trans "Emails once a week max, & we never sell your data" %})</label>
{% if not hide_newsletter_caption %}
<label for="newsletter-input">({% trans "Emails once a week max, & we never sell your data" %})</label>
{% endif %}
<div class="col-12">
<input name="EMAIL" placeholder="[email protected]" id="newsletter-input" required>
<input name="EMAIL" id="newsletter-input" required>
<button id="newsletter-subscribe" type="submit" class="addon subscribe"><i class="fas fa-paper-plane" aria-hidden="true"></i></button>
</div>
{% if not hide_newsletter_consent %}
<span style="display: block; margin-top: 3px; font-size: 10px;">
{% trans "You may withdraw email consent at any time" %} | <a href="{% url 'email_settings' email_key %}">{% trans "Manage preferences" %}</a> | <a href="{% url 'email_settings' email_key %}">{% trans "Opt out" %}</a> | <a href="mailto:[email protected]">{% trans "Email us" %}</a>
</span>

{% endif %}
</form>
</div>
9 changes: 4 additions & 5 deletions app/retail/templates/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,10 @@ <h4 class="font-title-lg">{% trans "Grow Your Open Source Community" %}</h4>
</div>
</div>

<div class="container-fluid pb-5 mb-2 landing__newsletter">
{% include 'shared/newsletter.html' %}
</div>

<div class="container-fluid p-5 tree_container white-bg">
<div id="gc-tree">
<img src="{% static "v2/images/gc-tree.png" %}" alt="Gitcoin Tree" />
Expand Down Expand Up @@ -361,11 +365,6 @@ <h2>{% trans "Who's Using Gitcoin?" %}</h2>
</div>
{% include 'landing/pilot.html' %}
{% include 'landing/press.html' %}
<div class="row landing__newsletter">
<div class="col-12 pb-5">
{% include 'shared/newsletter.html' %}
</div>
</div>
{% include 'shared/footer.html' %}
</div>
</div>
Expand Down
12 changes: 6 additions & 6 deletions app/retail/templates/shared/nav.html
Original file line number Diff line number Diff line change
Expand Up @@ -48,14 +48,14 @@
<span class="nav-link__icon hidden"><i class="fas fa-info"></i></span>
<span class="nav-link__text">{% trans " Help" %}</span>
</a>
{% if request.path == '/' %}
<a href="{% url "new_funding" %}" class="btn btn-gc-blue">
<i class="fab fa-ethereum" role="aria-hidden"></i>
Fund an Issue
</a>
{% endif %}
<img class="d-none d-md-block img__spaceship" src="{% static "v2/images/spaceship.png" %}" width="52" height="45" />
{% include 'shared/nav_auth.html' with source='authed' %}
</nav>
{% if request.path == '/' %}
<a href="{% url "new_funding" %}" class="btn btn-gc-blue">
<i class="fab fa-ethereum" role="aria-hidden"></i>
Fund an Issue
</a>
{% endif %}
</div>
</nav>
3 changes: 3 additions & 0 deletions app/retail/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ def index(request):
'slides': slides,
'slideDurationInMs': 6000,
'active': 'home',
'hide_newsletter_caption': True,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the utility of this bool? Are we altering this value at any point? 🤔

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mbeacom I think what @thelostone-mc has done here is he is sending this boolean only to landing-page, which makes it non-hidden in all the other pages. Hence both the caption and consent are shown in every other page except the landing page.

'hide_newsletter_consent': True,
'newsletter_headline': _("Get the Latest Gitcoin News! Join Our Newsletter."),
}
return TemplateResponse(request, 'index.html', context)

Expand Down