-
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.
Initial tidy of show Initiative page
- Loading branch information
Showing
17 changed files
with
120 additions
and
101 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,62 +1,81 @@ | ||
|
||
<p> | ||
Status: <%=initiative.status_name%><br /> | ||
<h2 class="u-mb">Description</h2> | ||
<div class="u-mb"> | ||
<p>What: <%=initiative.description_what%></p> | ||
<p>How: <%=initiative.description_how%></p> | ||
<% if initiative.anticipated_carbon_saving.present? %> | ||
Saving: <%=format_carbon_saving(initiative.anticipated_carbon_saving)%> | ||
<p>Saving: <%=format_carbon_saving(initiative.anticipated_carbon_saving)%></p> | ||
<% end %> | ||
</p> | ||
<p>Further Information: <%=initiative.description_further_information%></p> | ||
</div> | ||
|
||
<h2>Description</h2> | ||
<p>What: <%=initiative.description_what%></p> | ||
<p>How: <%=initiative.description_how%></p> | ||
<p>Further Information: <%=initiative.description_further_information%></p> | ||
<div class="Initiative-images_scroller"> | ||
<div class="Initiative-images"> | ||
<% initiative.images.each do |image|%> | ||
<%= image_tag image.variant(resize_to_limit: [200, 200]) %> | ||
<% end %> | ||
</div> | ||
</div> | ||
<h2>Solutions</h2> | ||
<% initiative.themes.each do |theme| %> | ||
<p>Theme: <%=theme.name%></p> | ||
<% end %> | ||
<% initiative.solutions.each do |solution| %> | ||
<p>Solution: <%=solution.name%></p> | ||
<% end %> | ||
<h2>Contacts</h2> | ||
<p>Lead Group: <%=initiative.lead_group_name%></p> | ||
<% if initiative.consent_to_share? %> | ||
<p>Contact Name: <%=initiative.contact_name%></p> | ||
<p>Contact Email: <%=initiative.contact_email%></p> | ||
<p>Contact Phone: <%=initiative.contact_phone%></p> | ||
<% end %> | ||
<p>Partner Groups Role: <%=initiative.partner_groups_role%></p> | ||
<% if initiative.related_initiatives? %> | ||
<p>Related Initiatives: <%=initiative.related_initiatives%></p> | ||
<% end %> | ||
<h2>Websites</h2> | ||
<% initiative.websites.each do |website| %> | ||
<%=link_to website.website, website.website, target: '_blank' %> | ||
|
||
<h2 class="u-mb">Solutions</h2> | ||
<div class="u-mb"> | ||
<ul class="u-listBulleted"> | ||
<% initiative.themes.each do |theme| %> | ||
<li>Theme: <%=theme.name%></li> | ||
<% end %> | ||
</ul> | ||
<% if initiative.solutions.any? %> | ||
<ul class="u-listBulleted"> | ||
<% initiative.solutions.each do |solution| %> | ||
<li>Solution: <%=solution.name%></li> | ||
<% end %> | ||
</ul> | ||
<% end %> | ||
</div> | ||
|
||
<h2 class="u-mb">Contacts</h2> | ||
<div class="u-mb"> | ||
<p>Lead Group: <%=initiative.lead_group_name%></p> | ||
<% if initiative.consent_to_share? %> | ||
<p>Contact Name: <%=initiative.contact_name%></p> | ||
<p>Contact Email: <%=initiative.contact_email%></p> | ||
<p>Contact Phone: <%=initiative.contact_phone%></p> | ||
<% end %> | ||
<p>Partner Groups Role: <%=initiative.partner_groups_role%></p> | ||
<% if initiative.related_initiatives? %> | ||
<p>Related Initiatives: <%=initiative.related_initiatives%></p> | ||
<% end %> | ||
</div> | ||
|
||
<% if initiative.websites.any? %> | ||
<h2 class="u-mb">Websites</h2> | ||
<div class="u-mb"> | ||
<ul class="u-listBulleted"> | ||
<% initiative.websites.each do |website| %> | ||
<li><%=link_to website.website, website.website, target: '_blank' %></li> | ||
<% end %> | ||
</ul> | ||
</div> | ||
<% end %> | ||
|
||
<% if local_assigns[:show_map] && show_map %> | ||
<h2>Location</h2> | ||
<p>Postcode: <%=initiative.postcode%></p> | ||
<p>Locality: <%=initiative.location%></p> | ||
<div class="Explore"> | ||
<h2 class="u-mb">Location</h2> | ||
<div class="u-mb"> | ||
<p>Postcode: <%=initiative.postcode%></p> | ||
<p>Locality: <%=initiative.location%></p> | ||
</div> | ||
<div class="Explore u-mb"> | ||
<% content_for :page_javascript do %> | ||
<script type="text/json" id="map_data_json"><%=@map_data.to_json.html_safe%></script> | ||
<%= javascript_packs_with_chunks_tag 'initiative_map', 'data-turbolinks-track': 'reload' %> | ||
<% content_for :page_head do %> | ||
<meta name="turbolinks-visit-control" content="reload"> | ||
<% end %> | ||
|
||
<% end %> | ||
<div class="Explore-map" id="initiative_location"></div> | ||
</div> | ||
<% end %> | ||
|
||
<h2>Timestamps</h2> | ||
<p>Created: <%=time_tag initiative.created_at%></p> | ||
<p>Updated: <%=time_tag initiative.updated_at%></p> | ||
<div class="u-textRight u-textMuted"> | ||
<p>Initiative Created: <%=time_tag initiative.created_at%></p> | ||
<p>Last Updated: <%=time_tag initiative.updated_at%></p> | ||
</div> |
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 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
/* | ||
* Extends SUIT CSS utilities: display, text | ||
* https://github.com/suitcss/utils-display | ||
* https://github.com/suitcss/utils-text | ||
*/ | ||
|
||
.u-mb { | ||
margin-bottom: $space-base !important; | ||
} | ||
|
||
.u-mbL { | ||
margin-bottom: $space-large !important; | ||
} | ||
|
||
.u-textMuted { | ||
color: #76767a !important; | ||
} | ||
|
||
.u-listBulleted { | ||
list-style: disc !important; | ||
padding-left: 20px !important; | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,8 @@ | ||
.Container { | ||
margin-left: auto; | ||
margin-right: auto; | ||
} | ||
|
||
@media (--bp-tablet-landscape) { | ||
|
||
.Container { | ||
@media (--bp-tablet-landscape) { | ||
max-width: 1180px; | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,3 @@ | |
margin-top: 20px; | ||
padding: 20px; | ||
} | ||
|
||
.Initiative p { | ||
margin: 0; | ||
} |
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 |
---|---|---|
|
@@ -7,6 +7,7 @@ | |
} | ||
|
||
.Nav a { | ||
color: #fff; | ||
font-size: 1.1em; | ||
font-weight: 600; | ||
line-height: 1.8em; | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
.sponsors { | ||
padding-top: 20px; | ||
} | ||
|
||
.sponsors-logos { | ||
display: flex; | ||
justify-content: space-evenly; | ||
|
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