├── tests ├── __init__.py ├── roots │ └── test-basic │ │ ├── bar.rst │ │ ├── foo.rst │ │ ├── conf.py │ │ ├── document_settings.yml │ │ └── index.rst ├── test_builders.py └── util.py ├── docs_italia_theme ├── data │ ├── _data │ │ ├── subnav.yml │ │ ├── contacts.yml │ │ ├── social.yml │ │ ├── footer_links.yml │ │ ├── network_links.yml │ │ ├── tools.yml │ │ ├── menu_items.yml │ │ └── l10n.yml │ └── _config.yml ├── static │ ├── font │ │ ├── docs-italia.eot │ │ ├── docs-italia.ttf │ │ ├── docs-italia.woff │ │ ├── italia-icon-font.eot │ │ ├── italia-icon-font.ttf │ │ ├── italia-icon-font.woff │ │ └── italia-icon-font.woff2 │ └── images │ │ ├── team-digitale-logo.svg │ │ ├── may.svg │ │ ├── should.svg │ │ ├── should_not.svg │ │ ├── must_not.svg │ │ └── must.svg ├── layouts │ ├── scrolltop.html │ ├── loader_show_script.html │ ├── l10n.html │ ├── templates │ │ ├── searchbox_collapse.html │ │ ├── glossary_page.html │ │ ├── markup_modifier.html │ │ ├── tooltip.html │ │ └── section_navigation.html │ ├── cookiebar.html │ ├── templates.html │ ├── web-analytics.html │ ├── searchbox.html │ ├── scripts.html │ ├── lang_switch.html │ ├── network.html │ ├── document_actions.html │ ├── default.html │ ├── footer.html │ ├── sidebar.html │ ├── doc_header.html │ ├── head.html │ ├── sidebar_offcanvas.html │ ├── document_modals.html │ └── header.html ├── layout.html ├── theme.conf ├── forum_italia.py ├── search.html └── Titillium-LICENSE.txt ├── setup.cfg ├── Gemfile ├── demo_docs ├── source │ ├── images │ │ ├── github_example.png │ │ └── piano-triennale.svg │ ├── document_settings.yml │ ├── glossario.rst │ └── index.rst └── Makefile ├── AUTHORS ├── .stylelintrc ├── sass ├── layout │ ├── _back-to-top.scss │ ├── _modals.scss │ ├── _scrollbar.scss │ ├── _table.scss │ ├── _note.scss │ ├── _general.scss │ ├── _glossary.scss │ ├── _footer.scss │ ├── _side-menu.scss │ ├── _dropdown.scss │ ├── _content-nav.scss │ ├── _navbar-secondary-offcanvas.scss │ ├── _tooltip.scss │ ├── _sidebar.scss │ ├── _comments.scss │ └── _header.scss ├── theme.scss ├── base │ ├── _helpers.scss │ ├── _normalize.scss │ └── _icon.scss └── abstract │ └── _variables.scss ├── js ├── sticky_header.js ├── offcanvas_feature.js ├── scroll_progressbar.js ├── get_glossary.js ├── admonition_toggle.js ├── searchbox_collapse.js ├── getTpl.js ├── index.js ├── note.js ├── active_versions.js ├── modernizr.min.js ├── glossary_page.js ├── copy_to_clipboard.js ├── sidebar_nav.js └── section_navigation.js ├── .gitignore ├── docs-italia-theme └── __init__.py ├── Gemfile.lock ├── .travis.yml ├── tox.ini ├── MANIFEST.in ├── LICENSE ├── package.json ├── setup.py ├── README.md ├── CODE_OF_CONDUCT.md └── Gruntfile.js /tests/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /docs_italia_theme/data/_data/subnav.yml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /setup.cfg: -------------------------------------------------------------------------------- 1 | [bdist_wheel] 2 | universal = 1 3 | -------------------------------------------------------------------------------- /tests/roots/test-basic/bar.rst: -------------------------------------------------------------------------------- 1 | bar 2 | === 3 | -------------------------------------------------------------------------------- /Gemfile: -------------------------------------------------------------------------------- 1 | # A sample Gemfile 2 | source "https://rubygems.org" 3 | 4 | gem "sass" 5 | -------------------------------------------------------------------------------- /tests/roots/test-basic/foo.rst: -------------------------------------------------------------------------------- 1 | foo 2 | === 3 | 4 | .. toctree:: 5 | 6 | bar 7 | -------------------------------------------------------------------------------- /tests/roots/test-basic/conf.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | master_doc = 'index' 4 | exclude_patterns = ['_build'] 5 | -------------------------------------------------------------------------------- /demo_docs/source/images/github_example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/italia/docs-italia-theme/HEAD/demo_docs/source/images/github_example.png -------------------------------------------------------------------------------- /AUTHORS: -------------------------------------------------------------------------------- 1 | Copyright (c) 2018 Presidenza del Consiglio dei Ministri 2 | 3 | The version control system provides attribution for specific lines of code. 4 | -------------------------------------------------------------------------------- /docs_italia_theme/static/font/docs-italia.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/italia/docs-italia-theme/HEAD/docs_italia_theme/static/font/docs-italia.eot -------------------------------------------------------------------------------- /docs_italia_theme/static/font/docs-italia.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/italia/docs-italia-theme/HEAD/docs_italia_theme/static/font/docs-italia.ttf -------------------------------------------------------------------------------- /docs_italia_theme/static/font/docs-italia.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/italia/docs-italia-theme/HEAD/docs_italia_theme/static/font/docs-italia.woff -------------------------------------------------------------------------------- /tests/roots/test-basic/document_settings.yml: -------------------------------------------------------------------------------- 1 | --- 2 | document: 3 | description: description 4 | name: document 5 | tags: 6 | - demo 7 | - test -------------------------------------------------------------------------------- /docs_italia_theme/static/font/italia-icon-font.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/italia/docs-italia-theme/HEAD/docs_italia_theme/static/font/italia-icon-font.eot -------------------------------------------------------------------------------- /docs_italia_theme/static/font/italia-icon-font.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/italia/docs-italia-theme/HEAD/docs_italia_theme/static/font/italia-icon-font.ttf -------------------------------------------------------------------------------- /docs_italia_theme/static/font/italia-icon-font.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/italia/docs-italia-theme/HEAD/docs_italia_theme/static/font/italia-icon-font.woff -------------------------------------------------------------------------------- /docs_italia_theme/static/font/italia-icon-font.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/italia/docs-italia-theme/HEAD/docs_italia_theme/static/font/italia-icon-font.woff2 -------------------------------------------------------------------------------- /docs_italia_theme/layouts/scrolltop.html: -------------------------------------------------------------------------------- 1 | 4 | -------------------------------------------------------------------------------- /tests/roots/test-basic/index.rst: -------------------------------------------------------------------------------- 1 | test-basic 2 | ========== 3 | 4 | .. toctree:: 5 | 6 | foo 7 | 8 | Heading 9 | ------- 10 | 11 | Subheading 12 | ~~~~~~~~~~ 13 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/loader_show_script.html: -------------------------------------------------------------------------------- 1 | 5 | -------------------------------------------------------------------------------- /.stylelintrc: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "stylelint-config-standard", 3 | "rules": { 4 | "at-rule-no-unknown": [ true, { 5 | ignoreAtRules: ['include'] 6 | }] 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /sass/layout/_back-to-top.scss: -------------------------------------------------------------------------------- 1 | .return-to-top { 2 | @include media-breakpoint-down(sm) { 3 | bottom: 4rem; 4 | } 5 | 6 | i::before { 7 | margin: 0; 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/l10n.html: -------------------------------------------------------------------------------- 1 | 8 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/templates/searchbox_collapse.html: -------------------------------------------------------------------------------- 1 | {% raw %} 2 | 5 | {% endraw %} 6 | -------------------------------------------------------------------------------- /docs_italia_theme/layout.html: -------------------------------------------------------------------------------- 1 | {%- set url_root = pathto('', 1) %} 2 | {%- if url_root == '#' %} 3 | {% set url_root = '' %} 4 | {% endif %} 5 | {%- extends 'layouts/default.html' %} 6 | {% block body %} 7 | {{ body }} 8 | {% endblock %} 9 | -------------------------------------------------------------------------------- /docs_italia_theme/data/_data/contacts.yml: -------------------------------------------------------------------------------- 1 | address: 2 | value: Via Roma 1, Roma, 00100 3 | phone: 4 | name: phone 5 | value: +00 000 000 000 6 | email: 7 | name: email 8 | value: my@email.com 9 | pec: 10 | name: pec 11 | value: my@pec.com 12 | -------------------------------------------------------------------------------- /docs_italia_theme/data/_data/social.yml: -------------------------------------------------------------------------------- 1 | twitter: 2 | name: twitter 3 | link: https://twitter.com/developersITA 4 | sharelink: https://twitter.com/intent/tweet?url= 5 | medium: 6 | name: medium 7 | link: https://medium.com/team-per-la-trasformazione-digitale/ 8 | -------------------------------------------------------------------------------- /js/sticky_header.js: -------------------------------------------------------------------------------- 1 | // Sticky header 2 | var stickybits = require('stickybits'); 3 | 4 | module.exports = themeStickyHeader = (function () { 5 | 6 | return { 7 | init: function() { 8 | stickybits('.doc-header'); 9 | } 10 | } 11 | 12 | })(); 13 | -------------------------------------------------------------------------------- /docs_italia_theme/data/_data/footer_links.yml: -------------------------------------------------------------------------------- 1 | privacy: 2 | title: footer_link_privacy_policy 3 | url: '/privacy-policy/' 4 | cookies: 5 | title: footer_link_cookies 6 | url: '/cookies-policy/' 7 | legal: 8 | title: footer_link_legal_notes 9 | url: '/note-legali/' 10 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.pyc 2 | *.egg-info 3 | *.egg 4 | *.inc 5 | *build/ 6 | .tox 7 | .pytest_cache 8 | .coverage 9 | *.DS_Store 10 | *.sass-cache 11 | .ropeproject/ 12 | .ruby-version 13 | .python-version 14 | .idea/ 15 | TODO 16 | dist/ 17 | bower_components/ 18 | node_modules/ 19 | npm-debug.log 20 | .venv 21 | -------------------------------------------------------------------------------- /demo_docs/source/document_settings.yml: -------------------------------------------------------------------------------- 1 | --- 2 | document: 3 | description: > 4 | Sommario di due/tre righe: lorem ipsum dolor sit amet, consectetur adipisici 5 | elit, sed eiusmod tempor incidunt ut labore et dolore magna aliqua. 6 | name: "Documento demo Docs Italia" 7 | tags: 8 | - demo 9 | - "docs italia" -------------------------------------------------------------------------------- /sass/layout/_modals.scss: -------------------------------------------------------------------------------- 1 | @include media-breakpoint-down(sm) { 2 | .modal.modal-sm-full { 3 | .modal-dialog { 4 | margin: 0; 5 | max-width: none; 6 | 7 | .modal-content { 8 | margin: 0; 9 | width: 100vw; 10 | height: 100vh; 11 | border-radius: 0 !important; 12 | border: none; 13 | } 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /docs-italia-theme/__init__.py: -------------------------------------------------------------------------------- 1 | # This file is here for compatibility because the 2 | # theme changed his name to docs_italia_theme 3 | 4 | """Docs Italia theme""" 5 | 6 | import os 7 | 8 | def get_html_theme_path(): 9 | """Return list of HTML theme paths.""" 10 | cur_dir = os.path.abspath(os.path.dirname(__file__) + '../docs_italia_theme') 11 | return cur_dir 12 | 13 | def setup(app): 14 | pass 15 | -------------------------------------------------------------------------------- /Gemfile.lock: -------------------------------------------------------------------------------- 1 | GEM 2 | remote: https://rubygems.org/ 3 | specs: 4 | ffi (1.11.1) 5 | rb-fsevent (0.10.2) 6 | rb-inotify (0.9.10) 7 | ffi (>= 0.5.0, < 2) 8 | sass (3.5.3) 9 | sass-listen (~> 4.0.0) 10 | sass-listen (4.0.0) 11 | rb-fsevent (~> 0.9, >= 0.9.4) 12 | rb-inotify (~> 0.9, >= 0.9.7) 13 | 14 | PLATFORMS 15 | ruby 16 | 17 | DEPENDENCIES 18 | sass 19 | 20 | BUNDLED WITH 21 | 1.16.0 22 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: python 2 | python: 3 | - 2.7 4 | - 3.6 5 | sudo: false 6 | before_install: 7 | - curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.2/install.sh | bash 8 | - source ~/.nvm/nvm.sh 9 | install: 10 | - pip install tox-travis 11 | - gem install sass 12 | - nvm install --lts 13 | - nvm use --lts 14 | - npm install 15 | script: 16 | - tox 17 | cache: 18 | directories: 19 | - ~/.cache/pip 20 | - ~/.nvm/ 21 | - ~/.rvm/ 22 | -------------------------------------------------------------------------------- /docs_italia_theme/theme.conf: -------------------------------------------------------------------------------- 1 | [theme] 2 | inherit = basic 3 | stylesheet = css/theme.css 4 | pygments_style = sphinx 5 | 6 | [options] 7 | #typekit_id = hiw1hhg 8 | canonical_url = 9 | analytics_id = 10 | collapse_navigation = False 11 | sticky_navigation = False 12 | navigation_depth = 4 13 | includehidden = True 14 | logo_only = 15 | display_version = True 16 | prev_next_buttons_location = bottom 17 | style_external_links = False 18 | 19 | # Additional options 20 | layout = 21 | versions = 22 | superproject = 23 | custom_versions_badge = True 24 | -------------------------------------------------------------------------------- /js/offcanvas_feature.js: -------------------------------------------------------------------------------- 1 | // Offcanvas feature 2 | module.exports = themeOffcanvasFeature = (function ($) { 3 | 4 | return { 5 | init: function(callback) { 6 | $('*[data-activate-element]').on('click', function(e) { 7 | e.preventDefault(); 8 | var genid = $(this).data('activeid'); 9 | var $targetelement = $('*[data-activatedby="'+genid+'"]'); 10 | $targetelement.toggleClass('js-active'); 11 | $('body').toggleClass('show-menu').toggleClass('stopScrolling--vertical'); 12 | }); 13 | } 14 | }; 15 | 16 | })(jQuery); 17 | -------------------------------------------------------------------------------- /tox.ini: -------------------------------------------------------------------------------- 1 | [tox] 2 | envlist = theme,py{27,36}-sphinx{16,17} 3 | 4 | [travis] 5 | python = 6 | 2.7: theme,py27-sphinx{16,17} 7 | 3.6: theme,py36-sphinx{16,17} 8 | 9 | [testenv:theme] 10 | description = run theme build pipeline 11 | passenv = GEM* 12 | whitelist_externals = 13 | npm 14 | sass 15 | deps = 16 | sphinx 17 | commands = 18 | npm run build 19 | 20 | [testenv] 21 | description = run test suite for the application with {basepython} 22 | setev = 23 | LANG=C 24 | deps = 25 | . 26 | readthedocs-sphinx-ext 27 | pytest 28 | sphinx16: Sphinx < 1.7 29 | sphinx17: Sphinx < 1.8 30 | commands = 31 | py.test {posargs} 32 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/cookiebar.html: -------------------------------------------------------------------------------- 1 | 14 | -------------------------------------------------------------------------------- /sass/layout/_scrollbar.scss: -------------------------------------------------------------------------------- 1 | #doc-content { 2 | *::-webkit-scrollbar { 3 | width: 1em; 4 | height: 14px; 5 | } 6 | 7 | *::-webkit-scrollbar-track { 8 | background-color: $light-blue; 9 | border-radius: 7px; 10 | border: 2px $white solid; 11 | } 12 | 13 | *::-webkit-scrollbar-thumb { 14 | background-color: $blue; 15 | border-radius: 7px; 16 | background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAHCAYAAAABIM1CAAAALUlEQVQoU2N88+m/hggf4w0GLODJp//CLEwMUhI8jJexyT/7/l+OcdSAQRAGABbrTN6F2sNMAAAAAElFTkSuQmCC"); 17 | background-repeat: no-repeat; 18 | background-position: center; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /docs_italia_theme/data/_config.yml: -------------------------------------------------------------------------------- 1 | # Custom vars 2 | theme_color: "#0066cc" 3 | css_theme: docs-italia 4 | agid_short: AGID 5 | agid_full: Agenzia per l'Italia Digitale 6 | agid_link: http://www.agid.gov.it 7 | logo: /assets/icons/logo-it.png 8 | agid_logo: https://www.spid.gov.it/assets/img/agid-logo-bb.svg 9 | team_short: Team Digitale 10 | team_full: Team per la Trasformazione Digitale 11 | team_link: https://teamdigitale.governo.it 12 | cookies_policy_link: /cookies-policy/ 13 | gov_logo: https://teamdigitale.governo.it/images/loghi/governo.svg 14 | partner_logo: https://teamdigitale.governo.it/images/loghi/dt-logo.svg 15 | pill: beta 16 | default_language: it 17 | -------------------------------------------------------------------------------- /MANIFEST.in: -------------------------------------------------------------------------------- 1 | include *.txt 2 | include LICENSE 3 | include package.json 4 | recursive-include docs_italia_theme *.conf 5 | recursive-include docs_italia_theme *.css 6 | recursive-include docs_italia_theme *.eot 7 | recursive-include docs_italia_theme *.html 8 | recursive-include docs_italia_theme *.js 9 | recursive-include docs_italia_theme *.svg 10 | recursive-include docs_italia_theme *.png 11 | recursive-include docs_italia_theme *.ttf 12 | recursive-include docs_italia_theme *.woff 13 | recursive-include docs_italia_theme *.woff2 14 | recursive-include docs_italia_theme/data *.yaml 15 | recursive-include docs_italia_theme/data *.yml 16 | recursive-include docs_italia_theme/data *.json 17 | -------------------------------------------------------------------------------- /js/scroll_progressbar.js: -------------------------------------------------------------------------------- 1 | // Admonition toggle 2 | module.exports = themeScrollProgressBar = (function ($) { 3 | 4 | return { 5 | init: function(callback) { 6 | that = this.$; 7 | 8 | // When the user scrolls the page, execute myFunction 9 | $(window).scroll(function() { 10 | var winScroll = document.body.scrollTop || document.documentElement.scrollTop; 11 | var height = document.documentElement.scrollHeight - document.documentElement.clientHeight; 12 | var scrolled = (winScroll / height) * 100; 13 | document.getElementById("scrollprogressBar").style.width = scrolled + "%"; 14 | }); 15 | } 16 | }; 17 | 18 | })(jQuery); 19 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/templates.html: -------------------------------------------------------------------------------- 1 | 4 | {% include 'layouts/templates/forum_italia.html' %} 5 | 6 | 9 | {% include 'layouts/templates/markup_modifier.html' %} 10 | 11 | 14 | {% include 'layouts/templates/glossary_page.html' %} 15 | 16 | 19 | {% include 'layouts/templates/searchbox_collapse.html' %} 20 | 21 | 24 | {% include 'layouts/templates/section_navigation.html' %} 25 | 26 | 29 | {% include 'layouts/templates/tooltip.html' %} 30 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/web-analytics.html: -------------------------------------------------------------------------------- 1 | 16 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/templates/glossary_page.html: -------------------------------------------------------------------------------- 1 | {% raw %} 2 | 9 | 10 | 16 | {% endraw %} 17 | -------------------------------------------------------------------------------- /sass/theme.scss: -------------------------------------------------------------------------------- 1 | /* Theme variables */ 2 | @import "bootstrap-italia/src/scss/bootstrap-italia"; 3 | @import "abstract/variables"; 4 | 5 | /* Base */ 6 | @import "base/helpers"; 7 | @import "base/icon"; 8 | @import "base/normalize"; 9 | 10 | /* Theme layout */ 11 | @import "layout/general"; 12 | @import "layout/dropdown"; 13 | @import "layout/header"; 14 | @import "layout/navbar-secondary-offcanvas"; 15 | @import "layout/sidebar"; 16 | @import "layout/content"; 17 | @import "layout/admonitions"; 18 | @import "layout/footer"; 19 | @import "layout/tooltip"; 20 | @import "layout/content-nav"; 21 | @import "layout/scrollbar"; 22 | @import "layout/table"; 23 | @import "layout/note"; 24 | @import "layout/comments"; 25 | @import "layout/side-menu"; 26 | @import "layout/glossary"; 27 | @import "layout/back-to-top"; 28 | @import "layout/modals"; 29 | -------------------------------------------------------------------------------- /sass/layout/_table.scss: -------------------------------------------------------------------------------- 1 | #doc-content { 2 | table:not(.footnote) { 3 | border: 0; 4 | 5 | td { 6 | border-right: 0; 7 | border-left: 0; 8 | } 9 | 10 | &:not(.highlighttable) { 11 | td { 12 | min-width: 220px; 13 | } 14 | } 15 | 16 | thead { 17 | .head { 18 | border-right: 0; 19 | border-left: 0; 20 | text-transform: uppercase; 21 | color: $black; 22 | font-size: 0.75rem; 23 | vertical-align: top; 24 | } 25 | } 26 | 27 | tr { 28 | font-size: 0.75rem; 29 | 30 | // This rule is not working for tables having rowspan 31 | // Consider using colgroups (supporting only few css properties) 32 | // td:nth-of-type(1) { 33 | // font-weight: 700; 34 | // color: $dark-blue; 35 | // } 36 | } 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /js/get_glossary.js: -------------------------------------------------------------------------------- 1 | // Get glossary terms 2 | module.exports = themeGlossary = (function ($) { 3 | var that; 4 | 5 | return { 6 | 7 | $: { 8 | $url: '_static/data/glossary.json', 9 | $glossary: {}, 10 | callback: {} 11 | }, 12 | 13 | init: function(callback) { 14 | that = this.$; 15 | that.callback = callback; 16 | 17 | $.ajax({ 18 | dataType: 'json', 19 | url: that.$url, 20 | success: themeGlossary.success, 21 | error: themeGlossary.error, 22 | cache: false 23 | }); 24 | }, 25 | 26 | success: function(data) { 27 | that.$glossary = data; 28 | that.callback(); 29 | }, 30 | 31 | error: function(data) { 32 | that.callback(); 33 | }, 34 | 35 | getGlossary: function() { 36 | return that.$glossary 37 | } 38 | } 39 | 40 | })(jQuery); 41 | -------------------------------------------------------------------------------- /docs_italia_theme/static/images/team-digitale-logo.svg: -------------------------------------------------------------------------------- 1 | 2 | 4 | 8 | 10 | 11 | 12 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/searchbox.html: -------------------------------------------------------------------------------- 1 | {%- if builder != 'singlehtml' %} 2 | 18 | {%- endif %} 19 | -------------------------------------------------------------------------------- /js/admonition_toggle.js: -------------------------------------------------------------------------------- 1 | // Admonition toggle 2 | module.exports = themeAdmonitionToggle = (function ($) { 3 | 4 | return { 5 | init: function(callback) { 6 | that = this.$; 7 | 8 | $('.admonition__toggle-btn').on('click',function(){ 9 | var $btn = $(this), 10 | $paragraph = $btn.closest('.admonition__toggle-wrap').siblings('.admonition__hidden-paragraph'), 11 | $admonition = $btn.closest('.admonition-deepening'); 12 | 13 | if( $paragraph.hasClass('active')) { 14 | $("html, body").animate({ scrollTop: $admonition.offset().top - 10 }, 300, function(){ 15 | $paragraph.removeClass('active').slideUp(); 16 | $btn.removeClass('active'); 17 | }); 18 | } else { 19 | $paragraph.addClass('active').slideDown(); 20 | $btn.addClass('active'); 21 | } 22 | 23 | $btn.blur(); 24 | }); 25 | } 26 | } 27 | 28 | })(jQuery); 29 | -------------------------------------------------------------------------------- /js/searchbox_collapse.js: -------------------------------------------------------------------------------- 1 | var $tpl = require('./getTpl'); 2 | 3 | // Sticky sidebar 4 | module.exports = themeSearchboxCollapse = (function ($) { 5 | 6 | return { 7 | init: function(callback) { 8 | var $searchbox = $('#rtd-search-form'), 9 | $searchboxDesktopContainer = $searchbox.parent(), 10 | $searchboxMobileContainer = $('.doc-header'), 11 | wrapper = $tpl({}, 'searchbox-collapse'); 12 | 13 | $('#searchbox-toggle').on('click', function(event) { 14 | $(this).toggleClass('active'); 15 | if($(this).hasClass('active')) { 16 | $searchbox.detach(); 17 | $searchboxMobileContainer.append($searchbox); 18 | $searchbox.wrap(wrapper).fadeIn(); 19 | } 20 | else { 21 | $searchbox.unwrap().unwrap().fadeOut(); 22 | $searchbox.detach(); 23 | $searchboxDesktopContainer.append($searchbox); 24 | } 25 | }); 26 | } 27 | } 28 | })(jQuery); 29 | -------------------------------------------------------------------------------- /docs_italia_theme/data/_data/network_links.yml: -------------------------------------------------------------------------------- 1 | trasformazione_digitale: 2 | title: header_link_trasformazione 3 | url: 'https://pianotriennale-ict.italia.it' 4 | class: delimiter 5 | li_markup_pre: 'il programma' 6 | developers: 7 | title: header_link_developers 8 | url: 'https://developers.italia.it/' 9 | li_markup_pre: 'le community' 10 | class: current 11 | design: 12 | title: header_link_design 13 | url: 'http://designers.italia.it' 14 | class: delimiter 15 | forum: 16 | title: header_link_forum 17 | url: 'https://forum.italia.it/' 18 | li_markup_pre: 'gli strumenti' 19 | docs: 20 | title: header_link_docs 21 | url: 'https://docs.developers.italia.it/' 22 | github: 23 | title: header_link_github 24 | url: 'https://github.com/italia/' -------------------------------------------------------------------------------- /sass/base/_helpers.scss: -------------------------------------------------------------------------------- 1 | /* Background colors */ 2 | .bg-primary--dark { 3 | background-color: $medium-blue; 4 | } 5 | 6 | .bg-primary--mid-dark { 7 | background-color: $mid-dark-blue; 8 | } 9 | 10 | .bg-primary--darken { 11 | background-color: $dark-blue; 12 | } 13 | 14 | /* Text colors */ 15 | .text-grey { 16 | color: $grey; 17 | } 18 | 19 | .text-sans-serif { 20 | font-family: $titillium-font; 21 | } 22 | 23 | .text-serif { 24 | font-family: $stack-font; 25 | } 26 | 27 | .text-light-blue { 28 | color: $light-blue; 29 | } 30 | 31 | .text-blue { 32 | color: $blue; 33 | } 34 | 35 | /* Border colors */ 36 | .border-dark-blue { 37 | border-color: $dark-blue-border !important; 38 | } 39 | 40 | .border-medium-blue { 41 | border-color: $medium-blue !important; 42 | } 43 | 44 | .border-grey-light { 45 | border-color: $grey-light-02 !important; 46 | } 47 | 48 | // Border width 49 | .border-width-2 { 50 | border-width: 2px !important; 51 | } 52 | 53 | .stopScrolling--vertical { 54 | overflow-y: hidden; 55 | } 56 | 57 | .deactive { 58 | display: none !important; 59 | } 60 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/templates/markup_modifier.html: -------------------------------------------------------------------------------- 1 | {% raw %} 2 | 3 | 4 | 7 | 8 | 14 | 15 | 27 | {% endraw %} 28 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/scripts.html: -------------------------------------------------------------------------------- 1 | 26 | 27 | {%- for scriptfile in script_files %} 28 | {%- if not 'jquery' in scriptfile %} 29 | 30 | {%- endif %} 31 | {%- endfor %} 32 | -------------------------------------------------------------------------------- /tests/test_builders.py: -------------------------------------------------------------------------------- 1 | import os 2 | 3 | import pytest 4 | import sphinx 5 | from sphinx import addnodes 6 | from sphinx.builders.html import SingleFileHTMLBuilder, DirectoryHTMLBuilder 7 | 8 | from .util import build_all 9 | 10 | 11 | def test_basic(): 12 | for (app, status, warning) in build_all('test-basic'): 13 | assert app.env.get_doctree('index').traverse(addnodes.toctree) 14 | content = open(os.path.join(app.outdir, 'index.html')).read() 15 | 16 | if isinstance(app.builder, DirectoryHTMLBuilder): 17 | search = ( 18 | '
' 19 | ) 20 | assert search in content 21 | elif isinstance(app.builder, SingleFileHTMLBuilder): 22 | search = ( 23 | '
' 24 | ) 25 | assert search in content 26 | else: 27 | search = ( 28 | '
' 29 | ) 30 | assert search in content, ('Missing search with builder {0}' 31 | .format(app.builder.name)) 32 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/lang_switch.html: -------------------------------------------------------------------------------- 1 | {% if READTHEDOCS and translations %} 2 | 23 | {% endif %} 24 | -------------------------------------------------------------------------------- /docs_italia_theme/forum_italia.py: -------------------------------------------------------------------------------- 1 | # coding=utf-8 2 | 3 | # define custom node 4 | from docutils import nodes 5 | 6 | # define custom directive 7 | from docutils.parsers.rst import Directive 8 | from docutils.parsers.rst import directives 9 | 10 | class ForumItaliaCommentsNode(nodes.Structural, nodes.Element): 11 | @staticmethod 12 | def visit(self, node): 13 | pass 14 | @staticmethod 15 | def depart(self, node): 16 | pass 17 | 18 | class ForumItaliaCommentsDirective(Directive): 19 | # parameters 20 | required_arguments = 0 21 | optional_arguments = 0 22 | option_spec = { 23 | 'topic_id': directives.unchanged_required, 24 | 'scope': directives.unchanged 25 | } 26 | final_argument_whitespace = True 27 | 28 | def run(self): 29 | options = self.options 30 | scope = options['scope'] if 'scope' in options else 'section' 31 | 32 | node = ForumItaliaCommentsNode() 33 | 34 | topic_markup = ' '.join([ 35 | '
' 39 | ]) 40 | 41 | node += nodes.raw(text=topic_markup, format='html') 42 | node['data-topic-id'] = options['topic_id'] 43 | 44 | return [ node ] 45 | -------------------------------------------------------------------------------- /sass/layout/_note.scss: -------------------------------------------------------------------------------- 1 | #doc-content { 2 | .footnote-reference { 3 | color: $dark-blue-border; 4 | border: 1px $dark-blue-border solid; 5 | border-radius: 3px; 6 | padding: 0 0.4rem; 7 | line-height: 1.4; 8 | } 9 | 10 | .note-action { 11 | margin-top: 0.5rem; 12 | } 13 | 14 | .note-close-btn, 15 | .note-back-btn { 16 | background: none; 17 | border: 0; 18 | display: inline-block; 19 | color: $blue; 20 | font-size: 1.2em; 21 | cursor: pointer; 22 | } 23 | 24 | .note-back-btn { 25 | position: relative; 26 | 27 | &::before { 28 | content: ''; 29 | top: 0; 30 | bottom: 0; 31 | width: 1px; 32 | position: absolute; 33 | background-color: $blue; 34 | left: 0; 35 | } 36 | 37 | &:hover { 38 | text-decoration: underline; 39 | } 40 | } 41 | 42 | .docutils.footnote { 43 | color: $black; 44 | font-size: 0.8rem; 45 | display: none; 46 | margin-bottom: 2rem; 47 | 48 | td { 49 | width: 100%; 50 | float: left; 51 | } 52 | 53 | .fn-backref { 54 | color: $dark-blue-border; 55 | border: 1px $dark-blue-border solid; 56 | border-radius: 3px; 57 | padding: 0.2rem; 58 | line-height: 1; 59 | display: inline-block; 60 | margin-bottom: 0.5rem; 61 | } 62 | } 63 | } 64 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/templates/tooltip.html: -------------------------------------------------------------------------------- 1 | {% raw %} 2 | 11 | 12 | 21 | 22 | 31 | {% endraw %} 32 | -------------------------------------------------------------------------------- /docs_italia_theme/search.html: -------------------------------------------------------------------------------- 1 | {%- extends "layouts/default.html" %} 2 | 3 | {% set title = t.search %} 4 | 5 | {% set script_files = script_files + ['_static/searchtools.js'] %} 6 | {% block scripts %} 7 | {{ super() }} 8 | 11 | {# this is used when loading the search index using $.ajax fails, 12 | such as on Chrome for documents on localhost #} 13 | 14 | {% endblock %} 15 | 16 | {% block body %} 17 | 25 | 26 | {% if search_performed %} 27 |

