diff options
author | Marcel Hellkamp <marc@gsites.de> | 2011-11-24 20:27:00 +0100 |
---|---|---|
committer | Marcel Hellkamp <marc@gsites.de> | 2011-11-24 20:27:00 +0100 |
commit | 13d9ffb33496e83e2211bd31454bac9edb6a2021 (patch) | |
tree | d27b530c1839a0a51e6a62cd5f70040defbc4e1d | |
parent | 5e57ead62ee563fdd2f3e2a9d0e8ae060a093bce (diff) | |
download | bottle-13d9ffb33496e83e2211bd31454bac9edb6a2021.tar.gz |
docs: Merging 0.11 doc layout changes.
-rwxr-xr-x | docs/_static/bottle.css_t | 33 | ||||
-rw-r--r-- | docs/_templates/page.html | 9 | ||||
-rw-r--r-- | docs/_templates/release-warning.html | 8 | ||||
-rw-r--r-- | docs/_templates/sidebar-intro.html | 9 | ||||
-rw-r--r-- | docs/conf.py | 4 |
5 files changed, 42 insertions, 21 deletions
diff --git a/docs/_static/bottle.css_t b/docs/_static/bottle.css_t index d7c8b9c..3dc0c9c 100755 --- a/docs/_static/bottle.css_t +++ b/docs/_static/bottle.css_t @@ -76,6 +76,10 @@ div.body h2 { -webkit-border-bottom-left-radius: 15px; } +div.body h3 { + margin: 2em 0 1em 0; +} + div.body h2 a { color: {{ linkcolor_border }}; } @@ -92,12 +96,10 @@ a:hover { /* Notes and Codes */ -pre, div.admonition { - background: #fafafa; - margin: 20px -15px; - padding: 10px 30px; - border-top: 1px solid #ccc; - border-bottom: 1px solid #ccc; +pre { + background-color: {{ color_body }}; + margin: 1em 2em; + padding: 0.5em; } dd pre, dd div.admonition { @@ -110,6 +112,18 @@ div.admonition p.last { margin-bottom: 0; } +div.admonition { + border: 1px solid {{ color_border }}; + margin: 1em 2em; + padding: 0.5em; + font-size: 0.9em; + line-height: 1.3em; +} + +div.admonition p.admonition-title { + margin: 0; +} + div.admonition p.admonition-title:after { content:":"; } @@ -119,7 +133,7 @@ div.warning { } div.note { - background-color: #ffd; + background-color: #ffc; } div.highlight { @@ -132,9 +146,8 @@ pre { } code, tt.docutils { - border: 1px dotted #ddd; - background-color: #eee; - font-size: 85%; + font-size: 0.9em; + padding: 0 0.2em; } tt.xref { diff --git a/docs/_templates/page.html b/docs/_templates/page.html new file mode 100644 index 0000000..8cb116c --- /dev/null +++ b/docs/_templates/page.html @@ -0,0 +1,9 @@ +{% extends "!page.html" %}
+
+{% block body %}
+ {% if 'dev' in release or 'rc' in release %}
+ <p style='font-size: 0.75em; color: darkred'><b>Warning:</b> This is a preview for <b>Bottle-{{release}}</b>, which is
+ not released yet. Switch to the latest <a href="http://bottlepy.org/docs/stable/"><b>stable release</b></a>?</p>
+ {% endif %}
+ {{ super() }}
+{% endblock %}
\ No newline at end of file diff --git a/docs/_templates/release-warning.html b/docs/_templates/release-warning.html deleted file mode 100644 index 67bec82..0000000 --- a/docs/_templates/release-warning.html +++ /dev/null @@ -1,8 +0,0 @@ -<p>
- Bottle is a fast, simple and lightweight WSGI micro web-framework for Python.
-</p>
-{% if 'dev' in release %}
-<h3>Release</h3>
-<p>This documentation is for Bottle <b>{{release}}</b>, which is
- not released yet. The current stable release is <a href="http://bottlepy.org/docs/{{releases[1][0]}}/"><b>Bottle {{releases[1][0]}}</b></a>.</p>
-{% endif %}
diff --git a/docs/_templates/sidebar-intro.html b/docs/_templates/sidebar-intro.html index 328b829..1175b6d 100644 --- a/docs/_templates/sidebar-intro.html +++ b/docs/_templates/sidebar-intro.html @@ -1,3 +1,6 @@ +<p> + Bottle is a fast, simple and lightweight WSGI micro web-framework for Python. +</p> <h3>Some Links</h3> <ul> <li><a target="_blank" href="https://github.com/defnull/bottle/issues">Issue Tracker</a></li> @@ -19,7 +22,11 @@ <h3>Other Releases</h3> <ul> {% for v, name in releases %} - <li><a href="http://bottlepy.org/docs/{{v}}/">Bottle {{v}} ({{name}})</a></li> + {% if v == version %} + <li><b>Bottle {{v}}</b> ({{name}})</li> + {% else %} + <li><a href="http://bottlepy.org/docs/{{v}}/">Bottle {{v}}</a> ({{name}})</li> + {% endif %} {% endfor %} </ul> diff --git a/docs/conf.py b/docs/conf.py index c6ae9c4..20bf41d 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -137,8 +137,8 @@ html_last_updated_fmt = '%b %d, %Y' # Custom sidebar templates, maps document names to template names. html_sidebars = { - 'index': ['release-warning.html', 'sidebar-intro.html', 'sourcelink.html', 'donation.html', 'searchbox.html'], - '**': ['release-warning.html', 'localtoc.html', 'relations.html', 'sourcelink.html', 'donation.html', 'searchbox.html'] + 'index': ['sidebar-intro.html', 'sourcelink.html', 'donation.html', 'searchbox.html'], + '**': ['localtoc.html', 'relations.html', 'sourcelink.html', 'donation.html', 'searchbox.html'] } html_context = { |