-
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.
* Move style and script into assets * Move style and script into assets for navbar * Move error page styles into assets * wip * Fix nonce for mirador link * Fix hero images on landing * Update google tag script * Update nonce syntax * Adds missing stub * Re enable conditional * Remove require * Remove duplicate * move into head * Additional nonce * pull nonce * Allow unsafe * Put full text specs in correct contexts and fix duplicate names * Adjust directives
- Loading branch information
Showing
17 changed files
with
204 additions
and
245 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
// override the addClass method so that a callback can be used | ||
(function($) { | ||
let oldAddClass = $.fn.addClass; | ||
$.fn.addClass = function() { | ||
for (let i in arguments) { | ||
let arg = arguments[i] | ||
if (!!(arg && arg.constructor && arg.call && arg.apply)) { | ||
setTimeout(arg.bind(this)) | ||
delete arguments[i] | ||
} | ||
} | ||
return oldAddClass.apply(this, arguments) | ||
} | ||
|
||
})(jQuery) | ||
|
||
// show and hide the dropdown links properly | ||
$(document).ready(function() { | ||
$('.secondary-nav .nav-link-title').click(function(e) { | ||
const width = window.innerWidth | ||
|| document.documentElement.clientWidth | ||
|| document.body.clientWidth | ||
|
||
$('.secondary-nav .content-yul').addClass('content-show', function() { | ||
const contentBlock = $('.secondary-nav .dropdown.show .menu-block-wrapper')[0] | ||
|
||
if (contentBlock) { | ||
if (width >= 1200) { | ||
$('.content-yul').height(contentBlock.offsetHeight + 20) | ||
} else { | ||
// on devices smaller than 1200px wide, only show the item that was clicked on | ||
$('.secondary-nav .dropdown.show .content-yul').height(contentBlock.offsetHeight + 20) | ||
$('.secondary-nav .dropdown:not(.show) .content-yul').height(0) | ||
} | ||
} else { | ||
$('.content-yul').height(0) | ||
} | ||
}) | ||
}) | ||
|
||
$('body').on('click', function(e) { | ||
if ( | ||
!$(e.target).is('.secondary-nav .nav-link-title') && !$(e.target).is('.secondary-nav .nav-link-title li a')|| | ||
$(e.target).is('.sort-dropdown') || | ||
$(e.target).is('.per-page-dropdown') | ||
) { | ||
$('.secondary-nav .content-yul').removeClass('content-show') | ||
$('.content-yul').height(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 |
---|---|---|
@@ -0,0 +1,51 @@ | ||
/******************************************************** | ||
DEFAULT MOBILE STYLING | ||
********************************************************/ | ||
|
||
.rails-default-error-page { | ||
background-color: #EFEFEF; | ||
color: #2E2F30; | ||
text-align: center; | ||
font-family: arial, sans-serif; | ||
margin: 0; | ||
} | ||
|
||
.rails-default-error-page div.dialog { | ||
width: 95%; | ||
max-width: 33em; | ||
margin: 4em auto 0; | ||
} | ||
|
||
.rails-default-error-page div.dialog > div { | ||
border: 1px solid #CCC; | ||
border-right-color: #999; | ||
border-left-color: #999; | ||
border-bottom-color: #BBB; | ||
border-top: #B00100 solid 4px; | ||
border-top-left-radius: 9px; | ||
border-top-right-radius: 9px; | ||
background-color: white; | ||
padding: 7px 12% 0; | ||
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17); | ||
} | ||
|
||
.rails-default-error-page h1 { | ||
font-size: 100%; | ||
color: #730E15; | ||
line-height: 1.5em; | ||
} | ||
|
||
.rails-default-error-page div.dialog > p { | ||
margin: 0 0 1em; | ||
padding: 1em; | ||
background-color: #F7F7F7; | ||
border: 1px solid #CCC; | ||
border-right-color: #999; | ||
border-left-color: #999; | ||
border-bottom-color: #999; | ||
border-bottom-left-radius: 4px; | ||
border-bottom-right-radius: 4px; | ||
border-top-color: #DADADA; | ||
color: #666; | ||
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17); | ||
} |
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 |
---|---|---|
@@ -1,3 +1,3 @@ | ||
<script type="application/ld+json"> | ||
<script type="application/ld+json" nonce="<%= content_security_policy_nonce %>"> | ||
<%= raw metadata.to_json %> | ||
</script> |
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 |
---|---|---|
@@ -1,7 +1,9 @@ | ||
<!-- Google Tag Manager --> | ||
<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start': | ||
<script nonce="<%= request.content_security_policy_nonce %>"> | ||
(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start': | ||
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0], | ||
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src= | ||
'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f); | ||
})(window,document,'script','dataLayer','GTM-PX75HSF');</script> | ||
<!-- End Google Tag Manager --> | ||
})(window,document,'script','dataLayer','GTM-PX75HSF') | ||
</script> | ||
<!-- End Google Tag Manager --> |
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
Oops, something went wrong.