diff --git a/docs/_static/jiodocs.css b/docs/_static/jiodocs.css new file mode 100644 index 0000000000000000000000000000000000000000..ff2970e87e86bb1440ba898fde13226781b22d7f --- /dev/null +++ b/docs/_static/jiodocs.css @@ -0,0 +1,79 @@ + +/* override sphinx theme */ + +.line-block { + margin-bottom: 0.4em; +} + + +a.button { + -moz-border-radius:6px; + -webkit-border-radius:6px; + border-radius:6px; + display:inline-block; + color:#ffffff; + font-family:arial; + font-size:15px; + font-weight:bold; + padding:6px 24px; + text-decoration:none; +} +a.button:hover { + color:#ffffff; +} +a.button:active { + position:relative; + top:1px; +} + +a.blue-button { + -moz-box-shadow:inset 0px 1px 0px 0px #97c4fe; + -webkit-box-shadow:inset 0px 1px 0px 0px #97c4fe; + box-shadow:inset 0px 1px 0px 0px #97c4fe; + background:-webkit-gradient(linear, left top, left bottom, color-stop(0.05, #3d94f6), color-stop(1, #1e62d0)); + background:-moz-linear-gradient(top, #3d94f6 5%, #1e62d0 100%); + background:-webkit-linear-gradient(top, #3d94f6 5%, #1e62d0 100%); + background:-o-linear-gradient(top, #3d94f6 5%, #1e62d0 100%); + background:-ms-linear-gradient(top, #3d94f6 5%, #1e62d0 100%); + background:linear-gradient(to bottom, #3d94f6 5%, #1e62d0 100%); + filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#3d94f6', endColorstr='#1e62d0',GradientType=0); + background-color:#3d94f6; + border:1px solid #337fed; + text-shadow:0px 1px 0px #1570cd; +} +a.blue-button:hover { + background:-webkit-gradient(linear, left top, left bottom, color-stop(0.05, #1e62d0), color-stop(1, #3d94f6)); + background:-moz-linear-gradient(top, #1e62d0 5%, #3d94f6 100%); + background:-webkit-linear-gradient(top, #1e62d0 5%, #3d94f6 100%); + background:-o-linear-gradient(top, #1e62d0 5%, #3d94f6 100%); + background:-ms-linear-gradient(top, #1e62d0 5%, #3d94f6 100%); + background:linear-gradient(to bottom, #1e62d0 5%, #3d94f6 100%); + filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#1e62d0', endColorstr='#3d94f6',GradientType=0); + background-color:#1e62d0; +} + +a.green-button { + -moz-box-shadow:inset 0px 1px 0px 0px #9acc85; + -webkit-box-shadow:inset 0px 1px 0px 0px #9acc85; + box-shadow:inset 0px 1px 0px 0px #9acc85; + background:-webkit-gradient(linear, left top, left bottom, color-stop(0.05, #74ad5a), color-stop(1, #68a54b)); + background:-moz-linear-gradient(top, #74ad5a 5%, #68a54b 100%); + background:-webkit-linear-gradient(top, #74ad5a 5%, #68a54b 100%); + background:-o-linear-gradient(top, #74ad5a 5%, #68a54b 100%); + background:-ms-linear-gradient(top, #74ad5a 5%, #68a54b 100%); + background:linear-gradient(to bottom, #74ad5a 5%, #68a54b 100%); + filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#74ad5a', endColorstr='#68a54b',GradientType=0); + background-color:#74ad5a; + border:1px solid #3b6e22; + text-shadow:0px 1px 0px #92b879; +} +a.green-button:hover { + background:-webkit-gradient(linear, left top, left bottom, color-stop(0.05, #68a54b), color-stop(1, #74ad5a)); + background:-moz-linear-gradient(top, #68a54b 5%, #74ad5a 100%); + background:-webkit-linear-gradient(top, #68a54b 5%, #74ad5a 100%); + background:-o-linear-gradient(top, #68a54b 5%, #74ad5a 100%); + background:-ms-linear-gradient(top, #68a54b 5%, #74ad5a 100%); + background:linear-gradient(to bottom, #68a54b 5%, #74ad5a 100%); + filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#68a54b', endColorstr='#74ad5a',GradientType=0); + background-color:#68a54b; +} diff --git a/docs/_static/jiodocs.js b/docs/_static/jiodocs.js new file mode 100644 index 0000000000000000000000000000000000000000..b980346c9550269599fde184eb6f36f33b6dfac9 --- /dev/null +++ b/docs/_static/jiodocs.js @@ -0,0 +1,8 @@ +/* jslint undef: true */ +/* global jQuery, document */ + +jQuery(document).ready(function ($) { + $('a:contains(Full download)').addClass('button').addClass('blue-button').addClass('blue'); + $('a:contains(Minified download)').addClass('button').addClass('green-button').addClass('blue'); +}); + diff --git a/docs/_templates/layout.html b/docs/_templates/layout.html index e0b0772f34eaa67eb588c09dccc2c9889c13d1ad..a12e3a61ed09691c0f0ba9e981778e8b946c7c6c 100644 --- a/docs/_templates/layout.html +++ b/docs/_templates/layout.html @@ -1,5 +1,7 @@ {%- extends "basic/layout.html" %} {%- block extrahead %} + <link rel="stylesheet" type="text/css" href="_static/jiodocs.css"> + <script type="text/javascript" src="_static/jiodocs.js"></script> {{ super() }} {% if theme_touch_icon %} <link rel="apple-touch-icon" href="{{ pathto('_static/' ~ theme_touch_icon, 1) }}" /> diff --git a/docs/conf.py b/docs/conf.py index 427e914f8ef983725ca32bb2f58ac5c2b5bb8c02..c3623aa08c5462c4a987f81856b5e83b9b1c1504 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -27,7 +27,7 @@ import sys, os # Add any Sphinx extension module names here, as strings. They can be extensions # coming with Sphinx (named 'sphinx.ext.*') or your custom ones. -extensions = ['sphinx.ext.todo', 'sphinx.ext.ifconfig'] +extensions = ['sphinx.ext.todo', 'sphinx.ext.ifconfig', 'sphinxcontrib.jsdemo'] # Add any paths that contain templates here, relative to this directory. templates_path = ['_templates'] @@ -134,7 +134,7 @@ html_static_path = ['_static'] # Custom sidebar templates, maps document names to template names. html_sidebars = { - 'index': ['side-top.html', 'side-support.html', 'side-informed.html', 'searchbox.html'], + 'index': ['side-top.html', 'side-gettingstarted.html', 'side-downloads.html', 'side-support.html', 'side-informed.html', 'searchbox.html'], '**': ['side-top.html', 'localtoc.html', 'relations.html', 'searchbox.html'] } diff --git a/docs/getting_started.rst b/docs/getting_started.rst index ce0b25d432a52ba7d2e282d917218c2fd2cff0c9..5c3195cfba8dc743c967124bef3a8788edfe3de8 100644 --- a/docs/getting_started.rst +++ b/docs/getting_started.rst @@ -85,6 +85,14 @@ This walkthrough is designed to get you started using a basic jIO instance. Download & Fork --------------- +You can use one of the ZIP packages, which include all the dependencies and storages: + +`Full download (172k) <_static/jio-2.0.0.zip>`_ +`Minified download (87k) <_static/jio-2.0.0-min.zip>`_ + +or you can create your own set of files using the following links: + + Core ^^^^ @@ -128,13 +136,6 @@ Revision based storage handlers * `revisionstorage.js <http://git.erp5.org/gitweb/jio.git/blob_plain/refs/heads/master:/src/jio.storage/revisionstorage.js>`_ (depends on sha256) (WIP) * `replicaterevisionstorage.js <http://git.erp5.org/gitweb/jio.git/blob_plain/refs/heads/master:/src/jio.storage/replicatestorage.js>`_ (WIP) -Minified version -^^^^^^^^^^^^^^^^ - -.. XXX this sounds harsh. Can we provide it or at least be more explicit? - -To get the minified version of the jIO library, you have to build it yourself. See documentation. - Unit tests ^^^^^^^^^^