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

T2 apply design customizations #35

Open
wants to merge 23 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
4e6a591
Applied GW custom design
StudioZut Oct 6, 2016
4926ba9
added solr and fcrepo nohups to gitignore
StudioZut Oct 6, 2016
1eea0a2
readded full institution name
StudioZut Oct 6, 2016
ef92712
applied design changes to new elements from rebase with master
StudioZut Oct 6, 2016
ba96764
replaced plaeholder links with working links (some hardcoded to prod …
StudioZut Oct 7, 2016
dbaa592
fixed Terms link in footer
StudioZut Oct 7, 2016
23c7668
comment and minor css cleanup
StudioZut Oct 17, 2016
0be1890
removed uneeded reference files
StudioZut Oct 17, 2016
32dad3c
removed Featured Work permissions work-around
StudioZut Oct 17, 2016
d7e2847
removed unused partials
StudioZut Oct 17, 2016
e5eb489
added resized liblogo file
StudioZut Oct 20, 2016
034477d
adjust how marketing partial and values are pulled
StudioZut Oct 21, 2016
0c00d49
replaced log with local optimized file
StudioZut Oct 21, 2016
0f3aaeb
replaced placeholder images with interim images
StudioZut Nov 2, 2016
b778ceb
adjusted marketing blurb text and narrower views behavior
StudioZut Nov 2, 2016
dad3c02
adjusted design to work with sufia 7.2 layout changes
StudioZut Nov 3, 2016
a9a15f6
adjusted marketing blurb for narrow views
StudioZut Nov 3, 2016
218d13f
adjustments for cross browser
StudioZut Nov 3, 2016
827e6ef
adjusted marketing blurb margins for better cross browser display, ad…
StudioZut Nov 10, 2016
2c6c484
fixed Sufia issue with navbar-header pushing out of bounds
StudioZut Nov 10, 2016
4e52007
removed placeholder images
StudioZut Nov 10, 2016
0ea7737
changed homepage links to point to local instead of external prod ins…
StudioZut Nov 11, 2016
7917cf0
fixed sufia out-of-bounds issue in auth user header
StudioZut Nov 11, 2016
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
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,7 @@

# Ignore sitemap
public/sitemap.xml
# Ignore nohup
nohup.out
nohup.fcrepo.out
nohup.solr.out
2 changes: 2 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -481,6 +481,7 @@ GEM
simple_form (3.3.1)
actionpack (> 4, < 5.1)
activemodel (> 4, < 5.1)
sitemap (0.3.3)
skydrive (1.2.0)
activesupport
httmultiparty
Expand Down Expand Up @@ -594,6 +595,7 @@ DEPENDENCIES
rspec-rails
sass-rails (~> 5.0)
sdoc (~> 0.4.0)
sitemap
solr_wrapper (>= 0.3)
spring
sqlite3
Expand Down
Binary file added app/assets/images/favicon.ico
Binary file not shown.
Binary file added app/assets/images/featured_econ_336px.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/featured_erpapers_336px.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/featured_etds_336px.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/featured_gwipp_336px.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/image_1_370.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/image_2_370.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/assets/images/image_3_370.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 2 additions & 1 deletion app/assets/stylesheets/application.css
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
* defined in the other CSS/SCSS files in this directory. It is generally better to create a new
* file per style scope.
*
*= require sufia
*= require_tree .
*= require dataTables/bootstrap/3/jquery.dataTables.bootstrap
*= require_self
*/
*/
269 changes: 269 additions & 0 deletions app/assets/stylesheets/gwcustom.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,269 @@
/* GW ScholarSpace customizations */

body { min-width: 400px; }

/* MASTHEAD */
/* hiding Sufia masthead image */
.image-masthead { display: none; }
#masthead { margin-bottom: 2em; }
#masthead.navbar-static-top { min-height: 54px; }
#masthead .container-fluid { padding-right: inherit; }
#masthead .libraries-logo img { height: 38px; }
#masthead .navbar-brand.libraries-logo { padding-top: 8px; }
#masthead .navbar-brand { font-size: 20px; line-height: 21px; }
a#logo.navbar-brand { color: #fff; }
a#logo.navbar-brand:hover { color: #9d9d9d; }
#masthead .col-md-6 { width: 40%; } /* searchbar */
#search-form-header { margin-top: 0.7em; } /* seachbar */
#search-form-header .input-group { margin-bottom: inherit; }
@media screen and (max-width:767px) {
#masthead .col-md-6 { width: initial; }
}
/* fixing out-of-bounds issue with narrow views */
/* first we override the negative margins (-15px) in the navbar-header div */
.container-fluid > .navbar-header {
margin-left: 0;
margin-right: 0;
}
.container-fluid > .navbar-collapse {
margin-right: 0;
}
/* next we reduce the padding/margin (15px) in the logo and hamburger blocks to offset the new margins we just set in the navbar-header container */
@media screen and (max-width:767px) {
.navbar-brand.libraries-logo { padding-left: 0; }
.navbar-toggle { margin-right: 5px; }
}

/* CONTENT CONTAINER */
#content-wrapper {
max-width: 1200px;
min-width: 320px;
}