{{ t.search_results }}

28 | {% if not search_results %} 29 |

{{ t.search_no_results }}

30 | {% endif %} 31 | {% endif %} 32 |
33 | {% if search_results %} 34 |
    35 | {% for href, caption, context in search_results %} 36 |
  • 37 | {{ caption }} 38 |

    {{ context|e }}

    39 |
  • 40 | {% endfor %} 41 |
42 | {% endif %} 43 |
44 | {% endblock %} 45 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/network.html: -------------------------------------------------------------------------------- 1 |
2 |

{{ t.navigation_network_menu_label }}

3 |
4 |
5 | 7 | 8 | 9 |
10 | 26 |
27 |
28 | -------------------------------------------------------------------------------- /sass/layout/_general.scss: -------------------------------------------------------------------------------- 1 | body { 2 | color: $grey-mid; 3 | background-color: $dark-blue; 4 | 5 | &.no-scroll { 6 | overflow-y: hidden; 7 | } 8 | } 9 | 10 | p { 11 | font-family: $stack-font; 12 | } 13 | 14 | h1, 15 | h2, 16 | h3, 17 | h4, 18 | h5 { 19 | color: $black; 20 | margin-bottom: 2rem; 21 | } 22 | 23 | img { 24 | max-width: 100%; 25 | height: auto; 26 | } 27 | 28 | .container-fluid--desktop { 29 | max-width: 1450px; 30 | } 31 | 32 | // Show loader when Body has .loading class 33 | @keyframes pulsate { 34 | 0% { 35 | transform: scale(0.1); 36 | opacity: 0; 37 | } 38 | 39 | 50% { 40 | opacity: 1; 41 | } 42 | 43 | 100% { 44 | transform: scale(1.2); 45 | opacity: 0; 46 | } 47 | } 48 | 49 | .loading { 50 | overflow: hidden; 51 | 52 | &::after { 53 | position: absolute; 54 | background: $blue; 55 | height: 100%; 56 | width: 100%; 57 | z-index: 10; 58 | content: ''; 59 | left: 0; 60 | top: 0; 61 | } 62 | 63 | &::before { 64 | border: 5px solid white; 65 | margin: -15px 0 0 -15px; 66 | border-radius: 30px; 67 | position: absolute; 68 | content: ''; 69 | z-index: 11; 70 | height: 30px; 71 | left: 50%; 72 | top: 50%; 73 | opacity: 0; 74 | width: 30px; 75 | animation: pulsate 1s ease-out; 76 | animation-iteration-count: infinite; 77 | } 78 | 79 | &.no-bg { 80 | &::after { 81 | background: none; 82 | position: relative; 83 | } 84 | } 85 | } 86 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2018, the respective contributors, as shown by the AUTHORS file. 2 | 3 | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 4 | 5 | 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 6 | 7 | 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 8 | 9 | 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. 10 | 11 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 12 | -------------------------------------------------------------------------------- /sass/base/_normalize.scss: -------------------------------------------------------------------------------- 1 | .small { 2 | font-size: 14px; 3 | } 4 | 5 | .navbar-dark--text-white { 6 | color: white; 7 | } 8 | 9 | .navbar-dark .navbar-nav .nav-link, 10 | .navbar-dark .lang-selector .nav-link { 11 | color: white !important; 12 | } 13 | 14 | .navbar.bg-white { 15 | background-color: $white; 16 | } 17 | 18 | .navbar.primary-bg-a7 { 19 | background-color: #0059b3; 20 | } 21 | 22 | .dropdown-menu.dropdown-menu-right::before { 23 | @include media-breakpoint-up(lg) { 24 | right: 24px; 25 | left: auto; 26 | } 27 | } 28 | 29 | @include media-breakpoint-up(lg) { 30 | .navbar .dropdown-menu.dropdown-menu-right { 31 | left: auto; 32 | right: 0; 33 | } 34 | } 35 | 36 | .dropdown-menu-right { 37 | @include media-breakpoint-down(md) { 38 | right: auto; 39 | left: auto; 40 | } 41 | } 42 | 43 | .dropdown.show .dropdown-menu[x-placement='bottom-start'], 44 | .btn-group.show .dropdown-menu[x-placement='bottom-start'] { 45 | animation: dropdownFadeIn forwards 0.3s; 46 | } 47 | 48 | .dropdown.show .dropdown-menu[x-placement='top-start'], 49 | .btn-group.show .dropdown-menu[x-placement='top-start'] { 50 | animation: dropdownFadeInTop forwards 0.3s; 51 | } 52 | 53 | .dropdown-menu[x-placement^="top"], 54 | .dropdown-menu[x-placement^="right"], 55 | .dropdown-menu[x-placement^="bottom"], 56 | .dropdown-menu[x-placement^="left"] { 57 | right: auto; 58 | bottom: auto; 59 | } 60 | 61 | .dropdown-menu::before { 62 | z-index: -1; 63 | } 64 | 65 | .injected { 66 | display: none; 67 | } 68 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/templates/section_navigation.html: -------------------------------------------------------------------------------- 1 | {% raw %} 2 | 29 | {% endraw %} 30 | -------------------------------------------------------------------------------- /js/getTpl.js: -------------------------------------------------------------------------------- 1 | /** 2 | * This is the modified library version of the github user romuleald. 3 | * https://github.com/romuleald/getTpl/blob/master/gettpl.js 4 | * 5 | * Modified because of we use ES5 and `let` keyword isn't. 6 | */ 7 | var getTpl = (function () { 8 | "use strict"; 9 | var cache = {}; 10 | var getCache = function (templateId) { 11 | return cache[templateId]; 12 | }; 13 | var setCache = function (templateId, html) { 14 | cache[templateId] = html; 15 | }; 16 | 17 | /** 18 | * 19 | * @param {Object} data formed object that match in template {foo:'bar'} will replace {{foo}} with bar 20 | * @param {String} templateId HTML attribute id 21 | * @returns {string} HTMl template transformed 22 | */ 23 | return function gettpl(data, templateId, debug) { 24 | var templateHTML = getCache(templateId); 25 | if (getCache(templateId)) { 26 | templateHTML = getCache(templateId); 27 | } 28 | else { 29 | var tpl = document.getElementById(templateId); 30 | templateHTML = tpl.innerHTML; 31 | setCache(templateId, templateHTML); 32 | } 33 | return templateHTML.replace(/{{ ?([^}]*) ?}}/g, function (search, result) { 34 | result = result.trim(); 35 | if (result.indexOf('.') > 0) { 36 | var obj_prop = result.split('.'); 37 | debug && console.info(result, data[obj_prop[0]][obj_prop[1]]); 38 | return data[obj_prop[0]][obj_prop[1]]; 39 | } 40 | debug && console.info(result, data[result]); 41 | return data[result] || ''; 42 | }); 43 | }; 44 | 45 | })(); 46 | module.exports = getTpl; 47 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "docs-italia-theme", 3 | "description": "Docs Italia theme è il tema Sphinx di riferimento per Docs Italia", 4 | "repository": "https://github.com/italia/docs-italia-theme", 5 | "version": "1.2.0-beta", 6 | "license": "MIT", 7 | "engines": { 8 | "node": ">=6" 9 | }, 10 | "author": "Presidenza del Consiglio dei Ministri", 11 | "scripts": { 12 | "start": "grunt", 13 | "build": "grunt build", 14 | "release": "grunt release" 15 | }, 16 | "dependencies": { 17 | "grunt-cli": "^1.3.2" 18 | }, 19 | "devDependencies": { 20 | "autoprefixer": "^8.5.0", 21 | "bootstrap-italia": "^0.10.3", 22 | "browserify": "^14.5.0", 23 | "connect-livereload": "^0.6.0", 24 | "cssnano": "^4.1.10", 25 | "discourse-client": "^0.1.2", 26 | "grunt": "^1.0.4", 27 | "grunt-browserify": "^5.2.0", 28 | "grunt-cache-bust": "1.4.1", 29 | "grunt-contrib-clean": "^1.1.0", 30 | "grunt-contrib-concat": "^1.0.1", 31 | "grunt-contrib-connect": "^1.0.2", 32 | "grunt-contrib-copy": "^1.0.0", 33 | "grunt-contrib-sass": "^1.0.0", 34 | "grunt-contrib-uglify": "^3.4.0", 35 | "grunt-contrib-watch": "^1.1.0", 36 | "grunt-exec": "^3.0.0", 37 | "grunt-modernizr": "^2.0.1", 38 | "grunt-postcss": "^0.9.0", 39 | "grunt-stylelint": "^0.10.0", 40 | "husky": "^1.2.0", 41 | "matchdep": "^2.0.0", 42 | "modernizr": "^3.7.1", 43 | "pixrem": "^4.0.1", 44 | "stickybits": "^3.5.8", 45 | "stylelint": "^9.10.1", 46 | "stylelint-config-standard": "^18.2.0" 47 | }, 48 | "husky": { 49 | "hooks": { 50 | "pre-commit": "grunt build" 51 | } 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /js/index.js: -------------------------------------------------------------------------------- 1 | global.$ = global.jQuery = require('jquery'); 2 | global.Popper = require('popper.js'); 3 | require('modernizr'); 4 | require('bootstrap-italia'); 5 | 6 | 7 | var themeMarkupModifier = require('./markup_modifier.js'); 8 | var themeToolTip = require('./tooltip.js'); 9 | var themeChapterNav = require('./section_navigation.js'); 10 | var themeNote = require('./note.js'); 11 | var themeGlossary = require('./get_glossary.js'); 12 | var themeAdmonitionToggle = require('./admonition_toggle.js'); 13 | var themeActiveVersions = require('./active_versions.js'); 14 | var themeCopyToClipboard = require('./copy_to_clipboard.js'); 15 | var themeSidebarNav = require('./sidebar_nav.js'); 16 | var themeGlossaryPage = require('./glossary_page.js'); 17 | var themeScrollProgressBar = require('./scroll_progressbar.js'); 18 | var themeStickyHeader = require('./sticky_header.js'); 19 | var themeOffcanvasFeature = require('./offcanvas_feature.js'); 20 | var themeSearchboxCollapse = require('./searchbox_collapse.js'); 21 | var forumItalia = require('./forum_italia.js'); 22 | 23 | // Init all 24 | $(document).ready(function() { 25 | 26 | themeGlossary.init(glossaryReady.bind(this)); 27 | themeMarkupModifier.init(); 28 | themeChapterNav.init(); 29 | themeNote.init(); 30 | themeAdmonitionToggle.init(); 31 | themeSidebarNav.init(); 32 | themeGlossaryPage.init(); 33 | themeCopyToClipboard.init(); 34 | themeActiveVersions.init(); 35 | themeScrollProgressBar.init(); 36 | themeStickyHeader.init(); 37 | themeOffcanvasFeature.init(); 38 | themeSearchboxCollapse.init(); 39 | forumItalia.init(); 40 | 41 | // Load tooltips when the ajax request for glossary terms is completed. 42 | function glossaryReady() { 43 | themeToolTip.init(); 44 | } 45 | }); 46 | -------------------------------------------------------------------------------- /sass/layout/_glossary.scss: -------------------------------------------------------------------------------- 1 | #glossary-page { 2 | > .chapter-header { 3 | display: none; 4 | } 5 | 6 | .chapter-header { 7 | padding-top: 2rem; 8 | padding-bottom: 2rem; 9 | padding-left: 0.5rem; 10 | overflow: hidden; 11 | 12 | h2 { 13 | font-size: 8rem; 14 | font-family: $stack-font; 15 | line-height: 1; 16 | } 17 | } 18 | 19 | .glossary-page__btn { 20 | border: 0; 21 | background: none; 22 | cursor: pointer; 23 | color: $blue; 24 | display: block; 25 | width: 100%; 26 | text-align: left; 27 | text-transform: uppercase; 28 | transition: color 0.3s; 29 | 30 | .docs-icon-minus, 31 | .docs-icon-plus { 32 | color: $blue; 33 | } 34 | 35 | .docs-icon-minus { 36 | display: inline-block; 37 | } 38 | 39 | .docs-icon-plus { 40 | display: none; 41 | } 42 | 43 | &.collapsed { 44 | color: $grey-mid; 45 | 46 | .docs-icon-minus { 47 | display: none; 48 | } 49 | 50 | .docs-icon-plus { 51 | display: inline-block; 52 | } 53 | } 54 | } 55 | 56 | .term-content { 57 | padding-left: 2.3rem; 58 | font-family: $titillium-font; 59 | 60 | p { 61 | font-family: $titillium-font; 62 | } 63 | 64 | &:last-of-type { 65 | &.show { 66 | border-bottom: 2px $grey-light-02 solid; 67 | } 68 | } 69 | } 70 | 71 | dt { 72 | &:last-of-type { 73 | .glossary-page__btn { 74 | &.collapsed { 75 | border-bottom: 2px $grey-light-02 solid; 76 | } 77 | } 78 | } 79 | } 80 | } 81 | 82 | .glossary-page__copy-link-wrap { 83 | color: $blue; 84 | } 85 | 86 | .glossary-page__copy-link { 87 | background: none; 88 | border: none; 89 | color: $blue; 90 | cursor: pointer; 91 | } 92 | -------------------------------------------------------------------------------- /sass/layout/_footer.scss: -------------------------------------------------------------------------------- 1 | .footer { 2 | * { 3 | font-family: $titillium-font; 4 | } 5 | 6 | a:hover { 7 | text-decoration: none; 8 | } 9 | 10 | .in-collaboration { 11 | font-size: 0.8em; 12 | } 13 | 14 | .team-logo--icon { 15 | width: 54px; 16 | } 17 | 18 | .team-logo--text { 19 | font-size: 1rem; 20 | line-height: 18px; 21 | max-width: 160px; 22 | text-transform: uppercase; 23 | } 24 | 25 | .agid-logo--icon { 26 | width: 8em; 27 | 28 | @include media-breakpoint-up(md) { 29 | width: 10em; 30 | } 31 | } 32 | 33 | .agid-logo--separator { 34 | border-left-width: 2px !important; 35 | height: 30px; 36 | 37 | @include media-breakpoint-up(md) { 38 | height: 40px; 39 | } 40 | } 41 | 42 | .agid-logo--text { 43 | width: 7rem; 44 | line-height: 1.2; 45 | font-size: 1em; 46 | display: inline-block; 47 | vertical-align: middle; 48 | 49 | @include media-breakpoint-up(md) { 50 | font-size: 1.1em; 51 | width: 8rem; 52 | } 53 | } 54 | 55 | .small-prints { 56 | color: #00fff8; 57 | font-weight: 600; 58 | } 59 | 60 | .social { 61 | font-size: 1em; 62 | color: #fff; 63 | 64 | .icon { 65 | color: #00264d; 66 | background-color: #fff; 67 | // padding: 0.2em 0.4em; 68 | padding: 0.3em 0.3em; 69 | border-radius: 100%; 70 | // font-size: initial; 71 | font-size: 22px; 72 | } 73 | } 74 | 75 | .colophon { 76 | border-top: 1px solid rgba(255, 255, 255, 0.1); 77 | margin-top: 1.5em; 78 | 79 | @include media-breakpoint-up(lg) { 80 | margin-top: 2em; 81 | } 82 | } 83 | } 84 | 85 | .footer-menu__link { 86 | &:hover { 87 | color: $white; 88 | } 89 | } 90 | 91 | .t_translate-wrap { 92 | display: none; 93 | } 94 | -------------------------------------------------------------------------------- /sass/layout/_side-menu.scss: -------------------------------------------------------------------------------- 1 | .sidebar-nav { 2 | @media (max-width: 767.98px) { 3 | padding-top: 5.5rem; 4 | } 5 | 6 | a { 7 | text-decoration: none; 8 | color: $grey-mid; 9 | font-size: 0.9rem; 10 | display: block; 11 | line-height: 1.6; 12 | margin-bottom: 1rem; 13 | margin-top: 1rem; 14 | 15 | &.current_item { 16 | position: relative; 17 | z-index: 1; 18 | margin-bottom: 1rem; 19 | margin-top: 1rem; 20 | transition: margin-bottom 0.3s, margin-top 0.3s; 21 | 22 | &::before { 23 | content: ''; 24 | position: absolute; 25 | top: -0.5rem; 26 | bottom: -0.5rem; 27 | left: -0.5rem; 28 | right: -0.5rem; 29 | background-color: $sky-blue; 30 | z-index: -1; 31 | } 32 | } 33 | 34 | &:hover, 35 | &:focus { 36 | text-decoration: underline; 37 | } 38 | } 39 | 40 | > .sidebar-list--wrapper { 41 | padding: 1rem; 42 | 43 | @include media-breakpoint-up(md) { 44 | padding: 0; 45 | } 46 | 47 | > ul { 48 | > li { 49 | padding: 0.1rem 3rem 0.1rem 1rem; 50 | 51 | > a { 52 | font-weight: 700; 53 | } 54 | } 55 | } 56 | 57 | ul { 58 | list-style-type: none; 59 | padding-left: 0; 60 | margin-bottom: 0; 61 | 62 | &.current { 63 | > li.current { 64 | background-color: $lighteen-blue; 65 | 66 | a { 67 | color: $mid-dark-blue; 68 | } 69 | } 70 | } 71 | 72 | ul { 73 | padding-left: 1rem; 74 | } 75 | } 76 | 77 | &.figures-index--menu, 78 | &.table-index--menu, 79 | &.glossary-mobile--menu { 80 | padding-top: 1rem; 81 | 82 | > ul { 83 | > li { 84 | padding-bottom: 0; 85 | padding-top: 0.5rem; 86 | } 87 | } 88 | } 89 | } 90 | } 91 | -------------------------------------------------------------------------------- /tests/util.py: -------------------------------------------------------------------------------- 1 | from __future__ import print_function 2 | 3 | import os 4 | import tempfile 5 | import shutil 6 | from contextlib import contextmanager 7 | 8 | import pytest 9 | from sphinx.application import Sphinx 10 | 11 | try: 12 | from StringIO import StringIO 13 | except ImportError: 14 | from io import StringIO 15 | 16 | 17 | @contextmanager 18 | def build(root, builder='html', **kwargs): 19 | tmpdir = tempfile.mkdtemp() 20 | 21 | srcdir = os.path.join(os.path.dirname(__file__), 'roots', root) 22 | destdir = os.path.join(tmpdir, builder) 23 | doctreedir = os.path.join(tmpdir, 'doctree/') 24 | 25 | status = StringIO() 26 | warning = StringIO() 27 | 28 | kwargs.update({ 29 | 'status': status, 30 | 'warning': warning, 31 | }) 32 | 33 | confoverrides = kwargs.pop('confoverrides', {}) 34 | confoverrides['html_theme'] = 'docs_italia_theme' 35 | extensions = confoverrides.get('extensions', []) 36 | extensions.append('readthedocs_ext.readthedocs') 37 | confoverrides['extensions'] = extensions 38 | kwargs['confoverrides'] = confoverrides 39 | 40 | try: 41 | app = Sphinx(srcdir, srcdir, destdir, doctreedir, builder, **kwargs) 42 | app.builder.build_all() 43 | yield (app, status.getvalue(), warning.getvalue()) 44 | except Exception as e: 45 | print('# root:', root) 46 | print('# builder:', builder) 47 | print('# source:', srcdir) 48 | print('# destination:', destdir) 49 | print('# status:', '\n' + status.getvalue()) 50 | print('# warning:', '\n' + warning.getvalue()) 51 | raise 52 | finally: 53 | shutil.rmtree(tmpdir) 54 | 55 | 56 | def build_all(root, **kwargs): 57 | for builder in ['html', 'singlehtml', 'readthedocs', 'readthedocsdirhtml', 58 | 'readthedocssinglehtml', 'readthedocssinglehtmllocalmedia']: 59 | with build(root, builder, **kwargs) as ret: 60 | yield ret 61 | -------------------------------------------------------------------------------- /js/note.js: -------------------------------------------------------------------------------- 1 | // Notes 2 | module.exports = themeNote = (function ($) { 3 | var that; 4 | 5 | return { 6 | 7 | $: { 8 | $noteBtn: $('.footnote-reference'), 9 | $note: $('.docutils.footnote'), 10 | $noteBackRef: $('.docutils.footnote').find('.fn-backref'), 11 | $noteStandardBtn: {}, 12 | $body: $('body'), 13 | $window: $(window), 14 | dataObj: {} 15 | }, 16 | 17 | init: function() { 18 | that = this.$; 19 | 20 | that.$noteStandardBtn = that.$noteBtn.filter(function() { 21 | return ($(this).closest('table').length == 0) 22 | }); 23 | that.$note.css('display', 'block').slideUp(0); 24 | that.$noteStandardBtn.on('click', themeNote.shownoteStandardBtn); 25 | that.$noteBackRef.on('click', themeNote.backToBtn); 26 | $('.note-close-btn').on('click', themeNote.closeNote); 27 | $('.note-back-btn').on('click', themeNote.backToBtn); 28 | }, 29 | 30 | shownoteStandardBtn: function(event) { 31 | event.preventDefault(); 32 | 33 | var $btn = $(event.target), 34 | noteid = $btn.attr('href').replace('#', ''), 35 | $note = $('#' + noteid); 36 | 37 | if($note.hasClass('active')) { 38 | $("html, body").animate({ scrollTop: $note.offset().top - 150 }, 300); 39 | } else { 40 | $note.addClass('active').slideDown(); 41 | $("html, body").animate({ scrollTop: $note.offset().top - 150 }, 300); 42 | } 43 | }, 44 | 45 | closeNote: function(event) { 46 | var $target = $(event.target), 47 | $note = $target.closest('.docutils.footnote.active'); 48 | 49 | that.$note.removeClass('active').slideUp(); 50 | }, 51 | 52 | backToBtn: function(event) { 53 | var $target = $(event.target), 54 | id = $target.closest('.footnote.active').attr('id'); 55 | 56 | $("html, body").animate({ scrollTop: $('a[href="#' + id + '"]').offset().top - 150 }, 200); 57 | } 58 | 59 | } 60 | })(jQuery); 61 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/document_actions.html: -------------------------------------------------------------------------------- 1 |
2 | 24 | 25 | {# 26 | 32 | #} 33 | {% if github_user and page_source_suffix %} 34 | {% set github_url = "https://github.com/" + github_user + "/" + github_repo + "/blob/" + github_version + conf_py_path + pagename + page_source_suffix %} 35 | {% endif %} 36 | 42 |
-------------------------------------------------------------------------------- /sass/abstract/_variables.scss: -------------------------------------------------------------------------------- 1 | /* Color */ 2 | $white: #fff; 3 | $black: #000; 4 | $lighteen-blue: #f6fbff; 5 | $light-blue: #e6f3fe; //#bbd8f1; ? 6 | $light-blue-01: #00c4c8; 7 | $blue: #0073e6; 8 | $medium-blue: #06c; 9 | $medium-blue-01: #799ebc; 10 | $medium-blue-02: #bbd8f1; 11 | $mid-dark-blue: #004e95; 12 | $dark-blue: #002b4d; 13 | $darker-blue: #004080; 14 | $sky-blue: #bffffd; 15 | $grey-light: #f9fafb; 16 | $grey-light-01: #eeeff0; 17 | $grey-light-02: #eaebed; 18 | $grey: #ccc; 19 | $grey-mid: #596771; 20 | $grey-mid-01: #8998a5; 21 | $grey-dark: #0b0b0b; 22 | $dark-blue-border: #193e5e; 23 | $red: #d83750; 24 | $red-alt: #d1344c; 25 | $orange: #df7d26; 26 | $teal: #4bd4d6; 27 | $green: #008255; 28 | $green-alt: #00cf86; 29 | $light-green: #efc; 30 | 31 | /* Font */ 32 | $stack-font: "Lora", serif; 33 | $titillium-font: "Titillium Web", "Helvetica Neue", Helvetica, Arial, sans-serif; 34 | $docs-font-icon: "docs-icons"; 35 | 36 | $chapter-nav-width: 200px; 37 | $sidebar-width: 420px; 38 | 39 | // Icon 40 | $icon-font-path: "../font" !default; 41 | 42 | $docs-icon-more: "\e900"; 43 | $docs-icon-expand: "\e901"; 44 | $docs-icon-collapse: "\e902"; 45 | $docs-icon-plus: "\e903"; 46 | $docs-icon-minus: "\e904"; 47 | $docs-icon-document: "\e905"; 48 | $docs-icon-edit: "\e906"; 49 | $docs-icon-download: "\e907"; 50 | $docs-icon-info: "\e908"; 51 | $docs-icon-compare: "\e909"; 52 | $docs-icon-github: "\e90a"; 53 | $docs-icon-share: "\e90b"; 54 | $docs-icon-search: "\e90c"; 55 | $docs-icon-link: "\e90d"; 56 | $docs-icon-external-link: "\e90e"; 57 | $docs-icon-comment: "\e90f"; 58 | $docs-icon-attention: "\e910"; 59 | $docs-icon-example: "\e911"; 60 | $docs-icon-procedure: "\e912"; 61 | $docs-icon-hint: "\e913"; 62 | $docs-icon-note: "\e914"; 63 | $docs-icon-step: "\e915"; 64 | $docs-icon-pdf: "\e916"; 65 | $docs-icon-html: "\e917"; 66 | $docs-icon-user: "\e918"; 67 | $docs-icon-docs: "\e919"; 68 | $docs-icon-project: "\e91a"; 69 | $docs-icon-publisher: "\e91b"; 70 | $docs-icon-check: "\e91c"; 71 | $docs-icon-not: "\e91d"; 72 | -------------------------------------------------------------------------------- /js/active_versions.js: -------------------------------------------------------------------------------- 1 | // Active versions 2 | module.exports = activeVersions = (function ($) { 3 | var that; 4 | 5 | return { 6 | $: { 7 | $versionList: $('#version-list').find('.version-list-wrapper'), 8 | $apiBaseUrl: '/docsitalia/api/document/', 9 | $activeVerionsEndpoint: READTHEDOCS_DATA.project + '/active_versions/', 10 | $activeVersions: [], 11 | $projectBaseUrl: [ 12 | '', 13 | DOCSITALIA_DATA.publisher_slug, 14 | DOCSITALIA_DATA.publisher_project_slug, 15 | READTHEDOCS_DATA.project, 16 | READTHEDOCS_DATA.language, 17 | '' 18 | ].join('/'), 19 | $versionElement: '%name%' 20 | }, 21 | 22 | init: function() { 23 | 24 | that = this.$; 25 | $.ajax({ 26 | dataType: 'json', 27 | url: READTHEDOCS_DATA.api_host + that.$apiBaseUrl + that.$activeVerionsEndpoint, 28 | success: activeVersions.success, 29 | error: activeVersions.error, 30 | complete: activeVersions.updateVersionList, 31 | cache: false 32 | }); 33 | }, 34 | 35 | success: function(data) { 36 | that.$activeVersions = data.versions.reduce(function(activeVersions, version) { 37 | (version.active == true && version.built == true) 38 | && activeVersions.push({ 39 | name: version.verbose_name, 40 | url: that.$projectBaseUrl + version.slug + '/' 41 | }); 42 | return activeVersions 43 | }, []); 44 | }, 45 | 46 | error: function() { 47 | that.$activeVersions = LOCAL ? [{ 48 | name: READTHEDOCS_DATA.version, 49 | url: '#' 50 | }] : []; 51 | }, 52 | 53 | updateVersionList: function() { 54 | that.$activeVersions.map(function(version) { 55 | that.$versionList.append(that.$versionElement.replace(/%\w+%/g, function(match) { 56 | return version[match.replace(/%/g, '')] || match; 57 | })); 58 | }); 59 | } 60 | } 61 | })(jQuery); 62 | -------------------------------------------------------------------------------- /setup.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | 3 | """Sphinx Docs Italia theme""" 4 | 5 | import codecs 6 | import json 7 | 8 | from setuptools import setup 9 | 10 | package_file = codecs.open('package.json', 'r', 'utf-8') 11 | package_data = json.load(package_file) 12 | 13 | 14 | setup( 15 | name = 'docs_italia_theme', 16 | version = package_data['version'], 17 | license = package_data['license'], 18 | author = 'Team per la Trasformazione Digitale - AgID', 19 | description = __doc__, 20 | long_description = codecs.open('README.md', 'r', 'utf-8').read(), 21 | zip_safe = False, 22 | packages = ['docs_italia_theme', 'docs-italia-theme'], 23 | package_data = {'docs_italia_theme': [ 24 | 'theme.conf', 25 | '*.html', 26 | 'static/css/*.css', 27 | 'static/icons/*.*', 28 | 'static/js/*.js', 29 | 'static/*.png', 30 | 'static/*.svg', 31 | 'static/font/*.*', 32 | 'data/*.*', 33 | ]}, 34 | include_package_data = True, 35 | # See http://www.sphinx-doc.org/en/stable/theming.html#distribute-your-theme-as-a-python-package 36 | entry_points = { 37 | 'sphinx.html_themes': [ 38 | 'docs_italia_theme = docs_italia_theme' 39 | ] 40 | }, 41 | classifiers = [ 42 | 'Development Status :: 5 - Production/Stable', 43 | 'License :: OSI Approved :: MIT License', 44 | 'Environment :: Console', 45 | 'Environment :: Web Environment', 46 | 'Intended Audience :: Developers', 47 | 'Programming Language :: Python :: 2.7', 48 | 'Programming Language :: Python :: 3', 49 | 'Programming Language :: Python :: 3.3', 50 | 'Programming Language :: Python :: 3.4', 51 | 'Programming Language :: Python :: 3.5', 52 | 'Programming Language :: Python :: 3.6', 53 | 'Operating System :: OS Independent', 54 | 'Topic :: Documentation', 55 | 'Topic :: Software Development :: Documentation' 56 | ], 57 | install_requires = [ 58 | 'PyYAML' 59 | ] 60 | ) 61 | -------------------------------------------------------------------------------- /docs_italia_theme/data/_data/tools.yml: -------------------------------------------------------------------------------- 1 | it: 2 | - 3 | title: Codice sorgente 4 | subtitle: Sul nostro GitHub Italia, sviluppiamo con un processo aperto gli SDK e gli esempi di supporto dei progetti, e gestiamo anche le segnalazioni dei problemi. 5 | icon: list 6 | url: https://github.com/italia 7 | - 8 | title: Forum 9 | subtitle: Utilizziamo Discourse come forum per aiutare la comunità a discutere sui progetti, scambiarsi trucchi e consigli, e parlare con i maintainer delle evoluzioni future. 10 | icon: comment 11 | url: https://forum.developers.italia.it 12 | - 13 | title: Documentazione 14 | subtitle: Qui trovi la documentazione tecnica dei progetti, scritta principalmente in Markdown and ReStructured Text, e compilata con Sphinx e ReadTheDocs 15 | url: https://docs.developers.italia.it 16 | - 17 | title: Sandbox per API 18 | subtitle: Gioca direttamente con le API dei progetti, in un ambiente di testing che ti aiuterà ad esplorare e sistemare la tua implementazione. 19 | comingsoon: true 20 | icon: settings 21 | 22 | en: 23 | - 24 | title: Source code 25 | subtitle: On our GitHub Italia, we develop SDK and examples to support our projects, with an open development process, and we also track existing issues. 26 | icon: list 27 | url: https://github.com/italia 28 | - 29 | title: Forum 30 | subtitle: Discourse is our forum of choice, to help the community discuss about the projects, exchange tips and tricks, and discuss with maintainers on the roadmap. 31 | icon: comment 32 | url: https://forum.developers.italia.it 33 | - 34 | title: Docs 35 | subtitle: Here you will find the technical documentation of all the projcets, mainly written in Markdown and ReStructured Text, and compiled with Sphinx and RedTheDocs 36 | url: https://docs.developers.italia.it 37 | - 38 | title: API Sandbox 39 | subtitle: Play with all the APIs exposed by the projects, in a testing environment that will help you exploring and fixing your implementation. 40 | comingsoon: true 41 | icon: settings 42 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/default.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | {% include 'layouts/head.html' %} 5 | 6 | 7 | {% include 'layouts/loader_show_script.html' %} 8 | {% include 'layouts/header.html' %} 9 | 10 | {% include 'layouts/templates.html' %} 11 | 12 |
13 |
14 |
15 | 19 |
20 | 24 | {% if prev %} 25 | 28 | {% endif %} 29 | {% block body %}{% endblock %} 30 | {% if next %} 31 | 34 | {% endif %} 35 |
36 | 37 |
38 |
39 |
40 | {% include 'layouts/footer.html' %} 41 | {% include 'layouts/l10n.html' %} 42 | {% include 'layouts/scrolltop.html' %} 43 | {% block scripts %} 44 | {% include 'layouts/scripts.html' %} 45 | {% endblock %} 46 | {% include 'layouts/web-analytics.html' %} 47 | {% if docsitalia_data %} 48 | {% include 'layouts/document_modals.html' %} 49 | {% endif %} 50 | 51 | 52 | -------------------------------------------------------------------------------- /sass/layout/_dropdown.scss: -------------------------------------------------------------------------------- 1 | .dropdown-menu { 2 | background-color: #fff; 3 | padding: 0.5rem; 4 | margin: 0; 5 | border-radius: 0.2rem; 6 | box-shadow: 2px 2px 8px 0 rgba(0, 0, 0, 0.35); 7 | z-index: 100; 8 | 9 | .dropdown-item { 10 | color: #0073e6; 11 | 12 | &.active, 13 | &:active { 14 | font-weight: 600; 15 | text-decoration: inherit; 16 | background-color: inherit; 17 | } 18 | } 19 | } 20 | 21 | #version-list { 22 | .dropdown-toggle .current-version { 23 | max-width: 8em; 24 | text-overflow: ellipsis; 25 | overflow: hidden; 26 | display: inline-block; 27 | font-size: inherit; 28 | font-weight: 400; 29 | } 30 | 31 | .version-list-wrapper { 32 | max-height: 10.2em; 33 | max-width: 18em; 34 | overflow-y: scroll; 35 | } 36 | 37 | .dropdown-item { 38 | text-overflow: ellipsis; 39 | max-width: 16em; 40 | overflow-x: hidden; 41 | } 42 | } 43 | 44 | .document-actions { 45 | .dropdown-toggle { 46 | &::after { 47 | vertical-align: middle; 48 | line-height: 1.5; 49 | } 50 | } 51 | 52 | @include media-breakpoint-down(sm) { 53 | .dropdown-toggle { 54 | &::after { 55 | /* stylelint-disable */ 56 | font-family: "italia-icon-font" !important; 57 | /* stylelint-enable */ 58 | border: none; 59 | margin: 0 2em 0 0; 60 | width: auto; 61 | height: auto; 62 | float: right; 63 | content: '\e818'; 64 | vertical-align: middle; 65 | font-size: $navigation-dropdown-icon-size; 66 | line-height: $navigation-dropdown-icon-line-height; 67 | transform-origin: center; 68 | transition: all 0.3s; 69 | } 70 | 71 | &[aria-expanded="true"]::after { 72 | transform: scaleY(-1); 73 | } 74 | 75 | &:hover { 76 | text-decoration: none; 77 | } 78 | } 79 | 80 | .dropdown-menu.show { 81 | position: static !important; 82 | transform: none !important; 83 | box-shadow: none; 84 | padding: 0; 85 | margin-top: 16px; 86 | animation: none; 87 | 88 | &::before { 89 | display: none; 90 | } 91 | } 92 | } 93 | } 94 | -------------------------------------------------------------------------------- /demo_docs/source/glossario.rst: -------------------------------------------------------------------------------- 1 | Glossario 2 | ========= 3 | 4 | A 5 | - 6 | 7 | .. glossary:: 8 | 9 | timeam 10 | Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, 11 | consectetur, adipisci velit, sed quia non numquam eius modi tempora 12 | incidunt ut labore et dolore magnam aliquam quaerat voluptatem. 13 | 14 | Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu 15 | fugiat nulla pariatur. 16 | 17 | antiopam 18 | Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, 19 | consectetur, adipisci velit, sed quia non numquam eius modi tempora 20 | incidunt ut labore et dolore magnam aliquam quaerat voluptatem. 21 | 22 | voluptatum 23 | Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, 24 | consectetur, adipisci velit, sed quia non numquam eius modi tempora 25 | incidunt ut labore et dolore magnam aliquam quaerat voluptatem. 26 | 27 | ullamco 28 | Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, 29 | consectetur, adipisci velit, sed quia non numquam eius modi tempora 30 | incidunt ut labore et dolore magnam aliquam quaerat voluptatem. 31 | 32 | B 33 | - 34 | 35 | .. glossary:: 36 | 37 | btimeam 38 | Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, 39 | consectetur, adipisci velit, sed quia non numquam eius modi tempora 40 | incidunt ut labore et dolore magnam aliquam quaerat voluptatem. 41 | 42 | bantiopam 43 | Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, 44 | consectetur, adipisci velit, sed quia non numquam eius modi tempora 45 | incidunt ut labore et dolore magnam aliquam quaerat voluptatem. 46 | 47 | bvoluptatum 48 | Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, 49 | consectetur, adipisci velit, sed quia non numquam eius modi tempora 50 | incidunt ut labore et dolore magnam aliquam quaerat voluptatem. 51 | 52 | BULL_AMCO 53 | Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, 54 | consectetur, adipisci velit, sed quia non numquam eius modi tempora 55 | incidunt ut labore et dolore magnam aliquam quaerat voluptatem. -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | [![Join the #design channel](https://img.shields.io/badge/Slack%20channel-%23design-blue.svg)](https://developersitalia.slack.com/messages/C7658JRJR) 2 | [![Get invited](https://slack.developers.italia.it/badge.svg)](https://slack.developers.italia.it/) 3 | 4 | # Docs Italia theme 5 | 6 | This is the official theme for any piece of documentation hosted on the 7 | upcoming Docs Italia. 8 | 9 | ## How to use Sphinx Italia on your documentation 10 | 11 | * Add the following line to your documentation `requirements.txt` file: 12 | 13 | ``` 14 | $ pip install git+https://github.com/italia/docs-italia-theme.git 15 | ``` 16 | 17 | * In your `conf.py` file, you'll need to specify the theme as follows: 18 | 19 | ``` 20 | # Add this line at the top of the file within the "import" section 21 | import docs_italia_theme 22 | 23 | # Add the Sphinx extension 'docs_italia_theme' in the extensions list 24 | extensions = [ 25 | # ..., 26 | 'docs_italia_theme' 27 | ] 28 | 29 | # Edit these lines 30 | html_theme = "docs_italia_theme" 31 | html_theme_path = [docs_italia_theme.get_html_theme_path()] 32 | ``` 33 | 34 | ## Contributing or modifying the theme 35 | 36 | * Clone the repository: 37 | 38 | ``` 39 | git clone git+https://github.com/italia/docs-italia-theme.git 40 | ``` 41 | 42 | * If needed, install [Sphinx](http://www.sphinx-doc.org/en/stable/) into a virtual environment: 43 | 44 | ``` 45 | pip install sphinx 46 | ``` 47 | 48 | * If needed, install [SASS](http://sass-lang.com/): 49 | 50 | ``` 51 | gem install sass 52 | ``` 53 | 54 | 4. Install [node.js](https://nodejs.org) and grunt: 55 | 56 | ``` 57 | // Install node on OS X 58 | brew install node 59 | 60 | // Install grunt 61 | npm install -g grunt-cli 62 | 63 | // Now that everything is installed, let's install the theme dependecies. 64 | npm install 65 | ``` 66 | 67 | 5. Run the main script to load a sample docs with the Sphinx Italia theme applied: 68 | 69 | ``` 70 | npm start 71 | ``` 72 | 73 | This will compile static assets and watch files required for the theme to reload at runtime. 74 | 75 | **TODO:** building a release, handling versioning system to enable automatic update on Docs Italia platform 76 | -------------------------------------------------------------------------------- /sass/layout/_content-nav.scss: -------------------------------------------------------------------------------- 1 | .chapter-nav__list--hidden { 2 | &:not(.show) { 3 | @include media-breakpoint-down(md) { 4 | display: none; 5 | } 6 | } 7 | 8 | @include media-breakpoint-up(lg) { 9 | visibility: hidden; 10 | opacity: 0; 11 | transition: visibility 0.35s, opacity 0.35s; 12 | 13 | &.active { 14 | visibility: visible; 15 | opacity: 1; 16 | } 17 | } 18 | } 19 | 20 | .chapter-nav__list-wrap { 21 | @include media-breakpoint-down(md) { 22 | max-width: 300px; 23 | margin-left: auto; 24 | margin-right: auto; 25 | border-radius: 4px; 26 | } 27 | } 28 | 29 | .chapter-nav__wrap { 30 | @include media-breakpoint-up(lg) { 31 | position: absolute; 32 | left: 2rem; 33 | top: 1rem; 34 | } 35 | } 36 | 37 | .chapter-link { 38 | background: none; 39 | border: none; 40 | color: $blue; 41 | padding: 0; 42 | display: inline-block; 43 | font-size: 0.9em; 44 | font-weight: 400; 45 | cursor: pointer; 46 | vertical-align: middle; 47 | 48 | &:hover { 49 | text-decoration: underline; 50 | } 51 | } 52 | 53 | .chapter-link__title { 54 | float: left; 55 | } 56 | 57 | .chapter-link__counter { 58 | margin-right: 0.3rem; 59 | display: inline-block; 60 | float: left; 61 | } 62 | 63 | .chapter-nav__list { 64 | list-style-type: none; 65 | margin-bottom: 0; 66 | padding: 1rem; 67 | 68 | @include media-breakpoint-up(lg) { 69 | padding: 0; 70 | } 71 | } 72 | 73 | .chapter-nav__title { 74 | padding: 1rem; 75 | color: $black; 76 | font-size: 0.8rem; 77 | font-weight: 700; 78 | border-bottom: 1px $grey solid; 79 | 80 | .title__chapter { 81 | color: $grey-mid-01; 82 | } 83 | 84 | @include media-breakpoint-up(lg) { 85 | display: none; 86 | } 87 | } 88 | 89 | .chapter-nav__item:not(:last-child) { 90 | margin-bottom: 1rem; 91 | 92 | @include media-breakpoint-up(lg) { 93 | margin-bottom: 0; 94 | } 95 | } 96 | 97 | .chapter-nav__list--visible { 98 | margin-top: 1rem; 99 | 100 | @include media-breakpoint-up(lg) { 101 | margin-top: -0.5rem; 102 | } 103 | 104 | .chapter-nav__item { 105 | display: inline-block; 106 | 107 | @include media-breakpoint-up(lg) { 108 | display: block; 109 | } 110 | } 111 | } 112 | -------------------------------------------------------------------------------- /docs_italia_theme/static/images/may.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 8 | 9 | 11 | 12 | 13 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /sass/layout/_navbar-secondary-offcanvas.scss: -------------------------------------------------------------------------------- 1 | .offcanvas-menu { 2 | position: fixed; 3 | z-index: 1000; 4 | width: 100vw; 5 | height: 100vh; 6 | top: 0; 7 | left: 0; 8 | right: 0; 9 | bottom: 0; 10 | 11 | &.animate--left { 12 | transform: translate3d(-100%, 0, 0); 13 | transition: transform 0.4s; 14 | transition-timing-function: cubic-bezier(0.7, 0, 0.3, 1); 15 | } 16 | 17 | &.js-active { 18 | transform: translate3d(0, 0, 0); 19 | transition: transform 0.8s; 20 | transition-timing-function: cubic-bezier(0.7, 0, 0.3, 1); 21 | } 22 | 23 | .offcanvas-menu__inner { 24 | width: 80%; 25 | background-color: #fff; 26 | height: 100vh; 27 | transform: translateX(0); 28 | transition: all 0.5s ease-out; 29 | 30 | .offcanvas-menu__header { 31 | padding: 1.5rem 1.8rem 1rem; 32 | 33 | .offcanvas-menu__title { 34 | font-weight: 600; 35 | font-size: 1.2rem; 36 | } 37 | } 38 | 39 | .offcanvas-menu__nav { 40 | padding: 0.5rem 0 0 0; 41 | margin: 0; 42 | 43 | .offcanvas-menu__nav__item { 44 | list-style: none; 45 | margin: 0; 46 | padding: 0.5rem 1rem; 47 | 48 | // Horiontal separators 49 | &:nth-child(1), 50 | &:nth-child(4) { 51 | position: relative; 52 | 53 | &::before { 54 | content: ''; 55 | width: 64px; 56 | height: 1px; 57 | left: 2rem; 58 | border-top: 1px solid rgba(0, 102, 204, 0.2); 59 | position: absolute; 60 | top: 0; 61 | } 62 | } 63 | 64 | .offcanvas-menu__nav__link { 65 | padding: 0.5rem 1rem; 66 | font-size: 1rem; 67 | display: block; 68 | } 69 | } 70 | } 71 | } 72 | 73 | &.deactive .offcanvas-menu__inner { 74 | margin-left: -80%; 75 | overflow: hidden; 76 | } 77 | 78 | .offcanvas-menu__extra { 79 | width: 20%; 80 | height: 100vh; 81 | position: fixed; 82 | right: 0; 83 | top: 0; 84 | } 85 | } 86 | 87 | body::before { 88 | position: fixed; 89 | top: 0; 90 | left: 0; 91 | z-index: 999; 92 | bottom: 0; 93 | right: 0; 94 | background: rgba(0, 0, 0, 0.5); 95 | content: ''; 96 | opacity: 0; 97 | transform: translate3d(100%, 0, 0); 98 | transition: opacity 0.4s, transform 0s 0.4s; 99 | transition-timing-function: cubic-bezier(0.7, 0, 0.3, 1); 100 | } 101 | 102 | body.show-menu::before { 103 | opacity: 1; 104 | transition: opacity 0.8s; 105 | transition-timing-function: cubic-bezier(0.7, 0, 0.3, 1); 106 | transform: translate3d(0, 0, 0); 107 | } 108 | -------------------------------------------------------------------------------- /js/modernizr.min.js: -------------------------------------------------------------------------------- 1 | /*! modernizr 3.7.1 (Custom Build) | MIT * 2 | * https://modernizr.com/download/?-touchevents-setclasses !*/ 3 | !function(e,n,t){function o(e,n){return typeof e===n}function s(){return"function"!=typeof n.createElement?n.createElement(arguments[0]):u?n.createElementNS.call(n,"http://www.w3.org/2000/svg",arguments[0]):n.createElement.apply(n,arguments)}function a(){var e=n.body;return e||(e=s(u?"svg":"body"),e.fake=!0),e}function i(e,t,o,i){var r,l,f,u,d="modernizr",p=s("div"),h=a();if(parseInt(o,10))for(;o--;)f=s("div"),f.id=i?i[o]:d+(o+1),p.appendChild(f);return r=s("style"),r.type="text/css",r.id="s"+d,(h.fake?h:p).appendChild(r),h.appendChild(p),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(n.createTextNode(e)),p.id=d,h.fake&&(h.style.background="",h.style.overflow="hidden",u=c.style.overflow,c.style.overflow="hidden",c.appendChild(h)),l=t(p,e),h.fake?(h.parentNode.removeChild(h),c.style.overflow=u,c.offsetHeight):p.parentNode.removeChild(p),!!l}var r=[],l={_version:"3.7.1",_config:{classPrefix:"",enableClasses:!0,enableJSClass:!0,usePrefixes:!0},_q:[],on:function(e,n){var t=this;setTimeout(function(){n(t[e])},0)},addTest:function(e,n,t){r.push({name:e,fn:n,options:t})},addAsyncTest:function(e){r.push({name:null,fn:e})}},Modernizr=function(){};Modernizr.prototype=l,Modernizr=new Modernizr;var f=[],c=n.documentElement,u="svg"===c.nodeName.toLowerCase(),d=l._config.usePrefixes?" -webkit- -moz- -o- -ms- ".split(" "):["",""];l._prefixes=d;var p=function(){var n=e.matchMedia||e.msMatchMedia;return n?function(e){var t=n(e);return t&&t.matches||!1}:function(n){var t=!1;return i("@media "+n+" { #modernizr { position: absolute; } }",function(n){t="absolute"===(e.getComputedStyle?e.getComputedStyle(n,null):n.currentStyle).position}),t}}();l.mq=p,Modernizr.addTest("touchevents",function(){if("ontouchstart"in e||e.TouchEvent||e.DocumentTouch&&n instanceof DocumentTouch)return!0;var t=["(",d.join("touch-enabled),("),"heartz",")"].join("");return p(t)}),function(){var e,n,t,s,a,i,l;for(var c in r)if(r.hasOwnProperty(c)){if(e=[],n=r[c],n.name&&(e.push(n.name.toLowerCase()),n.options&&n.options.aliases&&n.options.aliases.length))for(t=0;t0&&(n+=" "+t+e.join(" "+t)),u?c.className.baseVal=n:c.className=n)}(f),delete l.addTest,delete l.addAsyncTest;for(var h=0;h 2 |
3 |
4 | 16 | 30 |
31 | 39 |
40 |
41 | 42 | 43 |
44 |
    45 | {% for link in site.data.footer_links %} 46 |
  • 47 | {{ t[link.title] }} 48 |
  • 49 | {% endfor %} 50 |
51 |
52 |
53 | 54 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/sidebar.html: -------------------------------------------------------------------------------- 1 |
2 | 59 |
60 | -------------------------------------------------------------------------------- /demo_docs/source/index.rst: -------------------------------------------------------------------------------- 1 | H1 Titolo del documento, molto probabile su 2/3 righe 2 | +++++++++++++++++++++++++++++++++++++++++++++++++++++ 3 | 4 | .. highlights:: 5 | 6 | Sommario di due/tre righe: lorem ipsum dolor sit amet, consectetur adipisici 7 | elit, sed eiusmod tempor incidunt ut labore et dolore magna aliqua. 8 | 9 | .. container:: document-info 10 | 11 | :Publisher: Team per la Trasformazione Digitale 12 | :Licenza: CC-BY 4.0 13 | 14 | .. admonition:: consultation 15 | 16 | Questo documento è in consultazione pubblica dal 3 aprile al 4 maggio 2018, 17 | come previsto dall'`art. 71 comma 1 del decreto legislativo 7 marzo 2005, n. 18 | 82 `_. Ogni 19 | commento verrà preso in considerazione per la stesura finale. 20 | 21 | .. topic:: Titolo del Q&A fra utente e amministrazione 22 | :class: question-and-answers 23 | 24 | Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, 25 | sed quia consequuntur magni dolores eos qui ratione voluptatem sequi 26 | nesciunt. 27 | 28 | .. pull-quote:: utente 29 | 30 | Quote di domanda dell’utente. Lorem ipsum dolor sit amet, adipisici elit, 31 | sed aiusmod tempo soiu incidunt labore et aliqua sumen fortes crauden? 32 | 33 | - :term:`Keyword 1` 34 | - :term:`Keyword 2` 35 | - :term:`Keyword 3` 36 | - :term:`Keyword 4` 37 | 38 | .. pull-quote:: amministrazione 39 | 40 | Quote di risposta dall’Amministrazione. Quod sale ius, id volumus invidunt 41 | conclusionemque mea, vis no ipsum quaeque minimum tritani adipisci. 42 | 43 | - :term:`Keyword 1` 44 | - :term:`Keyword 2` 45 | - :term:`Keyword 3` 46 | 47 | .. glossary:: 48 | 49 | Keyword 1 50 | Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, 51 | consectetur, adipisci velit, sed quia non numquam eius modi tempora 52 | incidunt ut labore et dolore magnam aliquam quaerat voluptatem. 53 | 54 | Keyword 2 55 | Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, 56 | consectetur, adipisci velit, sed quia non numquam eius modi tempora 57 | incidunt ut labore et dolore magnam aliquam quaerat voluptatem. 58 | 59 | Keyword 3 60 | Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, 61 | consectetur, adipisci velit, sed quia non numquam eius modi tempora 62 | incidunt ut labore et dolore magnam aliquam quaerat voluptatem. 63 | 64 | Keyword 4 65 | Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, 66 | consectetur, adipisci velit, sed quia non numquam eius modi tempora 67 | incidunt ut labore et dolore magnam aliquam quaerat voluptatem. 68 | 69 | .. toctree:: 70 | :maxdepth: 3 71 | :numbered: 72 | :hidden: 73 | 74 | capitolo-1.rst 75 | capitolo-2.rst 76 | 77 | .. toctree:: 78 | :name: glossary_toc 79 | :hidden: 80 | 81 | glossario.rst 82 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/doc_header.html: -------------------------------------------------------------------------------- 1 |
2 |
3 | 10 |
11 | {% include 'layouts/searchbox.html' %} 12 |
13 |
14 | {% if docsitalia_data %} 15 | 16 | 17 | {{ t.info }} 18 | 19 | {% endif %} 20 |
21 |
22 |
23 | 31 |
32 |
33 |
34 | {% include 'layouts/document_actions.html' %} 35 |
36 | {# 37 |
38 | {% if docsitalia_data %} 39 | 40 | 41 | {{ t.related }} 42 | 43 | {% endif %} 44 |
45 | #} 46 | 52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 | -------------------------------------------------------------------------------- /sass/layout/_tooltip.scss: -------------------------------------------------------------------------------- 1 | .doc-tooltip { 2 | background-color: $white; 3 | font-family: $stack-font; 4 | box-shadow: 0 0 100px 0 rgba(0, 0, 0, 0.15); 5 | 6 | &.bs-popover-top::before, 7 | &.bs-popover-bottom::before { 8 | content: ""; 9 | width: 0; 10 | height: 0; 11 | border-top: 40px solid transparent; 12 | border-bottom: 40px solid transparent; 13 | border-left: 40px solid $white; 14 | position: absolute; 15 | left: 0; 16 | z-index: -1; 17 | } 18 | 19 | &.bs-popover-top::before { 20 | bottom: -40px; 21 | } 22 | 23 | &.bs-popover-bottom::before { 24 | top: -40px; 25 | } 26 | 27 | &.bs-popover-top::after, 28 | &.bs-popover-bottom::after { 29 | content: ""; 30 | width: 15px; 31 | height: 15px; 32 | transform: rotate(45deg); 33 | position: absolute; 34 | left: 5px; 35 | z-index: -2; 36 | } 37 | 38 | &.bs-popover-top::after { 39 | box-shadow: 5px 5px 70px 8px rgba(0, 0, 0, 0.15); 40 | bottom: -20px; 41 | } 42 | 43 | &.bs-popover-bottom::after { 44 | box-shadow: -5px -5px 70px 8px rgba(0, 0, 0, 0.15); 45 | top: -20px; 46 | } 47 | 48 | &.doc-tooltip--note { 49 | &::after, 50 | &::before { 51 | content: none; 52 | } 53 | } 54 | } 55 | 56 | .tooltip__wrap { 57 | overflow: hidden; 58 | width: 330px; 59 | padding: 2rem; 60 | font-family: $titillium-font; 61 | } 62 | 63 | .tooltip__title { 64 | overflow: hidden; 65 | font-style: italic; 66 | margin-bottom: 0.5rem; 67 | font-size: 1em; 68 | letter-spacing: 0; 69 | } 70 | 71 | .tooltip__content { 72 | font-size: 0.9rem; 73 | font-style: italic; 74 | margin-bottom: 0; 75 | } 76 | 77 | .tooltip__close-btn { 78 | position: absolute; 79 | top: 1rem; 80 | right: 1rem; 81 | width: 20px; 82 | height: 20px; 83 | padding: 0; 84 | background: none; 85 | border: 0; 86 | cursor: pointer; 87 | 88 | &::after, 89 | &::before { 90 | content: ""; 91 | position: absolute; 92 | height: 20px; 93 | width: 1px; 94 | background-color: $blue; 95 | top: 0; 96 | left: 50%; 97 | } 98 | 99 | &::after { 100 | transform: rotate(45deg) translateX(-50%); 101 | } 102 | 103 | &::before { 104 | transform: rotate(-45deg) translateX(-50%); 105 | } 106 | } 107 | 108 | .tooltip__link { 109 | color: $blue; 110 | font-size: 0.8rem; 111 | font-weight: 100; 112 | text-transform: uppercase; 113 | letter-spacing: 0; 114 | position: relative; 115 | display: inline-block; 116 | margin-top: 1rem; 117 | 118 | &::after { 119 | content: ''; 120 | position: absolute; 121 | left: 100%; 122 | top: 0; 123 | width: 30px; 124 | background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAAGCAYAAAAVMmT4AAAABmJLR0QAAAAAAAD5Q7t/AAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH4gUPDDQNy1r5IQAAAH5JREFUGNNj+I8HTD704v+ZR1/gfCYGPODNlz8MLv3XGc4+/srAwMDAwHjx6df//jNuYVX84esfhg9f/jAI8LAw3G4yYGD8+vPv/ztvfmBVPP3wK4YZ+14wdIfJM5Q4SzIw/v///z8uZzRsf8rAw8bEUOIsCRHA58EXn36h8AF2435mx6vmAAAAAABJRU5ErkJggg=='); 125 | background-repeat: no-repeat; 126 | bottom: 0; 127 | background-position: center; 128 | } 129 | } 130 | -------------------------------------------------------------------------------- /docs_italia_theme/data/_data/menu_items.yml: -------------------------------------------------------------------------------- 1 | it: 2 | - title: Progetti 3 | url: '#' 4 | liClass: 'Megamenu-item Megamenu-item--vert' 5 | subitems: 6 | - title: SPID 7 | url: /it/spid 8 | - title: dati.gov.it 9 | url: /it/datigov 10 | - title: ANPR 11 | url: /it/anpr 12 | - title: CIE 13 | url: /it/cie 14 | - title: Tutti i progetti 15 | url: /it/progetti 16 | liClass: 'Megamenu-showAll' 17 | - title: Strumenti 18 | url: '#' 19 | subitems: 20 | - title: Repository GitHub 21 | image: /assets/icons/tools/decorative_outlined_github.svg 22 | url: https://github.com/italia 23 | - title: Forum 24 | image: /assets/icons/tools/decorative_outlined_discourse.svg 25 | url: https://forum.developers.italia.it 26 | - title: Docs 27 | image: /assets/icons/tools/decorative_outlined_docs.svg 28 | url: https://docs.developers.italia.it 29 | - title: API Sandbox 30 | image: /assets/icons/tools/decorative_outlined_api.svg 31 | markup_post: > 32 |
33 | 35 | in arrivo 36 | 37 |
38 | - title: Notizie 39 | url: news 40 | - title: Chi siamo 41 | url: it/chi-siamo 42 | - title: FAQ 43 | url: it/faq 44 | 45 | en: 46 | - title: Projects 47 | url: '#' 48 | subitems: 49 | - title: Top projects 50 | url: /en/projects 51 | subitems: 52 | - title: SPID 53 | url: /en/spid 54 | - title: dati.gov.it 55 | url: /en/datigov 56 | - title: ANPR 57 | url: /en/anpr 58 | - title: CIE 59 | url: /en/cie 60 | - title: All projects 61 | url: /en/projects 62 | - title: Tools 63 | url: '#' 64 | subitems: 65 | - title: Tools 66 | url: '#' 67 | layout: horizontal 68 | subitems: 69 | - title: Repository GitHub 70 | image: /assets/icons/tools/decorative_outlined_github.svg 71 | url: https://github.com/italia 72 | - title: Forum 73 | image: /assets/icons/tools/decorative_outlined_discourse.svg 74 | url: https://forum.developers.italia.it 75 | - title: Docs 76 | image: /assets/icons/tools/decorative_outlined_docs.svg 77 | url: https://docs.developers.italia.it 78 | - title: API Sandbox 79 | image: /assets/icons/tools/decorative_outlined_api.svg 80 | url: / 81 | markup_post: > 82 |
83 | 84 | coming soon 85 | 86 |
87 | - title: News 88 | url: news 89 | - title: Credits 90 | url: en/credits 91 | - title: FAQ 92 | url: en/faq 93 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/head.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | {{ docstitle }} | {{ title|striptags|e }} 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | {%- if parents %} 15 | 16 | {%- endif %} 17 | {%- if next %} 18 | 19 | {%- endif %} 20 | {%- if prev %} 21 | 22 | {%- endif %} 23 | 24 | {% if docsitalia_data and not LOCAL %} 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | {% endif %} 55 | 56 | 57 | {% if PRODUCTION_DOMAIN != "docs.italia.it" %} 58 | 59 | {% endif %} 60 | 61 | -------------------------------------------------------------------------------- /js/glossary_page.js: -------------------------------------------------------------------------------- 1 | var $tpl = require('./getTpl'); 2 | 3 | // Get glossary terms 4 | module.exports = themeGlossaryPage = (function ($) { 5 | var that; 6 | 7 | return { 8 | 9 | $: { 10 | $letterBnt: $('#glossary-page .glossary.docutils dt'), 11 | $navLink: $('.sidebar-accordion-content a') 12 | }, 13 | 14 | init: function() { 15 | that = this.$; 16 | var sectionid = document.title.toLowerCase(document.title); 17 | 18 | if( $('#glossary-page').length ) { 19 | themeGlossaryPage.buildAccordion(); 20 | themeGlossaryPage.showRightTerm(); 21 | 22 | // Detect url change and open the right term, use to detect the click on nav item ex: 'A' 'B' etc.. 23 | $(window).bind('hashchange', function() { 24 | themeGlossaryPage.showRightTerm(); 25 | }); 26 | } 27 | }, 28 | 29 | buildAccordion: function() { 30 | that.$letterBnt.each(function(index){ 31 | var $btn = $(this), 32 | id = $btn.attr('id'), 33 | $target = $btn.next('dd'), 34 | $customBtn = $tpl({ id: id, text: $btn.text() }, 'glossary__btn'); 35 | 36 | $btn.html($customBtn); 37 | $target.attr('id', 'glossary-' + id).attr('aria-labelledby' , id).addClass(themeGlossaryPage.showClass(index)); 38 | $target.append($tpl({ copyLink: t.copy_link }, 'glossary__copy-link')); 39 | }); 40 | }, 41 | 42 | // Show first element is there is no anchor. 43 | showClass: function(index) { 44 | if (index == 0 && themeGlossaryPage.getWindowLocation() == undefined) { 45 | return 'pb-3 term-content collapse show' 46 | } else { 47 | return 'pb-3 term-content collapse' 48 | } 49 | }, 50 | 51 | // Open the right accordion. 52 | // If there is an anchor in url open the first term found. 53 | showRightTerm: function() { 54 | 55 | // If there is an anchor in url open the right accordion. 56 | if( themeGlossaryPage.getWindowLocation() != undefined ) { 57 | var anchor = themeGlossaryPage.getWindowLocation().replace('#' , ''), 58 | $glossaryTarget = $('#glossary-' + anchor); 59 | 60 | // A) Find a real anchor ex: '#glossary-term-btimeam'. 61 | if( $glossaryTarget.length ) { 62 | $('#glossary-' + anchor).collapse('show'); 63 | // call themeSidebarNav to open glossary accordion item 64 | themeSidebarNav.openGlossaryAccordion(); 65 | 66 | var letter = $('#glossary-' + anchor).closest('.section').attr('id'); 67 | // call themeSidebarNav to select nav item 68 | themeSidebarNav.selectCustomItem(letter); 69 | } 70 | 71 | // B) Find a letter anchor ex: '#a'. 72 | // Open the first term of letter. 73 | else if( themeGlossaryPage.getWindowLocation().length == 2 ) { 74 | $("#" + anchor + " dd:nth-of-type(1)").collapse('show'); 75 | } 76 | } 77 | }, 78 | 79 | getWindowLocation: function() { 80 | var location = window.location.href, 81 | hashtagIndex = location.indexOf("#"); 82 | 83 | // Clear previous hashtag 84 | if ( hashtagIndex != -1) { 85 | location = location.substring(hashtagIndex,location.length); 86 | return location 87 | } else { 88 | return undefined 89 | } 90 | } 91 | } 92 | 93 | 94 | })(jQuery); 95 | -------------------------------------------------------------------------------- /js/copy_to_clipboard.js: -------------------------------------------------------------------------------- 1 | // Copy to clipboard 2 | module.exports = themeCopyToClipboard = (function ($) { 3 | var that; 4 | 5 | return { 6 | 7 | $: { 8 | $captionLink: {}, 9 | $navLink: {}, 10 | $glossaryLink: {} 11 | }, 12 | 13 | init: function() { 14 | that = this.$; 15 | var $iconLink = $('.it-link'); 16 | 17 | // Caption 18 | that.$captionLink = $iconLink.closest('.reference.internal'); 19 | that.$captionLink.on('click', themeCopyToClipboard.copyCaption) 20 | 21 | that.$navLink = $iconLink.closest('.chapter-nav__item'); 22 | that.$navLink.on('click', themeCopyToClipboard.copyNav) 23 | 24 | that.$glossaryLink = $('.glossary-page__copy-link'); 25 | that.$glossaryLink.on('click', themeCopyToClipboard.copyGlossaryLink) 26 | }, 27 | 28 | copyCaption: function(event) { 29 | event.preventDefault(); 30 | 31 | var $btn = $(event.target).closest('a'), 32 | location = themeCopyToClipboard.getWindowLocation(), 33 | $span = $btn.find('span'); 34 | 35 | // Add current hashtag 36 | location += $btn.attr('href'); 37 | themeCopyToClipboard.copyToClipboard(location, $span); 38 | }, 39 | 40 | copyNav: function(event) { 41 | event.preventDefault(); 42 | 43 | var $el = $(this).find('.chapter-link'), 44 | $section = $el.closest('.section'), 45 | location = themeCopyToClipboard.getWindowLocation(); 46 | 47 | // Add current hashtag 48 | location += '#' + $section.attr('id'); 49 | themeCopyToClipboard.copyToClipboard(location, $el); 50 | }, 51 | 52 | copyGlossaryLink: function(event) { 53 | event.preventDefault(); 54 | 55 | var $el = $(event.target), 56 | $dt = $el.closest('dd').prev('dt'), 57 | location = themeCopyToClipboard.getWindowLocation(); 58 | 59 | // Add current hashtag 60 | location += '#' + $dt.attr('id'); 61 | themeCopyToClipboard.copyToClipboard(location, $el); 62 | }, 63 | 64 | getWindowLocation: function() { 65 | var location = window.location.href, 66 | hashtagIndex = location.indexOf("#"); 67 | 68 | // Clear previous hashtag 69 | if( hashtagIndex != -1) location = location.substring(0,hashtagIndex); 70 | return location; 71 | }, 72 | 73 | copyToClipboard: function(text, $button) { 74 | if (window.clipboardData && window.clipboardData.setData) { 75 | return clipboardData.setData("Text", text); 76 | 77 | } else if (document.queryCommandSupported && document.queryCommandSupported("copy")) { 78 | var textarea = document.createElement("textarea"); 79 | textarea.textContent = text; 80 | textarea.style.position = "fixed"; 81 | document.body.appendChild(textarea); 82 | textarea.select(); 83 | try { 84 | return document.execCommand("copy"); 85 | } catch (ex) { 86 | return false; 87 | } finally { 88 | document.body.removeChild(textarea) 89 | 90 | $button.html(t.copied_link); 91 | setTimeout(function(){ 92 | $button.html(t.copy_link); 93 | }, 3000); 94 | } 95 | } 96 | } 97 | } 98 | 99 | })(jQuery); 100 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/sidebar_offcanvas.html: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 48 | 49 | 50 | 51 | 81 | -------------------------------------------------------------------------------- /docs_italia_theme/static/images/should.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 8 | 10 | 11 | 12 | 13 | 14 | 15 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /js/sidebar_nav.js: -------------------------------------------------------------------------------- 1 | // Sidebar nav 2 | module.exports = themeSidebarNav = (function ($) { 3 | var that; 4 | 5 | return { 6 | 7 | $: { 8 | $openToggle: $('.navbar-toggler--open'), 9 | $backToggle: $('.navbar-toggler--back'), 10 | $tab: $('.sidebar-tabs'), 11 | $nav: $('.docs-offcanvas-menu'), 12 | $navItem: $('.sidebar-list--wrapper a'), 13 | $currentItem: {} // last menù item selected 14 | }, 15 | 16 | init: function(callback) { 17 | that = this.$; 18 | themeSidebarNav.displayNav(); 19 | themeSidebarNav.addHandler(); 20 | themeSidebarNav.selectNavItemOnLoad(); 21 | themeSidebarNav.selectAccordion(); 22 | }, 23 | 24 | // Offcanvas nav 25 | displayNav: function() { 26 | that.$openToggle.on('click', function () { 27 | that.$tab.addClass('active'); 28 | that.$nav.addClass('active'); 29 | }); 30 | 31 | that.$backToggle.on('click', function() { 32 | that.$tab.removeClass('active'); 33 | that.$nav.removeClass('active'); 34 | }); 35 | }, 36 | 37 | // Select current inten on click ( nav in same page). 38 | addHandler: function() { 39 | that.$navItem.on('click', function(){ 40 | that.$navItem.not($(this)).removeClass('current_item'); 41 | $(this).addClass('current_item'); 42 | 43 | // Close offcanvas on click 44 | if ( $( window ).width() <= 767 ) { 45 | that.$backToggle.trigger('click'); 46 | } 47 | }); 48 | }, 49 | 50 | // Force select menu item, used in js/glossary_page.js. 51 | selectCustomItem: function(id) { 52 | var $item = that.$navItem.filter(function(){ 53 | return $(this).attr('href') == '#' + id 54 | }) 55 | 56 | that.$navItem.not($(this)).removeClass('current_item'); 57 | $item.addClass('current_item'); 58 | }, 59 | 60 | // Select the right current item on page load. 61 | selectNavItemOnLoad: function() { 62 | var location = window.location.href, 63 | hashtagIndex = location.indexOf("#"), 64 | hash = location.substring(hashtagIndex,location.length); 65 | 66 | that.$currentItem = that.$navItem.filter(function(index) { 67 | var item = $(this), 68 | thisHashIndex = item.attr('href').indexOf("#"), 69 | thisHash = item.attr('href').substring(thisHashIndex,thisHashIndex.length); 70 | 71 | return thisHash == hash; 72 | }); 73 | 74 | // Check if item doesn't have hash on url, select the item with href = "#" (
  • ) 75 | if(that.$currentItem.length == 0) { 76 | that.$currentItem = that.$navItem.filter(function(index){ 77 | return $(this).attr('href') == '#' 78 | }) 79 | } 80 | that.$currentItem.addClass('current_item'); 81 | }, 82 | 83 | // Open the right accordion on page loaded, depends on the current item. 84 | selectAccordion: function() { 85 | // Detect desktop accordion. 86 | var $activeList = that.$currentItem.closest('.sidebar-accordion-content'), 87 | 88 | // Detect mobile tab. 89 | $activeListMobile = that.$currentItem.closest('.tab-pane'), 90 | idMobile = $activeListMobile.attr('id'), 91 | $listBtnMobile = $('.sidebar-btn--mobile').filter(function(){ 92 | return $(this).attr('href') == '#' + idMobile 93 | }); 94 | 95 | 96 | if ( $( window ).width() > 768 ) { 97 | $activeList.collapse('show'); 98 | } else { 99 | $listBtnMobile.tab('show'); 100 | } 101 | }, 102 | 103 | // Force opening glossary accordion, used in js/glossary_page.js. 104 | openGlossaryAccordion: function() { 105 | if ( $( window ).width() > 768 ) { 106 | $('#glossary-index').collapse('show'); 107 | } else { 108 | $('#glossary-index-mobile-tab').tab('show'); 109 | } 110 | } 111 | } 112 | 113 | })(jQuery); 114 | -------------------------------------------------------------------------------- /sass/layout/_sidebar.scss: -------------------------------------------------------------------------------- 1 | #desktop-menu { 2 | // See https://abouolia.github.io/sticky-sidebar/#configure-your-css 3 | transform: translate(0, 0); /* For browsers don't support translate3d. */ 4 | transform: translate3d(0, 0, 0); 5 | will-change: position, transform; 6 | padding-bottom: 5rem; 7 | 8 | & > button:first-of-type { 9 | margin-top: 1.5rem; 10 | } 11 | } 12 | 13 | .col--nav { 14 | width: 100%; 15 | 16 | @include media-breakpoint-up(md) { 17 | width: #{$sidebar-width}; 18 | float: left; 19 | border-right: 1px $grey-light-01 solid; 20 | padding-left: 4.5rem; 21 | } 22 | } 23 | 24 | .docs-menu { 25 | // See https://abouolia.github.io/sticky-sidebar/#configure-your-css 26 | will-change: min-height; 27 | display: none; 28 | 29 | @include media-breakpoint-up(md) { 30 | display: block; 31 | } 32 | } 33 | 34 | .docs-offcanvas-menu { 35 | @include media-breakpoint-down(sm) { 36 | transform: translateX(100%); 37 | z-index: 10; 38 | background-color: $white; 39 | transition: transform 0.3s; 40 | transition-timing-function: ease-in-out; 41 | position: fixed; 42 | top: 0; 43 | left: 0; 44 | bottom: 0; 45 | right: 0; 46 | overflow-y: auto; 47 | 48 | &.active { 49 | transform: translateX(0); 50 | } 51 | } 52 | 53 | @include media-breakpoint-up(md) { 54 | display: none; 55 | } 56 | } 57 | 58 | .navbar-toggler--wrap { 59 | position: fixed; 60 | bottom: 0; 61 | left: 0; 62 | right: 0; 63 | z-index: 9; 64 | background-color: $white; 65 | box-shadow: -1px -2px 62px -13px rgba($black, 0.25); 66 | 67 | @include media-breakpoint-up(md) { 68 | display: none; 69 | } 70 | } 71 | 72 | .navbar-toggler { 73 | color: $medium-blue; 74 | padding: 1rem 1rem 1rem 2rem; 75 | } 76 | 77 | .navbar-toggler__chapter { 78 | color: $black; 79 | font-size: 0.8rem; 80 | } 81 | 82 | .sidebar-tabs { 83 | position: fixed; 84 | top: 0; 85 | left: 0; 86 | right: 0; 87 | background-color: $white; 88 | transform: translateX(100%); 89 | transition: transform 0.3s; 90 | transition-timing-function: ease-in-out; 91 | z-index: 11; 92 | box-shadow: -1px -2px 62px -13px rgba($black, 0.25); 93 | 94 | &.active { 95 | transform: translateX(0); 96 | } 97 | 98 | @include media-breakpoint-up(md) { 99 | display: none; 100 | } 101 | } 102 | 103 | .sidebar-btn { 104 | text-transform: uppercase; 105 | color: $medium-blue; 106 | font-weight: 700; 107 | cursor: pointer; 108 | border: 0; 109 | border-bottom: 3px $blue solid; 110 | background: none; 111 | 112 | @include media-breakpoint-up(md) { 113 | border-bottom: 2px $medium-blue-02 solid; 114 | } 115 | 116 | &.sidebar-btn--mobile { 117 | display: inline-block; 118 | font-size: 0.7rem; 119 | text-align: center; 120 | border: 0; 121 | 122 | &.active.show { 123 | border-bottom: 3px $blue solid; 124 | text-decoration: none; 125 | 126 | @include media-breakpoint-up(md) { 127 | border-bottom: 2px $medium-blue-02 solid; 128 | } 129 | } 130 | } 131 | 132 | &.focus--mouse { 133 | border-color: $blue !important; 134 | 135 | @include media-breakpoint-up(md) { 136 | border-color: $medium-blue-02 !important; 137 | } 138 | } 139 | 140 | .it-expand, 141 | .it-collapse { 142 | font-size: 0.6rem; 143 | line-height: 2.5; 144 | } 145 | 146 | .it-expand { 147 | display: inline-block; 148 | } 149 | 150 | .it-collapse { 151 | display: none; 152 | } 153 | 154 | &.collapsed { 155 | .it-expand { 156 | display: none; 157 | } 158 | 159 | .it-collapse { 160 | display: inline-block; 161 | } 162 | } 163 | 164 | @include media-breakpoint-up(md) { 165 | display: block; 166 | width: 100%; 167 | text-align: left; 168 | } 169 | 170 | @include media-breakpoint-down(sm) { 171 | .it-expand, 172 | .it-collapse { 173 | display: none; 174 | } 175 | 176 | &.collapsed { 177 | .it-expand, 178 | .it-collapse { 179 | display: none; 180 | } 181 | } 182 | } 183 | } 184 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/document_modals.html: -------------------------------------------------------------------------------- 1 | 38 | 47 | {# 48 | 78 | #} 79 | -------------------------------------------------------------------------------- /docs_italia_theme/static/images/should_not.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 8 | 14 | 15 | 16 | 17 | 18 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 48 | 49 | 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /sass/base/_icon.scss: -------------------------------------------------------------------------------- 1 | @font-face { 2 | font-family: $docs-font-icon; 3 | src: url('#{$icon-font-path}/docs.eot'); 4 | src: 5 | url('#{$icon-font-path}/docs-italia.eot#iefix') format('embedded-opentype'), 6 | url('#{$icon-font-path}/docs-italia.ttf') format('truetype'), 7 | url('#{$icon-font-path}/docs-italia.woff') format('woff'), 8 | url('#{$icon-font-path}/docs-italia.svg#docs') format('svg'); 9 | font-weight: normal; 10 | font-style: normal; 11 | } 12 | 13 | [class^="docs-icon-"], 14 | [class*=" docs-icon-"] { 15 | /* use !important to prevent issues with browser extensions that change fonts */ 16 | /* stylelint-disable */ 17 | font-family: $docs-font-icon !important; 18 | /* stylelint-enable */ 19 | speak: none; 20 | font-style: normal; 21 | font-weight: normal; 22 | font-variant: normal; 23 | text-transform: none; 24 | line-height: 1; 25 | vertical-align: middle; 26 | color: inherit; 27 | font-size: 1.3rem; 28 | 29 | /* Better Font Rendering =========== */ 30 | -webkit-font-smoothing: antialiased; 31 | -moz-osx-font-smoothing: grayscale; 32 | } 33 | 34 | /* stylelint-disable */ 35 | @function unicode($str) { 36 | @return unquote("\"") + $str + unquote("\""); 37 | } 38 | /* stylelint-enable */ 39 | 40 | .docs-icon-more { 41 | &::before { 42 | content: unicode($docs-icon-more); 43 | } 44 | } 45 | 46 | .docs-icon-expand { 47 | &::before { 48 | content: unicode($docs-icon-expand); 49 | } 50 | } 51 | 52 | .docs-icon-collapse { 53 | &::before { 54 | content: unicode($docs-icon-collapse); 55 | } 56 | } 57 | 58 | .docs-icon-plus { 59 | &::before { 60 | content: unicode($docs-icon-plus); 61 | } 62 | } 63 | 64 | .docs-icon-minus { 65 | &::before { 66 | content: unicode($docs-icon-minus); 67 | } 68 | } 69 | 70 | .docs-icon-document { 71 | &::before { 72 | content: unicode($docs-icon-document); 73 | } 74 | } 75 | 76 | .docs-icon-edit { 77 | &::before { 78 | content: unicode($docs-icon-edit); 79 | } 80 | } 81 | 82 | .docs-icon-download { 83 | &::before { 84 | content: unicode($docs-icon-download); 85 | } 86 | } 87 | 88 | .docs-icon-info { 89 | &::before { 90 | content: unicode($docs-icon-info); 91 | } 92 | } 93 | 94 | .docs-icon-compare { 95 | &::before { 96 | content: unicode($docs-icon-compare); 97 | } 98 | } 99 | 100 | .docs-icon-github { 101 | &::before { 102 | content: unicode($docs-icon-github); 103 | } 104 | } 105 | 106 | .docs-icon-share { 107 | &::before { 108 | content: unicode($docs-icon-share); 109 | } 110 | } 111 | 112 | .docs-icon-search { 113 | &::before { 114 | content: unicode($docs-icon-search); 115 | } 116 | } 117 | 118 | .docs-icon-link { 119 | &::before { 120 | content: unicode($docs-icon-link); 121 | } 122 | } 123 | 124 | .docs-icon-external-link { 125 | &::before { 126 | content: unicode($docs-icon-external-link); 127 | } 128 | } 129 | 130 | .docs-icon-comment { 131 | &::before { 132 | content: unicode($docs-icon-comment); 133 | } 134 | } 135 | 136 | .docs-icon-attention, 137 | .docs-icon-warning { 138 | &::before { 139 | content: unicode($docs-icon-attention); 140 | } 141 | } 142 | 143 | .docs-icon-example { 144 | &::before { 145 | content: unicode($docs-icon-example); 146 | } 147 | } 148 | 149 | .docs-icon-procedure { 150 | &::before { 151 | content: unicode($docs-icon-procedure); 152 | } 153 | } 154 | 155 | .docs-icon-hint { 156 | &::before { 157 | content: unicode($docs-icon-hint); 158 | } 159 | } 160 | 161 | .docs-icon-note { 162 | &::before { 163 | content: unicode($docs-icon-note); 164 | } 165 | } 166 | 167 | .docs-icon-step { 168 | &::before { 169 | content: unicode($docs-icon-step); 170 | } 171 | } 172 | 173 | .docs-icon-pdf { 174 | &::before { 175 | content: unicode($docs-icon-pdf); 176 | } 177 | } 178 | 179 | .docs-icon-html { 180 | &::before { 181 | content: unicode($docs-icon-html); 182 | } 183 | } 184 | 185 | .docs-icon-project { 186 | &::before { 187 | content: unicode($docs-icon-project); 188 | } 189 | } 190 | 191 | .docs-icon-publisher { 192 | &::before { 193 | content: unicode($docs-icon-publisher); 194 | } 195 | } 196 | 197 | .docs-icon-docs { 198 | &::before { 199 | content: unicode($docs-icon-docs); 200 | } 201 | } 202 | 203 | .docs-icon-user { 204 | &::before { 205 | content: unicode($docs-icon-user); 206 | } 207 | } 208 | -------------------------------------------------------------------------------- /docs_italia_theme/static/images/must_not.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 8 | 9 | 10 | 11 | 12 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 61 | 62 | 63 | 64 | 65 | 66 | -------------------------------------------------------------------------------- /js/section_navigation.js: -------------------------------------------------------------------------------- 1 | var $tpl = require('./getTpl'); 2 | 3 | // Section navigation 4 | module.exports = themeSectionNav = (function ($) { 5 | var that; 6 | 7 | return { 8 | 9 | $: { 10 | $title: {}, 11 | $body: $('body'), 12 | $html: $('html'), 13 | $window: $(window) 14 | }, 15 | 16 | init: function() { 17 | that = this.$; 18 | $('.chapter-nav').remove(); 19 | 20 | that.$title = $('.chapter-header.has-nav h1, .chapter-header.has-nav h2, .chapter-header.has-nav h3'), 21 | that.$title.each(function(index) { 22 | var $element = $(this), 23 | title = $element.html(); 24 | themeSectionNav.addNav($element,title); 25 | }); 26 | themeSectionNav.addHandler(); 27 | }, 28 | 29 | // Add navigation markdown, in case of mobile (window width <= 991) the class for bootstrap modal will be applied. 30 | addNav: function(element,title) { 31 | var modalClass = detectCModal(), 32 | modalContentClass = detectCModalContent(), 33 | modalContainerClass = detectCModalContainer(), 34 | nav = $tpl({ 35 | seeActions: t.see_actions, 36 | modalClass: modalClass, 37 | modalContainerClass: modalContainerClass, 38 | modalContentClass: modalContentClass, 39 | title: title, 40 | copyLink: t.copy_link 41 | }, 'section_navigation__nav'); 42 | container = element.closest('.chapter-header'); 43 | container.append(nav); 44 | 45 | function detectCModal(){ 46 | if (Modernizr.touchevents && that.$window.outerWidth() <= 991) { 47 | return 'modal fade '; 48 | } else { 49 | return ''; 50 | } 51 | } 52 | 53 | function detectCModalContent(){ 54 | if (that.$window.outerWidth() <= 991) { 55 | return 'modal-content '; 56 | } else { 57 | return ''; 58 | } 59 | } 60 | 61 | function detectCModalContainer(){ 62 | if (that.$window.outerWidth() <= 991) { 63 | return 'modal-dialog modal-dialog-centered modal-sm '; 64 | } else { 65 | return ''; 66 | } 67 | } 68 | }, 69 | 70 | addHandler: function(element) { 71 | // Display nav on mouseover (desktop) 72 | $('.chapter-header.has-nav').on('mouseover', function() { 73 | if (!Modernizr.touchevents && that.$window.outerWidth() > 992) { 74 | var $nav = $(this).closest('.chapter-header').find('.chapter-nav__list--hidden'), 75 | $wrap = $(this).find('.title-wrap'); 76 | lineHeight = parseInt($(this).find('.title-has-nav').css('line-height'))+2; 77 | 78 | $nav.addClass('active'); 79 | $wrap.addClass('active'); 80 | $wrap.find('.title__background').css('height',lineHeight); 81 | } 82 | }); 83 | 84 | // Close nav on mouseout (desktop) 85 | $('.chapter-header.has-nav').on('mouseout', function() { 86 | if (!Modernizr.touchevents && that.$window.outerWidth() > 992) { 87 | var $nav = $(this).closest('.chapter-header').find('.chapter-nav__list--hidden'), 88 | $wrap = $(this).find('.title-wrap'); 89 | $nav.removeClass('active'); 90 | $wrap.removeClass('active'); 91 | } 92 | }); 93 | 94 | // Display nav on click, dropdown on desktop and modal on mobile/tablet 95 | $('.chapter-link--expand').on('click', function() { 96 | var $nav = $(this).closest('.chapter-header').find('.chapter-nav__list--hidden'), 97 | $wrap = $(this).closest('.chapter-header').find('.title-wrap'), 98 | lineHeight = parseInt($(this).closest('.chapter-header').find('.title-has-nav').css('line-height'))+4; 99 | 100 | if (that.$window.outerWidth() > 992) { 101 | if ($nav.hasClass('active')) { 102 | $nav.removeClass('active'); 103 | $wrap.removeClass('active'); 104 | } 105 | else { 106 | $nav.addClass('active'); 107 | $wrap.addClass('active'); 108 | $wrap.find('.title__background').css('height',lineHeight); 109 | if(that.$window.outerWidth() <= 576) { 110 | that.$body.addClass('no-scroll'); 111 | } 112 | } 113 | } else if (that.$window.outerWidth() <= 991) { 114 | var $modal = $(this).closest('.chapter-nav__wrap').find('.chapter-nav__list--hidden'); 115 | $modal.modal('show') 116 | } 117 | }); 118 | 119 | // Close when body is clicked (desktop) 120 | that.$body.on('click', function(event){ 121 | if (Modernizr.touchevents && that.$window.outerWidth() > 992) { 122 | var $nav = that.$title.closest('.chapter-header').find('.chapter-nav__list--hidden'); 123 | if( !$('.chapter-header').has(event.target).length > 0 ) { 124 | $('.chapter-nav__list--hidden').removeClass('active'); 125 | $('.title-wrap').removeClass('active'); 126 | } 127 | } 128 | }); 129 | } 130 | } 131 | })(jQuery); 132 | -------------------------------------------------------------------------------- /docs_italia_theme/layouts/header.html: -------------------------------------------------------------------------------- 1 |
    2 | 48 | 49 |
    50 |
    51 |
    52 | 55 |
    56 | 67 |
    68 |
    69 | 75 |
    76 | {% if publisher_project %} 77 |
    78 | 79 | {{ t.project }}: 80 | 81 | {{ publisher_project }} 82 | 83 |
    84 | {% endif %} 85 | {% if publisher %} 86 |
    87 | 88 | {{ t.administration }}: 89 | 90 | {{ publisher }} 91 | 92 |
    93 | {% endif %} 94 |
    95 |
    96 |
    97 |
    98 | {% include 'layouts/doc_header.html' %} 99 | -------------------------------------------------------------------------------- /docs_italia_theme/static/images/must.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 8 | 9 | 10 | 11 | 12 | 13 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | # Code of Conduct 2 | 3 | ## 1. Purpose 4 | 5 | A primary goal of Developers Italia is to be inclusive to the largest number of contributors, with the most varied and diverse backgrounds possible. As such, we are committed to providing a friendly, safe and welcoming environment for all, regardless of gender, sexual orientation, ability, ethnicity, socioeconomic status, and religion (or lack thereof). 6 | 7 | This code of conduct outlines our expectations for all those who participate in our community, as well as the consequences for unacceptable behavior. 8 | 9 | We invite all those who participate in Developers Italia to help us create safe and positive experiences for everyone. 10 | 11 | ## 2. Open Source Citizenship 12 | 13 | A supplemental goal of this Code of Conduct is to increase open source citizenship by encouraging participants to recognize and strengthen the relationships between our actions and their effects on our community. 14 | 15 | Communities mirror the societies in which they exist and positive action is essential to counteract the many forms of inequality and abuses of power that exist in society. 16 | 17 | If you see someone who is making an extra effort to ensure our community is welcoming, friendly, and encourages all participants to contribute to the fullest extent, we want to know. 18 | 19 | ## 3. Expected Behavior 20 | 21 | The following behaviors are expected and requested of all community members: 22 | 23 | * Participate in an authentic and active way. In doing so, you contribute to the health and longevity of this community. 24 | * Exercise consideration and respect in your speech and actions. 25 | * Attempt collaboration before conflict. 26 | * Refrain from demeaning, discriminatory, or harassing behavior and speech. 27 | * Be mindful of your surroundings and of your fellow participants. Alert community leaders if you notice a dangerous situation, someone in distress, or violations of this Code of Conduct, even if they seem inconsequential. 28 | * Remember that community event venues may be shared with members of the public; please be respectful to all patrons of these locations. 29 | 30 | ## 4. Unacceptable Behavior 31 | 32 | The following behaviors are considered harassment and are unacceptable within our community: 33 | 34 | * Violence, threats of violence or violent language directed against another person. 35 | * Sexist, racist, homophobic, transphobic, ableist or otherwise discriminatory jokes and language. 36 | * Posting or displaying sexually explicit or violent material. 37 | * Personal insults, particularly those related to gender, sexual orientation, race, religion, or disability. 38 | * Inappropriate photography or recording. 39 | * Inappropriate physical contact. You should have someone’s consent before touching them. 40 | * Unwelcome sexual attention. This includes, sexualized comments or jokes; inappropriate touching, groping, and unwelcomed sexual advances. 41 | * Deliberate intimidation, stalking or following (online or in person). 42 | * Advocating for, or encouraging, any of the above behavior. 43 | * Sustained disruption of community events, including talks and presentations. 44 | 45 | ## 5. Consequences of Unacceptable Behavior 46 | 47 | Unacceptable behavior from any community member, including sponsors and those with decision-making authority, will not be tolerated. 48 | 49 | Anyone asked to stop unacceptable behavior is expected to comply immediately. 50 | 51 | If a community member engages in unacceptable behavior, the community organizers may take any action they deem appropriate, up to and including a temporary ban or permanent expulsion from the community without warning (and without refund in the case of a paid event). 52 | 53 | ## 6. Reporting Guidelines 54 | 55 | If you are subject to or witness unacceptable behavior, or have any other concerns, please notify a community organizer as soon as possible. You can do so by e-mailing coc-report@developers.italia.it. 56 | 57 | Additionally, community organizers are available to help community members engage with local law enforcement or to otherwise help those experiencing unacceptable behavior feel safe. In the context of in-person events, organizers will also provide escorts as desired by the person experiencing distress. 58 | 59 | ## 7. Addressing Grievances 60 | 61 | If you feel you have been falsely or unfairly accused of violating this Code of Conduct, you should notify the managers of Developers Italia with a concise description of your grievance. Your grievance will be handled in accordance with our existing governing policies. 62 | 63 | ## 8. Scope 64 | 65 | We expect all community participants (contributors, paid or otherwise; sponsors; and other guests) to abide by this Code of Conduct in all community venues–online and in-person–as well as in all one-on-one communications pertaining to community business. 66 | 67 | This code of conduct and its related procedures also applies to unacceptable behavior occurring outside the scope of community activities when such behavior has the potential to adversely affect the safety and well-being of community members. 68 | 69 | ## 9. Contact info 70 | 71 | You can reach the managers of Developers Italia at coc-report@developers.italia.it 72 | 73 | ## 10. License and attribution 74 | 75 | This Code of Conduct is distributed under a [Creative Commons Attribution-ShareAlike license](http://creativecommons.org/licenses/by-sa/3.0/). 76 | 77 | Portions of text derived from the [Django Code of Conduct](https://www.djangoproject.com/conduct/) and the [Geek Feminism Anti-Harassment Policy](http://geekfeminism.wikia.com/wiki/Conference_anti-harassment/Policy). 78 | 79 | Retrieved on November 22, 2016 from [http://citizencodeofconduct.org/](http://citizencodeofconduct.org/) 80 | -------------------------------------------------------------------------------- /sass/layout/_comments.scss: -------------------------------------------------------------------------------- 1 | $comment_font_size: 14px; 2 | $comment_line_height: 21px; 3 | $letter_spacing: 0.88px; 4 | 5 | .block-comments { 6 | margin-top: 4.4rem; 7 | padding-bottom: 2rem; 8 | } 9 | 10 | .block-comments__body { 11 | p { 12 | font-family: $font-family-sans-serif; 13 | } 14 | } 15 | 16 | .block-comments__header { 17 | border-bottom-color: $grey !important; 18 | border-top-color: $grey-light-01 !important; 19 | 20 | h6 { 21 | color: $medium-blue; 22 | } 23 | } 24 | 25 | .block-comments__img { 26 | width: 56px; 27 | } 28 | 29 | .block-comments__reply-anchor { 30 | margin-top: -5em; 31 | padding-top: 5em; 32 | } 33 | 34 | .block-comments__logout-link { 35 | display: none; 36 | padding-top: 0.25em; 37 | 38 | &--icon { 39 | position: absolute; 40 | top: 50%; 41 | left: 50%; 42 | transform: translate(-50%, -50%); 43 | color: $red; 44 | text-shadow: 0 0 20px black; 45 | 46 | &:hover { 47 | color: white; 48 | } 49 | } 50 | 51 | &:hover { 52 | text-decoration: none; 53 | } 54 | 55 | &--visible { 56 | display: block; 57 | position: relative; 58 | } 59 | } 60 | 61 | .block-comments__input { 62 | margin-bottom: 1em !important; 63 | } 64 | 65 | .block-comments__toggle-btn { 66 | background: none; 67 | width: 2rem; 68 | height: 2rem; 69 | 70 | .docs-icon-plus, 71 | .docs-icon-minus { 72 | color: $medium-blue; 73 | position: absolute; 74 | top: 50%; 75 | left: 50%; 76 | transform: translate(-50%, -50%); 77 | } 78 | 79 | .docs-icon-plus { 80 | display: none; 81 | } 82 | 83 | &.collapsed { 84 | .docs-icon-plus { 85 | display: block; 86 | } 87 | 88 | .docs-icon-minus { 89 | display: none; 90 | } 91 | } 92 | } 93 | 94 | .block-comments__item-btn { 95 | background: none; 96 | width: 2rem; 97 | height: 1.5rem; 98 | border: 0; 99 | 100 | .it-collapse, 101 | .it-expand { 102 | color: $medium-blue; 103 | } 104 | 105 | .it-expand { 106 | display: none; 107 | } 108 | 109 | &.collapsed { 110 | .it-collapse { 111 | display: none; 112 | } 113 | 114 | .it-expand { 115 | display: inline-block; 116 | } 117 | } 118 | } 119 | 120 | .block-comments__item { 121 | padding-top: 1em; 122 | 123 | &.hidden { 124 | opacity: 0.5; 125 | } 126 | 127 | &.is-new { 128 | background-color: $light-blue; 129 | animation: background-fade-highlight 2s ease-out 1 forwards; 130 | } 131 | } 132 | 133 | .block-comments__content { 134 | word-wrap: break-word; 135 | } 136 | 137 | .block-comments__name { 138 | color: $medium-blue; 139 | font-weight: 400; 140 | font-size: 1rem; 141 | letter-spacing: 0; 142 | } 143 | 144 | .block-comments__date, 145 | .block-comments__role { 146 | font-size: $comment_font_size; 147 | line-height: $comment_line_height; 148 | } 149 | 150 | .block-comments__role { 151 | letter-spacing: $letter_spacing; 152 | } 153 | 154 | .block-comments__paragraph { 155 | font-size: $comment_font_size; 156 | line-height: $comment_line_height; 157 | 158 | a { 159 | text-decoration: underline; 160 | } 161 | } 162 | 163 | .box-comment { 164 | &:not(.sending) { 165 | .loading { 166 | display: none; 167 | } 168 | } 169 | 170 | &.sending { 171 | .loading { 172 | margin-left: 1em; 173 | display: inline-block !important; 174 | position: relative; 175 | overflow: visible; 176 | width: 40px; 177 | z-index: 1; 178 | 179 | &::before { 180 | border: 5px solid $blue !important; 181 | top: 60%; 182 | } 183 | } 184 | } 185 | 186 | position: relative; 187 | width: 100%; 188 | 189 | textarea { 190 | min-height: 5em; 191 | font-weight: normal; 192 | border: 1px $grey-light-01 solid; 193 | border-radius: 5px; 194 | 195 | &:focus { 196 | border: 1px $grey-mid solid; 197 | } 198 | 199 | &::placeholder { 200 | color: $grey; 201 | } 202 | } 203 | 204 | &__login { 205 | display: flex; 206 | border: 1px solid $lightgrey-a2; 207 | border-radius: 5px; 208 | padding: 1em; 209 | } 210 | 211 | &__legend { 212 | font-size: $comment_font_size - 2; 213 | } 214 | 215 | &__user-image { 216 | border-radius: 50%; 217 | position: relative; 218 | height: 56px; 219 | width: 56px; 220 | float: left; 221 | 222 | &--anon { 223 | margin: 0.25em; 224 | margin-right: 0.75em; 225 | background-color: $lightgrey-a1; 226 | } 227 | 228 | i { 229 | position: absolute; 230 | top: 50%; 231 | left: 50%; 232 | transform: translate(-50%, -50%); 233 | } 234 | } 235 | 236 | &__buttons { 237 | float: left; 238 | } 239 | 240 | &__required { 241 | float: right; 242 | 243 | & > span { 244 | font-size: 0.8em; 245 | } 246 | } 247 | 248 | &__submit { 249 | position: relative; 250 | overflow: hidden; 251 | 252 | .loading.no-bg { 253 | display: none; 254 | width: 30px; 255 | height: 0; 256 | content: ' '; 257 | overflow: visible; 258 | margin-bottom: 5px; 259 | margin-left: -15px; 260 | margin-right: 5px; 261 | 262 | &::before { 263 | left: auto; 264 | } 265 | } 266 | 267 | & > div:not(.loading) { 268 | display: inline; 269 | } 270 | } 271 | 272 | &__suggestions { 273 | &__tooltip { 274 | .tooltip__content { 275 | font-style: normal; 276 | padding-left: 1.75em; 277 | font-size: 0.95em; 278 | } 279 | } 280 | } 281 | } 282 | 283 | .missing_permission { 284 | width: 100%; 285 | 286 | &__text { 287 | border: 1px solid $lightgrey-a2; 288 | border-radius: 5px; 289 | padding: 1em; 290 | } 291 | } 292 | 293 | @keyframes background-fade-highlight { 294 | to { 295 | background-color: transparent; 296 | } 297 | } 298 | -------------------------------------------------------------------------------- /demo_docs/Makefile: -------------------------------------------------------------------------------- 1 | # Makefile for Sphinx documentation 2 | # 3 | 4 | # You can set these variables from the command line. 5 | SPHINXOPTS = 6 | SPHINXBUILD = sphinx-build 7 | PAPER = 8 | BUILDDIR = build 9 | 10 | # Internal variables. 11 | PAPEROPT_a4 = -D latex_paper_size=a4 12 | PAPEROPT_letter = -D latex_paper_size=letter 13 | ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source 14 | # the i18n builder cannot share the environment and doctrees with the others 15 | I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source 16 | 17 | .PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest gettext 18 | 19 | help: 20 | @echo "Please use \`make ' where is one of" 21 | @echo " html to make standalone HTML files" 22 | @echo " dirhtml to make HTML files named index.html in directories" 23 | @echo " singlehtml to make a single large HTML file" 24 | @echo " pickle to make pickle files" 25 | @echo " json to make JSON files" 26 | @echo " htmlhelp to make HTML files and a HTML help project" 27 | @echo " qthelp to make HTML files and a qthelp project" 28 | @echo " devhelp to make HTML files and a Devhelp project" 29 | @echo " epub to make an epub" 30 | @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter" 31 | @echo " latexpdf to make LaTeX files and run them through pdflatex" 32 | @echo " text to make text files" 33 | @echo " man to make manual pages" 34 | @echo " texinfo to make Texinfo files" 35 | @echo " info to make Texinfo files and run them through makeinfo" 36 | @echo " gettext to make PO message catalogs" 37 | @echo " changes to make an overview of all changed/added/deprecated items" 38 | @echo " linkcheck to check all external links for integrity" 39 | @echo " doctest to run all doctests embedded in the documentation (if enabled)" 40 | 41 | clean: 42 | -rm -rf $(BUILDDIR)/* 43 | 44 | html: 45 | $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html 46 | @echo 47 | @echo "Build finished. The HTML pages are in $(BUILDDIR)/html." 48 | 49 | dirhtml: 50 | $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml 51 | @echo 52 | @echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml." 53 | 54 | singlehtml: 55 | $(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml 56 | @echo 57 | @echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml." 58 | 59 | pickle: 60 | $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle 61 | @echo 62 | @echo "Build finished; now you can process the pickle files." 63 | 64 | json: 65 | $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json 66 | @echo 67 | @echo "Build finished; now you can process the JSON files." 68 | 69 | htmlhelp: 70 | $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp 71 | @echo 72 | @echo "Build finished; now you can run HTML Help Workshop with the" \ 73 | ".hhp project file in $(BUILDDIR)/htmlhelp." 74 | 75 | qthelp: 76 | $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp 77 | @echo 78 | @echo "Build finished; now you can run "qcollectiongenerator" with the" \ 79 | ".qhcp project file in $(BUILDDIR)/qthelp, like this:" 80 | @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/SphinxRTDthemedemo.qhcp" 81 | @echo "To view the help file:" 82 | @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/SphinxRTDthemedemo.qhc" 83 | 84 | devhelp: 85 | $(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp 86 | @echo 87 | @echo "Build finished." 88 | @echo "To view the help file:" 89 | @echo "# mkdir -p $$HOME/.local/share/devhelp/SphinxRTDthemedemo" 90 | @echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/SphinxRTDthemedemo" 91 | @echo "# devhelp" 92 | 93 | epub: 94 | $(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub 95 | @echo 96 | @echo "Build finished. The epub file is in $(BUILDDIR)/epub." 97 | 98 | latex: 99 | $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex 100 | @echo 101 | @echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex." 102 | @echo "Run \`make' in that directory to run these through (pdf)latex" \ 103 | "(use \`make latexpdf' here to do that automatically)." 104 | 105 | latexpdf: 106 | $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex 107 | @echo "Running LaTeX files through pdflatex..." 108 | $(MAKE) -C $(BUILDDIR)/latex all-pdf 109 | @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex." 110 | 111 | text: 112 | $(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text 113 | @echo 114 | @echo "Build finished. The text files are in $(BUILDDIR)/text." 115 | 116 | man: 117 | $(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man 118 | @echo 119 | @echo "Build finished. The manual pages are in $(BUILDDIR)/man." 120 | 121 | texinfo: 122 | $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo 123 | @echo 124 | @echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo." 125 | @echo "Run \`make' in that directory to run these through makeinfo" \ 126 | "(use \`make info' here to do that automatically)." 127 | 128 | info: 129 | $(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo 130 | @echo "Running Texinfo files through makeinfo..." 131 | make -C $(BUILDDIR)/texinfo info 132 | @echo "makeinfo finished; the Info files are in $(BUILDDIR)/texinfo." 133 | 134 | gettext: 135 | $(SPHINXBUILD) -b gettext $(I18NSPHINXOPTS) $(BUILDDIR)/locale 136 | @echo 137 | @echo "Build finished. The message catalogs are in $(BUILDDIR)/locale." 138 | 139 | changes: 140 | $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes 141 | @echo 142 | @echo "The overview file is in $(BUILDDIR)/changes." 143 | 144 | linkcheck: 145 | $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck 146 | @echo 147 | @echo "Link check complete; look for any errors in the above output " \ 148 | "or in $(BUILDDIR)/linkcheck/output.txt." 149 | 150 | doctest: 151 | $(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest 152 | @echo "Testing of doctests in the sources finished, look at the " \ 153 | "results in $(BUILDDIR)/doctest/output.txt." 154 | -------------------------------------------------------------------------------- /docs_italia_theme/Titillium-LICENSE.txt: -------------------------------------------------------------------------------- 1 | SIL Open Font License 2 | 3 | Copyright (c) 2008-2010, Accademia di Belle Arti di Urbino (www.campivisivi.net|direzione@accademiadiurbino.it), 4 | with Reserved Font Name Titillium. 5 | 6 | N: Luca Antonucci 7 | W: http://www.campivisivi.net 8 | D: Contributor 9 | 10 | N: Paola Bacchiocchi 11 | W: http://www.campivisivi.net 12 | D: Contributor 13 | 14 | N: Simone Bastianelli 15 | W: http://www.campivisivi.net 16 | D: Contributor 17 | 18 | N: Valerio Bosi 19 | W: http://www.campivisivi.net 20 | D: Contributor 21 | 22 | N: Fabio Cecchi 23 | W: http://www.campivisivi.net 24 | D: Contributor 25 | 26 | N: Giulia Di Grusa 27 | W: http://www.campivisivi.net 28 | D: Contributor 29 | 30 | N: Donatella Esposito 31 | W: http://www.campivisivi.net 32 | D: Contributor 33 | 34 | N: Giulia Giordani 35 | W: http://www.campivisivi.net 36 | D: Contributor 37 | 38 | N: Raffaele Mariotti 39 | W: http://www.campivisivi.net 40 | D: Contributor 41 | 42 | N: Leslie Ameto 43 | W: http://www.campivisivi.net 44 | D: Contributor 45 | 46 | N: Elisa Mearelli 47 | W: http://www.campivisivi.net 48 | D: Contributor 49 | 50 | N: Silvia Mengarelli 51 | W: http://www.campivisivi.net 52 | D: Contributor 53 | 54 | N: Roberto Mezzano 55 | W: http://www.campivisivi.net 56 | D: Contributor 57 | 58 | N: Valentina Mingucci 59 | W: http://www.campivisivi.net 60 | D: Contributor 61 | 62 | N: Andrea Monachesi 63 | W: http://www.campivisivi.net 64 | D: Contributor 65 | 66 | N: Manuel Pasini 67 | W: http://www.campivisivi.net 68 | D: Contributor 69 | 70 | N: David Pulga 71 | W: http://www.campivisivi.net 72 | D: Contributor 73 | 74 | N: Luca Silvestri 75 | W: http://www.campivisivi.net 76 | D: Contributor 77 | 78 | N: Paolo Tripodi 79 | W: http://www.campivisivi.net 80 | D: Contributor 81 | 82 | N: Fancesco Zamboni 83 | W: http://www.campivisivi.net 84 | D: Contributor 85 | 86 | N: Giuliano Chimenti 87 | W: http://www.isiaurbino.it 88 | D: Contributor 89 | 90 | N: Francesco Piarulli 91 | W: http://www.isiaurbino.it 92 | D: Contributor 93 | 94 | N: Ivan Abbattista 95 | W: http://www.isiaurbino.it 96 | D: Contributor 97 | 98 | N: Rita Colacicco 99 | W: http://www.isiaurbino.it 100 | D: Contributor 101 | 102 | N: Paolo Mazzetti 103 | W: http://www.scriptype.net 104 | D: Contributor 105 | 106 | N: Claudio Piccinini 107 | W: http://www.tht.it/ 108 | D: Contributor 109 | 110 | N: Luciano Perondi 111 | E: luciano.perondi@campivisivi.net 112 | W: http://www.campivisivi.net 113 | D: Director of progect 114 | 115 | This Font Software is licensed under the SIL Open Font License, Version 1.1. 116 | This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL 117 | 118 | —————————————————————————————- 119 | SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 120 | —————————————————————————————- 121 | 122 | PREAMBLE 123 | The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others. 124 | 125 | The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives. 126 | 127 | DEFINITIONS 128 | “Font Software” refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation. 129 | 130 | “Reserved Font Name” refers to any names specified as such after the copyright statement(s). 131 | 132 | “Original Version” refers to the collection of Font Software components as distributed by the Copyright Holder(s). 133 | 134 | “Modified Version” refers to any derivative made by adding to, deleting, or substituting—in part or in whole—any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment. 135 | 136 | “Author” refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software. 137 | 138 | PERMISSION & CONDITIONS 139 | Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions: 140 | 141 | 1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself. 142 | 143 | 2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user. 144 | 145 | 3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users. 146 | 147 | 4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission. 148 | 149 | 5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software. 150 | 151 | TERMINATION 152 | This license becomes null and void if any of the above conditions are not met. 153 | 154 | DISCLAIMER 155 | THE FONT SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE. 156 | -------------------------------------------------------------------------------- /Gruntfile.js: -------------------------------------------------------------------------------- 1 | module.exports = function(grunt) { 2 | 3 | // load all grunt tasks 4 | require('matchdep').filterDev('grunt-*').forEach(grunt.loadNpmTasks); 5 | 6 | grunt.initConfig({ 7 | 8 | connect: { 9 | server: { 10 | options: { 11 | port: 1919, 12 | base: 'demo_docs/build', 13 | livereload: true, 14 | open: true 15 | } 16 | } 17 | }, 18 | 19 | stylelint: { 20 | dev: { 21 | options: { 22 | failOnError: false 23 | }, 24 | src: ['sass/**/*.scss'] 25 | }, 26 | 27 | build: ['sass/**/*.scss'] 28 | }, 29 | 30 | copy: { 31 | all: { 32 | files: [{ 33 | expand: true, 34 | cwd: 'node_modules/bootstrap-italia/src/icons/font', 35 | src: ['**'], 36 | dest: 'docs_italia_theme/static/font' 37 | }, 38 | { 39 | expand: true, 40 | cwd: 'node_modules/bootstrap-italia/src/icons/css', 41 | src: 'italia-icon-font.css', 42 | dest: 'docs_italia_theme/static/css' 43 | }], 44 | }, 45 | }, 46 | 47 | sass: { 48 | all: { 49 | options: { 50 | style: 'expanded', 51 | loadPath: ['node_modules', '.'] 52 | }, 53 | files: [{ 54 | expand: true, 55 | cwd: 'sass', 56 | src: ['*.scss'], 57 | dest: 'docs_italia_theme/static/css', 58 | ext: '.css' 59 | }] 60 | } 61 | }, 62 | 63 | concat: { 64 | all: { 65 | src: ['docs_italia_theme/static/css/theme.css', 'docs_italia_theme/static/css/italia-icon-font.css'], 66 | dest: 'docs_italia_theme/static/css/theme.css' 67 | }, 68 | }, 69 | 70 | postcss: { 71 | dev: { 72 | options: { 73 | map: { 74 | inline: false, 75 | annotation: 'docs_italia_theme/static/css' 76 | }, 77 | processors: [ 78 | require('pixrem')(), 79 | require('autoprefixer')({browsers: 'last 2 versions'}) 80 | ] 81 | }, 82 | files: [{ 83 | src: 'docs_italia_theme/static/css/theme.css', 84 | dest: 'docs_italia_theme/static/css/theme.css' 85 | }] 86 | }, 87 | 88 | build: { 89 | options: { 90 | map: false, 91 | processors: [ 92 | require('pixrem')(), 93 | require('autoprefixer')({browsers: 'last 2 versions'}), 94 | require('cssnano')() 95 | ] 96 | }, 97 | files: [{ 98 | src: 'docs_italia_theme/static/css/theme.css', 99 | dest: 'docs_italia_theme/static/css/theme.css' 100 | }] 101 | } 102 | }, 103 | 104 | modernizr: { 105 | all: { 106 | 'crawl': false, 107 | 'customTests': [], 108 | 'dest': 'js/modernizr.min.js', 109 | 'tests': [ 110 | 'touchevents' 111 | ], 112 | 'options': [ 113 | 'setClasses' 114 | ], 115 | 'uglify' : true 116 | } 117 | }, 118 | 119 | browserify: { 120 | build: { 121 | options: { 122 | alias: { 123 | 'bootstrap-italia': './node_modules/bootstrap-italia/dist/js/bootstrap-italia.min.js', 124 | 'modernizr': './js/modernizr.min.js' 125 | } 126 | }, 127 | src: ['js/index.js'], 128 | dest: 'docs_italia_theme/static/js/theme.js', 129 | }, 130 | 131 | dev: { 132 | options: { 133 | alias: { 134 | 'bootstrap-italia': './node_modules/bootstrap-italia/dist/js/bootstrap-italia.min.js', 135 | 'modernizr': './js/modernizr.min.js' 136 | }, 137 | browserifyOptions: { 138 | debug: true 139 | } 140 | }, 141 | src: ['js/index.js'], 142 | dest: 'docs_italia_theme/static/js/theme.js', 143 | } 144 | }, 145 | 146 | uglify: { 147 | options: { 148 | mangle: false 149 | }, 150 | all: { 151 | files: { 152 | 'docs_italia_theme/static/js/theme.js': ['docs_italia_theme/static/js/theme.js'] 153 | } 154 | } 155 | }, 156 | 157 | cacheBust: { 158 | all: { 159 | options: { 160 | baseDir: 'docs_italia_theme/', 161 | assets: [ 162 | 'static/css/*.css', 163 | 'static/js/*.js' 164 | ], 165 | deleteOriginals: true 166 | }, 167 | files: [{ 168 | expand: true, 169 | cwd: 'docs_italia_theme/layouts/', 170 | src: ['head.html', 'scripts.html'] 171 | }] 172 | } 173 | }, 174 | 175 | exec: { 176 | build_sphinx: { 177 | cmd: 'sphinx-build demo_docs/source demo_docs/build' 178 | } 179 | }, 180 | 181 | clean: { 182 | build: ['demo_docs/build'], 183 | css: ['docs_italia_theme/static/css/italia-icon-font.css', 'docs_italia_theme/static/css/*.map'] 184 | }, 185 | 186 | watch: { 187 | /* Watch scss files */ 188 | scss: { 189 | files: [ 190 | 'sass/**/*.scss' 191 | ], 192 | tasks: ['stylelint:dev', 'copy', 'sass', 'concat', 'clean:css', 'postcss:dev'] 193 | }, 194 | /* Changes in theme dir rebuild sphinx */ 195 | sphinx: { 196 | files: ['docs_italia_theme/**/*', 'demo_docs/**/*.rst', 'demo_docs/**/*.py'], 197 | tasks: ['clean:build', 'exec:build_sphinx'] 198 | }, 199 | /* JavaScript */ 200 | browserify: { 201 | files: ['js/*.js'], 202 | tasks: ['browserify:dev'] 203 | }, 204 | /* live-reload the demo_docs if sphinx re-builds */ 205 | livereload: { 206 | files: ['demo_docs/build/**/*'], 207 | options: { 208 | livereload: true 209 | } 210 | } 211 | } 212 | }); 213 | 214 | grunt.registerTask('default', [ 215 | 'clean:build', 216 | 'stylelint:dev', 217 | 'copy', 218 | 'sass', 219 | 'concat', 220 | 'clean:css', 221 | 'postcss:dev', 222 | 'modernizr', 223 | 'browserify:dev', 224 | 'exec:build_sphinx', 225 | 'connect', 226 | 'watch' 227 | ]); 228 | 229 | grunt.registerTask('build', [ 230 | 'clean:build', 231 | 'stylelint:build', 232 | 'copy', 233 | 'sass', 234 | 'concat', 235 | 'clean:css', 236 | 'postcss:build', 237 | 'modernizr', 238 | 'browserify:build', 239 | 'uglify', 240 | 'exec:build_sphinx' 241 | ]); 242 | 243 | grunt.registerTask('release', [ 244 | 'clean:build', 245 | 'stylelint:build', 246 | 'copy', 247 | 'sass', 248 | 'concat', 249 | 'clean:css', 250 | 'postcss:build', 251 | 'modernizr', 252 | 'browserify:build', 253 | 'uglify', 254 | 'cacheBust', 255 | 'exec:build_sphinx' 256 | ]); 257 | } 258 | -------------------------------------------------------------------------------- /docs_italia_theme/data/_data/l10n.yml: -------------------------------------------------------------------------------- 1 | it: 2 | code: ita 3 | name: italiano 4 | t: 5 | this: it 6 | locale: it_IT 7 | about_these_documents: Informazioni su questi documenti 8 | active_lang: lingua attiva 9 | cookiebar_accept: Accetto 10 | cookiebar_msg: Questo sito utilizza cookie tecnici, analytics e di terze parti. Proseguendo nella navigazione accetti l’utilizzo dei cookie. 11 | cookiebar_privacy_policy: Cookie policy 12 | copyright: Copyright 13 | documents: Documentazione 14 | download: Scarica 15 | footer_link_privacy_policy: Privacy policy 16 | footer_link_cookies: Cookie policy 17 | footer_link_legal_notes: Note legali 18 | go_to: Vai a 19 | index: Indice 20 | last_updated: Più recenti 21 | most_viewed_this_month: Più visti questo mese 22 | navigation_menu_label: Menu di navigazione 23 | navigation_menu_esc: esci dalla navigazione 24 | search: Cerca 25 | search_form_label: Cerca nel documento 26 | search_form_off: disattiva il form di ricerca 27 | search_form_on: attiva il form di ricerca 28 | search_form_start: avvia la ricerca 29 | search_results: Risultati della ricerca 30 | search_no_results: La tua ricerca non ha prodotto documenti. Assicurati di non aver commesso errori di digitazione. 31 | site_subtitle: Documenti pubblici, digitali. 32 | site_title: Docs Italia 33 | share_msg: condividi 34 | skiplink_goto_content: vai ai contenuti 35 | skiplink_goto_navigation: vai alla navigazione del sito 36 | toggle_menu_label: accedi al menu 37 | version: versione 38 | compare: Confronta 39 | copy_link: copia link 40 | copied_link: link copiato 41 | see_actions: vedi azioni 42 | other_actions: altre azioni 43 | comments: commenti 44 | back_to_text: torna al testo 45 | glossary_empty: informazione non trovata 46 | glossary: glossario 47 | go_to_glossary: vai al glossario 48 | deepening: approfondimento 49 | example: esempio 50 | must: si deve 51 | must_not: non si deve 52 | should: si dovrebbe 53 | should_not: non si dovrebbe 54 | may: si può 55 | use: usa 56 | use_not: non usare 57 | consultation: consultazione 58 | show_more: mostra tutto 59 | show_less: mostra meno 60 | content_index: indice dei contenuti 61 | table_index: indice delle tabelle 62 | figures_index: indice delle figure 63 | figures: figure 64 | tables: tabelle 65 | contents: contenuti 66 | in_consultation: in consultazione 67 | indices_and_glossary: indici e glossario 68 | note: nota 69 | no_description: nessuna descrizione 70 | no_content: nessuna sezione 71 | no_glossary: nessun glossario 72 | no_figures: nessuna figura 73 | no_tables: nessuna tabella 74 | summary: sommario 75 | project: Progetto 76 | administration: Amministrazione 77 | info: Informazioni 78 | related: Documenti correlati 79 | actions: Azioni 80 | tags: Tag 81 | 82 | view_source: Sorgente 83 | 84 | previous: precedente 85 | next: successivo 86 | 87 | in_collaboration_with: in collaborazione con 88 | follow_us: seguici su 89 | 90 | header_link_trasformazione: Piano Triennale 91 | header_link_piattaforme: Piattaforme 92 | header_link_software: Software 93 | header_link_api: API 94 | header_link_community: Le community 95 | header_link_developers: Developers 96 | header_link_design: Designers 97 | header_link_tools: Gli strumenti 98 | header_link_forum: Forum 99 | header_link_docs: Docs 100 | header_link_github: GitHub 101 | header_link_secondary_who_we_are: Chi siamo 102 | header_link_projects: Progetti 103 | header_link_documents: Documenti 104 | header_link_administrations: Amministrazioni 105 | header_link_whatis: Che cos'è 106 | 107 | en: 108 | code: eng 109 | name: english 110 | t: 111 | this: en 112 | locale: en_US 113 | about_these_documents: About these Documents 114 | active_lang: current language 115 | cookiebar_accept: Accept 116 | cookiebar_msg: We are using cookies to provide statistics that help us give you the best experience of our site. By continuing to use the site you are agreeing to our use of cookies. 117 | cookiebar_privacy_policy: Cookie policy 118 | copyright: Copyright 119 | documents: Documents 120 | download: Download 121 | footer_link_privacy_policy: Privacy policy 122 | footer_link_cookies: Cookie policy 123 | footer_link_legal_notes: Legal notes 124 | go_to: Go to 125 | index: Index 126 | last_updated: Last updated 127 | most_viewed_this_month: Most viewed this month 128 | navigation_menu_label: Navigation menu 129 | navigation_menu_esc: exit navigation 130 | search: Search 131 | search_form_label: Search in Document 132 | search_form_off: exit search form 133 | search_form_on: enter search form 134 | search_form_start: start searching 135 | search_results: Search Results 136 | search_no_results: Your search did not match any documents. Please make sure that all words are spelled correctly. 137 | site_subtitle: Public documents, made digital. 138 | site_title: Docs Italia 139 | share_msg: share 140 | skiplinks_goto_content: go to content 141 | skiplinks_goto_navigation: go to site navigation 142 | toggle_menu_label: go to navigation 143 | version: version 144 | compare: Compare 145 | copy_link: copy link 146 | copied_link: copied link 147 | see_actions: see actions 148 | other_actions: other actions 149 | comments: comments 150 | back_to_text: back to the text 151 | glossary_empty: information not found 152 | glossary: glossary 153 | go_to_glossary: vai al glossario 154 | deepening: deepening 155 | example: example 156 | must: must 157 | must_not: must not 158 | should: should 159 | should_not: should not 160 | may: may 161 | use: use 162 | use_not: don't use 163 | consultation: consultation 164 | show_more: show more 165 | show_less: show less 166 | content_index: content index 167 | table_index: table index 168 | figures_index: index of figures 169 | figures: figures 170 | tables: tables 171 | contents: contents 172 | in_consultation: in consultation 173 | indices_and_glossary: indices and glossary 174 | note: note 175 | no_description: no description 176 | no_content: no sections 177 | no_glossary: no glossary 178 | no_figures: no figures 179 | no_tables: no tables 180 | summary: summary 181 | project: Project 182 | administration: Administration 183 | info: About this document 184 | related: Related documents 185 | actions: Actions 186 | tags: Tags 187 | 188 | view_source: Source 189 | 190 | previous: previous 191 | next: next 192 | 193 | in_collaboration_with: in collaboration with 194 | follow_us: follow us on 195 | 196 | header_link_trasformazione: Piano Triennale 197 | header_link_piattaforme: Platforms 198 | header_link_software: Software 199 | header_link_api: API 200 | header_link_community: Communities 201 | header_link_developers: Developers 202 | header_link_design: Designers 203 | header_link_tools: Tools 204 | header_link_forum: Forum 205 | header_link_docs: Docs 206 | header_link_github: GitHub 207 | header_link_projects: Projects 208 | header_link_documents: Documents 209 | header_link_administrations: Administrations 210 | header_link_whatis: What is 211 | -------------------------------------------------------------------------------- /sass/layout/_header.scss: -------------------------------------------------------------------------------- 1 | .header { 2 | font-size: 1rem; 3 | 4 | .navbar-brand { 5 | font-size: 0.889rem; 6 | font-weight: 600; 7 | 8 | a { 9 | text-decoration: none; 10 | } 11 | } 12 | 13 | .navbar .dropdown-toggle::after { 14 | margin: 0 0.2rem; 15 | font-size: 0.7rem; 16 | } 17 | 18 | .nav-item { 19 | margin-left: 0.2rem; 20 | 21 | @include media-breakpoint-up(lg) { 22 | border-left: 0; 23 | margin-left: 0; 24 | } 25 | 26 | &.active { 27 | font-weight: 600; 28 | } 29 | 30 | &:not(.nav-text):not(.nav-item--no-underline):hover, 31 | &:not(.nav-text):not(.nav-item--no-underline).active { 32 | border-left: 0.2rem solid $white; 33 | margin-left: 0; 34 | 35 | @include media-breakpoint-up(lg) { 36 | border-left: 0; 37 | margin-left: 0; 38 | border-bottom: 2px solid $white; 39 | margin-bottom: 0; 40 | } 41 | } 42 | } 43 | } 44 | 45 | .slim-header { 46 | font-size: 0.889rem; 47 | 48 | .navbar-toggler { 49 | .navbar__icon { 50 | font-size: 0.7rem; 51 | line-height: 3em; 52 | display: inline-block; 53 | transform: scaleY(-1); 54 | transition: transform 0.3s; 55 | } 56 | 57 | &.collapsed .navbar__icon { 58 | transform: scaleY(1); 59 | } 60 | 61 | .dropdown-toggle::after { 62 | content: ""; 63 | } 64 | } 65 | 66 | &.navbar .divider { 67 | border-top: 0.05rem solid $medium-blue-01; 68 | padding-right: 1px; 69 | width: 10%; 70 | margin-top: 0.75rem; 71 | margin-bottom: 1rem; 72 | margin-left: 0.2rem; 73 | padding-bottom: 1px; 74 | 75 | &:first-child { 76 | margin-top: 1px; 77 | } 78 | 79 | &.divider--w-100 { 80 | width: 100%; 81 | 82 | @include media-breakpoint-up(lg) { 83 | width: inherit; 84 | } 85 | } 86 | 87 | @include media-breakpoint-up(lg) { 88 | border-top: 0; 89 | width: inherit; 90 | margin-top: inherit; 91 | margin-bottom: inherit; 92 | border-right: 0.05rem solid $medium-blue; 93 | padding-right: 1px; 94 | margin-left: 0; 95 | } 96 | } 97 | } 98 | 99 | .secondary-nav { 100 | font-weight: 600; 101 | 102 | &.secondary-nav--offcanvas { 103 | @include media-breakpoint-down(md) { 104 | transform: translateX(-100%); 105 | z-index: 10; 106 | background-color: $white; 107 | color: $medium-blue; 108 | transition: transform 0.3s; 109 | transition-timing-function: ease-in-out; 110 | position: fixed; 111 | top: 0; 112 | left: 0; 113 | bottom: 0; 114 | right: 25%; 115 | overflow-y: auto; 116 | 117 | &.active { 118 | transform: translateX(0); 119 | } 120 | } 121 | } 122 | 123 | .navbar-nav li { 124 | padding: 0.5rem; 125 | border-bottom: 0.2rem solid transparent; 126 | } 127 | 128 | .nav-item:not(.nav-text):not(.nav-item--no-underline):hover, 129 | .nav-item:not(.nav-text):not(.nav-item--no-underline).active { 130 | border-bottom: 0.2rem solid $white; 131 | } 132 | } 133 | 134 | .article-intro-more .dropdown { 135 | // Modal behaviour 136 | @include media-breakpoint-down(md) { 137 | &.show::before { 138 | content: ''; 139 | width: 100vw; 140 | height: 100%; 141 | position: fixed; 142 | top: 0; 143 | left: 0; 144 | background-color: rgba(0, 0, 0, 0.5); 145 | z-index: 999; 146 | } 147 | } 148 | 149 | .dropdown-toggle::after { 150 | display: none; 151 | } 152 | 153 | .dropdown-menu { 154 | background-color: #fff; 155 | padding: 0.5rem; 156 | margin: 0; 157 | border-radius: 0.2rem; 158 | box-shadow: 2px 2px 8px 0 rgba(0, 0, 0, 0.35); 159 | z-index: 100; 160 | 161 | @include media-breakpoint-down(md) { 162 | position: fixed !important; 163 | z-index: 1001 !important; 164 | top: calc(50% - 140px) !important; 165 | left: calc(50% - 140px) !important; 166 | transform: none !important; 167 | 168 | &::before { 169 | display: none; 170 | } 171 | } 172 | 173 | .dropdown-item { 174 | color: #0073e6; 175 | } 176 | } 177 | } 178 | 179 | .lang-selector .dropdown { 180 | // Modal behaviour 181 | @include media-breakpoint-down(md) { 182 | &.show::before { 183 | content: ''; 184 | width: 100vw; 185 | height: 100%; 186 | position: fixed; 187 | top: 0; 188 | left: 0; 189 | background-color: rgba(0, 0, 0, 0.5); 190 | z-index: 999; 191 | } 192 | } 193 | 194 | .dropdown-menu { 195 | background-color: #fff; 196 | padding: 0.5rem; 197 | margin: 0; 198 | border-radius: 0.2rem; 199 | box-shadow: 2px 2px 8px 0 rgba(0, 0, 0, 0.35); 200 | z-index: 100; 201 | 202 | @include media-breakpoint-down(md) { 203 | position: fixed !important; 204 | z-index: 1001 !important; 205 | top: calc(50% - 80px) !important; 206 | left: calc(50% - 80px) !important; 207 | transform: none !important; 208 | 209 | &::before { 210 | display: none; 211 | } 212 | } 213 | 214 | .dropdown-item { 215 | color: #0073e6; 216 | 217 | &.active, 218 | &:active { 219 | font-weight: 600; 220 | text-decoration: inherit; 221 | background-color: inherit; 222 | } 223 | } 224 | } 225 | } 226 | 227 | // ********************* 228 | 229 | .h1--header { 230 | font-size: 1.333rem; 231 | font-weight: 600; 232 | line-height: 1.2; 233 | letter-spacing: unset; 234 | 235 | @include media-breakpoint-up(sm) { 236 | font-size: 1.8rem; 237 | } 238 | 239 | span { 240 | font-size: 0.7rem; 241 | font-weight: 400; 242 | } 243 | } 244 | 245 | .svg--header { 246 | width: 39px; 247 | height: 36px; 248 | 249 | @include media-breakpoint-up(sm) { 250 | width: 65px; 251 | height: 60px; 252 | } 253 | } 254 | 255 | .h2--header { 256 | font-size: 14px; 257 | font-weight: 300; 258 | letter-spacing: unset; 259 | } 260 | 261 | .docs__document-info { 262 | color: $white; 263 | font-size: 0.9rem; 264 | vertical-align: bottom; 265 | 266 | .docs__document-info__icon { 267 | font-size: 1.2rem; 268 | vertical-align: bottom; 269 | } 270 | 271 | .docs__document-info__ownership { 272 | .docs__document-info__label { 273 | font-size: 0.8rem; 274 | } 275 | 276 | .docs__document-info__icon { 277 | font-size: 1rem; 278 | } 279 | } 280 | } 281 | 282 | .doc-header { 283 | box-shadow: 0 0 120px 0 rgba($black, 0.1); 284 | position: relative; 285 | z-index: 10; 286 | color: $blue; 287 | font-size: 16px; 288 | font-weight: 600; 289 | 290 | // .btn { 291 | // span { 292 | // font-size: 1.3rem; 293 | // display: block; 294 | // } 295 | // } 296 | 297 | // Feature progress-bar 298 | .progress-container { 299 | width: 100%; 300 | height: 0.25rem; 301 | background: $light-blue; 302 | } 303 | 304 | .progress-bar { 305 | height: 0.25rem; 306 | background: $medium-blue; 307 | width: 0%; 308 | } 309 | } 310 | 311 | .docs-italia { 312 | #cerca { 313 | border: 1px $grey solid; 314 | font-size: 0.8rem; 315 | font-weight: 100; 316 | 317 | &::placeholder { 318 | color: $grey; 319 | } 320 | } 321 | } 322 | 323 | .social { 324 | color: $white; 325 | 326 | .social__label { 327 | font-size: 0.95rem; 328 | } 329 | 330 | .social__link { 331 | color: $white; 332 | font-size: 1rem; 333 | 334 | &:hover, 335 | &:active { 336 | text-decoration: none; 337 | } 338 | } 339 | } 340 | 341 | #rtd-search-form { 342 | border: 1px solid #ccc; 343 | 344 | input[type="text"] { 345 | border: none; 346 | height: 100%; 347 | } 348 | 349 | .input-group-append button { 350 | background-color: $white; 351 | 352 | .docs-icon-search { 353 | font-size: 1.2rem; 354 | } 355 | } 356 | } 357 | 358 | #documentInfo .tag { 359 | font-family: $font-family-base; 360 | } 361 | -------------------------------------------------------------------------------- /demo_docs/source/images/piano-triennale.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 21 | 22 | 23 | 24 | 25 | 26 | Group 42 27 | Created with Sketch. 28 | 29 | 30 | 31 | 32 | 33 | 35 | CONTESTO NORMATIVO 36 | PUBBLICHE AMMINISTRAZIONI 37 | INDIRIZZI AGID 38 | 39 | 41 | Legge di stablità 42 | 43 | 44 | 45 | 47 | Strategia 48 | 49 | 50 | 51 | 53 | Fabbisogni 54 | 55 | 56 | 58 | Priorità 59 | 60 | Strategia per la Crescita Digitale 61 | 62 | 64 | Stratega di evoluzione ICT 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | Piano Triennale 115 | 116 | per l’informatica 117 | 118 | nelle PA 119 | 127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | --------------------------------------------------------------------------------