commit a877906e71b315c9edc392383cf80b738084b39b Author: Gilbert Pellegrom Date: Wed Apr 4 14:45:09 2012 +0100 Initial commit. diff --git a/themes/default/font/LICENSE.txt b/themes/default/font/LICENSE.txt new file mode 100644 index 0000000..270e046 --- /dev/null +++ b/themes/default/font/LICENSE.txt @@ -0,0 +1,23 @@ +Icon fonts generator + +## Fontello + + Copyright (C) 2011 by Vitaly Puzrin + + Author: Vitaly Puzrin + License: The MIT License + Homepage: http://fontello.com/ + + + +Font license info + +## Font Awesome + + Copyright (C) 2012 by Dave Gandy + + Author: Dave Gandy + License: SIL OFL 1.1 + Homepage: http://fortawesome.github.com/Font-Awesome/ + + Icons: menu, github-circled ("octocat"), twitter ("birdy"), chat diff --git a/themes/default/font/fontello.eot b/themes/default/font/fontello.eot new file mode 100644 index 0000000..0d93cf8 Binary files /dev/null and b/themes/default/font/fontello.eot differ diff --git a/themes/default/font/fontello.svg b/themes/default/font/fontello.svg new file mode 100644 index 0000000..181dad9 --- /dev/null +++ b/themes/default/font/fontello.svg @@ -0,0 +1,18 @@ + + + +Copyright (C) 2016 by original authors @ fontello.com + + + + + + + + + + + + + + \ No newline at end of file diff --git a/themes/default/font/fontello.ttf b/themes/default/font/fontello.ttf new file mode 100644 index 0000000..fb11489 Binary files /dev/null and b/themes/default/font/fontello.ttf differ diff --git a/themes/default/font/fontello.woff b/themes/default/font/fontello.woff new file mode 100644 index 0000000..d37a536 Binary files /dev/null and b/themes/default/font/fontello.woff differ diff --git a/themes/default/font/fontello.woff2 b/themes/default/font/fontello.woff2 new file mode 100644 index 0000000..38039ce Binary files /dev/null and b/themes/default/font/fontello.woff2 differ diff --git a/themes/default/fontello.css b/themes/default/fontello.css new file mode 100644 index 0000000..e9a005e --- /dev/null +++ b/themes/default/fontello.css @@ -0,0 +1,61 @@ +@font-face { + font-family: 'fontello'; + src: url('font/fontello.eot?13793670'); + src: url('font/fontello.eot?13793670#iefix') format('embedded-opentype'), + url('font/fontello.woff2?13793670') format('woff2'), + url('font/fontello.woff?13793670') format('woff'), + url('font/fontello.ttf?13793670') format('truetype'), + url('font/fontello.svg?13793670#fontello') format('svg'); + font-weight: normal; + font-style: normal; +} +/* Chrome hack: SVG is rendered more smooth in Windozze. 100% magic, uncomment if you need it. */ +/* Note, that will break hinting! In other OS-es font will be not as sharp as it could be */ +/* +@media screen and (-webkit-min-device-pixel-ratio:0) { + @font-face { + font-family: 'fontello'; + src: url('../font/fontello.svg?13793670#fontello') format('svg'); + } +} +*/ + +[class^="icon-"]:before, [class*=" icon-"]:before { + font-family: "fontello"; + font-style: normal; + font-weight: normal; + speak: none; + + display: inline-block; + text-decoration: inherit; + width: 1em; + margin-right: .2em; + text-align: center; + /* opacity: .8; */ + + /* For safety - reset parent styles, that can break glyph codes*/ + font-variant: normal; + text-transform: none; + + /* fix buttons height, for twitter bootstrap */ + line-height: 1em; + + /* Animation center compensation - margins should be symmetric */ + /* remove if not needed */ + margin-left: .2em; + + /* you can be more comfortable with increased icons size */ + /* font-size: 120%; */ + + /* Font smoothing. That was taken from TWBS */ + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + + /* Uncomment for 3D effect */ + /* text-shadow: 1px 1px 1px rgba(127, 127, 127, 0.3); */ +} + +.icon-menu:before { content: '\f0c9'; } /* '' */ +.icon-octocat:before { content: '\f09b'; } /* '' */ +.icon-birdy:before { content: '\f099'; } /* '' */ +.icon-chat:before { content: '\e800'; } /* '' */ diff --git a/themes/default/index.twig b/themes/default/index.twig new file mode 100644 index 0000000..4197e13 --- /dev/null +++ b/themes/default/index.twig @@ -0,0 +1,73 @@ + + + + + + + {% if meta.title %}{{ meta.title }} | {% endif %}{{ site_title }} + {% if meta.description %} + + {% endif %}{% if meta.robots %} + + {% endif %} + + + + + + + + + +
+
+ {{ content }} +
+
+ + + + + + + + + diff --git a/themes/default/js/modernizr-3.3.1-custom.min.js b/themes/default/js/modernizr-3.3.1-custom.min.js new file mode 100644 index 0000000..33ad568 --- /dev/null +++ b/themes/default/js/modernizr-3.3.1-custom.min.js @@ -0,0 +1,3 @@ +/*! modernizr 3.3.1 (Custom Build) | MIT * + * https://modernizr.com/download/?-classlist-csstransitions-requestanimationframe !*/ +!function(e,n,t){function r(e,n){return typeof e===n}function i(){var e,n,t,i,o,s,a;for(var f in y)if(y.hasOwnProperty(f)){if(e=[],n=y[f],n.name&&(e.push(n.name.toLowerCase()),n.options&&n.options.aliases&&n.options.aliases.length))for(t=0;tp;p++)if(v=e[p],h=P.style[v],s(v,"-")&&(v=o(v)),P.style[v]!==t){if(a||r(i,"undefined"))return f(),"pfx"==n?v:!0;try{P.style[v]=i}catch(g){}if(P.style[v]!=h)return f(),"pfx"==n?v:!0}return f(),!1}function v(e,n,t,i,o){var s=e.charAt(0).toUpperCase()+e.slice(1),a=(e+" "+_.join(s+" ")+s).split(" ");return r(n,"string")||r(n,"undefined")?m(a,n,i,o):(a=(e+" "+E.join(s+" ")+s).split(" "),f(a,n,t))}function h(e,n,r){return v(e,t,t,n,r)}var y=[],g={_version:"3.3.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){y.push({name:e,fn:n,options:t})},addAsyncTest:function(e){y.push({name:null,fn:e})}},Modernizr=function(){};Modernizr.prototype=g,Modernizr=new Modernizr;var C=[],w=n.documentElement;Modernizr.addTest("classlist","classList"in w);var x="Moz O ms Webkit",_=g._config.usePrefixes?x.split(" "):[];g._cssomPrefixes=_;var S=function(n){var r,i=prefixes.length,o=e.CSSRule;if("undefined"==typeof o)return t;if(!n)return!1;if(n=n.replace(/^@/,""),r=n.replace(/-/g,"_").toUpperCase()+"_RULE",r in o)return"@"+n;for(var s=0;i>s;s++){var a=prefixes[s],f=a.toUpperCase()+"_"+r;if(f in o)return"@-"+a.toLowerCase()+"-"+n}return!1};g.atRule=S;var E=g._config.usePrefixes?x.toLowerCase().split(" "):[];g._domPrefixes=E;var T="svg"===w.nodeName.toLowerCase(),z={elem:l("modernizr")};Modernizr._q.push(function(){delete z.elem});var P={style:z.elem.style};Modernizr._q.unshift(function(){delete P.style}),g.testAllProps=v;var b=g.prefixed=function(e,n,t){return 0===e.indexOf("@")?S(e):(-1!=e.indexOf("-")&&(e=o(e)),n?v(e,n,t):v(e,"pfx"))};Modernizr.addTest("requestanimationframe",!!b("requestAnimationFrame",e),{aliases:["raf"]}),g.testAllProps=h,Modernizr.addTest("csstransitions",h("transition","all",!0)),i(),delete g.addTest,delete g.addAsyncTest;for(var L=0;L .container > table'); + for (var i = 0; i < tables.length; i++) { + if (!/\btable-responsive\b/.test(tables[i].parentElement.className)) { + var tableWrapper = document.createElement('div'); + tableWrapper.className = 'table-responsive'; + + tables[i].parentElement.insertBefore(tableWrapper, tables[i]); + tableWrapper.appendChild(tables[i]); + } + } + + // responsive menu + var menu = document.getElementById('nav'), + menuToggle = document.getElementById('nav-toggle'), + toggleMenuEvent = function (event) { + if (event.type === 'keydown') { + if ((event.keyCode != 13) && (event.keyCode != 32)) { + return; + } + } + + event.preventDefault(); + + if (menuToggle.getAttribute('aria-expanded') === 'false') { + menuToggle.setAttribute('aria-expanded', 'true'); + utils.slideDown(menu, null, function () { + if (event.type === 'keydown') { + menu.focus(); + } + }); + } else { + menuToggle.setAttribute('aria-expanded', 'false'); + utils.slideUp(menu); + } + }, + onResizeEvent = function () { + if (utils.isElementVisible(menuToggle)) { + menu.className = 'hidden'; + menuToggle.addEventListener('click', toggleMenuEvent); + menuToggle.addEventListener('keydown', toggleMenuEvent); + } else { + menu.className = ''; + menu.removeAttribute('data-slide-id'); + menuToggle.removeEventListener('click', toggleMenuEvent); + menuToggle.removeEventListener('keydown', toggleMenuEvent); + } + }; + + window.addEventListener('resize', onResizeEvent); + onResizeEvent(); +} + +main(); diff --git a/themes/default/js/utils.js b/themes/default/js/utils.js new file mode 100644 index 0000000..3b48911 --- /dev/null +++ b/themes/default/js/utils.js @@ -0,0 +1,135 @@ +/** + * Pico's Default Theme - JavaScript helper + * + * Pico is a stupidly simple, blazing fast, flat file CMS. + * + * @author Daniel Rudolf + * @link http://picocms.org + * @license http://opensource.org/licenses/MIT The MIT License + * @version 2.0 + */ + +utils = {}; + +/** + * Checks whether the client's browser is able to slide elements or not + * + * @return boolean TRUE when the browser supports sliding, FALSE otherwise + */ +utils.canSlide = function () +{ + return (Modernizr.classlist && Modernizr.requestanimationframe && Modernizr.csstransitions); +}; + +/** + * Slides a element up (i.e. hide a element by changing its height to 0px) + * + * @param HTMLElement element the element to slide up + * @param function finishCallback function to call when the animation has + * been finished (i.e. the element is hidden) + * @param function startCallback function to call when the animation starts + * @return void + */ +utils.slideUp = function (element, finishCallback, startCallback) +{ + if (!utils.canSlide()) { + if (startCallback) startCallback(); + element.className += (element.className !== '') ? ' hidden' : 'hidden'; + if (finishCallback) window.requestAnimationFrame(finishCallback); + return; + } + + element.style.height = element.clientHeight + 'px'; + + var slideId = parseInt(element.getAttribute('data-slide-id')) || 0; + element.setAttribute('data-slide-id', ++slideId); + + window.requestAnimationFrame(function () { + element.classList.add('slide'); + + window.requestAnimationFrame(function () { + element.style.height = '0px'; + + if (startCallback) { + startCallback(); + } + + window.setTimeout(function () { + if (parseInt(element.getAttribute('data-slide-id')) !== slideId) return; + + element.classList.add('hidden'); + element.classList.remove('slide'); + element.style.height = null; + + if (finishCallback) { + window.requestAnimationFrame(finishCallback); + } + }, 500); + }); + }); +}; + +/** + * Slides a element down (i.e. show a hidden element) + * + * @param HTMLElement element the element to slide down + * @param function finishCallback function to call when the animation has + * been finished (i.e. the element is visible) + * @param function startCallback function to call when the animation starts + * @return void + */ +utils.slideDown = function (element, finishCallback, startCallback) +{ + if (!utils.canSlide()) { + if (startCallback) startCallback(); + element.className = element.className.replace(/\bhidden\b */g, ''); + if (finishCallback) window.requestAnimationFrame(finishCallback); + return; + } + + var cssRuleOriginalValue = element.clientHeight + 'px', + slideId = parseInt(element.getAttribute('data-slide-id')) || 0; + + element.setAttribute('data-slide-id', ++slideId); + + element.style.height = null; + element.classList.remove('hidden'); + element.classList.remove('slide'); + var cssRuleValue = element.clientHeight + 'px'; + + element.style.height = cssRuleOriginalValue; + + window.requestAnimationFrame(function () { + element.classList.add('slide'); + + window.requestAnimationFrame(function () { + element.style.height = cssRuleValue; + + if (startCallback) { + startCallback(); + } + + window.setTimeout(function () { + if (parseInt(element.getAttribute('data-slide-id')) !== slideId) return; + + element.classList.remove('slide'); + element.style.height = null; + + if (finishCallback) { + window.requestAnimationFrame(finishCallback); + } + }, 500); + }); + }); +}; + +/** + * Checks whether a element is visible or not + * + * @param HTMLElement element the element to check + * @return boolean TRUE when the element is visible, FALSE otherwise + */ +utils.isElementVisible = function (element) +{ + return !!(element.offsetWidth || element.offsetHeight || element.getClientRects().length); +}; diff --git a/themes/default/style.css b/themes/default/style.css new file mode 100644 index 0000000..331ba8b --- /dev/null +++ b/themes/default/style.css @@ -0,0 +1,357 @@ +/** + * Pico's Default Theme + * + * Pico's default theme is a bit bare - but that's intentional! The default + * theme isn't meant for production use, it's actually a template for you to + * design your own theme around. + * + * Pico is a stupidly simple, blazing fast, flat file CMS. + * + * @author Gilbert Pellegrom + * @author Daniel Rudolf + * @link http://picocms.org + * @license http://opensource.org/licenses/MIT The MIT License + * @version 2.0 + */ + +* { + box-sizing: border-box; + border: 0 none; + margin: 0; + padding: 0; +} + +.hidden { display: none !important; } +.sr-only { + position: absolute; + width: 1px; + height: 1px; + padding: 0; + margin: -1px; + overflow: hidden; + clip: rect(0, 0, 0, 0); + border: 0 none; +} + +.slide { + overflow-y: hidden !important; + -webkit-transition: height .5s ease-in !important; + transition: height .5s ease-in !important; +} + +/*** BASIC LAYOUT ***/ + +html, body { height: 100%; } + +body { display: flex; flex-direction: column; } +#main { flex: 1 0 auto; } +#header, #footer { flex: 0 0 auto; } + +#main { + padding: 5em 0 4em; +} + +.container { + max-width: 48em; + padding: 0 0.5em; + margin: 0 auto; +} +.widescreen .container { max-width: 72em; } + +/* very ugly overflow fix, avoid this whenever possible! */ +#main .container { overflow-x: auto; } + +/*** BASIC LAYOUT: HEADER ***/ + +#header { background: #2EAE9B; } + +#header h1 { + float: left; + font-size: 2rem; + margin: 0; + padding: 1.5em 1em 1.5em 0; +} +#header h1 a, #header h1 a:hover { color: #fff; } + +#nav { + text-align: right; + padding: 3em 0; +} +#nav ul { + list-style: none; + margin: 0; + padding: 0; +} +#nav ul li { + display: inline-block; + margin-left: 1em; + padding: 0; + font-weight: bold; +} + +#nav a, #nav-toggle { color: #afe1da; } +#nav .active a, #nav a:hover, #nav-toggle:hover { color: #fff; } + +#nav-toggle { display: none; } + +/* IE8 + IE9 clearfix */ +#header > .container:after { + content: ''; + display: block; + clear: both; +} + +/*** BASIC LAYOUT: FOOTER ***/ + +#footer { + background: #707070; + color: #C0C0C0; +} + +#footer a { color: #ddd; } +#footer a:hover { color: #fff; } + +#footer p { + margin: 0; + padding: 3em 0; +} + +#footer .social { + float: right; + padding: 1.5em 0 1.5em 1em; + font-size: 2rem; +} + +/*** BASIC LAYOUT: EXTRA SMALL DEVICES ***/ + +@media (max-width: 767px) { + #main { padding: 2em 0 1em; } + + #header h1 { + float: none; + padding: 0.5em 0; + } + + #nav { + clear: right; + padding: 0; + } + #nav ul { + padding-bottom: 1em; + } + #nav ul li { + display: block; + margin-left: 0; + text-align: center; + } + #nav ul li a { + display: block; + padding: 0.5em 0; + } + + .js #nav-toggle { + display: block; + float: right; + width: 2em; + margin: 0.6667em 0 0.6667em 1.3333em; + font-size: 1.5rem; + line-height: 2em; + text-align: center; + cursor: pointer; + } + .js #nav-toggle > * { vertical-align: middle; } + + #footer p { padding: 1em 0; } + #footer .social { padding: 0.5em 0 0.5em 1em; } +} + +/*** TYPOGRAPHY ***/ + +html { font-size: 16px; } + +body { + font-family: 'Droid Sans', 'Helvetica', 'Arial', sans-serif; + font-size: 1rem; + line-height: 1.6; + font-variant-ligatures: common-ligatures; + text-rendering: optimizeLegibility; + font-kerning: normal; + color: #444; +} + +p, td, th, li, dd { + text-align: justify; + overflow-wrap: break-word; + word-wrap: break-word; +} + +p, hr, table, .table-responsive, ol, ul, dl, pre, blockquote, fieldset { + margin-bottom: 1em; +} + +a { + color: #2EAE9B; + text-decoration: none; + -webkit-transition: color .2s ease-in; + transition: color .2s ease-in; +} +a:hover { color: #444; } + +h1, h2, h3, h4, h5, h6 { + margin-bottom: 0.6em; + font-weight: bold; + color: #333; +} +h1 { font-size: 2rem; } +h2 { font-size: 1.7rem; } +h3 { font-size: 1.4rem; } +h4 { font-size: 1.1rem; } +h5 { font-size: 1rem; } +h6 { font-size: 1rem; font-weight: normal; font-style: italic; } + +img { max-width: 100%; } + +hr { + border: 0.15em solid #f5f5f5; + border-radius: 0.3em; + background: #f5f5f5; +} + +abbr { text-decoration: underline dotted; } + +/*** TABLES ***/ + +table { border-spacing: 0; } + +td, th { + padding: 0.4em 1em; + vertical-align: top; +} +th { + font-weight: bold; + text-align: center; + background: #f5f5f5; + color: #333; +} + +td, th { border: solid 1px #ccc; } +tr:not(:last-child) td, tr:not(:last-child) th { border-bottom: 0 none; } +thead tr:last-child th { border-bottom: 0 none; } +td:not(:last-child), th:not(:last-child) { border-right: 0 none; } + +tr:first-child td:first-child, tr:first-child th:first-child { border-top-left-radius: 0.3em; } +tr:first-child td:last-child, tr:first-child th:last-child { border-top-right-radius: 0.3em; } +tbody tr:last-child td:first-child { border-bottom-left-radius: 0.3em; } +tbody tr:last-child td:last-child { border-bottom-right-radius: 0.3em; } +table thead + tbody tr:first-child td { border-radius: 0 !important; } + +.table-responsive { overflow-x: auto; } +.table-responsive > table { margin-bottom: 0; } + +/*** LISTS ***/ + +ol, ul { + list-style-position: outside; + padding-left: 1.5em; +} +ol { padding-left: 2.5em; } +li { padding-left: 0.5em; } + +dt { font-weight: bold; } +dd { margin-left: 2em; } + +/*** CODE ***/ + +code { + margin: 0 0.1em; + padding: 0.1em 0.2em; + border: 1px solid #ccc; + border-radius: 0.3em; + background: #f5f5f5; + font-family: 'Droid Sans Mono', 'Courier New', 'Courier', monospace; + font-size: 0.9rem; +} + +pre { + padding: 0 1em; + border: 1px solid #ccc; + border-radius: 0.3em; + background: #f5f5f5; + line-height: 1.4; +} +pre code { + display: block; + margin: 0; + padding: 1.1111em 0; + border: 0 none; + background: transparent; + overflow-x: auto; +} + +/*** BLOCKQUOTE ***/ + +blockquote { + font-style: italic; + margin-left: 1em; + padding-left: 1em; + border-left: 0.5em solid #f5f5f5; +} + +/*** FORMS ***/ + +label, fieldset legend { font-weight: bold; } + +input:not([type="checkbox"]):not([type="radio"]), button, select, textarea, fieldset, fieldset legend { + border: solid 1px #ccc; + border-radius: 0.3em; + background: #fff; + -webkit-transition: none .2s ease-in; + transition: none .2s ease-in; + -webkit-transition-property: border-color, background, box-shadow; + transition-property: border-color, background, box-shadow; +} + +input:not([type="checkbox"]):not([type="radio"]), button, select, textarea { + padding: 0.5em 1em; + outline: 0 none; + font-size: 1rem; +} +input:focus:not([type="checkbox"]):not([type="radio"]), button:focus, select:focus, textarea:focus { + border-color: #2EAE9B; + box-shadow: 0 0 8px #2EAE9B; +} +input[type="button"]:focus, input[type="submit"]:focus, input[type="reset"]:focus, button:focus, +input[type="button"]:hover, input[type="submit"]:hover, input[type="reset"]:hover, button:hover { + background: #f5f5f5; + cursor: pointer; +} + +textarea, select[multiple] { + vertical-align: bottom; + overflow: auto; +} + +fieldset { + padding: 1em; + background: #f5f5f5; +} +fieldset legend { padding: 0 0.5em; } + +fieldset label, fieldset input, fieldset button, +fieldset select, fieldset textarea { + margin: 0.2em 0.5em; +} +fieldset label:first-child, fieldset input:first-child, fieldset button:first-child, +fieldset select:first-child, fieldset textarea:first-child { + margin-left: 0; +} +fieldset label:last-child, fieldset input:last-child, fieldset button:last-child, +fieldset select:last-child, fieldset textarea:last-child { + margin-right: 0; +} + +/* Firefox input size fix */ +input::-moz-focus-inner, button::-moz-focus-inner { + border: 0; + padding: 0; +}