From 141e0fa458a8fae8e48f56d846304e04b6add715 Mon Sep 17 00:00:00 2001 From: Gringo Suave Date: Fri, 3 Mar 2017 13:40:07 -0800 Subject: [PATCH] add css for figures under .rst --- pelican/themes/notmyidea/static/css/main.css | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/pelican/themes/notmyidea/static/css/main.css b/pelican/themes/notmyidea/static/css/main.css index 03a77e69..c90652a5 100644 --- a/pelican/themes/notmyidea/static/css/main.css +++ b/pelican/themes/notmyidea/static/css/main.css @@ -148,8 +148,24 @@ aside, nav, article, figure { /***** Layout *****/ .body {clear: both; margin: 0 auto; width: 800px;} -img.right, figure.right {float: right; margin: 0 0 2em 2em;} -img.left, figure.left {float: left; margin: 0 2em 2em 0;} +img.right, figure.right, div.figure.align-right { + float: right; + margin: 0 0 2em 2em; +} +img.left, figure.left, div.figure.align-left { + float: left; + margin: 0 2em 2em 0; +} + +/* .rst support */ +div.figure img, figure img { /* to fill figure exactly */ + width: 100%; +} +div.figure p.caption, figure p.caption { /* margin provided by figure */ + margin-top: 0; + margin-bottom: 0; +} + /* Header