Skip to content

Commit

Permalink
Use same theme as fhirflat
Browse files Browse the repository at this point in the history
  • Loading branch information
abhidg committed May 31, 2024
1 parent 25014df commit ee380c1
Show file tree
Hide file tree
Showing 5 changed files with 139 additions and 16 deletions.
Binary file added docs/_static/G.h_Gr&B_Mark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
114 changes: 114 additions & 0 deletions docs/_static/style.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,114 @@
@import url('https://fonts.googleapis.com/css2?family=Source+Serif+4:ital,opsz,wght@0,8..60,200..900;1,8..60,200..900&display=swap');

a {
color: #0e7569;
text-decoration: underline !important;
}

h2 {
font-size: 1.2rem;
border-bottom: 2px solid #0e7569;
}

footer {
font-size: 0.9rem !important;
text-align: left !important;
color: gray !important;
}

header#pageheader,
footer#pagefooter,
.related,
.document {
max-width: 80rem;
}

div.bodywrapper li {
margin-left: -1rem;
}

div.body {
padding-right: 20px;
font-family: 'Source Serif 4', Georgia, serif;
}

h1,
h2,
h3,
table {
font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

div.sphinxsidebarwrapper {
padding-left: 15px;
padding-bottom: 50px;
}

body {
padding: 0 20px;
border-top: 7px solid #0e7569;
}

pre {
font-family: monospace;
}

div.sphinxsidebar {
background: #ecf3f0;
}

table.docutils {
font-size: 0.9rem;
border: 1px solid silver;
}

@media print {
body {
font-size: 85% !important;
}
}

dd.field-even {
font-family: monospace;
}

span.sig-name {
font-weight: bold;
}

ul.simple strong,
ul.simple em,
span.pre,
dd strong,
dd em {
font-family: monospace;
}
div.highlight {
background-color: none;
margin-left: 0.4rem;
}
pre {
padding: 0.7rem;
border: 1px solid #999;
background-color: white;
}

div.bodywrapper h4 {
font-size: 1.1rem;
font-style: italic;
margin-bottom: -0.6rem;
}

@media (max-width: 820px) {
header#pageheader, footer#pagefooter, .related, .document {
margin: 0;
padding: 0;
}
body {
margin: 0; padding: 0; padding-left: 1rem;
}
div.body {
padding-right: 0;
}
}

14 changes: 14 additions & 0 deletions docs/_templates/layout.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{% extends '!layout.html' %}
{% block footer %}
<footer id="pagefooter">
<img
alt="logo"
src="_static/G.h_Gr&B_Mark.png"
style="width: 1.5rem; vertical-align: top;"
/>&nbsp;&nbsp;&copy; 2023,
<a href="https://global.health">Global.health</a>. Created using
<a href="http://sphinx-doc.org/">Sphinx</a> with the
<a href="http://github.com/irskep/sphinx-better-theme"> better</a>
theme.<br />
</footer>
{% endblock %}
25 changes: 10 additions & 15 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
import os
import sys

import better

# Add root dir so that adtl module is visible to Sphinx
sys.path.insert(0, os.path.abspath(".."))
sys.path.insert(0, os.path.abspath("."))
Expand All @@ -34,21 +36,14 @@
# -- Options for HTML output -------------------------------------------------
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output

html_theme = "furo"
html_theme = "better"
html_static_path = ["_static"]
html_theme_path=[better.better_theme_path]
html_short_title = "Home"

html_theme_options = {
"light_css_variables": {
"color-brand-primary": "#0e7569",
"color-problematic": "#0e7569",
"color-brand-content": "#0e7569",
"color-background-secondary": "#ecf3f0",
"color-background-hover": "#cfe6db",
},
"dark_css_variables": {
"color-brand-primary": "#d2d9d6",
"color-problematic": "#d2d9d6",
"color-brand-content": "#d2d9d6",
"color-background-secondary": "#0b5950",
},
}
"rightsidebar": True,
"sidebarwidth": "25rem",
"cssfiles": ["_static/style.css"],
"showheader": False,
}
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ test = [
docs = [
"sphinx>=7.2.2",
"myst-parser==2.0.*",
"furo"
"sphinx-better-theme"
]

[project.urls]
Expand Down

0 comments on commit ee380c1

Please sign in to comment.