Skip to content
Permalink
Browse files

showoff a little using Dr. Nikola's Vendetta

  • Loading branch information
ralsina committed Sep 11, 2015
1 parent bce97f0 commit e46d01b882e09b9784486fb4d0a55026b9174be4
Showing with 120 additions and 17 deletions.
  1. +2 −0 CHANGES.txt
  2. +14 −17 nikola/data/samplesite/stories/dr-nikolas-vendetta.rst
  3. +104 −0 nikola/data/samplesite/templates/book.tmpl
@@ -3,6 +3,8 @@ New in master

Features
--------

* Better Template / JS / CSS demo in sample site.
* Support UTF-8 paths and encoded links when the ``USE_SLUGIFY`` option
is disabled. (Issue #2037)
* Per-document hyphenation using "hyphenate" metadata flag.
@@ -1,23 +1,17 @@
A BID FOR FORTUNE OR; DR. NIKOLA'S VENDETTA
===========================================
.. title: A BID FOR FORTUNE OR; DR. NIKOLA'S VENDETTA
.. hyphenate: yeah
.. template: book.tmpl
By GUY BOOTHBY

Author of "Dr. Nikola," "The Beautiful White Devil," etc., etc.

PART I
======



PROLOGUE
--------

DR. NIKOLA
~~~~~~~~~~


.. sidebar:: The Project Gutenberg EBook of A Bid for Fortune, by Guy Boothby
.. topic:: The Project Gutenberg EBook of A Bid for Fortune, by Guy Boothby

This eBook is for the use of anyone anywhere at no cost and with
almost no restrictions whatsoever. You may copy it, give it away or
@@ -43,7 +37,17 @@ DR. NIKOLA
LONDON, MELBOURNE AND TORONTO
1918

------------------------

.. figure:: /images/illus_001.jpg
:class: illus1
:figclass: figure1

PART I
======

PROLOGUE
--------

The manager of the new Imperial Restaurant on the Thames Embankment went
into his luxurious private office and shut the door. Having done so, he
@@ -61,13 +65,6 @@ at the dial; the hands stood at half-past seven. He immediately threw
the letter on the table, and as he did so his anxiety found relief in
words.

.. class:: pull-left

.. figure:: /images/illus_001.jpg

"Again she turned her face from me."


"It's really the most extraordinary affair I ever had to do with," he
remarked. "And as I've been in the business just three-and-thirty years
at eleven a.m. next Monday morning, I ought to know something about it.
@@ -0,0 +1,104 @@
## -*- coding: utf-8 -*-
<%namespace name="helper" file="post_helper.tmpl"/>
<%namespace name="pheader" file="post_header.tmpl"/>
<%namespace name="comments" file="comments_helper.tmpl"/>
<%inherit file="post.tmpl"/>

<%block name="extra_head">
${parent.extra_head()}
<script src="/assets/js/jquery.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/Flowtype.js/1.1.0/flowtype.min.js"></script>
<link href='https://fonts.googleapis.com/css?family=Gentium+Book+Basic' rel='stylesheet' type='text/css'>
<link href='https://fonts.googleapis.com/css?family=Rye' rel='stylesheet' type='text/css'>
<style>
p {
text-align: justify;
}
.chapter {
width: 100%;
padding: 10px 10px;
-webkit-column-gap: 40px;
-webkit-column-width: 400px;
-webkit-column-count: 2;
-webkit-column-rule: 1px solid #ddd;
height: 800px;
font-family: 'Gentium Book Basic', serif;
}

div.frame {
overflow: hidden;
padding: 0;
margin: 0;
}
div.scrolling-cont {
overflow-x: scroll;
padding: 0;
margin: 0;
}

.illus1 {
margin-left: auto;
margin-right: auto;
max-height: 780px;
width: 100%;
}

.figure1 {
padding-top: 20%;
padding-bottom: 20%;
height: 80%;
}

h1, h2, h3, h4 {
text-align: center;
width: 100%;
font-family: 'Rye', cursive;
}

</style>
</%block>

<%block name="content">
<article class="storypage" itemscope="itemscope" itemtype="http://schema.org/Article">
<div class="frame">
<div class="scrolling-cont" id="scrolling-cont" name="scrolling-cont">
<div class="e-content entry-content chapter" itemprop="articleBody text">
<header>
${pheader.html_title()}
${pheader.html_translations(post)}
</header>
${post.text()}
</div>
</div>
</div>
%if site_has_comments and enable_comments and not post.meta('nocomments'):
<section class="comments">
<h2>${messages("Comments")}</h2>
${comments.comment_form(post.permalink(absolute=True), post.title(), post.base_path)}
</section>
%endif
${helper.mathjax_script(post)}
<script>
$('#scrolling-cont').flowtype({
minimum : 500,
maximum : 1200,
minFont : 20,
maxFont : 40,
fontRatio : 50
});
$(document).ready(function() {
var elem = $('#scrolling-cont');
elem.click(function(event) {
var x1 = elem.position().left;
var pw = elem.width() + 20;
var x2 = event.pageX;
if (x2-x1 < pw/2) {
pw = -pw;
}
elem.animate({scrollLeft: '+='+pw}, 500)
});
});
</script>
</article>

</%block>

0 comments on commit e46d01b

Please sign in to comment.
You can’t perform that action at this time.