Skip to content

Commit

Permalink
Merge pull request #64 from shinyichen/ui
Browse files Browse the repository at this point in the history
UI Styling
  • Loading branch information
shinyichen authored Apr 12, 2021
2 parents 136047c + 94d17e4 commit a1180d8
Show file tree
Hide file tree
Showing 8 changed files with 721 additions and 20 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
*.py[co]
local_config.py
python
.coverage
dump.rdb
# Mac specific files
.DS_Store
13 changes: 11 additions & 2 deletions resolverway/templates/400.html
Original file line number Diff line number Diff line change
@@ -1,10 +1,19 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
{% include "head.html" %}
<title>Error</title>
</head>
<body>
<h3>The requested resource does not exist.</h3>
{% include "header.html" %}

<div class="main-container">
<h3 style="text-align: center">The requested resouces does not exist.</h3>
<p style="text-align: center">
<a href="/">Click here to reload Bumblebee</a> or use your browser's back button to go to a previous page.
</p>
</div>

{% include "footer.html" %}
</body>
</html>
139 changes: 139 additions & 0 deletions resolverway/templates/footer.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,139 @@
<footer>
<div class="footer_wrapper">
<div class="footer_brand">
&copy; The SAO/NASA Astrophysics Data System
<div class="footer_brand_extra">
<p>
<i class="fa fa-envelope" aria-hidden="true"></i>
adshelp[at]cfa.harvard.edu
</p>
<p>
The ADS is operated by the Smithsonian Astrophysical Observatory under
NASA Cooperative Agreement <em>80NSSC21M0056</em>
</p>
</div>
<div class="footer_brand_logos">
<a href="http://www.nasa.gov" target="_blank" rel="noreferrer noopener">
<img src="/styles/img/nasa.svg" alt="NASA logo" id="nasa-logo" />
</a>
<a href="http://www.si.edu" target="_blank" rel="noreferrer noopener">
<img
id="smithsonian-logo"
src="/styles/img/smithsonian.svg"
alt="Smithsonian logo"
/>
</a>
<a
href="https://www.cfa.harvard.edu/"
target="_blank"
rel="noreferrer noopener"
>
<img
src="/styles/img/cfa.png"
alt="Harvard Center for Astrophysics logo"
id="cfa-logo"
/>
</a>
</div>
</div>
<div class="footer_list">
<div class="footer_list_title">
Resources
</div>
<ul class="footer_links">
<li>
<a href="/about/" target="_blank" rel="noreferrer noopener">
<i class="fa fa-question-circle" aria-hidden="true"></i> About ADS
</a>
</li>
<li>
<a href="/help/" target="_blank" rel="noreferrer noopener">
<i class="fa fa-info-circle" aria-hidden="true"></i> ADS Help
</a>
</li>
<li>
<a href="/help/whats_new/" target="_blank" rel="noreferrer noopener">
<i class="fa fa-bullhorn" aria-hidden="true"></i> What's New
</a>
</li>
<li>
<a href="/about/careers/" target="_blank" rel="noreferrer noopener">
<i class="fa fa-group" aria-hidden="true"></i> Careers@ADS
</a>
</li>
<li>
<a
href="/help/accessibility/"
target="_blank"
rel="noreferrer noopener"
>
<i class="fa fa-universal-access" aria-hidden="true"></i>
Accessibility
</a>
</li>
</ul>
</div>
<div class="footer_list">
<div class="footer_list_title">
Social
</div>
<ul class="footer_links">
<li>
<a
href="//twitter.com/adsabs"
target="_blank"
rel="noreferrer noopener"
>
<i class="fa fa-twitter" aria-hidden="true"></i> @adsabs
</a>
</li>
<li>
<a href="/blog/" target="_blank" rel="noreferrer noopener">
<i class="fa fa-newspaper-o" aria-hidden="true"></i> ADS Blog
</a>
</li>
</ul>
</div>
<div class="footer_list">
<div class="footer_list_title">
Project
</div>
<ul class="footer_links">
<li>
<a href="/core">Switch to basic HTML</a>
</li>
<li>
<a href="/help/privacy/" target="_blank" rel="noreferrer noopener"
>Privacy Policy</a
>
</li>
<li>
<a href="/help/terms" target="_blank" rel="noreferrer noopener"
>Terms of Use</a
>
</li>
<li>
<a
href="http://www.cfa.harvard.edu/sao"
target="_blank"
rel="noreferrer noopener"
>Smithsonian Astrophysical Observatory</a
>
</li>
<li>
<a href="http://www.si.edu" target="_blank" rel="noreferrer noopener"
>Smithsonian Institution</a
>
</li>
<li>
<a
href="http://www.nasa.gov"
target="_blank"
rel="noreferrer noopener"
>NASA</a
>
</li>
</ul>
</div>
</div>
</footer>
169 changes: 169 additions & 0 deletions resolverway/templates/head.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,169 @@
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link
href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css"
rel="stylesheet"
integrity="sha384-eOJMYsd53ii+scO/bJGFsiCZc+5NDVN2yr8+0RDqr0Ql0h+rP48ckxlpbzKgwra6"
crossorigin="anonymous"
/>
<style type="text/css">
body {
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
font-size: 1em;
}