/* NAVBAR */
/* hiding nav items */
nav.navbar.navbar-default { display:none; }
ul.top-nav-links { display: none; }

/* HOME HEADER */
/* hiding "terms of service" */
#home_header .text-center { display: none; }
/* hiding "share your work" */
#home_header .home_share_work { display: none; }
/* hiding header "login" */
#user_utility_links li.user-login { display: none; }
/* removing gray top and bottom border */
#home_header {
margin-top: -1em;
margin-bottom: 2em;
border-top: none;
border-bottom: none;
}
.marketing-blurb {
margin: 3.4em 2em 0;
border-radius: 15px;
padding: 0 1em 1em;
width: 179%;
position: absolute;
z-index: 900;
background-color: #fff;
}
.marketing-blurb h3 {
margin-top: .7em;
font-size: 23px;
font-weight: bold;
letter-spacing: -0.5px;
}
.sub-blurb {
font-size: 1.15em;
}

.home-header-box {
opacity: 0.8;
}

@media screen and (max-width:1199px) {
.marketing-blurb { width: 273%; }
}

#home_header .home-header-box {
height: 240px;
margin-top: 1.8em;
}
#home_header .box1 {
background-image: image-url('image_1_370.png');
}
#home_header .box2 {
background-image: image-url('image_2_370.png');
}
#home_header .box3 {
background-image: image-url('image_3_370.png');
}

@media screen and (max-width: 991px) {
.marketing-blurb { width: 266%; }
}

@media screen and (max-width: 767px) {
.marketing-blurb {
width: calc(100% - 61px);
position: absolute;
top: .2em;
margin-left: 14px;
margin-right: 14px;
}
.marketing-blurb h3 {
font-size: 20px;
}
.marketing-blurb p {
margin-bottom: 5px;
}
#home_header .home-header-box.box2 { display: none; }
#home_header .home-header-box.box3 { display: none; }
}

/* FEATURED WORKS */
#featured_works h3 {
margin-bottom: 3px;
font-size: 19px;
}
#featured_works .col-sm-3 { padding-right: 2%; }
/* hiding work type field */
#featured_works .col-sm-9 div:nth-child(3) { display: none; }
/* hiding keywords (quick fix to remove commas) */
#featured_works .col-sm-9 div:nth-child(4) {
visibility: hidden;
margin-top: 10px;
}
/* showing keyword anchors (but not the commas) */
#featured_works .col-sm-9 div:nth-child(4) a {
visibility: visible;
color: #fff;
display: inline-block;
padding: .1em .5em;
background-color: #337ab7;
border-radius: .5em;
margin-bottom: .5em;
}
#featured_works .col-sm-9 div:nth-child(4) a:hover {
text-decoration: none;
color: #337ab7;
background-color: inherit;
}
#featured_works img {
width: 115%;
border: 1px solid #999;
margin-bottom: .8em;
}

@media screen and (max-width:767px) {
#featured_works img {
width: 90px;
vertical-align: initial;
}
#featured_works .col-sm-3 {
display: inline-block;
padding-right: 0;
width: 25%;
}
#featured_works .col-sm-9 {
display: inline-block;
vertical-align: top;
width: 74%;
}
}

/* RECENTLY UPLOADED */
#recent_docs th { display: none; }
#recent_docs td { border: 0; }
#recent_docs .table-striped > tbody > tr:nth-of-type(odd) { background-color: initial; }
#recent_docs .table-bordered {
margin-top: 1em;
border: 0;
}

#recent_docs h3 {
font-size: 19px;
margin-top: 2px;
}
#recent_docs td img {
width: 130px;
border: 1px solid #999;
}
#recent_docs p:nth-child(3) { visibility: hidden; }
#recent_docs p:nth-child(3) a {
visibility: visible;
color: #fff;
display: inline-block;
padding: .1em .5em;
background-color: #337ab7;
border-radius: .5em;
margin-bottom: .5em;
}
#recent_docs p:nth-child(3) a:hover, #featured_docs p a:hover {
text-decoration: none;
color: #337ab7;
background-color: inherit;
}

/* FEATURED BLOCK */
#feature-block {
display: flex;
flex-flow: row wrap;
margin-bottom: 1em;
}
.feature-block {
margin: 10px;
flex-basis: calc(50% - 20px); /* width minus margins */
}
.feature-block img {
max-width: 100%;
}
.feature-block div {
position: absolute;
width: calc(50% - 35px); /* width minus margins */
padding: 2%;
font-size: 1.3em;
font-weight: 700;
color: #fff;
background-color: #000;
opacity: 0.9;
}
@media screen and (max-width:991px) {
.feature-block div {
font-size: 1em;
}
}

