diff --git a/docs/stylesheets/extra.css b/docs/stylesheets/extra.css index 1318c60d4..0766a1a71 100644 --- a/docs/stylesheets/extra.css +++ b/docs/stylesheets/extra.css @@ -82,6 +82,112 @@ /*Make definition list definitions stand out*/ .md-typeset dt { - font-weight: bold; - font-style: italic; + font-weight: bold; + font-style: italic; +} + +/* Cookie Banner */ +#cookieModal { + position: fixed; + top: 0; + left: 0; + z-index: 9999; + display: none; + width: 100%; + height: 100%; + overflow: hidden; + outline: 0; +} + +#cookieModal .modal-dialog .opt-out { + display: none; +} + +.modal-dialog { + position: fixed; + margin: 0; + top: 35px; + max-width: -webkit-fit-content; + max-width: -moz-fit-content; + max-width: fit-content; + left: 5%; + padding-left: 8%; + padding-right: 8%; + color: black; +} + +.cookienotice { + overflow: hidden; + outline: 0; + position: fixed; + display: none; + padding-top: 15px; + bottom: 0; + right: 0; + left: 0; + background: #c3c3c3; + z-index: 1000; + text-align: center; + color: black; +} + +.cookienotice .text { + float: left; + margin-left: 15px; + margin-right: 100px; + font-size: .875rem; +} + +.cookienotice .text p { + margin-top: 0; +} + +.cookienotice .buttons { + position: fixed; + right: 0; + float: right; + padding-right: 15px; +} + +.cookienotice .buttons .close { + margin-right: 15px; + top: 0; + float: right; + font-size: 1.5rem; + font-weight: 700; + line-height: 1; + color: #000; + text-shadow: 0 1px 0 #fff; + opacity: .5; + cursor: pointer; +} + +.cookienotice .buttons .ok { + background: #6695ca; + color: #fff; + margin-right: 15px; + padding: .25rem .5rem; + font-size: .875rem; + line-height: 1.5; + border-radius: 0; + cursor: pointer; +} + +.modal-body { + position: relative; + flex: auto; + padding: 1rem; +} + +.modal-content { + box-shadow: 1px 1px 4px #000000; + position: relative; + display: flex; + flex-direction: column; + width: 100%; + pointer-events: auto; + background-color: #fff; + background-clip: padding-box; + border: 1px solid rgba(0,0,0,.2); + outline: 0; } diff --git a/hack/build.sh b/hack/build.sh index 7a93e8791..7771b0ca5 100755 --- a/hack/build.sh +++ b/hack/build.sh @@ -117,12 +117,15 @@ if [ -z "$SKIP_BLOG" ]; then find . -type f -path '*/content/*.md' \ -exec sed -i '/](/ { /http/ !{s#\.md##g} }' {} + + # Move about cookie page in. + cp -rfv content-override/en/about-analytics-cookies.md content/en/ + # Run the hugo build as normal! hugo popd # Hugo builds to public/, just copy over to site/ to match up with mkdocs - for d in blog community css scss webfonts images js; do + for d in blog community css scss webfonts images js "about-analytics-cookies"; do mv temp/website/public/$d site/ done diff --git a/overrides/home.html b/overrides/home.html index ff3d34c39..fd3dbf346 100644 --- a/overrides/home.html +++ b/overrides/home.html @@ -178,4 +178,35 @@ {% endblock %} -{% block footer %}{% endblock %} +{% block footer %} + + +
+
+

We use analytics and cookies to understand site traffic. Information about your use of + our site is shared with Google for that purpose. Learn more. +

+
+
+ × + OK +
+
+{% endblock %} diff --git a/overrides/main.html b/overrides/main.html index 6fa5ef26c..f32a25566 100644 --- a/overrides/main.html +++ b/overrides/main.html @@ -11,3 +11,10 @@ {% endif %} {% endblock %} +{% block scripts %} + {{ super() }} + + + + +{% endblock %} diff --git a/overrides/partials/footer.html b/overrides/partials/footer.html index 50abea651..77f4c7b0d 100644 --- a/overrides/partials/footer.html +++ b/overrides/partials/footer.html @@ -84,3 +84,33 @@ + + +
+
+

We use analytics and cookies to understand site traffic. Information about your use of + our site is shared with Google for that purpose. Learn more. +

+
+
+ × + OK +
+