a {
text-decoration: none;
color: #2152b9;
}
.starry-background-wrapper {
background-image: linear-gradient(
to bottom,
rgba(0, 0, 0, 0.2),
rgba(0, 0, 0, 0.5)
),
url("/styles/img/background.jpg");
margin: 0 -15px;
background-attachment: fixed;
}

.logo-header {
padding: 50px;
font-size: 18px;
display: flex;
justify-content: center;
align-items: center;
color: white;
-webkit-font-smoothing: antialiased;
font-weight: 300;
background-attachment: fixed;
text-align: center;
}

.logo-link {
color: #fff;
text-decoration: none;
}

.logo-header img {
max-width: 75px;
position: relative;
top: -5px;
max-height: 66px;
}

.logo-header a,
.logo-header a:hover,
.logo-header a:visited {
color: #fff;
text-decoration: none;
}

.main-container {
margin-top: 40px;
margin-bottom: 40px;
}

.title {
font-weight: bold;
}

.main-container a {
line-height: 1.2;
letter-spacing: 0.01em;
word-spacing: 0.05em;
}

@media screen and (min-width: 480px) {
.logo-header {
font-size: 22px;
}
}
@media screen and (min-width: 788px) {
.logo-header {
font-size: 40px;
}
}

.footer_wrapper {
background-color: #484f4f;
color: white;
font-size: 1.1em;
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
font-weight: 300;
padding: 30px 0;
display: flex;
flex-direction: column;
justify-content: center;
}

.footer_wrapper > * {
padding: 0 30px;
}

.footer_wrapper .footer_brand_extra {
color: rgba(255, 255, 255, 0.5);
font-size: 0.7em;
max-width: 300px;
}

@media (min-width: 788px) {
.footer_wrapper .footer_brand_extra {
width: 100%;
}
}

.footer_wrapper .footer_brand_logos #nasa-logo {
width: 80px;
}

.footer_wrapper .footer_brand_logos #smithsonian-logo {
width: 66px;
}

.footer_wrapper .footer_brand_logos #cfa-logo {
width: 100px;
padding-left: 5px;
}

@media (min-width: 788px) {
.footer_wrapper {
flex-direction: row;
}
}

.footer_links {
list-style: none;
padding-left: 0;
margin-top: 0;
margin-bottom: 0;
}

.footer_links a {
text-decoration: none;
color: rgba(255, 255, 255, 0.8);
font-weight: 100;
}

.footer_links a:hover {
color: #5683e0;
}

.footer_links li {
line-height: 1.25;
margin-bottom: 8px;
}

.footer_list_title {
font-weight: 400;
margin-bottom: 1em;
}

.s-footer {
width: 100%;
}
</style>
<script
src="https://kit.fontawesome.com/6b7af20fb7.js"
crossorigin="anonymous"
></script>
8 changes: 8 additions & 0 deletions resolverway/templates/header.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<header class="starry-background-wrapper">
<div class="logo-header">
<a href="/">
<img src="/styles/img/transparent_logo.svg" alt="The Astrophysics Data System Logo">
<b>astrophysics</b>&nbsp;data system
</a>
</div>
</header>
Loading

0 comments on commit a1180d8

Please sign in to comment.