/* FOOTER */
footer a:hover {
color: #fff;
text-decoration: none;
}
footer .navbar-right {
font-size: 1.3em;
}
footer .navbar-right ul {
padding-left: 0;
}
footer .navbar-right ul li {
display: inline;
padding-right: 1em;
}
@media screen and (max-width:767px) {
footer .navbar-right ul {
padding-left: 0;
}
footer .navbar-right ul li {
display: inherit;
padding-right: 0;
text-align: left;
}
}
footer .navbar-right ul li:last-child {
padding-right: 0;
}

footer .text-left p:first-child {
font-size: .8em;
}
15 changes: 15 additions & 0 deletions app/views/_controls.html.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<nav class="navbar navbar-default navbar-static-top" role="navigation">
<div class="container-fluid">
<div class="row">
<ul class="top-nav-links nav navbar-nav col-sm-5 col-md-6">
<li <%= 'class=active' if current_page?(sufia.root_path) %>><%= link_to 'Home', sufia.root_path, :'data-no-turbolink'=>"true" %></li>
<li <%= 'class=active' if current_page?(sufia.about_path) %>><%= link_to 'About', sufia.about_path, :'data-no-turbolink'=>"true" %></li>
<li <%= 'class=active' if action_name == "help" %>><a href="<%#= sufia.help_path %>">Help</a></li>
<li <%#='class=active' if current_page?(sufia.contact_path) %>><a href="<%#= sufia.contact_path %>">Contact</a></li>
</ul><!-- /.nav -->
<div class="searchbar-right navbar-right col-sm-7 col-md-6">
<%= render partial: 'catalog/search_form' %>
</div>
</div>
</div>
</nav><!-- /.navbar -->
9 changes: 9 additions & 0 deletions app/views/_logo.html.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<a class="navbar-brand libraries-logo" href="https://library.gwu.edu">
<img src="/assets/gw_iddol_libraries_wht_rev_107px.png" alt="loho: GW Libraries">
<!-- <img src="https://scholarspace.library.gwu.edu/assets/gw_iddol_libraries_wht_rev-58be0b47e2d7f727e8ed4b54cd19141536a3d76c02ea881dbc32b39c496a9775.png" alt="logo: GW Libraries">
-->
</a>
<a id="logo" class="navbar-brand" href="<%= sufia.root_path %>" data-no-turbolink="true">
<!--<span class="glyphicon glyphicon-globe"></span>-->
<span class="institution_name"><%=application_name %></span>
</a>
23 changes: 23 additions & 0 deletions app/views/_masthead.html.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<nav id="masthead" class="navbar navbar-inverse navbar-static-top" role="navigation">
<div class="container-fluid">
<!-- Brand and toggle get grouped for better mobile display -->
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#top-navbar-collapse" aria-expanded="false">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<%= render partial: '/logo' %>
</div>

<div class="collapse navbar-collapse" id="top-navbar-collapse">
<%= render partial: '/toolbar' %>

<div class="searchbar-right navbar-right col-sm-7 col-md-6">
<%= render partial: 'catalog/search_form' %>
</div>
<%= render partial: '/user_util_links' %>
</div>
</div>
</nav>
31 changes: 31 additions & 0 deletions app/views/_user_util_links.html.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<ul id="user_utility_links" class="nav navbar-nav navbar-right">
<% if user_signed_in? %>
<li>
<%= link_to sufia.notifications_path do %>
Notifications
<%= render partial: 'users/notify_number' %>
<% end %>
</li>
<li class="dropdown">
<%= link_to sufia.profile_path(current_user), role: 'button', data: { toggle: 'dropdown' }, aria: { haspopup: true, expanded: false} do %>
<span class="sr-only">View</span>
<span class="hidden-xs">&nbsp;<%= current_user.name %></span>
<span class="sr-only"> profile</span>
<span class="fa fa-user"></span>
<span class="caret" ></span>
<% end %>
<ul class="dropdown-menu dropdown-menu-right" role="menu">
<li><%= link_to 'View Profile', sufia.profile_path(current_user) %></li>
<li><%= link_to 'Edit Profile', sufia.edit_profile_path(current_user) %></li>
<li class="divider"></li>
<li><%= link_to 'Logout', main_app.destroy_user_session_path %></li>
</ul>
</li><!-- /.btn-group -->
<% else %>
<li class="user-login">
<%= link_to main_app.new_user_session_path do %>
<span class="glyphicon glyphicon-log-in" aria-hidden="true"></span> Login
<% end %>
</li>
<% end %>
</ul>
Loading